|
@@ -280,6 +280,9 @@ NativeWindowMac::NativeWindowMac(const gin_helper::Dictionary& options,
|
|
|
std::string windowType;
|
|
|
options.Get(options::kType, &windowType);
|
|
|
|
|
|
+ bool hiddenInMissionControl = false;
|
|
|
+ options.Get(options::kHiddenInMissionControl, &hiddenInMissionControl);
|
|
|
+
|
|
|
bool useStandardWindow = true;
|
|
|
// eventually deprecate separate "standardWindow" option in favor of
|
|
|
// standard / textured window types
|
|
@@ -418,6 +421,8 @@ NativeWindowMac::NativeWindowMac(const gin_helper::Dictionary& options,
|
|
|
options.Get(options::kDisableAutoHideCursor, &disableAutoHideCursor);
|
|
|
[window_ setDisableAutoHideCursor:disableAutoHideCursor];
|
|
|
|
|
|
+ SetHiddenInMissionControl(hiddenInMissionControl);
|
|
|
+
|
|
|
// Set maximizable state last to ensure zoom button does not get reset
|
|
|
// by calls to other APIs.
|
|
|
SetMaximizable(maximizable);
|
|
@@ -1159,9 +1164,17 @@ bool NativeWindowMac::IsDocumentEdited() {
|
|
|
return [window_ isDocumentEdited];
|
|
|
}
|
|
|
|
|
|
+bool NativeWindowMac::IsHiddenInMissionControl() {
|
|
|
+ NSUInteger collectionBehavior = [window_ collectionBehavior];
|
|
|
+ return collectionBehavior & NSWindowCollectionBehaviorTransient;
|
|
|
+}
|
|
|
+
|
|
|
+void NativeWindowMac::SetHiddenInMissionControl(bool hidden) {
|
|
|
+ SetCollectionBehavior(hidden, NSWindowCollectionBehaviorTransient);
|
|
|
+}
|
|
|
+
|
|
|
void NativeWindowMac::SetIgnoreMouseEvents(bool ignore, bool forward) {
|
|
|
[window_ setIgnoresMouseEvents:ignore];
|
|
|
-
|
|
|
if (!ignore) {
|
|
|
SetForwardMouseMessages(NO);
|
|
|
} else {
|