diff options
author | Timothy Pearson <[email protected]> | 2014-11-29 00:33:46 -0600 |
---|---|---|
committer | Timothy Pearson <[email protected]> | 2014-11-29 00:34:07 -0600 |
commit | 17b142dd646ce4053f4548c0ff7b189531219c32 (patch) | |
tree | f1cdf93b01b4c76d8d9e5079d64c2a27b442cc98 /twin/client.cpp | |
parent | 2f7d50c20cebb33745c0ecea5a5b6cc3f4747d6e (diff) | |
download | tdebase-17b142dd646ce4053f4548c0ff7b189531219c32.tar.gz tdebase-17b142dd646ce4053f4548c0ff7b189531219c32.zip |
Send setActive signal when taking focus in Client::takeFocus
This relates to Bug 2189
Clean up minor formatting issues
Diffstat (limited to 'twin/client.cpp')
-rw-r--r-- | twin/client.cpp | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/twin/client.cpp b/twin/client.cpp index f32c5064b..4d26bb816 100644 --- a/twin/client.cpp +++ b/twin/client.cpp @@ -612,7 +612,7 @@ void Client::hideClient( bool hide ) hidden = hide; updateVisibility(); } - + /*! Returns whether the window is minimizable or not */ @@ -2200,9 +2200,13 @@ void Client::takeFocus( allowed_t ) if ( rules()->checkAcceptFocus( input )) { XSetInputFocus( tqt_xdisplay(), window(), RevertToPointerRoot, GET_QT_X_TIME() ); + // Signal that we took focus! + setActive( true, true ); } if ( Ptakefocus ) + { sendClientMessage(window(), atoms->wm_protocols, atoms->wm_take_focus); + } workspace()->setShouldGetFocus( this ); } @@ -2745,7 +2749,7 @@ void Client::autoRaise() workspace()->raiseClient( this ); cancelAutoRaise(); } - + void Client::cancelAutoRaise() { delete autoRaiseTimer; @@ -2773,7 +2777,7 @@ void Client::setOpacity(bool translucent, uint opacity) XChangeProperty(tqt_xdisplay(), window(), atoms->net_wm_window_opacity, XA_CARDINAL, 32, PropModeReplace, (unsigned char *) &data, 1L); } } - + void Client::setShadowSize(uint shadowSize) { // ignoring all individual settings - if we control a window, we control it's shadow @@ -2781,7 +2785,7 @@ void Client::setShadowSize(uint shadowSize) long data = shadowSize; XChangeProperty(tqt_xdisplay(), frameId(), atoms->net_wm_window_shadow, XA_CARDINAL, 32, PropModeReplace, (unsigned char *) &data, 1L); } - + void Client::updateOpacity() // extra syncscreen flag allows to avoid double syncs when active state changes (as it will usually change for two windows) { |