XQuartz: Properly set the menu bar and hotkey state when changing rootless mode.

Currently no code path exhibits the broken behavior since we only toggle into rootless if we don't have the root.
(cherry picked from commit 970f100ca3c5fc0662ae7658d49d118fbd9de943)
This commit is contained in:
Jeremy Huddleston 2009-04-09 04:36:26 -07:00
parent 82d7cf5cdc
commit 8d5dcfe215

View File

@ -352,13 +352,20 @@ void QuartzSetRootless(Bool state) {
/* When in rootless, the menubar is not part of the screen, so we need to update our screens on toggle */ /* When in rootless, the menubar is not part of the screen, so we need to update our screens on toggle */
QuartzUpdateScreens(); QuartzUpdateScreens();
if (!quartzEnableRootless && !quartzHasRoot) { if(!quartzHasRoot) {
if(!quartzEnableRootless) {
RootlessHideAllWindows(); RootlessHideAllWindows();
} else if (quartzEnableRootless && !quartzHasRoot) { } else {
RootlessShowAllWindows(); RootlessShowAllWindows();
} }
}
X11ApplicationShowHideMenubar(!quartzHasRoot);
xp_reenable_update(); xp_reenable_update();
if (!quartzEnableRootless && quartzFullscreenDisableHotkeys)
xp_disable_hot_keys(quartzHasRoot);
} }
/* /*