Merge lp:~aacid/unity-api/use_qenum into lp:unity-api

Proposed by Albert Astals Cid
Status: Merged
Approved by: Lukáš Tinkl
Approved revision: 264
Merged at revision: 263
Proposed branch: lp:~aacid/unity-api/use_qenum
Merge into: lp:unity-api
Prerequisite: lp:~aacid/unity-api/add_suggest-override
Diff against target: 534 lines (+31/-49)
22 files modified
debian/control (+1/-1)
include/unity/shell/application/ApplicationInfoInterface.h (+3/-4)
include/unity/shell/application/ApplicationManagerInterface.h (+1/-1)
include/unity/shell/application/Mir.h (+5/-5)
include/unity/shell/application/MirSurfaceItemInterface.h (+1/-2)
include/unity/shell/launcher/AppDrawerModelInterface.h (+1/-1)
include/unity/shell/notifications/Enums.h (+3/-6)
include/unity/shell/notifications/ModelInterface.h (+1/-1)
include/unity/shell/scopes/CategoriesInterface.h (+1/-2)
include/unity/shell/scopes/FiltersInterface.h (+2/-3)
include/unity/shell/scopes/NavigationInterface.h (+1/-2)
include/unity/shell/scopes/OptionSelectorOptionsInterface.h (+1/-2)
include/unity/shell/scopes/PreviewModelInterface.h (+1/-2)
include/unity/shell/scopes/PreviewWidgetModelInterface.h (+1/-2)
include/unity/shell/scopes/ResultsModelInterface.h (+1/-2)
include/unity/shell/scopes/ScopeInterface.h (+1/-2)
include/unity/shell/scopes/ScopesInterface.h (+1/-2)
include/unity/shell/scopes/SettingsModelInterface.h (+1/-2)
include/unity/shell/scopes/ValueSliderValuesInterface.h (+1/-2)
test/qmltest/mocks/plugins/Unity/Notifications/Mocks/MockActionModel.h (+1/-2)
test/qmltest/mocks/plugins/Unity/Notifications/Mocks/MockModel.h (+1/-2)
test/qmltest/mocks/plugins/Unity/Scopes/Mocks/MockPreviewWidgetModel.h (+1/-1)
To merge this branch: bzr merge lp:~aacid/unity-api/use_qenum
Reviewer Review Type Date Requested Status
Paweł Stołowski (community) Approve
Lukáš Tinkl (community) Approve
Unity8 CI Bot continuous-integration Approve
Review via email: mp+313821@code.launchpad.net

Commit message

Use the new Q_ENUM (Qt 5.5)

It's generally better than Q_ENUMS, one example it will fail to compile if you had specified the name wrong as in OptionSelectorOptionsInterface.h

Also fixes a warning about MockPreviewData being forward-declared as class but then being a struct

To post a comment you must log in.
lp:~aacid/unity-api/use_qenum updated
263. By Albert Astals Cid

Some more i missed somehow

Includes another one that was badly typed

264. By Albert Astals Cid

Q_FLAG is also the moderm way of Q_FLAGS

Revision history for this message
Unity8 CI Bot (unity8-ci-bot) wrote :

PASSED: Continuous integration, rev:262
https://unity8-jenkins.ubuntu.com/job/lp-unity-api-ci/124/
Executed test runs:
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build/3642
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-0-fetch/3670
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=amd64,release=xenial+overlay/3514
        deb: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=amd64,release=xenial+overlay/3514/artifact/output/*zip*/output.zip
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=amd64,release=zesty/3514
        deb: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=amd64,release=zesty/3514/artifact/output/*zip*/output.zip
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=armhf,release=xenial+overlay/3514
        deb: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=armhf,release=xenial+overlay/3514/artifact/output/*zip*/output.zip
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=armhf,release=zesty/3514
        deb: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=armhf,release=zesty/3514/artifact/output/*zip*/output.zip
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=i386,release=xenial+overlay/3514
        deb: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=i386,release=xenial+overlay/3514/artifact/output/*zip*/output.zip
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=i386,release=zesty/3514
        deb: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=i386,release=zesty/3514/artifact/output/*zip*/output.zip

Click here to trigger a rebuild:
https://unity8-jenkins.ubuntu.com/job/lp-unity-api-ci/124/rebuild

review: Approve (continuous-integration)
Revision history for this message
Unity8 CI Bot (unity8-ci-bot) wrote :

PASSED: Continuous integration, rev:264
https://unity8-jenkins.ubuntu.com/job/lp-unity-api-ci/125/
Executed test runs:
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build/3646
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-0-fetch/3674
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=amd64,release=xenial+overlay/3519
        deb: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=amd64,release=xenial+overlay/3519/artifact/output/*zip*/output.zip
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=amd64,release=zesty/3519
        deb: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=amd64,release=zesty/3519/artifact/output/*zip*/output.zip
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=armhf,release=xenial+overlay/3519
        deb: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=armhf,release=xenial+overlay/3519/artifact/output/*zip*/output.zip
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=armhf,release=zesty/3519
        deb: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=armhf,release=zesty/3519/artifact/output/*zip*/output.zip
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=i386,release=xenial+overlay/3519
        deb: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=i386,release=xenial+overlay/3519/artifact/output/*zip*/output.zip
    SUCCESS: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=i386,release=zesty/3519
        deb: https://unity8-jenkins.ubuntu.com/job/build-2-binpkg/arch=i386,release=zesty/3519/artifact/output/*zip*/output.zip

Click here to trigger a rebuild:
https://unity8-jenkins.ubuntu.com/job/lp-unity-api-ci/125/rebuild

review: Approve (continuous-integration)
Revision history for this message
Lukáš Tinkl (lukas-kde) wrote :

Yup, makes sense, compiles and tests passing

review: Approve
Revision history for this message
Paweł Stołowski (stolowski) wrote :

+1, thanks!

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'debian/control'
2--- debian/control 2016-08-02 00:40:57 +0000
3+++ debian/control 2016-12-23 10:18:10 +0000
4@@ -17,7 +17,7 @@
5 pkg-config,
6 python3:any,
7 qt5-default,
8- qtbase5-dev,
9+ qtbase5-dev (>= 5.5),
10 qtdeclarative5-dev,
11 qtdeclarative5-dev-tools,
12 qtdeclarative5-qtquick2-plugin,
13
14=== modified file 'include/unity/shell/application/ApplicationInfoInterface.h'
15--- include/unity/shell/application/ApplicationInfoInterface.h 2016-11-14 20:35:23 +0000
16+++ include/unity/shell/application/ApplicationInfoInterface.h 2016-12-23 10:18:10 +0000
17@@ -44,10 +44,6 @@
18 {
19 Q_OBJECT
20
21- Q_ENUMS(Stage)
22- Q_ENUMS(State)
23- Q_ENUMS(RequestedState)
24-
25 /**
26 * @brief The appId of the application.
27 *
28@@ -250,6 +246,7 @@
29 MainStage,
30 SideStage
31 };
32+ Q_ENUM(Stage)
33
34 /**
35 * @brief An application's state.
36@@ -269,6 +266,7 @@
37 Suspended,
38 Stopped
39 };
40+ Q_ENUM(State)
41
42 /**
43 * @brief The desired state of an application
44@@ -281,6 +279,7 @@
45 RequestedRunning = Running,
46 RequestedSuspended = Suspended
47 };
48+ Q_ENUM(RequestedState)
49
50 /**
51 * @brief Closes the application
52
53=== modified file 'include/unity/shell/application/ApplicationManagerInterface.h'
54--- include/unity/shell/application/ApplicationManagerInterface.h 2016-12-07 11:11:32 +0000
55+++ include/unity/shell/application/ApplicationManagerInterface.h 2016-12-23 10:18:10 +0000
56@@ -44,7 +44,6 @@
57 class UNITY_API ApplicationManagerInterface: public QAbstractListModel
58 {
59 Q_OBJECT
60- Q_ENUMS(Roles)
61
62 /**
63 * @brief The count of the applications known to the manager.
64@@ -98,6 +97,7 @@
65 RoleExemptFromLifecycle,
66 RoleApplication,
67 };
68+ Q_ENUM(Roles)
69
70 /// @cond
71 virtual ~ApplicationManagerInterface() {}
72
73=== modified file 'include/unity/shell/application/Mir.h'
74--- include/unity/shell/application/Mir.h 2016-11-03 12:25:43 +0000
75+++ include/unity/shell/application/Mir.h 2016-12-23 10:18:10 +0000
76@@ -25,11 +25,6 @@
77 class Mir : public QObject
78 {
79 Q_OBJECT
80- Q_ENUMS(Type)
81- Q_ENUMS(State)
82- Q_ENUMS(OrientationAngle)
83- Q_ENUMS(ShellChrome)
84- Q_ENUMS(FormFactor)
85
86 /**
87 @brief Name of the mouse cursor to be used. Follows the X Cursor naming convention.
88@@ -54,6 +49,7 @@
89 SatelliteType,
90 TipType,
91 };
92+ Q_ENUM(Type)
93
94 /**
95 @brief Surface state
96@@ -74,6 +70,7 @@
97 MaximizedBottomRightState,
98 HiddenState,
99 };
100+ Q_ENUM(State)
101
102 /**
103 @brief Surface orientation angle
104@@ -84,6 +81,7 @@
105 Angle180 = 180,
106 Angle270 = 270
107 };
108+ Q_ENUM(OrientationAngle)
109
110 /**
111 @brief Shell chrome
112@@ -92,6 +90,7 @@
113 NormalChrome,
114 LowChrome,
115 };
116+ Q_ENUM(ShellChrome)
117
118 /**
119 @brief Form Factor
120@@ -104,6 +103,7 @@
121 FormFactorTV,
122 FormFactorProjector,
123 };
124+ Q_ENUM(FormFactor)
125
126 /// @cond
127 virtual void setCursorName(const QString &cursorName) = 0;
128
129=== modified file 'include/unity/shell/application/MirSurfaceItemInterface.h'
130--- include/unity/shell/application/MirSurfaceItemInterface.h 2016-11-03 12:25:43 +0000
131+++ include/unity/shell/application/MirSurfaceItemInterface.h 2016-12-23 10:18:10 +0000
132@@ -41,8 +41,6 @@
133 {
134 Q_OBJECT
135
136- Q_ENUMS(FillMode)
137-
138 /**
139 * @brief The surface to be displayed
140 */
141@@ -118,6 +116,7 @@
142 Stretch,
143 PadOrCrop
144 };
145+ Q_ENUM(FillMode)
146
147 /// @cond
148 MirSurfaceItemInterface(QQuickItem *parent = 0) : QQuickItem(parent) {}
149
150=== modified file 'include/unity/shell/launcher/AppDrawerModelInterface.h'
151--- include/unity/shell/launcher/AppDrawerModelInterface.h 2016-11-16 18:52:33 +0000
152+++ include/unity/shell/launcher/AppDrawerModelInterface.h 2016-12-23 10:18:10 +0000
153@@ -32,7 +32,6 @@
154 class UNITY_API AppDrawerModelInterface: public QAbstractListModel
155 {
156 Q_OBJECT
157- Q_ENUMS(Roles)
158 public:
159 /**
160 * @brief The Roles supported by the model
161@@ -46,6 +45,7 @@
162 RoleKeywords,
163 RoleUsage
164 };
165+ Q_ENUM(Roles)
166
167 /// @cond
168 AppDrawerModelInterface(QObject* parent = nullptr): QAbstractListModel(parent) {}
169
170=== modified file 'include/unity/shell/notifications/Enums.h'
171--- include/unity/shell/notifications/Enums.h 2013-05-30 12:22:50 +0000
172+++ include/unity/shell/notifications/Enums.h 2016-12-23 10:18:10 +0000
173@@ -42,8 +42,6 @@
174 {
175 Q_OBJECT
176
177- Q_ENUMS(UrgencyEnum)
178-
179 public:
180 /**
181 \brief NotificationInterface's urgency enumeration.
182@@ -57,6 +55,7 @@
183 Normal, /**< Displayed before Low, after Critical. */
184 Critical /**< Displayed before Low and Normal. */
185 };
186+ Q_ENUM(UrgencyEnum)
187 };
188
189
190@@ -68,8 +67,6 @@
191 {
192 Q_OBJECT
193
194- Q_ENUMS(TypeEnum)
195-
196 public:
197 /**
198 \brief NotificationInterface's type enumeration.
199@@ -85,6 +82,7 @@
200 SnapDecision, /**< Snap decision (multi-button). */
201 Placeholder /**< Non-visible placeholder of default size. */
202 };
203+ Q_ENUM(TypeEnum)
204 };
205
206
207@@ -96,8 +94,6 @@
208 {
209 Q_OBJECT
210
211- Q_FLAGS(HintEnum)
212-
213 public:
214 /**
215 \brief NotificationInterface's hint flags.
216@@ -110,6 +106,7 @@
217 ButtonTint = 1 << 1, /**< Use a colour tint on the positive button in a snap decision. */
218 IconOnly = 1 << 2 /**< Only display the icon, no summary or body. */
219 };
220+ Q_FLAG(HintEnum)
221
222 Q_DECLARE_FLAGS(Hints, HintEnum)
223 };
224
225=== modified file 'include/unity/shell/notifications/ModelInterface.h'
226--- include/unity/shell/notifications/ModelInterface.h 2014-03-31 16:00:27 +0000
227+++ include/unity/shell/notifications/ModelInterface.h 2016-12-23 10:18:10 +0000
228@@ -47,7 +47,6 @@
229 class UNITY_API ModelInterface : public QAbstractListModel
230 {
231 Q_OBJECT
232- Q_ENUMS(Roles)
233
234 /**
235 \brief Whether a placeholder for confirmation should be kept at the beginning
236@@ -91,6 +90,7 @@
237 RoleHints = Qt::UserRole + 10, /** attached hints */
238 RoleNotification = Qt::UserRole + 11 /** notification object */
239 };
240+ Q_ENUM(Roles)
241
242 Q_SIGNALS:
243 /**
244
245=== modified file 'include/unity/shell/scopes/CategoriesInterface.h'
246--- include/unity/shell/scopes/CategoriesInterface.h 2015-10-09 08:30:31 +0000
247+++ include/unity/shell/scopes/CategoriesInterface.h 2016-12-23 10:18:10 +0000
248@@ -38,8 +38,6 @@
249 {
250 Q_OBJECT
251
252- Q_ENUMS(Roles)
253-
254 protected:
255 /// @cond
256 explicit CategoriesInterface(QObject* parent = 0) : QAbstractListModel(parent) { }
257@@ -60,6 +58,7 @@
258 RoleResults,
259 RoleCount
260 };
261+ Q_ENUM(Roles)
262
263 /**
264 * @brief Override definition of a category by passing a custom JSON string.
265
266=== modified file 'include/unity/shell/scopes/FiltersInterface.h'
267--- include/unity/shell/scopes/FiltersInterface.h 2016-03-10 11:11:35 +0000
268+++ include/unity/shell/scopes/FiltersInterface.h 2016-12-23 10:18:10 +0000
269@@ -32,15 +32,13 @@
270 {
271 Q_OBJECT
272
273- Q_ENUMS(Roles)
274- Q_ENUMS(FilterType)
275-
276 public:
277 enum Roles {
278 RoleFilterId = Qt::UserRole + 1,
279 RoleFilterType,
280 RoleFilter
281 };
282+ Q_ENUM(Roles)
283
284 enum FilterType {
285 Invalid,
286@@ -50,6 +48,7 @@
287 ExpandableFilterWidget
288 // TODO add remaining filters
289 };
290+ Q_ENUM(FilterType)
291
292 QHash<int, QByteArray> roleNames() const override
293 {
294
295=== modified file 'include/unity/shell/scopes/NavigationInterface.h'
296--- include/unity/shell/scopes/NavigationInterface.h 2015-09-28 09:35:17 +0000
297+++ include/unity/shell/scopes/NavigationInterface.h 2016-12-23 10:18:10 +0000
298@@ -35,8 +35,6 @@
299 {
300 Q_OBJECT
301
302- Q_ENUMS(Roles)
303-
304 /**
305 * @brief Id of the navigation.
306 */
307@@ -98,6 +96,7 @@
308 RoleHasChildren,
309 RoleIsActive
310 };
311+ Q_ENUM(Roles)
312
313 // @cond
314 virtual QString navigationId() const = 0;
315
316=== modified file 'include/unity/shell/scopes/OptionSelectorOptionsInterface.h'
317--- include/unity/shell/scopes/OptionSelectorOptionsInterface.h 2015-04-02 14:42:29 +0000
318+++ include/unity/shell/scopes/OptionSelectorOptionsInterface.h 2016-12-23 10:18:10 +0000
319@@ -31,14 +31,13 @@
320 {
321 Q_OBJECT
322
323- Q_ENUMS(OptionRoles)
324-
325 public:
326 enum Roles {
327 RoleOptionId = Qt::UserRole + 1,
328 RoleOptionLabel,
329 RoleOptionChecked
330 };
331+ Q_ENUM(Roles)
332
333 Q_INVOKABLE virtual void setChecked(int index, bool checked) = 0;
334
335
336=== modified file 'include/unity/shell/scopes/PreviewModelInterface.h'
337--- include/unity/shell/scopes/PreviewModelInterface.h 2014-05-19 08:42:28 +0000
338+++ include/unity/shell/scopes/PreviewModelInterface.h 2016-12-23 10:18:10 +0000
339@@ -38,8 +38,6 @@
340 {
341 Q_OBJECT
342
343- Q_ENUMS(Roles)
344-
345 /**
346 * @brief Number of column models this preview should expose.
347 *
348@@ -75,6 +73,7 @@
349 enum Roles {
350 RoleColumnModel
351 };
352+ Q_ENUM(Roles)
353
354 // @cond
355 virtual void setWidgetColumnCount(int count) = 0;
356
357=== modified file 'include/unity/shell/scopes/PreviewWidgetModelInterface.h'
358--- include/unity/shell/scopes/PreviewWidgetModelInterface.h 2014-05-15 12:04:55 +0000
359+++ include/unity/shell/scopes/PreviewWidgetModelInterface.h 2016-12-23 10:18:10 +0000
360@@ -37,8 +37,6 @@
361 {
362 Q_OBJECT
363
364- Q_ENUMS(Roles)
365-
366 protected:
367 /// @cond
368 explicit PreviewWidgetModelInterface(QObject* parent = 0) : QAbstractListModel(parent) { }
369@@ -53,6 +51,7 @@
370 RoleType,
371 RoleProperties
372 };
373+ Q_ENUM(Roles)
374
375 // @cond
376 QHash<int, QByteArray> roleNames() const override
377
378=== modified file 'include/unity/shell/scopes/ResultsModelInterface.h'
379--- include/unity/shell/scopes/ResultsModelInterface.h 2016-03-03 09:46:51 +0000
380+++ include/unity/shell/scopes/ResultsModelInterface.h 2016-12-23 10:18:10 +0000
381@@ -35,8 +35,6 @@
382 {
383 Q_OBJECT
384
385- Q_ENUMS(Roles)
386-
387 /**
388 * @brief Id of associated category.
389 */
390@@ -74,6 +72,7 @@
391 RoleQuickPreviewData, ///< Data for UI quick previewing. In case of audio should contain uri and duration
392 RoleSocialActions ///< Data for social actions (in-card actions such as "+1").
393 };
394+ Q_ENUM(Roles)
395
396 // @cond
397 virtual QString categoryId() const = 0;
398
399=== modified file 'include/unity/shell/scopes/ScopeInterface.h'
400--- include/unity/shell/scopes/ScopeInterface.h 2016-03-07 08:27:25 +0000
401+++ include/unity/shell/scopes/ScopeInterface.h 2016-12-23 10:18:10 +0000
402@@ -43,8 +43,6 @@
403 {
404 Q_OBJECT
405
406- Q_ENUMS(Status)
407-
408 /**
409 * @brief Id of the scope.
410 */
411@@ -181,6 +179,7 @@
412 NoLocationData, // No location data available
413 Unknown, // A code unknown to the run-time was used
414 };
415+ Q_ENUM(Status)
416
417 // @cond
418 virtual QString id() const = 0;
419
420=== modified file 'include/unity/shell/scopes/ScopesInterface.h'
421--- include/unity/shell/scopes/ScopesInterface.h 2015-02-04 17:24:55 +0000
422+++ include/unity/shell/scopes/ScopesInterface.h 2016-12-23 10:18:10 +0000
423@@ -39,8 +39,6 @@
424 {
425 Q_OBJECT
426
427- Q_ENUMS(Roles)
428-
429 /**
430 * @brief Boolean indicating whether asynchronous populating of the model finished.
431 */
432@@ -72,6 +70,7 @@
433 RoleId,
434 RoleTitle
435 };
436+ Q_ENUM(Roles)
437
438 /**
439 * @brief Get ScopeInterface instance associated with a row.
440
441=== modified file 'include/unity/shell/scopes/SettingsModelInterface.h'
442--- include/unity/shell/scopes/SettingsModelInterface.h 2014-07-08 09:30:20 +0000
443+++ include/unity/shell/scopes/SettingsModelInterface.h 2016-12-23 10:18:10 +0000
444@@ -32,8 +32,6 @@
445 {
446 Q_OBJECT
447
448-Q_ENUMS(Roles)
449-
450 /**
451 * @brief Integer representing the number of setting elements in the model.
452 */
453@@ -63,6 +61,7 @@
454 RoleProperties,
455 RoleValue
456 };
457+ Q_ENUM(Roles)
458
459 // @cond
460 QHash<int, QByteArray> roleNames() const override
461
462=== modified file 'include/unity/shell/scopes/ValueSliderValuesInterface.h'
463--- include/unity/shell/scopes/ValueSliderValuesInterface.h 2015-12-02 15:04:53 +0000
464+++ include/unity/shell/scopes/ValueSliderValuesInterface.h 2016-12-23 10:18:10 +0000
465@@ -31,13 +31,12 @@
466 {
467 Q_OBJECT
468
469- Q_ENUMS(SliderValueRoles)
470-
471 public:
472 enum Roles {
473 RoleValue = Qt::UserRole + 1,
474 RoleLabel
475 };
476+ Q_ENUM(Roles)
477
478 QHash<int, QByteArray> roleNames() const override
479 {
480
481=== modified file 'test/qmltest/mocks/plugins/Unity/Notifications/Mocks/MockActionModel.h'
482--- test/qmltest/mocks/plugins/Unity/Notifications/Mocks/MockActionModel.h 2016-12-23 10:18:10 +0000
483+++ test/qmltest/mocks/plugins/Unity/Notifications/Mocks/MockActionModel.h 2016-12-23 10:18:10 +0000
484@@ -30,8 +30,6 @@
485 class UNITY_API MockActionModel : public QAbstractListModel
486 {
487 Q_OBJECT
488-
489- Q_ENUMS(RoleEnum)
490 public:
491 explicit MockActionModel(QObject *parent = 0);
492
493@@ -44,6 +42,7 @@
494 Label = Qt::DisplayRole,
495 Id = Qt::UserRole
496 };
497+ Q_ENUM(RoleEnum)
498
499 private:
500 QHash<int, QByteArray> m_roles;
501
502=== modified file 'test/qmltest/mocks/plugins/Unity/Notifications/Mocks/MockModel.h'
503--- test/qmltest/mocks/plugins/Unity/Notifications/Mocks/MockModel.h 2016-12-23 10:18:10 +0000
504+++ test/qmltest/mocks/plugins/Unity/Notifications/Mocks/MockModel.h 2016-12-23 10:18:10 +0000
505@@ -36,8 +36,6 @@
506 {
507 Q_OBJECT
508
509- Q_ENUMS(RoleEnum)
510-
511 public:
512 MockModel(QObject* parent = 0);
513
514@@ -68,6 +66,7 @@
515 Hints,
516 Actions
517 };
518+ Q_ENUM(RoleEnum)
519
520 private:
521 bool m_confirmationPlaceholder;
522
523=== modified file 'test/qmltest/mocks/plugins/Unity/Scopes/Mocks/MockPreviewWidgetModel.h'
524--- test/qmltest/mocks/plugins/Unity/Scopes/Mocks/MockPreviewWidgetModel.h 2014-05-13 13:52:12 +0000
525+++ test/qmltest/mocks/plugins/Unity/Scopes/Mocks/MockPreviewWidgetModel.h 2016-12-23 10:18:10 +0000
526@@ -22,7 +22,7 @@
527
528 #include <QSharedPointer>
529
530-class MockPreviewData;
531+struct MockPreviewData;
532
533 class MockPreviewWidgetModel : public unity::shell::scopes::PreviewWidgetModelInterface
534 {

Subscribers

People subscribed via source and target branches

to all changes: