on xenial help sign in
ApplicationInfo->ApplicationInfoInterface
bc30295Nick Dedekind
qml/Stages/ApplicationWindow.qml+3−3
@@ -42,7 +42,7 @@ SessionContainer {
42
42
43 property bool needToTakeScreenshot:
43 property bool needToTakeScreenshot:
44 root.surface && d.surfaceInitialized && screenshotImage.status === Image.Null
44 root.surface && d.surfaceInitialized && screenshotImage.status === Image.Null
45− && d.applicationState === ApplicationInfo.Stopped
45+ && d.applicationState === ApplicationInfoInterface.Stopped
46 onNeedToTakeScreenshotChanged: {
46 onNeedToTakeScreenshotChanged: {
47 if (needToTakeScreenshot) {
47 if (needToTakeScreenshot) {
48 screenshotImage.take();
48 screenshotImage.take();
@@ -133,7 +133,7 @@ SessionContainer {
133 when:
133 when:
134 (root.surface && d.surfaceInitialized)
134 (root.surface && d.surfaceInitialized)
135 &&
135 &&
136− (d.applicationState !== ApplicationInfo.Stopped
136+ (d.applicationState !== ApplicationInfoInterface.Stopped
137 || screenshotImage.status !== Image.Ready)
137 || screenshotImage.status !== Image.Ready)
138 },
138 },
139 State {
139 State {
@@ -141,7 +141,7 @@ SessionContainer {
141 when:
141 when:
142 screenshotImage.status === Image.Ready
142 screenshotImage.status === Image.Ready
143 &&
143 &&
144− (d.applicationState === ApplicationInfo.Stopped
144+ (d.applicationState === ApplicationInfoInterface.Stopped
145 || !root.surface || !d.surfaceInitialized)
145 || !root.surface || !d.surfaceInitialized)
146 }
146 }
147 ]
147 ]
tests/qmltests/Panel/tst_ActiveCallHint.qml+1−1
@@ -97,7 +97,7 @@ Item {
97 var application = ApplicationManager.startApplication("dialer-app");
97 var application = ApplicationManager.startApplication("dialer-app");
98 ApplicationManager.focusApplication("dialer-app");
98 ApplicationManager.focusApplication("dialer-app");
99 tryCompare(ApplicationManager, "focusedApplicationId", "dialer-app");
99 tryCompare(ApplicationManager, "focusedApplicationId", "dialer-app");
100− tryCompare(application, "state", ApplicationInfo.Running);
100+ tryCompare(application, "state", ApplicationInfoInterface.Running);
101
101
102 if (!data.focused) { ApplicationManager.unfocusCurrentApplication(); }
102 if (!data.focused) { ApplicationManager.unfocusCurrentApplication(); }
103 }
103 }
tests/qmltests/Stages/tst_ApplicationWindow.qml+9−9
@@ -32,7 +32,7 @@ Rectangle {
32 Component.onCompleted: {
32 Component.onCompleted: {
33 root.fakeApplication = ApplicationManager.add("gallery-app");
33 root.fakeApplication = ApplicationManager.add("gallery-app");
34 root.fakeApplication.manualSessionCreation = true;
34 root.fakeApplication.manualSessionCreation = true;
35− root.fakeApplication.setState(ApplicationInfo.Starting);
35+ root.fakeApplication.setState(ApplicationInfoInterface.Starting);
36 }
36 }
37 property QtObject fakeApplication: null
37 property QtObject fakeApplication: null
38 readonly property var fakeSession: fakeApplication ? fakeApplication.session : null
38 readonly property var fakeSession: fakeApplication ? fakeApplication.session : null
@@ -103,13 +103,13 @@ Rectangle {
103 "Stopped"]
103 "Stopped"]
104 property int selectedApplicationState: {
104 property int selectedApplicationState: {
105 if (model[selectedIndex] === "Starting") {
105 if (model[selectedIndex] === "Starting") {
106− return ApplicationInfo.Starting;
106+ return ApplicationInfoInterface.Starting;
107 } else if (model[selectedIndex] === "Running") {
107 } else if (model[selectedIndex] === "Running") {
108− return ApplicationInfo.Running;
108+ return ApplicationInfoInterface.Running;
109 } else if (model[selectedIndex] === "Suspended") {
109 } else if (model[selectedIndex] === "Suspended") {
110− return ApplicationInfo.Suspended;
110+ return ApplicationInfoInterface.Suspended;
111 } else {
111 } else {
112− return ApplicationInfo.Stopped;
112+ return ApplicationInfoInterface.Stopped;
113 }
113 }
114 }
114 }
115 onSelectedApplicationStateChanged: {
115 onSelectedApplicationStateChanged: {
@@ -126,10 +126,10 @@ Rectangle {
126 when: windowShown
126 when: windowShown
127
127
128 // just to make them shorter
128 // just to make them shorter
129− property int appStarting: ApplicationInfo.Starting
129+ property int appStarting: ApplicationInfoInterface.Starting
130− property int appRunning: ApplicationInfo.Running
130+ property int appRunning: ApplicationInfoInterface.Running
131− property int appSuspended: ApplicationInfo.Suspended
131+ property int appSuspended: ApplicationInfoInterface.Suspended
132− property int appStopped: ApplicationInfo.Stopped
132+ property int appStopped: ApplicationInfoInterface.Stopped
133
133
134 function setApplicationState(appState) {
134 function setApplicationState(appState) {
135 switch (appState) {
135 switch (appState) {
tests/qmltests/Stages/tst_PhoneStage.qml+1−1
@@ -64,7 +64,7 @@ Item {
64 anchors { left: parent.left; right: parent.right }
64 anchors { left: parent.left; right: parent.right }
65 text: "Stop Selected"
65 text: "Stop Selected"
66 onClicked: {
66 onClicked: {
67− ApplicationManager.get(appList.selectedAppIndex).setState(ApplicationInfo.Stopped);
67+ ApplicationManager.get(appList.selectedAppIndex).setState(ApplicationInfoInterface.Stopped);
68 }
68 }
69 }
69 }
70 }
70 }
tests/qmltests/tst_Shell.qml+3−3
@@ -144,7 +144,7 @@ Item {
144 verify(mainAppId != "");
144 verify(mainAppId != "");
145 var mainApp = ApplicationManager.findApplication(mainAppId);
145 var mainApp = ApplicationManager.findApplication(mainAppId);
146 verify(mainApp);
146 verify(mainApp);
147− tryCompare(mainApp, "state", ApplicationInfo.Running);
147+ tryCompare(mainApp, "state", ApplicationInfoInterface.Running);
148
148
149 // Try to suspend while proximity is engaged...
149 // Try to suspend while proximity is engaged...
150 Powerd.displayPowerStateChange(Powerd.Off, Powerd.Proximity);
150 Powerd.displayPowerStateChange(Powerd.Off, Powerd.Proximity);
@@ -157,7 +157,7 @@ Item {
157 tryCompare(greeter, "showProgress", 1);
157 tryCompare(greeter, "showProgress", 1);
158
158
159 tryCompare(ApplicationManager, "suspended", true);
159 tryCompare(ApplicationManager, "suspended", true);
160− compare(mainApp.state, ApplicationInfo.Suspended);
160+ compare(mainApp.state, ApplicationInfoInterface.Suspended);
161
161
162 // And wake up
162 // And wake up
163 Powerd.displayPowerStateChange(Powerd.On, 0);
163 Powerd.displayPowerStateChange(Powerd.On, 0);
@@ -166,7 +166,7 @@ Item {
166 // Swipe away greeter to focus app
166 // Swipe away greeter to focus app
167 swipeAwayGreeter();
167 swipeAwayGreeter();
168 tryCompare(ApplicationManager, "suspended", false);
168 tryCompare(ApplicationManager, "suspended", false);
169− compare(mainApp.state, ApplicationInfo.Running);
169+ compare(mainApp.state, ApplicationInfoInterface.Running);
170 tryCompare(ApplicationManager, "focusedApplicationId", mainAppId);
170 tryCompare(ApplicationManager, "focusedApplicationId", mainAppId);
171 }
171 }
172
172