on xenial help sign in
[ Michael Terry ]
bcea04bJosh Arenson
debian/changelog+10
@@ -1,3 +1,13 @@
1+unity8 (8.11+15.04.20150821-0ubuntu1) vivid; urgency=medium
2+
3+ [ Michael Terry ]
4+ * Skip the tutorial entirely when in desktop mode. This fixes the
5+ emulator not being able to pass the tutorial.
6+ * Skip the tutorial entirely when in desktop mode. This fixes the
7+ emulator not being able to pass the tutorial.
8+
9+ -- CI Train Bot <ci-train-bot@canonical.com> Fri, 21 Aug 2015 14:34:50 +0000
10+
1unity8 (8.11+15.04.20150817-0ubuntu1) vivid; urgency=medium
11unity8 (8.11+15.04.20150817-0ubuntu1) vivid; urgency=medium
2
12
3 [ Albert Astals Cid ]
13 [ Albert Astals Cid ]
qml/Shell.qml+7−8
@@ -371,20 +371,19 @@ Item {
371 id: tutorial
371 id: tutorial
372 objectName: "tutorial"
372 objectName: "tutorial"
373 anchors.fill: parent
373 anchors.fill: parent
374− active: AccountsService.demoEdges && shell.mode !== "greeter"
375− paused: lightDM.greeter.active
376− launcher: launcher
377− panel: panel
378− edgeSize: shell.edgeSize
379
374
380 // EdgeDragAreas don't work with mice. So to avoid trapping the user,
375 // EdgeDragAreas don't work with mice. So to avoid trapping the user,
381− // we'll tell the tutorial to avoid using them on the Desktop. The
376+ // we skip the tutorial on the Desktop to avoid using them. The
382 // Desktop doesn't use the same spread design anyway. The tutorial is
377 // Desktop doesn't use the same spread design anyway. The tutorial is
383 // all a bit of a placeholder on non-phone form factors right now.
378 // all a bit of a placeholder on non-phone form factors right now.
384 // When the design team gives us more guidance, we can do something
379 // When the design team gives us more guidance, we can do something
385 // more clever here.
380 // more clever here.
386− // TODO: use DeviceConfiguration instead of checking source
381+ active: usageScenario != "desktop" && AccountsService.demoEdges
387− useEdgeDragArea: applicationsDisplayLoader.source != Qt.resolvedUrl("Stages/DesktopStage.qml")
382+
383+ paused: LightDM.Greeter.active
384+ launcher: launcher
385+ panel: panel
386+ edgeSize: shell.edgeSize
388
387
389 onFinished: {
388 onFinished: {
390 AccountsService.demoEdges = false;
389 AccountsService.demoEdges = false;
qml/Tutorial/Tutorial.qml−7
@@ -23,7 +23,6 @@ Item {
23 property alias active: loader.active
23 property alias active: loader.active
24 property bool paused
24 property bool paused
25 property real edgeSize
25 property real edgeSize
26− property bool useEdgeDragArea
27
26
28 property Item launcher
27 property Item launcher
29 property Item panel
28 property Item panel
@@ -59,12 +58,6 @@ Item {
59 value: root.edgeSize
58 value: root.edgeSize
60 }
59 }
61
60
62− Binding {
63− target: loader.item
64− property: "useEdgeDragArea"
65− value: root.useEdgeDragArea
66− }
67−
68 Binding {
61 Binding {
69 target: loader.item
62 target: loader.item
70 property: "launcher"
63 property: "launcher"
qml/Tutorial/TutorialContent.qml+2−9
@@ -32,7 +32,6 @@ Item {
32
32
33 property bool paused: false
33 property bool paused: false
34 property real edgeSize
34 property real edgeSize
35− property bool useEdgeDragArea
36
35
37 signal finished()
36 signal finished()
38
37
@@ -78,17 +77,11 @@ Item {
78 anchors.fill: parent
77 anchors.fill: parent
79 textXOffset: root.launcher.panelWidth
78 textXOffset: root.launcher.panelWidth
80 paused: !shown || root.paused
79 paused: !shown || root.paused
81− text: root.useEdgeDragArea ? i18n.tr("Tap here to continue.") : i18n.tr("Click here to finish.")
80+ text: i18n.tr("Tap here to continue.")
82
81
83 onFinished: {
82 onFinished: {
84 root.launcher.hide();
83 root.launcher.hide();
85− if (root.useEdgeDragArea) {
86− tutorialRight.show();
84+ tutorialRight.show();
87− } else {
88− // Last two screens use EdgeDragArea (right edge spread and
89− // bottom edge). So just end tutorial here.
90− root.finish();
91− }
92 }
85 }
93 }
86 }
94
87
tests/qmltests/Tutorial/tst_Tutorial.qml+7−6
@@ -17,7 +17,6 @@
17import QtQuick 2.0
17import QtQuick 2.0
18import QtTest 1.0
18import QtTest 1.0
19import AccountsService 0.1
19import AccountsService 0.1
20−import GSettings 1.0
21import IntegratedLightDM 0.1 as LightDM
20import IntegratedLightDM 0.1 as LightDM
22import Ubuntu.Components 1.1
21import Ubuntu.Components 1.1
23import Unity.Application 0.1
22import Unity.Application 0.1
@@ -264,12 +263,14 @@ Item {
264 goToPage(null);
263 goToPage(null);
265 }
264 }
266
265
267− function test_walkthroughOnDesktop() {
266+ function test_skipOnDesktop() {
267+ var tutorial = findChild(shell, "tutorial");
268+ tryCompare(tutorial, "active", true);
269+ tryCompare(tutorial, "running", true);
270+
268 shell.usageScenario = "desktop";
271 shell.usageScenario = "desktop";
269− var page = goToPage("tutorialLeftFinish");
272+ tryCompare(tutorial, "active", false);
270− var tick = findChild(page, "tick");
273+ tryCompare(tutorial, "running", false);
271− tap(tick);
272− checkFinished();
273 }
274 }
274
275
275 function test_launcherShortDrag() {
276 function test_launcherShortDrag() {