1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-04 12:00:25 +00:00

macOS: Embedded window can be dismissed by clicking close

- Installed a SIGINT handler to terminate the application gracefully.
- Handle varying display scaling
This commit is contained in:
Stuart Carnie
2025-05-08 18:51:28 +10:00
parent 19bb18716e
commit f658161619
12 changed files with 144 additions and 70 deletions

View File

@@ -1399,9 +1399,12 @@ Error Main::setup(const char *execpath, int argc, char *argv[], bool p_second_ph
display_driver = NULL_DISPLAY_DRIVER;
} else if (arg == "--embedded") { // Enable embedded mode.
#ifdef MACOS_ENABLED
display_driver = EMBEDDED_DISPLAY_DRIVER;
#else
OS::get_singleton()->print("--embedded is only supported on macOS, aborting.\n");
goto error;
#endif
} else if (arg == "--log-file") { // write to log file
if (N) {