Merge lp:~brandontschaefer/unity/command-to-dash-fix into lp:unity

Proposed by Brandon Schaefer
Status: Merged
Approved by: Stephen M. Webb
Approved revision: no longer in the source branch.
Merged at revision: 3949
Proposed branch: lp:~brandontschaefer/unity/command-to-dash-fix
Merge into: lp:unity
Diff against target: 29 lines (+7/-1)
2 files modified
plugins/unityshell/src/unityshell.cpp (+6/-0)
tests/autopilot/unity/emulators/dash.py (+1/-1)
To merge this branch: bzr merge lp:~brandontschaefer/unity/command-to-dash-fix
Reviewer Review Type Date Requested Status
Stephen M. Webb (community) Approve
PS Jenkins bot (community) continuous-integration Approve
Christopher Townsend Approve
Review via email: mp+254830@code.launchpad.net

Commit message

When we get a launcher key press (ie. super key). We check if the command lens is open. If it is then just switch the lens to the home lens. This way we dont close the dash.

Description of the change

When we get a launcher key press (ie. super key). We check if the command lens is open. If it is then just switch the lens to the home lens. This way we dont close the dash.

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

Yep, seems to work now. +1

review: Approve
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)
Revision history for this message
Stephen M. Webb (bregma) wrote :

This change causes a whole slew of Autopilot tests to fail because they rely on the Super key to close the command lens.

Evidently the test suite was not run before submitting this merge proposal.

The test suite should be changed to use the escape key (or hide_dash_via_dbus()) to close the dash after the test has completed, since it was relying on incorrect behaviour previously.

review: Needs Fixing
Revision history for this message
Stephen M. Webb (bregma) :
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 2015-03-05 16:35:54 +0000
3+++ plugins/unityshell/src/unityshell.cpp 2015-04-10 16:33:35 +0000
4@@ -2121,6 +2121,12 @@
5 g_variant_new("(sus)", "home.scope", dash::GOTO_DASH_URI, ""));
6 }
7 }
8+ else if (dash_controller_->IsCommandLensOpen())
9+ {
10+ tap_handled = true;
11+ ubus_manager_.SendMessage(UBUS_PLACE_ENTRY_ACTIVATE_REQUEST,
12+ g_variant_new("(sus)", "home.scope", dash::GOTO_DASH_URI, ""));
13+ }
14 else
15 {
16 dash_controller_->HideDash();
17
18=== modified file 'tests/autopilot/unity/emulators/dash.py'
19--- tests/autopilot/unity/emulators/dash.py 2013-05-19 07:25:11 +0000
20+++ tests/autopilot/unity/emulators/dash.py 2015-04-10 16:33:35 +0000
21@@ -70,7 +70,7 @@
22 Ensures the dash is hidden.
23 """
24 if self.visible:
25- self.toggle_reveal()
26+ self.hide_dash_via_dbus()
27 self.visible.wait_for(False)
28
29 @property