Fix OS X nowx.

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7321 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
Soren Jorvang 2011-03-08 23:25:37 +00:00
parent 431f6b596a
commit 610df4ab78
4 changed files with 1697 additions and 1696 deletions

View File

@ -274,6 +274,13 @@ void X11_MainLoop()
int main(int argc, char* argv[]) int main(int argc, char* argv[])
{ {
#ifdef __APPLE__
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
NSEvent *event = [[NSEvent alloc] init];
[NSApplication sharedApplication];
[NSApp activateIgnoringOtherApps: YES];
[NSApp finishLaunching];
#endif
int ch, help = 0; int ch, help = 0;
struct option longopts[] = { struct option longopts[] = {
{ "exec", no_argument, NULL, 'e' }, { "exec", no_argument, NULL, 'e' },
@ -317,12 +324,6 @@ int main(int argc, char* argv[])
if (BootManager::BootCore(argv[optind])) if (BootManager::BootCore(argv[optind]))
{ {
#ifdef __APPLE__ #ifdef __APPLE__
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
NSEvent *event = [[NSEvent alloc] init];
[NSApplication sharedApplication];
[NSApp activateIgnoringOtherApps: YES];
[NSApp finishLaunching];
while (running) while (running)
{ {
event = [NSApp nextEventMatchingMask: NSAnyEventMask event = [NSApp nextEventMatchingMask: NSAnyEventMask