summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormarkt <markt>2007-01-14 19:02:01 (GMT)
committermarkt <markt>2007-01-14 19:02:01 (GMT)
commitfc502861a45704a8f7cd21282cbccd7e5ac620f3 (patch)
treee23f6a03244fcffb9bd651197bd5d64f7a6c641d
parent6ed9f38b7a6cb4ac85522b9f9c2074342ddffd3f (diff)
downloadfluxbox_lack-fc502861a45704a8f7cd21282cbccd7e5ac620f3.zip
fluxbox_lack-fc502861a45704a8f7cd21282cbccd7e5ac620f3.tar.bz2
make sure we ungrab the keyboard when changing the alt-tab screen,
or else we'll lose an entire keystroke!\
-rw-r--r--ChangeLog2
-rw-r--r--src/fluxbox.cc7
2 files changed, 8 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 166c15c..79e0654 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -9,6 +9,8 @@ Changes for 1.0rc3:
9 - fixed bug with style backgrounds not getting set when changing styles 9 - fixed bug with style backgrounds not getting set when changing styles
10 - updated default styles to be valid wrt background options 10 - updated default styles to be valid wrt background options
11 RootTheme.cc/hh Screen.cc FbTk/Theme.hh 11 RootTheme.cc/hh Screen.cc FbTk/Theme.hh
12 * Minor fix for window cycling on multiple screens (Mark)
13 fluxbox.cc
12*07/01/13: 14*07/01/13:
13 * Only change focus order when user specifically focuses a window (Mark) 15 * Only change focus order when user specifically focuses a window (Mark)
14 Screen.cc Window.cc FocusControl.cc/hh 16 Screen.cc Window.cc FocusControl.cc/hh
diff --git a/src/fluxbox.cc b/src/fluxbox.cc
index e492fb5..89b37fe 100644
--- a/src/fluxbox.cc
+++ b/src/fluxbox.cc
@@ -1129,8 +1129,11 @@ void Fluxbox::handleKeyEvent(XKeyEvent &ke) {
1129 if (!m_key->doAction(ke)) // could still be cycling 1129 if (!m_key->doAction(ke)) // could still be cycling
1130 m_watching_screen = old_watching_screen; 1130 m_watching_screen = old_watching_screen;
1131 else if (old_watching_screen && 1131 else if (old_watching_screen &&
1132 m_watching_screen != old_watching_screen) 1132 m_watching_screen != old_watching_screen) {
1133 old_watching_screen->notifyReleasedKeys(ke); 1133 old_watching_screen->notifyReleasedKeys(ke);
1134 if (!m_watching_screen)
1135 XUngrabKeyboard(FbTk::App::instance()->display(), CurrentTime);
1136 }
1134 break; 1137 break;
1135 case KeyRelease: { 1138 case KeyRelease: {
1136 // we ignore most key releases unless we need to use 1139 // we ignore most key releases unless we need to use
@@ -1852,6 +1855,8 @@ void Fluxbox::watchKeyRelease(BScreen &screen, unsigned int mods) {
1852 1855
1853 // just make sure we are saving the mods with any other flags (xkb) 1856 // just make sure we are saving the mods with any other flags (xkb)
1854 m_watch_keyrelease = FbTk::KeyUtil::instance().isolateModifierMask(mods); 1857 m_watch_keyrelease = FbTk::KeyUtil::instance().isolateModifierMask(mods);
1858 // TODO: it's possible (and happens to me sometimes) for the mods to be
1859 // released before we grab the keyboard -- not sure of a good way to fix it
1855 XGrabKeyboard(FbTk::App::instance()->display(), 1860 XGrabKeyboard(FbTk::App::instance()->display(),
1856 screen.rootWindow().window(), True, 1861 screen.rootWindow().window(), True,
1857 GrabModeAsync, GrabModeAsync, CurrentTime); 1862 GrabModeAsync, GrabModeAsync, CurrentTime);