Merge lp:~3v1n0/compiz/scale-focus-fix into lp:compiz/0.9.11

Proposed by Marco Trevisan (Treviño)
Status: Merged
Approved by: Christopher Townsend
Approved revision: 3836
Merged at revision: 3836
Proposed branch: lp:~3v1n0/compiz/scale-focus-fix
Merge into: lp:compiz/0.9.11
Diff against target: 12 lines (+2/-1)
1 file modified
plugins/scale/src/scale.cpp (+2/-1)
To merge this branch: bzr merge lp:~3v1n0/compiz/scale-focus-fix
Reviewer Review Type Date Requested Status
PS Jenkins bot (community) continuous-integration Approve
Christopher Townsend (community) Approve
Review via email: mp+209274@code.launchpad.net

Commit message

Scale: don't try to re-focus an already focused window

This might make moveInputFocusTo to get stuck on X calls

Description of the change

Scale seems to try to set the input focus on the same window repeatedly when quickly invoked or relayouted, this makes the window to stuck at X calls (not sure if actually it would be better to avoid to try to focus an already focused at global level, always).

To post a comment you must log in.
Revision history for this message
Christopher Townsend (townsend) wrote :

LGTM

review: Approve
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'plugins/scale/src/scale.cpp'
2--- plugins/scale/src/scale.cpp 2014-02-17 03:06:55 +0000
3+++ plugins/scale/src/scale.cpp 2014-03-04 14:35:09 +0000
4@@ -1487,7 +1487,8 @@
5 lastActiveNum = focus->activeNum ();
6 lastActiveWindow = focus->id ();
7
8- focus->moveInputFocusTo ();
9+ if (!focus->focused ())
10+ focus->moveInputFocusTo ();
11 }
12 }
13

Subscribers

People subscribed via source and target branches