From 47b457541b33f00807fd495f5b0b24d5f143bf84 Mon Sep 17 00:00:00 2001 From: Jeremy Huddleston Date: Sat, 28 Jan 2012 23:11:44 -0800 Subject: [PATCH] XQuartz: Toggle off fullscreen mode when XQuartz is hidden http://xquartz.macosforge.org/trac/ticket/478 Signed-off-by: Jeremy Huddleston --- hw/xquartz/X11Controller.m | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/hw/xquartz/X11Controller.m b/hw/xquartz/X11Controller.m index 01526b7d0..3de4e139d 100644 --- a/hw/xquartz/X11Controller.m +++ b/hw/xquartz/X11Controller.m @@ -773,6 +773,13 @@ objectValueForTableColumn:(NSTableColumn *)tableColumn row:(NSInteger)row - (void) applicationDidHide:(NSNotification *)notify { DarwinSendDDXEvent(kXquartzControllerNotify, 1, AppleWMHideAll); + + /* Toggle off fullscreen mode to leave our non-default video + * mode and hide our guard window. + */ + if (!XQuartzIsRootless && XQuartzFullscreenVisible) { + DarwinSendDDXEvent(kXquartzToggleFullscreen, 0); + } } - (void) applicationDidUnhide:(NSNotification *)notify