Merge lp:~dandrader/qtmir/removeApplicationStage into lp:qtmir

Proposed by Daniel d'Andrada on 2016-07-25
Status: Merged
Approved by: Gerry Boland on 2016-07-25
Approved revision: 531
Merged at revision: 543
Proposed branch: lp:~dandrader/qtmir/removeApplicationStage
Merge into: lp:qtmir
Prerequisite: lp:~dandrader/qtmir/removeDBusWindowStack
Diff against target: 180 lines (+5/-41)
6 files modified
CMakeLists.txt (+1/-1)
debian/control (+2/-2)
debian/gles-patches/convert-to-gles.patch (+1/-1)
src/modules/Unity/Application/application.cpp (+0/-19)
src/modules/Unity/Application/application.h (+0/-4)
src/modules/Unity/Application/application_manager.cpp (+1/-14)
To merge this branch: bzr merge lp:~dandrader/qtmir/removeApplicationStage
Reviewer Review Type Date Requested Status
Unity8 CI Bot continuous-integration 2016-07-25 Needs Fixing on 2016-07-25
Gerry Boland 2016-07-25 Approve on 2016-07-25
Review via email: mp+301103@code.launchpad.net

This proposal supersedes a proposal from 2016-06-17.

Commit Message

Remove Application.stage and RoleStage from ApplicationManager

They're not used anymore

Description of the Change

* Are there any related MPs required for this MP to build/function as expected? Please list.
https://code.launchpad.net/~dandrader/unity-api/removeApplicationStage/+merge/297764
https://code.launchpad.net/~dandrader/unity8/removeApplicationStage/+merge/297766

* Did you perform an exploratory manual test run of your code change and any related functionality?
Yes

* If you changed the packaging (debian), did you subscribe the ubuntu-unity team to this MP?
Not applicable

To post a comment you must log in.
Unity8 CI Bot (unity8-ci-bot) wrote : Posted in a previous version of this proposal

FAILED: Continuous integration, rev:505
https://unity8-jenkins.ubuntu.com/job/lp-qtmir-ci/279/
Executed test runs:
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build/2007/console
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-0-fetch/2035
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-1-sourcepkg/release=vivid+overlay/1952
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-1-sourcepkg/release=xenial+overlay/1952
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-1-sourcepkg/release=yakkety/1952
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=amd64,release=vivid+overlay/1943/console
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=amd64,release=xenial+overlay/1943/console
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=amd64,release=yakkety/1943/console
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=armhf,release=vivid+overlay/1943/console
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=armhf,release=xenial+overlay/1943/console
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=armhf,release=yakkety/1943/console
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=i386,release=vivid+overlay/1943/console
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=i386,release=xenial+overlay/1943/console
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=i386,release=yakkety/1943/console

Click here to trigger a rebuild:
https://unity8-jenkins.ubuntu.com/job/lp-qtmir-ci/279/rebuild

review: Needs Fixing (continuous-integration)
Unity8 CI Bot (unity8-ci-bot) wrote : Posted in a previous version of this proposal

FAILED: Continuous integration, rev:521
https://unity8-jenkins.ubuntu.com/job/lp-qtmir-ci/286/
Executed test runs:
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build/2091/console
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-0-fetch/2119
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-1-sourcepkg/release=vivid+overlay/2030
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-1-sourcepkg/release=xenial+overlay/2030
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-1-sourcepkg/release=yakkety/2030
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=amd64,release=vivid+overlay/2021/console
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=amd64,release=xenial+overlay/2021/console
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=amd64,release=yakkety/2021/console
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=armhf,release=vivid+overlay/2021/console
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=armhf,release=xenial+overlay/2021/console
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=armhf,release=yakkety/2021/console
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=i386,release=vivid+overlay/2021/console
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=i386,release=xenial+overlay/2021/console
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=i386,release=yakkety/2021/console

Click here to trigger a rebuild:
https://unity8-jenkins.ubuntu.com/job/lp-qtmir-ci/286/rebuild

review: Needs Fixing (continuous-integration)
Gerry Boland (gerboland) wrote : Posted in a previous version of this proposal

Yay!

review: Approve
Gerry Boland (gerboland) :
review: Approve
Unity8 CI Bot (unity8-ci-bot) wrote :

FAILED: Continuous integration, rev:531
https://unity8-jenkins.ubuntu.com/job/lp-qtmir-ci/310/
Executed test runs:
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build/2367/console
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-0-fetch/2395
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-1-sourcepkg/release=vivid+overlay/2282
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-1-sourcepkg/release=xenial+overlay/2282
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-1-sourcepkg/release=yakkety/2282
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=amd64,release=vivid+overlay/2275/console
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=amd64,release=xenial+overlay/2275/console
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=amd64,release=yakkety/2275/console
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=armhf,release=vivid+overlay/2275/console
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=armhf,release=xenial+overlay/2275/console
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=armhf,release=yakkety/2275/console
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=i386,release=vivid+overlay/2275/console
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=i386,release=xenial+overlay/2275/console
    FAILURE: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=i386,release=yakkety/2275/console

Click here to trigger a rebuild:
https://unity8-jenkins.ubuntu.com/job/lp-qtmir-ci/310/rebuild

review: Needs Fixing (continuous-integration)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'CMakeLists.txt'
2--- CMakeLists.txt 2016-07-05 12:41:04 +0000
3+++ CMakeLists.txt 2016-07-25 19:20:34 +0000
4@@ -83,7 +83,7 @@
5 pkg_check_modules(GSETTINGS_QT REQUIRED gsettings-qt)
6 pkg_check_modules(QTDBUSTEST libqtdbustest-1 REQUIRED)
7 pkg_check_modules(QTDBUSMOCK libqtdbusmock-1 REQUIRED)
8-pkg_check_modules(APPLICATION_API REQUIRED unity-shell-application=19)
9+pkg_check_modules(APPLICATION_API REQUIRED unity-shell-application=20)
10 pkg_check_modules(CGMANAGER libcgmanager REQUIRED)
11
12 add_definitions(-DMIR_REQUIRE_DEPRECATED_EVENT_OPT_IN=1)
13
14=== modified file 'debian/control'
15--- debian/control 2016-07-14 07:08:13 +0000
16+++ debian/control 2016-07-25 19:20:34 +0000
17@@ -23,7 +23,7 @@
18 libubuntu-app-launch2-dev (>= 0.9),
19 libubuntu-application-api-dev (>= 2.1.0),
20 libudev-dev,
21- libunity-api-dev (>= 7.116),
22+ libunity-api-dev (>= 7.117),
23 liburl-dispatcher1-dev,
24 libxkbcommon-dev,
25 libxrender-dev,
26@@ -94,7 +94,7 @@
27 Conflicts: libqtmir,
28 libunity-mir1,
29 Provides: unity-application-impl,
30- unity-application-impl-19,
31+ unity-application-impl-20,
32 Description: Qt plugin for Unity specific Mir APIs
33 QtMir provides Qt/QML bindings for Mir features that are exposed through the
34 qtmir-desktop or qtmir-android QPA plugin such as Application management
35
36=== modified file 'debian/gles-patches/convert-to-gles.patch'
37--- debian/gles-patches/convert-to-gles.patch 2016-07-14 07:08:13 +0000
38+++ debian/gles-patches/convert-to-gles.patch 2016-07-25 19:20:34 +0000
39@@ -84,7 +84,7 @@
40 -Conflicts: libqtmir,
41 - libunity-mir1,
42 -Provides: unity-application-impl,
43-- unity-application-impl-19,
44+- unity-application-impl-20,
45 -Description: Qt plugin for Unity specific Mir APIs
46 - QtMir provides Qt/QML bindings for Mir features that are exposed through the
47 - qtmir-desktop or qtmir-android QPA plugin such as Application management
48
49=== modified file 'src/modules/Unity/Application/application.cpp'
50--- src/modules/Unity/Application/application.cpp 2016-06-24 13:46:39 +0000
51+++ src/modules/Unity/Application/application.cpp 2016-07-25 19:20:34 +0000
52@@ -47,7 +47,6 @@
53 , m_sharedWakelock(sharedWakelock)
54 , m_appInfo(appInfo)
55 , m_pid(0)
56- , m_stage(Application::MainStage)
57 , m_supportedStages(Application::MainStage|Application::SideStage)
58 , m_state(InternalState::Starting)
59 , m_arguments(arguments)
60@@ -232,11 +231,6 @@
61 return colorFromString(colorStr, "splashColorFooter");
62 }
63
64-Application::Stage Application::stage() const
65-{
66- return m_stage;
67-}
68-
69 Application::Stages Application::supportedStages() const
70 {
71 return m_supportedStages;
72@@ -533,19 +527,6 @@
73 Q_EMIT sessionChanged(m_session);
74 }
75
76-void Application::setStage(Application::Stage stage)
77-{
78- if (m_stage != stage) {
79- if ((stage | m_supportedStages) == 0) {
80- return;
81- }
82- DEBUG_MSG << "(stage=" << stage << ")";
83-
84- m_stage = stage;
85- Q_EMIT stageChanged(stage);
86- }
87-}
88-
89 void Application::setInternalState(Application::InternalState state)
90 {
91 if (m_state == state) {
92
93=== modified file 'src/modules/Unity/Application/application.h'
94--- src/modules/Unity/Application/application.h 2016-06-24 13:46:39 +0000
95+++ src/modules/Unity/Application/application.h 2016-07-25 19:20:34 +0000
96@@ -89,8 +89,6 @@
97 QString name() const override;
98 QString comment() const override;
99 QUrl icon() const override;
100- Stage stage() const override;
101- void setStage(Stage stage) override;
102 State state() const override;
103 RequestedState requestedState() const override;
104 void setRequestedState(RequestedState) override;
105@@ -140,7 +138,6 @@
106
107 Q_SIGNALS:
108 void fullscreenChanged(bool fullscreen);
109- void stageChanged(Stage stage);
110 void sessionChanged(SessionInterface *session);
111
112 void startProcessRequested();
113@@ -177,7 +174,6 @@
114 QSharedPointer<SharedWakelock> m_sharedWakelock;
115 QSharedPointer<ApplicationInfo> m_appInfo;
116 pid_t m_pid;
117- Stage m_stage;
118 Stages m_supportedStages;
119 InternalState m_state;
120 QStringList m_arguments;
121
122=== modified file 'src/modules/Unity/Application/application_manager.cpp'
123--- src/modules/Unity/Application/application_manager.cpp 2016-07-25 19:20:34 +0000
124+++ src/modules/Unity/Application/application_manager.cpp 2016-07-25 19:20:34 +0000
125@@ -209,8 +209,6 @@
126 return QVariant::fromValue(application->comment());
127 case RoleIcon:
128 return QVariant::fromValue(application->icon());
129- case RoleStage:
130- return QVariant::fromValue((int)application->stage());
131 case RoleState:
132 return QVariant::fromValue((int)application->state());
133 case RoleFocused:
134@@ -538,7 +536,7 @@
135 * Hack: Allow applications to be launched without being managed by upstart, where AppManager
136 * itself manages processes executed with a "--desktop_file_hint=/path/to/desktopFile.desktop"
137 * parameter attached. This exists until ubuntu-app-launch can notify shell any application is
138- * and so shell should allow it. Also reads the --stage parameter to determine the desired stage
139+ * and so shell should allow it.
140 */
141 std::unique_ptr<ProcInfo::CommandLine> info = m_procInfo->commandLine(pid);
142 if (!info) {
143@@ -583,14 +581,6 @@
144 return;
145 }
146
147- // if stage supplied in CLI, fetch that
148- Application::Stage stage = Application::MainStage;
149- QString stageParam = info->getParameter("--stage_hint=");
150-
151- if (stageParam == "side_stage") {
152- stage = Application::SideStage;
153- }
154-
155 qCDebug(QTMIR_APPLICATIONS) << "New process with pid" << pid << "appeared, adding new application to the"
156 << "application list with appId:" << appInfo->appId();
157
158@@ -601,7 +591,6 @@
159 arguments,
160 this);
161 application->setPid(pid);
162- application->setStage(stage);
163 add(application);
164 authorized = true;
165 }
166@@ -646,7 +635,6 @@
167
168 connect(application, &Application::focusedChanged, this, [this](bool) { onAppDataChanged(RoleFocused); });
169 connect(application, &Application::stateChanged, this, [this](Application::State) { onAppDataChanged(RoleState); });
170- connect(application, &Application::stageChanged, this, [this](Application::Stage) { onAppDataChanged(RoleStage); });
171 connect(application, &Application::closing, this, [this, application]() { onApplicationClosing(application); });
172 connect(application, &unityapi::ApplicationInfoInterface::focusRequested, this, [this, application]() {
173 Q_EMIT focusRequested(application->appId());
174@@ -721,7 +709,6 @@
175 disconnect(application, &Application::fullscreenChanged, this, 0);
176 disconnect(application, &Application::focusedChanged, this, 0);
177 disconnect(application, &Application::stateChanged, this, 0);
178- disconnect(application, &Application::stageChanged, this, 0);
179 disconnect(application, &Application::closing, this, 0);
180 disconnect(application, &unityapi::ApplicationInfoInterface::focusRequested, this, 0);
181

Subscribers

People subscribed via source and target branches