diff options
author | Kevin Walzer <kw@codebykevin.com> | 2012-10-02 00:49:25 (GMT) |
---|---|---|
committer | Kevin Walzer <kw@codebykevin.com> | 2012-10-02 00:49:25 (GMT) |
commit | d372dabf08248cddd5705a24c327decd6d5ffefb (patch) | |
tree | 549927193340a734dce34da8094620d4f1d5611a | |
parent | c994b1b0118df67b399a41e1c150cf7ce78283a6 (diff) | |
download | tk-d372dabf08248cddd5705a24c327decd6d5ffefb.zip tk-d372dabf08248cddd5705a24c327decd6d5ffefb.tar.gz tk-d372dabf08248cddd5705a24c327decd6d5ffefb.tar.bz2 |
Fix for 3572016, menus not re-enabling after modal dialog
-rw-r--r-- | macosx/tkMacOSXMenu.c | 6 | ||||
-rw-r--r-- | macosx/tkMacOSXNotify.c | 2 | ||||
-rw-r--r-- | macosx/tkMacOSXSubwindows.c | 2 |
3 files changed, 8 insertions, 2 deletions
diff --git a/macosx/tkMacOSXMenu.c b/macosx/tkMacOSXMenu.c index 8054c57..83ad47a 100644 --- a/macosx/tkMacOSXMenu.c +++ b/macosx/tkMacOSXMenu.c @@ -236,6 +236,12 @@ static int ModifierCharWidth(Tk_Font tkfont); return [menuItem isEnabled]; } +// Workaround for bug 3572016; leaves menu items enabled during modal dialog. +- (BOOL)worksWhenModal +{ + return YES; +} + - (void) tkMenuItemInvoke: (id) sender { /* diff --git a/macosx/tkMacOSXNotify.c b/macosx/tkMacOSXNotify.c index 689f45e..3e0dfde 100644 --- a/macosx/tkMacOSXNotify.c +++ b/macosx/tkMacOSXNotify.c @@ -274,7 +274,7 @@ TkMacOSXEventsCheckProc( TSD_INIT(); if (tsdPtr->currentEvent) { currentEvent = TkMacOSXMakeCollectableAndAutorelease( - tsdPtr->currentEvent); + tsdPtr->currentEvent); } do { modalSession = TkMacOSXGetModalSession(); diff --git a/macosx/tkMacOSXSubwindows.c b/macosx/tkMacOSXSubwindows.c index 8cf8d65..18276fb 100644 --- a/macosx/tkMacOSXSubwindows.c +++ b/macosx/tkMacOSXSubwindows.c @@ -65,7 +65,7 @@ XDestroyWindow( TkMacOSXSelDeadWindow(macWin->winPtr); macWin->toplevel->referenceCount--; - if (!Tk_IsTopLevel(macWin->winPtr)) { + if (!Tk_IsTopLevel(macWin->winPtr) ) { TkMacOSXInvalidateWindow(macWin, TK_PARENT_WINDOW); if (macWin->winPtr->parentPtr != NULL) { TkMacOSXInvalClipRgns((Tk_Window) macWin->winPtr->parentPtr); |