Merge lp://qastaging/~3v1n0/unity/focused-non-top-windows-fix into lp://qastaging/unity

Proposed by Marco Trevisan (Treviño)
Status: Merged
Approved by: Marco Trevisan (Treviño)
Approved revision: no longer in the source branch.
Merged at revision: 2344
Proposed branch: lp://qastaging/~3v1n0/unity/focused-non-top-windows-fix
Merge into: lp://qastaging/unity
Diff against target: 237 lines (+116/-43)
6 files modified
manual-tests/Launcher.txt (+23/-0)
plugins/unityshell/src/BamfLauncherIcon.cpp (+53/-43)
plugins/unityshell/src/PluginAdapter.cpp (+33/-0)
plugins/unityshell/src/PluginAdapter.h (+1/-0)
plugins/unityshell/src/WindowManager.cpp (+5/-0)
plugins/unityshell/src/WindowManager.h (+1/-0)
To merge this branch: bzr merge lp://qastaging/~3v1n0/unity/focused-non-top-windows-fix
Reviewer Review Type Date Requested Status
Tim Penhey (community) Approve
Alex Launi (community) quality Needs Fixing
Review via email: mp+102958@code.qastaging.launchpad.net

Commit message

BamfLauncherIcon: Focus an application if no child window is actually on top of the stack. Raises all urgent windows.

This fixes bug #802816 that happens when an application raises a window on the top of the stack but the focus doesn't change.

Plus, don't perform unneeded checks when focusing non-active applications.

Description of the change

When a launcher icon is clicked, it should focus a window if the window is currently not on top of the stack (excluding from that the unity or other invalid windows).
To do that I've implemented a new method into PluginAdapter that checks if a Window is on top.

Also, when activating a launcher icon, we should always raise all the urgent windows, not only the top one.

Added manual tests, due to the fact that AP at the moment can't create such kind of windows on the fly.

To post a comment you must log in.
Revision history for this message
Alex Launi (alexlauni) wrote :

This is autopilot testable. Start gimp, execute gimp foo-image.png (we'll need to ship an image to test with). Then check state. Simple.

review: Needs Fixing (quality)
Revision history for this message
Marco Trevisan (Treviño) (3v1n0) wrote :

Alex, I can't get this into an AP test... It fails to work like it should.
Also it's too application dependent and not always reproducible, so we must go with manual test.

Revision history for this message
Tim Penhey (thumper) wrote :

I'm ok with a manual test for this at this stage.

review: Approve
Revision history for this message
Unity Merger (unity-merger) wrote :

Attempt to merge into lp:unity failed due to conflicts:

text conflict in manual-tests/Launcher.txt

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.