diff options
author | rathnor <rathnor> | 2003-09-14 11:23:48 (GMT) |
---|---|---|
committer | rathnor <rathnor> | 2003-09-14 11:23:48 (GMT) |
commit | f68c15cfa29a3eefc6e209ab1799e4d02c5cce40 (patch) | |
tree | 0b6de6f70343cf3b0b4e755ff3a3c25ff2318657 /src/fluxbox.cc | |
parent | 7a20120bbcba2ff9ca1465bc8d9a9a94b19c3a05 (diff) | |
download | fluxbox-f68c15cfa29a3eefc6e209ab1799e4d02c5cce40.zip fluxbox-f68c15cfa29a3eefc6e209ab1799e4d02c5cce40.tar.bz2 |
focus fixes
Diffstat (limited to 'src/fluxbox.cc')
-rw-r--r-- | src/fluxbox.cc | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/src/fluxbox.cc b/src/fluxbox.cc index d83fe0b..2fbf56b 100644 --- a/src/fluxbox.cc +++ b/src/fluxbox.cc | |||
@@ -22,7 +22,7 @@ | |||
22 | // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER | 22 | // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER |
23 | // DEALINGS IN THE SOFTWARE. | 23 | // DEALINGS IN THE SOFTWARE. |
24 | 24 | ||
25 | // $Id: fluxbox.cc,v 1.190 2003/09/12 22:55:33 fluxgen Exp $ | 25 | // $Id: fluxbox.cc,v 1.191 2003/09/14 11:23:48 rathnor Exp $ |
26 | 26 | ||
27 | #include "fluxbox.hh" | 27 | #include "fluxbox.hh" |
28 | 28 | ||
@@ -852,7 +852,10 @@ void Fluxbox::handleEvent(XEvent * const e) { | |||
852 | } | 852 | } |
853 | } break; | 853 | } break; |
854 | case FocusIn: { | 854 | case FocusIn: { |
855 | if (e->xfocus.mode == NotifyUngrab || | 855 | |
856 | // a grab is something of a pseudo-focus event, so we ignore | ||
857 | // them, here we ignore some window receiving it | ||
858 | if (e->xfocus.mode == NotifyGrab || | ||
856 | e->xfocus.detail == NotifyPointer) | 859 | e->xfocus.detail == NotifyPointer) |
857 | break; | 860 | break; |
858 | 861 | ||
@@ -862,7 +865,7 @@ void Fluxbox::handleEvent(XEvent * const e) { | |||
862 | 865 | ||
863 | } break; | 866 | } break; |
864 | case FocusOut:{ | 867 | case FocusOut:{ |
865 | 868 | // and here we ignore some window losing the special grab focus | |
866 | if (e->xfocus.mode == NotifyUngrab || | 869 | if (e->xfocus.mode == NotifyUngrab || |
867 | e->xfocus.detail == NotifyPointer) | 870 | e->xfocus.detail == NotifyPointer) |
868 | break; | 871 | break; |
@@ -871,6 +874,8 @@ void Fluxbox::handleEvent(XEvent * const e) { | |||
871 | #ifdef DEBUG | 874 | #ifdef DEBUG |
872 | cerr<<__FILE__<<"("<<__FUNCTION__<<") Focus out is not a FluxboxWindow !!"<<endl; | 875 | cerr<<__FILE__<<"("<<__FUNCTION__<<") Focus out is not a FluxboxWindow !!"<<endl; |
873 | #endif // DEBUG | 876 | #endif // DEBUG |
877 | } else if (winclient && winclient == m_focused_window) { | ||
878 | setFocusedWindow(0); | ||
874 | } | 879 | } |
875 | } | 880 | } |
876 | break; | 881 | break; |