diff options
author | rathnor <rathnor> | 2003-12-21 15:24:28 (GMT) |
---|---|---|
committer | rathnor <rathnor> | 2003-12-21 15:24:28 (GMT) |
commit | dfdb8219fa74defd4608f3574128f95eb9fcde64 (patch) | |
tree | 02825d7e3375ebb94daf50015928669764c45cb7 /src/fluxbox.cc | |
parent | 8192e8bc2a34d55adae71322362890bace43de72 (diff) | |
download | fluxbox-dfdb8219fa74defd4608f3574128f95eb9fcde64.zip fluxbox-dfdb8219fa74defd4608f3574128f95eb9fcde64.tar.bz2 |
more sloppy focus fixing
Diffstat (limited to 'src/fluxbox.cc')
-rw-r--r-- | src/fluxbox.cc | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/fluxbox.cc b/src/fluxbox.cc index 3808893..3330c8c 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.211 2003/12/21 15:13:00 fluxgen Exp $ | 25 | // $Id: fluxbox.cc,v 1.212 2003/12/21 15:24:28 rathnor Exp $ |
26 | 26 | ||
27 | #include "fluxbox.hh" | 27 | #include "fluxbox.hh" |
28 | 28 | ||
@@ -1946,7 +1946,8 @@ void Fluxbox::revertFocus(BScreen &screen, bool wait_for_end) { | |||
1946 | // when doFocusLast is set, we don't do exact sloppy focus - we | 1946 | // when doFocusLast is set, we don't do exact sloppy focus - we |
1947 | // go to the last focused window, rather than the pointer window | 1947 | // go to the last focused window, rather than the pointer window |
1948 | // i.e. we ignore any EnterNotify events until the focus sending arrives | 1948 | // i.e. we ignore any EnterNotify events until the focus sending arrives |
1949 | ignore_event = EnterNotify; | 1949 | if (screen.getFocusModel() != BScreen::CLICKTOFOCUS) |
1950 | ignore_event = EnterNotify; | ||
1950 | } | 1951 | } |
1951 | 1952 | ||
1952 | // if setting focus fails, or isn't possible, fallback correctly | 1953 | // if setting focus fails, or isn't possible, fallback correctly |
@@ -2004,13 +2005,14 @@ void Fluxbox::addRedirectEvent(BScreen *screen, | |||
2004 | } | 2005 | } |
2005 | 2006 | ||
2006 | // So that an object may remove the ignore on its own | 2007 | // So that an object may remove the ignore on its own |
2008 | // stop_type of None means remove all redirects for this window | ||
2007 | void Fluxbox::removeRedirectEvent(long stop_type, Window stop_win) { | 2009 | void Fluxbox::removeRedirectEvent(long stop_type, Window stop_win) { |
2008 | RedirectEvents::iterator it = m_redirect_events.begin(); | 2010 | RedirectEvents::iterator it = m_redirect_events.begin(); |
2009 | RedirectEvents::iterator it_end = m_redirect_events.end(); | 2011 | RedirectEvents::iterator it_end = m_redirect_events.end(); |
2010 | RedirectEvent *re = 0; | 2012 | RedirectEvent *re = 0; |
2011 | for (; it != it_end; ++it) { | 2013 | for (; it != it_end; ++it) { |
2012 | re = *it; | 2014 | re = *it; |
2013 | if (re->stop_type == re->stop_type && re->stop_win == stop_win) { | 2015 | if (re->stop_win == stop_win && (stop_type == None || stop_type == re->stop_type)) { |
2014 | m_redirect_events.erase(it); | 2016 | m_redirect_events.erase(it); |
2015 | delete re; | 2017 | delete re; |
2016 | return; | 2018 | return; |