Merge lp:~brandontschaefer/unity/lp.1291497-fix into lp:unity

Proposed by Brandon Schaefer
Status: Work in progress
Proposed branch: lp:~brandontschaefer/unity/lp.1291497-fix
Merge into: lp:unity
Prerequisite: lp:~brandontschaefer/unity/lp.1291383-fix
Diff against target: 17 lines (+7/-0)
1 file modified
plugins/unityshell/src/unityshell.cpp (+7/-0)
To merge this branch: bzr merge lp:~brandontschaefer/unity/lp.1291497-fix
Reviewer Review Type Date Requested Status
PS Jenkins bot (community) continuous-integration Approve
Unity Team Pending
Review via email: mp+210723@code.launchpad.net

Commit message

If scale is active, close it before going into lockscreen.

Description of the change

If scale is active, close it before going into lockscreen.

To post a comment you must log in.
3711. By Brandon Schaefer

* Merge parent

Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)
Revision history for this message
Marco Trevisan (Treviño) (3v1n0) wrote :

Mh, I guess this won't work if the lockscreen is activated by the screensaver on idle or when suspending...

What about using the "locked" signal of session::Manager?

Unmerged revisions

3711. By Brandon Schaefer

* Merge parent

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-03-13 02:52:37 +0000
3+++ plugins/unityshell/src/unityshell.cpp 2014-03-13 02:52:37 +0000
4@@ -2530,6 +2530,13 @@
5 CompOption::Vector& options)
6 {
7 sources_.AddIdle([this] {
8+ PluginAdapter& adapter = PluginAdapter::Default();
9+ // FIXME Need to get this work with the signal, but the signal emits
10+ // a bit to late causing more problem then the bug it self!
11+ // possibly a re-focus function for the session
12+ if (adapter.IsScaleActive())
13+ adapter.TerminateScale();
14+
15 session_controller_->LockScreen();
16 return false;
17 });