on xenial help sign in
Fix going to scopes when the Manage Dash is open Fixes: #1403464
94796fdAlbert Astals
qml/Dash/Dash.qml+1−2
@@ -36,9 +36,8 @@ Showable {
36 dashContent.setCurrentScopeAtIndex(index, animate, isSwipe)
36 dashContent.setCurrentScopeAtIndex(index, animate, isSwipe)
37 // Close dash overview and nested temp scopes in it
37 // Close dash overview and nested temp scopes in it
38 if (bottomEdgeController.progress != 0) {
38 if (bottomEdgeController.progress != 0) {
39− bottomEdgeController.enableAnimation = window.active && !scopesOverview.showingNonFavoriteScope;
39+ bottomEdgeController.enableAnimation = window.active;
40 bottomEdgeController.progress = 0;
40 bottomEdgeController.progress = 0;
41− scopesOverview.closeTempScope();
42 }
41 }
43 // Close normal temp scopes (e.g. App Store)
42 // Close normal temp scopes (e.g. App Store)
44 if (scopeItem.scope) {
43 if (scopeItem.scope) {
tests/qmltests/Dash/tst_Dash.qml+17
@@ -411,5 +411,22 @@ Item {
411 tryCompare(dashContentList, "currentIndex", 2);
411 tryCompare(dashContentList, "currentIndex", 2);
412 compare(dashContentList.currentItem.scopeId, "MockScope5");
412 compare(dashContentList.currentItem.scopeId, "MockScope5");
413 }
413 }
414+
415+ function test_manage_dash_close_dashCommunicator() {
416+ var dashContentList = findChild(dash, "dashContentList");
417+ compare(dashContentList.currentIndex, 0);
418+ compare(dashContentList.currentItem.scopeId, "MockScope1");
419+
420+ // Show the manage dash
421+ touchFlick(dash, dash.width / 2, dash.height - 1, dash.width / 2, units.gu(2));
422+ var bottomEdgeController = findInvisibleChild(dash, "bottomEdgeController");
423+ tryCompare(bottomEdgeController, "progress", 1);
424+
425+ var dashCommunicatorService = findInvisibleChild(dash, "dashCommunicatorService");
426+ dashCommunicatorService.mockSetCurrentScope(1, true, false);
427+
428+ tryCompare(bottomEdgeController, "progress", 0);
429+ tryCompare(dashContentList, "currentIndex", 1)
430+ }
414 }
431 }
415}
432}