aboutsummaryrefslogtreecommitdiffstats
path: root/lib/wx
diff options
context:
space:
mode:
authorDan Gudmundsson <[email protected]>2013-11-29 11:56:02 +0100
committerDan Gudmundsson <[email protected]>2013-11-29 11:56:02 +0100
commit76a1a59d320f3b48c86fe82c6d47c6bfa232196b (patch)
tree1d1cbfbb4393f4f5d418c3673467e1983a9269ba /lib/wx
parent2b27f9ca85a68f44ddab06b386ee25c4e055e353 (diff)
downloadotp-76a1a59d320f3b48c86fe82c6d47c6bfa232196b.tar.gz
otp-76a1a59d320f3b48c86fe82c6d47c6bfa232196b.tar.bz2
otp-76a1a59d320f3b48c86fe82c6d47c6bfa232196b.zip
wx: Fix initialization
The first window didn't get activated when using old method and new wxWidgets-3.0.1.
Diffstat (limited to 'lib/wx')
-rw-r--r--lib/wx/c_src/wxe_ps_init.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/wx/c_src/wxe_ps_init.c b/lib/wx/c_src/wxe_ps_init.c
index 6ec702d18f..d000e242de 100644
--- a/lib/wx/c_src/wxe_ps_init.c
+++ b/lib/wx/c_src/wxe_ps_init.c
@@ -34,7 +34,12 @@ void * wxe_ps_init()
// Enable GUI
if(!GetCurrentProcess(&psn)) {
TransformProcessType(&psn, kProcessTransformToForegroundApplication);
+#ifdef MAC_OS_X_VERSION_10_6
+ [[NSRunningApplication currentApplication] activateWithOptions:
+ (NSApplicationActivateAllWindows | NSApplicationActivateIgnoringOtherApps)];
+#else
SetFrontProcess(&psn);
+#endif
}
return (void *) 0;
}