summaryrefslogtreecommitdiff
path: root/platform
diff options
context:
space:
mode:
authorbruvzg <7645683+bruvzg@users.noreply.github.com>2022-02-08 13:22:03 +0200
committerbruvzg <7645683+bruvzg@users.noreply.github.com>2022-02-08 13:22:03 +0200
commit720fbe310112521663d3d04bb3ebda7623a9d158 (patch)
tree8f1f1c7a80da75b8a814d6843a27fbec32b212cd /platform
parentf425d403fe8be16b1a5dafbdce4dce546bdd28a4 (diff)
[macOS] Fix NO_FOCUS macOS flag.
Diffstat (limited to 'platform')
-rw-r--r--platform/osx/display_server_osx.mm1
-rw-r--r--platform/osx/godot_window.mm4
2 files changed, 3 insertions, 2 deletions
diff --git a/platform/osx/display_server_osx.mm b/platform/osx/display_server_osx.mm
index ba10d7593f..2691664b96 100644
--- a/platform/osx/display_server_osx.mm
+++ b/platform/osx/display_server_osx.mm
@@ -125,6 +125,7 @@ DisplayServerOSX::WindowID DisplayServerOSX::_create_window(WindowMode p_mode, V
backing:NSBackingStoreBuffered
defer:NO];
ERR_FAIL_COND_V_MSG(wd.window_object == nil, INVALID_WINDOW_ID, "Can't create a window");
+ [wd.window_object setWindowID:window_id_counter];
wd.window_view = [[GodotContentView alloc] init];
ERR_FAIL_COND_V_MSG(wd.window_view == nil, INVALID_WINDOW_ID, "Can't create a window view");
diff --git a/platform/osx/godot_window.mm b/platform/osx/godot_window.mm
index e392cfb384..772a2ddb9f 100644
--- a/platform/osx/godot_window.mm
+++ b/platform/osx/godot_window.mm
@@ -45,7 +45,7 @@
}
- (BOOL)canBecomeKeyWindow {
- // Required for NSBorderlessWindowMask windows.
+ // Required for NSWindowStyleMaskBorderless windows.
DisplayServerOSX *ds = (DisplayServerOSX *)DisplayServer::get_singleton();
if (!ds || !ds->has_window(window_id)) {
return YES;
@@ -56,7 +56,7 @@
}
- (BOOL)canBecomeMainWindow {
- // Required for NSBorderlessWindowMask windows.
+ // Required for NSWindowStyleMaskBorderless windows.
DisplayServerOSX *ds = (DisplayServerOSX *)DisplayServer::get_singleton();
if (!ds || !ds->has_window(window_id)) {
return YES;