on xenial help sign in
Make sure we hide indicators/launcher when greeter is asked to be shown
bb89272Michael Terry
qml/Greeter/Greeter.qml+6−3
@@ -69,11 +69,14 @@ Showable {
69 d.isLockscreen = true;
69 d.isLockscreen = true;
70 }
70 }
71 forcedUnlock = false;
71 forcedUnlock = false;
72− if (!required) {
72+ if (required) {
73− showNow(); // loader.onLoaded will select a user
73+ // Normally loader.onLoaded will select a user, but if we're
74− } else {
74+ // already shown, do it manually.
75 d.selectUser(d.currentIndex, true);
75 d.selectUser(d.currentIndex, true);
76 }
76 }
77+ // Even though we may already be shown, we want to call show() for its
78+ // possible side effects, like hiding indicators and such.
79+ showNow();
77 }
80 }
78
81
79 function notifyAppFocusRequested(appId) {
82 function notifyAppFocusRequested(appId) {
tests/qmltests/tst_Shell.qml+11
@@ -1161,6 +1161,17 @@ Rectangle {
1161 tryCompare(indicators, "fullyClosed", true);
1161 tryCompare(indicators, "fullyClosed", true);
1162 }
1162 }
1163
1163
1164+ function test_greeterShownAgainHidesIndicators() {
1165+ // Regression test for https://launchpad.net/bugs/1595569
1166+
1167+ loadShell("phone");
1168+ showIndicators();
1169+ showGreeter();
1170+
1171+ var indicators = findChild(shell, "indicators");
1172+ tryCompare(indicators, "fullyClosed", true);
1173+ }
1174+
1164 function test_showAndHideGreeterDBusCalls() {
1175 function test_showAndHideGreeterDBusCalls() {
1165 loadShell("phone");
1176 loadShell("phone");
1166 swipeAwayGreeter();
1177 swipeAwayGreeter();