diff options
author | Jeremy Huddleston <jeremyhu@freedesktop.org> | 2008-12-21 20:40:36 -0800 |
---|---|---|
committer | Jeremy Huddleston <jeremyhu@freedesktop.org> | 2008-12-21 20:40:36 -0800 |
commit | 508aa95bc2cd3fdc3dff448ec090919bf807d153 (patch) | |
tree | 1bd002596a5a5b2bee11c35bd16689d37f394d98 | |
parent | 67455e716e3ecffd528930479192785958d37988 (diff) |
XQuartz: Update our "screens" when we toggle rootless rather than when we toggle fullscreen
This old behavior was used as a workaround for the menubar behavior in the older server,
but we handle it better now and need to update our screens when we toggle the rootless
state instead.
-rw-r--r-- | hw/xquartz/quartz.c | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/hw/xquartz/quartz.c b/hw/xquartz/quartz.c index a2cccd62b..7fc68d868 100644 --- a/hw/xquartz/quartz.c +++ b/hw/xquartz/quartz.c | |||
@@ -332,16 +332,9 @@ void QuartzSetFullscreen(Bool state) { | |||
332 | if (quartzHasRoot && !quartzEnableRootless) | 332 | if (quartzHasRoot && !quartzEnableRootless) |
333 | RootlessShowAllWindows (); | 333 | RootlessShowAllWindows (); |
334 | 334 | ||
335 | /* Only update screen info when something is visible. Avoids the wm | ||
336 | * moving the windows out from under the menubar when it shouldn't | ||
337 | */ | ||
338 | if (quartzHasRoot || quartzEnableRootless) | ||
339 | QuartzUpdateScreens(); | ||
340 | |||
341 | /* Somehow the menubar manages to interfere with our event stream | 335 | /* Somehow the menubar manages to interfere with our event stream |
342 | * in fullscreen mode, even though it's not visible. | 336 | * in fullscreen mode, even though it's not visible. |
343 | */ | 337 | */ |
344 | |||
345 | X11ApplicationShowHideMenubar(!quartzHasRoot); | 338 | X11ApplicationShowHideMenubar(!quartzHasRoot); |
346 | 339 | ||
347 | xp_reenable_update (); | 340 | xp_reenable_update (); |
@@ -355,7 +348,10 @@ void QuartzSetRootless(Bool state) { | |||
355 | return; | 348 | return; |
356 | 349 | ||
357 | quartzEnableRootless = state; | 350 | quartzEnableRootless = state; |
358 | 351 | ||
352 | /* When in rootless, the menubar is not part of the screen, so we need to update our screens on toggle */ | ||
353 | QuartzUpdateScreens(); | ||
354 | |||
359 | if (!quartzEnableRootless && !quartzHasRoot) { | 355 | if (!quartzEnableRootless && !quartzHasRoot) { |
360 | xp_disable_update(); | 356 | xp_disable_update(); |
361 | RootlessHideAllWindows(); | 357 | RootlessHideAllWindows(); |
@@ -363,7 +359,6 @@ void QuartzSetRootless(Bool state) { | |||
363 | } else if (quartzEnableRootless && !quartzHasRoot) { | 359 | } else if (quartzEnableRootless && !quartzHasRoot) { |
364 | xp_disable_update(); | 360 | xp_disable_update(); |
365 | RootlessShowAllWindows(); | 361 | RootlessShowAllWindows(); |
366 | QuartzUpdateScreens(); | ||
367 | xp_reenable_update(); | 362 | xp_reenable_update(); |
368 | } | 363 | } |
369 | } | 364 | } |