diff options
author | simonb <simonb> | 2006-04-19 06:55:14 (GMT) |
---|---|---|
committer | simonb <simonb> | 2006-04-19 06:55:14 (GMT) |
commit | 853b0340373b81110c151e97189dea16938d3dd9 (patch) | |
tree | 6358647bc2057d40fa0fe93a99dec32088e37091 /src | |
parent | 759ca9e6b5103c5589d4d5db3883fd34801cb1bf (diff) | |
download | fluxbox_paul-853b0340373b81110c151e97189dea16938d3dd9.zip fluxbox_paul-853b0340373b81110c151e97189dea16938d3dd9.tar.bz2 |
mouse focus fixes - thanks Scott Kuhl: skuhl AT cs utah edu
Diffstat (limited to 'src')
-rw-r--r-- | src/FocusControl.hh | 1 | ||||
-rw-r--r-- | src/Window.cc | 4 |
2 files changed, 3 insertions, 2 deletions
diff --git a/src/FocusControl.hh b/src/FocusControl.hh index 0d9cd05..65363dd 100644 --- a/src/FocusControl.hh +++ b/src/FocusControl.hh | |||
@@ -82,6 +82,7 @@ public: | |||
82 | void dirFocus(FluxboxWindow &win, FocusDir dir); | 82 | void dirFocus(FluxboxWindow &win, FocusDir dir); |
83 | bool isMouseFocus() const { return focusModel() == MOUSEFOCUS; } | 83 | bool isMouseFocus() const { return focusModel() == MOUSEFOCUS; } |
84 | bool isMouseTabFocus() const { return tabFocusModel() == MOUSETABFOCUS; } | 84 | bool isMouseTabFocus() const { return tabFocusModel() == MOUSETABFOCUS; } |
85 | bool isCycling() const { return m_cycling_focus; } | ||
85 | void addFocusFront(WinClient &client); | 86 | void addFocusFront(WinClient &client); |
86 | void addFocusBack(WinClient &client); | 87 | void addFocusBack(WinClient &client); |
87 | 88 | ||
diff --git a/src/Window.cc b/src/Window.cc index e766cab..4ced1c6 100644 --- a/src/Window.cc +++ b/src/Window.cc | |||
@@ -2662,7 +2662,7 @@ void FluxboxWindow::buttonPressEvent(XButtonEvent &be) { | |||
2662 | frame().buttonPressEvent(be); | 2662 | frame().buttonPressEvent(be); |
2663 | 2663 | ||
2664 | if (be.button == 1 || (be.button == 3 && be.state == Mod1Mask)) { | 2664 | if (be.button == 1 || (be.button == 3 && be.state == Mod1Mask)) { |
2665 | if ((! focused) && (! screen().focusControl().isMouseFocus())) { //check focus | 2665 | if ( (! focused) ) { //check focus |
2666 | setInputFocus(); | 2666 | setInputFocus(); |
2667 | } | 2667 | } |
2668 | 2668 | ||
@@ -3024,7 +3024,7 @@ void FluxboxWindow::enterNotifyEvent(XCrossingEvent &ev) { | |||
3024 | sa.enter = sa.leave = False; | 3024 | sa.enter = sa.leave = False; |
3025 | XCheckIfEvent(display, &dummy, queueScanner, (char *) &sa); | 3025 | XCheckIfEvent(display, &dummy, queueScanner, (char *) &sa); |
3026 | 3026 | ||
3027 | if ((!sa.leave || sa.inferior)) { | 3027 | if ((!sa.leave || sa.inferior) && !screen().focusControl().isCycling() ) { |
3028 | setInputFocus(); | 3028 | setInputFocus(); |
3029 | } | 3029 | } |
3030 | } | 3030 | } |