Merge lp:~mzanetti/unity-api/mirsurface-appid into lp:unity-api

Proposed by Michael Zanetti
Status: Superseded
Proposed branch: lp:~mzanetti/unity-api/mirsurface-appid
Merge into: lp:unity-api
Diff against target: 129 lines (+31/-4)
7 files modified
debian/changelog (+13/-0)
include/unity/shell/application/CMakeLists.txt (+1/-1)
include/unity/shell/application/MirSurfaceInterface.h (+7/-0)
include/unity/shell/launcher/CMakeLists.txt (+1/-1)
include/unity/shell/launcher/QuickListModelInterface.h (+5/-1)
test/qmltest/mocks/plugins/Unity/Launcher/Mocks/MockQuickListModel.cpp (+2/-0)
test/qmltest/unity/shell/launcher/tst_Launcher.qml (+2/-1)
To merge this branch: bzr merge lp:~mzanetti/unity-api/mirsurface-appid
Reviewer Review Type Date Requested Status
Unity Team Pending
Review via email: mp+319948@code.launchpad.net

This proposal has been superseded by a proposal from 2017-03-15.

Commit message

add appId property to MirSurfaceInterface

To post a comment you must log in.
280. By Michael Zanetti

Add appId property to MirSurfaceInterface

Unmerged revisions

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'debian/changelog'
--- debian/changelog 2017-02-23 11:22:38 +0000
+++ debian/changelog 2017-03-15 16:51:45 +0000
@@ -1,3 +1,16 @@
1unity-api (8.6) UNRELEASED; urgency=medium
2
3 * Add appId property to MirSurfaceInterface
4
5 -- Michael Zanetti <michael.zanetti@canonical.com> Wed, 15 Mar 2017 17:38:36 +0100
6
7unity-api (8.5) zesty; urgency=medium
8
9 [ Michael Zanetti ]
10 * Add RoleIsPrivate to launcher's quicklist entries
11
12 -- Michael Zanetti <michael.zanetti@canonical.com> Fri, 24 Feb 2017 13:57:12 +0000
13
1unity-api (8.4+17.04.20170223-0ubuntu1) zesty; urgency=medium14unity-api (8.4+17.04.20170223-0ubuntu1) zesty; urgency=medium
215
3 [ Pete Woods ]16 [ Pete Woods ]
417
=== modified file 'include/unity/shell/application/CMakeLists.txt'
--- include/unity/shell/application/CMakeLists.txt 2017-01-26 11:07:35 +0000
+++ include/unity/shell/application/CMakeLists.txt 2017-03-15 16:51:45 +0000
@@ -7,7 +7,7 @@
77
8set(UNITY_API_LIB_HDRS ${UNITY_API_LIB_HDRS} ${headers} ${internal_headers} PARENT_SCOPE)8set(UNITY_API_LIB_HDRS ${UNITY_API_LIB_HDRS} ${headers} ${internal_headers} PARENT_SCOPE)
99
10set(VERSION 26)10set(VERSION 27)
11set(PKGCONFIG_NAME "unity-shell-application")11set(PKGCONFIG_NAME "unity-shell-application")
12set(PKGCONFIG_DESCRIPTION "Unity shell Application APIs")12set(PKGCONFIG_DESCRIPTION "Unity shell Application APIs")
13set(PKGCONFIG_REQUIRES "Qt5Core")13set(PKGCONFIG_REQUIRES "Qt5Core")
1414
=== modified file 'include/unity/shell/application/MirSurfaceInterface.h'
--- include/unity/shell/application/MirSurfaceInterface.h 2017-01-26 11:07:35 +0000
+++ include/unity/shell/application/MirSurfaceInterface.h 2017-03-15 16:51:45 +0000
@@ -58,6 +58,11 @@
58 Q_PROPERTY(QString persistentId READ persistentId CONSTANT)58 Q_PROPERTY(QString persistentId READ persistentId CONSTANT)
5959
60 /**60 /**
61 * @brief App Id of the app this surface belongs to
62 */
63 Q_PROPERTY(QString appId READ appId CONSTANT)
64
65 /**
61 * @brief Position of the current surface buffer, in pixels.66 * @brief Position of the current surface buffer, in pixels.
62 */67 */
63 Q_PROPERTY(QPoint position READ position NOTIFY positionChanged)68 Q_PROPERTY(QPoint position READ position NOTIFY positionChanged)
@@ -188,6 +193,8 @@
188193
189 virtual QString persistentId() const = 0;194 virtual QString persistentId() const = 0;
190195
196 virtual QString appId() const = 0;
197
191 virtual QPoint position() const = 0;198 virtual QPoint position() const = 0;
192199
193 virtual QSize size() const = 0;200 virtual QSize size() const = 0;
194201
=== modified file 'include/unity/shell/launcher/CMakeLists.txt'
--- include/unity/shell/launcher/CMakeLists.txt 2016-11-30 10:43:52 +0000
+++ include/unity/shell/launcher/CMakeLists.txt 2017-03-15 16:51:45 +0000
@@ -7,7 +7,7 @@
77
8set(UNITY_API_LIB_HDRS ${UNITY_API_LIB_HDRS} ${headers} ${internal_headers} PARENT_SCOPE)8set(UNITY_API_LIB_HDRS ${UNITY_API_LIB_HDRS} ${headers} ${internal_headers} PARENT_SCOPE)
99
10set(VERSION 11)10set(VERSION 12)
11set(PKGCONFIG_NAME "unity-shell-launcher")11set(PKGCONFIG_NAME "unity-shell-launcher")
12set(PKGCONFIG_DESCRIPTION "Unity shell Launcher APIs")12set(PKGCONFIG_DESCRIPTION "Unity shell Launcher APIs")
13set(PKGCONFIG_REQUIRES "Qt5Core")13set(PKGCONFIG_REQUIRES "Qt5Core")
1414
=== modified file 'include/unity/shell/launcher/QuickListModelInterface.h'
--- include/unity/shell/launcher/QuickListModelInterface.h 2016-12-14 15:57:28 +0000
+++ include/unity/shell/launcher/QuickListModelInterface.h 2017-03-15 16:51:45 +0000
@@ -39,6 +39,7 @@
39 * - RoleIcon (icon): The icon to be shown for this entry (QString).39 * - RoleIcon (icon): The icon to be shown for this entry (QString).
40 * - RoleClickable (clickable): Determines if the entry can be triggered or is just a static text (boolean)40 * - RoleClickable (clickable): Determines if the entry can be triggered or is just a static text (boolean)
41 * - RoleHasSeparator (hasSeparator): Determines if the entry has a separator (boolean)41 * - RoleHasSeparator (hasSeparator): Determines if the entry has a separator (boolean)
42 * - RoleIsPrivate (isPrivate): Determines whether the entry should be shown or not in locked mode (e.g. greeter is locked)
42 */43 */
43class UNITY_API QuickListModelInterface: public QAbstractListModel44class UNITY_API QuickListModelInterface: public QAbstractListModel
44{45{
@@ -51,6 +52,7 @@
51 m_roleNames.insert(RoleIcon, "icon");52 m_roleNames.insert(RoleIcon, "icon");
52 m_roleNames.insert(RoleClickable, "clickable");53 m_roleNames.insert(RoleClickable, "clickable");
53 m_roleNames.insert(RoleHasSeparator, "hasSeparator");54 m_roleNames.insert(RoleHasSeparator, "hasSeparator");
55 m_roleNames.insert(RoleIsPrivate, "isPrivate");
54 }56 }
55 /// @endcond57 /// @endcond
56public:58public:
@@ -63,8 +65,10 @@
63 RoleLabel,65 RoleLabel,
64 RoleIcon,66 RoleIcon,
65 RoleClickable,67 RoleClickable,
66 RoleHasSeparator68 RoleHasSeparator,
69 RoleIsPrivate
67 };70 };
71 Q_ENUM(Roles)
6872
69 /// @cond73 /// @cond
70 virtual ~QuickListModelInterface() {}74 virtual ~QuickListModelInterface() {}
7175
=== modified file 'test/qmltest/mocks/plugins/Unity/Launcher/Mocks/MockQuickListModel.cpp'
--- test/qmltest/mocks/plugins/Unity/Launcher/Mocks/MockQuickListModel.cpp 2016-10-28 11:14:37 +0000
+++ test/qmltest/mocks/plugins/Unity/Launcher/Mocks/MockQuickListModel.cpp 2017-03-15 16:51:45 +0000
@@ -39,6 +39,8 @@
39 return true;39 return true;
40 case RoleHasSeparator:40 case RoleHasSeparator:
41 return true;41 return true;
42 case RoleIsPrivate:
43 return false;
42 }44 }
43 return QVariant();45 return QVariant();
44}46}
4547
=== modified file 'test/qmltest/unity/shell/launcher/tst_Launcher.qml'
--- test/qmltest/unity/shell/launcher/tst_Launcher.qml 2016-11-30 10:38:23 +0000
+++ test/qmltest/unity/shell/launcher/tst_Launcher.qml 2017-03-15 16:51:45 +0000
@@ -175,7 +175,8 @@
175 { tag: "Model.roles[label]", role: "label", type: "string" },175 { tag: "Model.roles[label]", role: "label", type: "string" },
176 { tag: "Model.roles[icon]", role: "icon", type: "string" },176 { tag: "Model.roles[icon]", role: "icon", type: "string" },
177 { tag: "Model.roles[clickable]", role: "clickable", type: "boolean" },177 { tag: "Model.roles[clickable]", role: "clickable", type: "boolean" },
178 { tag: "Model.roles[hasSeparator]", role: "hasSeparator", type: "boolean" }178 { tag: "Model.roles[hasSeparator]", role: "hasSeparator", type: "boolean" },
179 { tag: "Model.roles[isPrivate]", role: "isPrivate", type: "boolean" }
179 ];180 ];
180 }181 }
181182

Subscribers

People subscribed via source and target branches

to all changes: