diff options
-rw-r--r-- | components/mail/contents/ui/Mail.qml | 7 | ||||
-rw-r--r-- | components/package/contents/ui/FolderListView.qml | 6 | ||||
-rw-r--r-- | components/theme/contents/ui/Icons.qml | 31 | ||||
-rw-r--r-- | components/theme/qmldir | 1 |
4 files changed, 39 insertions, 6 deletions
diff --git a/components/mail/contents/ui/Mail.qml b/components/mail/contents/ui/Mail.qml index 0643287f..1bdbc5ed 100644 --- a/components/mail/contents/ui/Mail.qml +++ b/components/mail/contents/ui/Mail.qml | |||
@@ -31,6 +31,7 @@ import org.kube.framework.notifications 1.0 as KubeNotifications | |||
31 | import org.kube.framework.accounts 1.0 as KubeAccountsFramework | 31 | import org.kube.framework.accounts 1.0 as KubeAccountsFramework |
32 | import org.kube.components 1.0 as KubeComponents | 32 | import org.kube.components 1.0 as KubeComponents |
33 | import org.kube.components.accounts 1.0 as KubeAccounts | 33 | import org.kube.components.accounts 1.0 as KubeAccounts |
34 | import org.kube.components.theme 1.0 as KubeTheme | ||
34 | 35 | ||
35 | Controls2.ApplicationWindow { | 36 | Controls2.ApplicationWindow { |
36 | id: app | 37 | id: app |
@@ -298,15 +299,15 @@ Controls2.ApplicationWindow { | |||
298 | states: [ | 299 | states: [ |
299 | State { | 300 | State { |
300 | name: "busy"; when: model.status == KubeAccountsFramework.AccountsModel.BusyStatus | 301 | name: "busy"; when: model.status == KubeAccountsFramework.AccountsModel.BusyStatus |
301 | PropertyChanges { target: statusIcon; iconName: "view-refresh"; visible: true } | 302 | PropertyChanges { target: statusIcon; iconName: KubeTheme.Icons.busy; visible: true } |
302 | }, | 303 | }, |
303 | State { | 304 | State { |
304 | name: "error"; when: model.status == KubeAccountsFramework.AccountsModel.ErrorStatus | 305 | name: "error"; when: model.status == KubeAccountsFramework.AccountsModel.ErrorStatus |
305 | PropertyChanges { target: statusIcon; iconName: "emblem-error"; visible: true } | 306 | PropertyChanges { target: statusIcon; iconName: KubeTheme.Icons.error; visible: true } |
306 | }, | 307 | }, |
307 | State { | 308 | State { |
308 | name: "checkmark"; when: model.status == KubeAccountsFramework.AccountsModel.ConnectedStatus | 309 | name: "checkmark"; when: model.status == KubeAccountsFramework.AccountsModel.ConnectedStatus |
309 | PropertyChanges { target: statusIcon; iconName: "checkmark"; visible: true } | 310 | PropertyChanges { target: statusIcon; iconName: KubeTheme.Icons.connected; visible: true } |
310 | } | 311 | } |
311 | ] | 312 | ] |
312 | } | 313 | } |
diff --git a/components/package/contents/ui/FolderListView.qml b/components/package/contents/ui/FolderListView.qml index 1a2f055c..c0b9c222 100644 --- a/components/package/contents/ui/FolderListView.qml +++ b/components/package/contents/ui/FolderListView.qml | |||
@@ -171,17 +171,17 @@ Rectangle { | |||
171 | states: [ | 171 | states: [ |
172 | State { | 172 | State { |
173 | name: "busy"; when: model.status == KubeFramework.FolderListModel.InProgressStatus | 173 | name: "busy"; when: model.status == KubeFramework.FolderListModel.InProgressStatus |
174 | PropertyChanges { target: statusIcon; iconName: "view-refresh"; visible: styleData.selected } | 174 | PropertyChanges { target: statusIcon; iconName: KubeTheme.Icons.busy ; visible: styleData.selected } |
175 | }, | 175 | }, |
176 | State { | 176 | State { |
177 | name: "error"; when: model.status == KubeFramework.FolderListModel.ErrorStatus | 177 | name: "error"; when: model.status == KubeFramework.FolderListModel.ErrorStatus |
178 | //The error status should only be visible for a moment, otherwise we'll eventually always show errors everywhere. | 178 | //The error status should only be visible for a moment, otherwise we'll eventually always show errors everywhere. |
179 | PropertyChanges { target: statusIcon; iconName: "emblem-error"; visible: styleData.selected } | 179 | PropertyChanges { target: statusIcon; iconName: KubeTheme.Icons.error; visible: styleData.selected } |
180 | }, | 180 | }, |
181 | State { | 181 | State { |
182 | name: "checkmark"; when: model.status == KubeFramework.FolderListModel.SuccessStatus | 182 | name: "checkmark"; when: model.status == KubeFramework.FolderListModel.SuccessStatus |
183 | //The success status should only be visible for a moment, otherwise we'll eventually always show checkmarks everywhere. | 183 | //The success status should only be visible for a moment, otherwise we'll eventually always show checkmarks everywhere. |
184 | PropertyChanges { target: statusIcon; iconName: "checkmark"; visible: styleData.selected } | 184 | PropertyChanges { target: statusIcon; iconName: KubeTheme.Icons.success; visible: styleData.selected } |
185 | } | 185 | } |
186 | ] | 186 | ] |
187 | } | 187 | } |
diff --git a/components/theme/contents/ui/Icons.qml b/components/theme/contents/ui/Icons.qml new file mode 100644 index 00000000..417a598c --- /dev/null +++ b/components/theme/contents/ui/Icons.qml | |||
@@ -0,0 +1,31 @@ | |||
1 | /* | ||
2 | Copyright (C) 2017 Michael Bohlender, <bohlender@kolabsys.com> | ||
3 | Copyright (C) 2017 Christian Mollekopf, <mollekopf@kolabsys.com> | ||
4 | |||
5 | This program is free software; you can redistribute it and/or modify | ||
6 | it under the terms of the GNU General Public License as published by | ||
7 | the Free Software Foundation; either version 2 of the License, or | ||
8 | (at your option) any later version. | ||
9 | |||
10 | This program is distributed in the hope that it will be useful, | ||
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
13 | GNU General Public License for more details. | ||
14 | |||
15 | You should have received a copy of the GNU General Public License along | ||
16 | with this program; if not, write to the Free Software Foundation, Inc., | ||
17 | 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. | ||
18 | */ | ||
19 | |||
20 | pragma Singleton | ||
21 | |||
22 | import QtQuick 2.7 | ||
23 | |||
24 | Item { | ||
25 | property string error: "error" | ||
26 | property string busy: "view-refresh" | ||
27 | property string noNetworkConnection: "network-disconnect" | ||
28 | property string connected: "checkmark" | ||
29 | property string success: "checkmark" | ||
30 | } | ||
31 | |||
diff --git a/components/theme/qmldir b/components/theme/qmldir index 29cb06d9..6d11dd64 100644 --- a/components/theme/qmldir +++ b/components/theme/qmldir | |||
@@ -1,3 +1,4 @@ | |||
1 | module org.kube.components.theme | 1 | module org.kube.components.theme |
2 | 2 | ||
3 | singleton Colors 1.0 Colors.qml | 3 | singleton Colors 1.0 Colors.qml |
4 | singleton Icons 1.0 Icons.qml | ||