mirror of
https://github.com/kanjitalk755/macemu.git
synced 2024-11-23 04:33:24 +00:00
Sheepshaver: misc, runtime fixes on OSX hosts
This commit is contained in:
parent
e55df3de96
commit
eb36b34106
@ -1556,6 +1556,8 @@ void VideoVBL(void)
|
||||
if (toggle_fullscreen)
|
||||
do_toggle_fullscreen();
|
||||
|
||||
present_sdl_video();
|
||||
|
||||
// Temporarily give up frame buffer lock (this is the point where
|
||||
// we are suspended when the user presses Ctrl-Tab)
|
||||
UNLOCK_FRAME_BUFFER;
|
||||
|
@ -729,7 +729,25 @@ int main(int argc, char **argv)
|
||||
#endif
|
||||
|
||||
// Parse command line arguments
|
||||
|
||||
#if defined(__APPLE__) && defined(__MACH__)
|
||||
// Mac OS X likes to pass in various options of its own, when launching an app.
|
||||
// Attempt to ignore these.
|
||||
for (int i=1; i<argc; i++) {
|
||||
const char * mac_psn_prefix = "-psn_";
|
||||
if (strcmp(argv[i], "-NSDocumentRevisionsDebugMode") == 0) {
|
||||
argv[i] = NULL;
|
||||
} else if (strncmp(mac_psn_prefix, argv[i], strlen(mac_psn_prefix)) == 0) {
|
||||
argv[i] = NULL;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
for (int i=1; i<argc; i++) {
|
||||
if (argv[i] == NULL) {
|
||||
continue;
|
||||
}
|
||||
|
||||
if (strcmp(argv[i], "--help") == 0) {
|
||||
usage(argv[0]);
|
||||
#ifndef USE_SDL_VIDEO
|
||||
@ -754,17 +772,6 @@ int main(int argc, char **argv)
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
#if defined(__APPLE__) && defined(__MACH__)
|
||||
// Mac OS X likes to pass in various options of its own, when launching an app.
|
||||
// Attempt to ignore these.
|
||||
const char * mac_psn_prefix = "-psn_";
|
||||
if (strcmp(argv[i], "-NSDocumentRevisionsDebugMode") == 0) {
|
||||
argv[i] = NULL;
|
||||
} else if (strncmp(mac_psn_prefix, argv[i], strlen(mac_psn_prefix)) == 0) {
|
||||
argv[i] = NULL;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
// Remove processed arguments
|
||||
|
Loading…
Reference in New Issue
Block a user