on xenial help sign in
Dash manage hint should not be visible in previews+test Fixes: #1422260
d89bf73Albert Astals Cid
qml/Dash/Dash.qml+2−1
@@ -300,10 +300,11 @@ Showable {
300 }
300 }
301
301
302 Image {
302 Image {
303+ objectName: "overviewHint"
303 source: "graphics/overview_hint.png"
304 source: "graphics/overview_hint.png"
304 anchors.horizontalCenter: parent.horizontalCenter
305 anchors.horizontalCenter: parent.horizontalCenter
305 opacity: !scopeItem.scope && (scopes.count == 0 || dashContent.pageHeaderTotallyVisible) &&
306 opacity: !scopeItem.scope && (scopes.count == 0 || dashContent.pageHeaderTotallyVisible) &&
306− (overviewDragHandle.enabled || overviewDragHandle.status.progress != 0) ? 1 : 0
307+ (overviewDragHandle.enabled || bottomEdgeController.progress != 0) ? 1 : 0
307 Behavior on opacity {
308 Behavior on opacity {
308 enabled: bottomEdgeController.progress == 0
309 enabled: bottomEdgeController.progress == 0
309 UbuntuNumberAnimation {}
310 UbuntuNumberAnimation {}
tests/qmltests/Dash/tst_Dash.qml+22
@@ -429,6 +429,28 @@ Item {
429 tryCompare(dashContentList, "currentIndex", 1)
429 tryCompare(dashContentList, "currentIndex", 1)
430 }
430 }
431
431
432+ function test_preview_no_show_manage_dash_hint() {
433+ var dashContentList = findChild(dash, "dashContentList");
434+ compare(dashContentList.currentIndex, 0);
435+ compare(dashContentList.currentItem.scopeId, "MockScope1");
436+
437+ tryCompareFunction(function() {
438+ var cardGrid = findChild(dashContentList, "dashCategory0");
439+ if (cardGrid != null) {
440+ var tile = findChild(cardGrid, "delegate0");
441+ return tile != null;
442+ }
443+ return false;
444+ },
445+ true);
446+ var tile = findChild(findChild(dashContentList, "dashCategory0"), "delegate0");
447+ waitForRendering(tile);
448+ mouseClick(tile);
449+
450+ var overviewHint = findChild(dash, "overviewHint");
451+ tryCompare(overviewHint, "opacity", 0);
452+ }
453+
432 function test_close_temp_scope_preview_opening_scope() {
454 function test_close_temp_scope_preview_opening_scope() {
433 // Show the manage dash
455 // Show the manage dash
434 touchFlick(dash, dash.width / 2, dash.height - 1, dash.width / 2, units.gu(2));
456 touchFlick(dash, dash.width / 2, dash.height - 1, dash.width / 2, units.gu(2));