Merge lp:~3v1n0/unity/scaled-windows-filtering-out-reset into lp:unity

Proposed by Marco Trevisan (Treviño)
Status: Merged
Approved by: Andrea Azzarone
Approved revision: no longer in the source branch.
Merged at revision: 3888
Proposed branch: lp:~3v1n0/unity/scaled-windows-filtering-out-reset
Merge into: lp:unity
Diff against target: 33 lines (+14/-2)
1 file modified
plugins/unityshell/src/unityshell.cpp (+14/-2)
To merge this branch: bzr merge lp:~3v1n0/unity/scaled-windows-filtering-out-reset
Reviewer Review Type Date Requested Status
Andrea Azzarone (community) Approve
PS Jenkins bot (community) continuous-integration Approve
Review via email: mp+239231@code.launchpad.net

Commit message

UnityScreen: when filtering out windows in spread, make sure we unscale them

To post a comment you must log in.
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)
Revision history for this message
Andrea Azzarone (azzar1) wrote :

Just a small comment.

Revision history for this message
Andrea Azzarone (azzar1) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'plugins/unityshell/src/unityshell.cpp'
2--- plugins/unityshell/src/unityshell.cpp 2014-10-16 15:10:15 +0000
3+++ plugins/unityshell/src/unityshell.cpp 2014-10-22 16:30:47 +0000
4@@ -538,7 +538,19 @@
5 else
6 {
7 CompMatch windows_match;
8- for (auto xid : spread_filter_->FilteredWindows())
9+ auto const& filtered_windows = spread_filter_->FilteredWindows();
10+
11+ for (auto const& swin : sScreen->getWindows())
12+ {
13+ if (std::find(filtered_windows.begin(), filtered_windows.end(), swin->window->id()) != filtered_windows.end())
14+ continue;
15+
16+ auto* uwin = UnityWindow::get(swin->window);
17+ uwin->OnTerminateSpread();
18+ fake_decorated_windows_.erase(uwin);
19+ }
20+
21+ for (auto xid : filtered_windows)
22 windows_match |= "xid="+std::to_string(xid);
23
24 auto match = sScreen->getCustomMatch();
25@@ -4430,7 +4442,7 @@
26 }
27 else
28 {
29- window->setShowDesktopMode (false);
30+ window->setShowDesktopMode(false);
31 }
32 }
33 }