summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam Spilsbury <sam.spilsbury@canonical.com>2011-02-19 01:25:14 +0800
committerSam Spilsbury <sam.spilsbury@canonical.com>2011-02-19 01:25:14 +0800
commit55997d7b3d8863212006e87c6780d522b9a0b5ea (patch)
tree2cc662501ad6699cb68a328f582791abd2ee189a
parent90ba08b759121a54be07fa70e0cf824b966cd0b9 (diff)
downloadstaticswitcher-55997d7b3d8863212006e87c6780d522b9a0b5ea.tar.gz
staticswitcher-55997d7b3d8863212006e87c6780d522b9a0b5ea.tar.bz2
Map and unmap switcher directly
-rw-r--r--src/staticswitcher.cpp22
1 files changed, 2 insertions, 20 deletions
diff --git a/src/staticswitcher.cpp b/src/staticswitcher.cpp
index 726f406..988ae09 100644
--- a/src/staticswitcher.cpp
+++ b/src/staticswitcher.cpp
@@ -291,16 +291,10 @@ StaticSwitchScreen::createPopup ()
bool
StaticSwitchScreen::showPopup ()
{
- CompWindow *w;
-
/* Always checks for an existing popup */
createPopup ();
- w = ::screen->findWindow (popupWindow);
- if (w && (w->state () & CompWindowStateHiddenMask))
- w->show ();
- else
- XMapWindow (::screen->dpy (), popupWindow);
+ XMapWindow (::screen->dpy (), popupWindow);
cScreen->damageScreen ();
@@ -427,23 +421,11 @@ switchTerminate (CompAction *action,
if (ss->grabIndex)
{
- CompWindow *w;
-
if (ss->popupDelayTimer.active ())
ss->popupDelayTimer.stop ();
if (ss->popupWindow)
- {
- w = ::screen->findWindow (ss->popupWindow);
- if (w && w->managed () && w->mapNum ())
- {
- w->hide ();
- }
- else
- {
- XUnmapWindow (::screen->dpy (), ss->popupWindow);
- }
- }
+ XUnmapWindow (::screen->dpy (), ss->popupWindow);
ss->switching = false;