diff options
author | culler <culler> | 2019-02-18 18:48:45 (GMT) |
---|---|---|
committer | culler <culler> | 2019-02-18 18:48:45 (GMT) |
commit | 26f086b4be1a8a8a559d080ece2f257b19763c17 (patch) | |
tree | dd64b09bc862e86a461e1924898ac6a5bb7e23c6 /macosx/tkMacOSXInit.c | |
parent | 467268bf38ec0cab6e8c5cc66e44f6953f13b684 (diff) | |
download | tk-26f086b4be1a8a8a559d080ece2f257b19763c17.zip tk-26f086b4be1a8a8a559d080ece2f257b19763c17.tar.gz tk-26f086b4be1a8a8a559d080ece2f257b19763c17.tar.bz2 |
Fix bug [56a1823c73]: Aqua toplevels can fail to appear on screen.
Diffstat (limited to 'macosx/tkMacOSXInit.c')
-rw-r--r-- | macosx/tkMacOSXInit.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/macosx/tkMacOSXInit.c b/macosx/tkMacOSXInit.c index 9d4d487..e1d56fa 100644 --- a/macosx/tkMacOSXInit.c +++ b/macosx/tkMacOSXInit.c @@ -122,7 +122,17 @@ static char scriptPath[PATH_MAX + 1] = ""; * method is called. Activating too early can cause the menu * bar to be unresponsive. */ + [NSApp activateIgnoringOtherApps: YES]; + + /* + * Process events to ensure that the root window is fully + * initialized. See ticket 56a1823c73. + */ + + [NSApp _lockAutoreleasePool]; + while (Tcl_DoOneEvent(TCL_WINDOW_EVENTS| TCL_DONT_WAIT)) {} + [NSApp _unlockAutoreleasePool]; } - (void) _setup: (Tcl_Interp *) interp |