Unity 8
 All Classes Functions Properties
indicators.h
1 /*
2  * Copyright (C) 2012 Canonical, Ltd.
3  *
4  * This program is free software; you can redistribute it and/or modify
5  * it under the terms of the GNU General Public License as published by
6  * the Free Software Foundation; version 3.
7  *
8  * This program is distributed in the hope that it will be useful,
9  * but WITHOUT ANY WARRANTY; without even the implied warranty of
10  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11  * GNU General Public License for more details.
12  *
13  * You should have received a copy of the GNU General Public License
14  * along with this program. If not, see <http://www.gnu.org/licenses/>.
15  *
16  * Author: Nick Dedekind <nick.dedekind@canonical.com>
17  */
18 
19 #ifndef INDICATORS_H
20 #define INDICATORS_H
21 
22 #include "unityindicatorsglobal.h"
23 
24 #include <QObject>
25 
26 class UNITYINDICATORS_EXPORT ActionState : public QObject
27 {
28  Q_OBJECT
29 public:
30  Q_ENUMS(ActionStates)
31  enum ActionStates {
32  Label = 0x00,
33  IconSource = 0x01,
34  AccessableName = 0x02,
35  Visible = 0x03,
36  };
37 
38  ActionState(QObject*parent=0):QObject(parent) {}
39 };
40 
41 class UNITYINDICATORS_EXPORT NetworkActionState : public QObject
42 {
43  Q_OBJECT
44 public:
45  Q_ENUMS(NetworkActionStates)
46  enum NetworkActionStates {
47  Connection = 0x01,
48  SignalStrength = 0x02,
49  };
50 
51  NetworkActionState(QObject*parent=0):QObject(parent) {}
52 };
53 
54 class UNITYINDICATORS_EXPORT NetworkConnection : public QObject
55 {
56  Q_OBJECT
57 public:
58  Q_ENUMS(NetworkConnectionStates)
59  enum NetworkConnectionStates {
60  Initial = 0x00,
61  Activating = 0x01,
62  Activated = 0x02,
63  Deactivating = 0x03,
64  };
65 
66  NetworkConnection(QObject*parent=0):QObject(parent) {}
67 };
68 
69 class UNITYINDICATORS_EXPORT IndicatorsModelRole : public QObject
70 {
71  Q_OBJECT
72 public:
73  Q_ENUMS(Roles)
74  enum Roles {
75  Identifier = 0,
76  Position,
77  WidgetSource,
78  PageSource,
79  IndicatorProperties,
80  IsVisible
81  };
82 
83  IndicatorsModelRole(QObject*parent=0):QObject(parent) {}
84 };
85 
86 class UNITYINDICATORS_EXPORT FlatMenuProxyModelRole : public QObject
87 {
88  Q_OBJECT
89 public:
90  Q_ENUMS(Roles)
91  enum Roles {
92  Action = Qt::DisplayRole + 1,
93  Label,
94  Extra,
95  Depth,
96  hasSection,
97  hasSubMenu
98  };
99 
100  FlatMenuProxyModelRole(QObject*parent=0):QObject(parent) {}
101 };
102 
103 #endif // INDICATORS_H