forked from rosebudai/OpenRCT2-Web
Merge pull request #2801 from LRFLEW/osx-focus
Regain window focus on OS X file dialog close
This commit is contained in:
commit
b5f9fa4bc4
1 file changed
+2
@@ -164,9 +164,11 @@ int platform_open_common_file_dialog(int type, utf8 *title, utf8 *filename, utf8
|
||||
panel.allowedFileTypes = extensions;
|
||||
panel.directoryURL = [NSURL fileURLWithPath:directory];
|
||||
if ([panel runModal] == NSFileHandlingPanelCancelButton){
|
||||
SDL_RaiseWindow(gWindow);
|
||||
return 0;
|
||||
} else {
|
||||
strcpy(filename, panel.URL.path.UTF8String);
|
||||
SDL_RaiseWindow(gWindow);
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user