diff options
-rw-r--r-- | components/mail/contents/ui/main.qml | 17 | ||||
-rw-r--r-- | components/package/contents/ui/People.qml | 133 | ||||
-rw-r--r-- | components/qmldir | 1 |
3 files changed, 151 insertions, 0 deletions
diff --git a/components/mail/contents/ui/main.qml b/components/mail/contents/ui/main.qml index 2afac750..88aabf7e 100644 --- a/components/mail/contents/ui/main.qml +++ b/components/mail/contents/ui/main.qml | |||
@@ -162,6 +162,10 @@ Controls2.ApplicationWindow { | |||
162 | iconName: "user" | 162 | iconName: "user" |
163 | height: Kirigami.Units.gridUnit * 1.5 | 163 | height: Kirigami.Units.gridUnit * 1.5 |
164 | width: height | 164 | width: height |
165 | |||
166 | onClicked: { | ||
167 | people.open() | ||
168 | } | ||
165 | } | 169 | } |
166 | 170 | ||
167 | ToolButton { | 171 | ToolButton { |
@@ -309,4 +313,17 @@ Controls2.ApplicationWindow { | |||
309 | } | 313 | } |
310 | } | 314 | } |
311 | //END Search | 315 | //END Search |
316 | |||
317 | //BEGIN People | ||
318 | KubeComponents.People { | ||
319 | id: people | ||
320 | |||
321 | height: app.height * 0.85 | ||
322 | width: app.width * 0.85 | ||
323 | |||
324 | x: app.width * 0.075 | ||
325 | y: app.height * 0.075 | ||
326 | |||
327 | } | ||
328 | //END People | ||
312 | } | 329 | } |
diff --git a/components/package/contents/ui/People.qml b/components/package/contents/ui/People.qml new file mode 100644 index 00000000..47dd82ec --- /dev/null +++ b/components/package/contents/ui/People.qml | |||
@@ -0,0 +1,133 @@ | |||
1 | /* | ||
2 | Copyright (C) 2017 Michael Bohlender, <michael.bohlender@kdemail.net> | ||
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; either version 2 of the License, or | ||
7 | (at your option) any later version. | ||
8 | |||
9 | This program is distributed in the hope that it will be useful, | ||
10 | but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
11 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
12 | GNU General Public License for more details. | ||
13 | |||
14 | You should have received a copy of the GNU General Public License along | ||
15 | with this program; if not, write to the Free Software Foundation, Inc., | ||
16 | 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. | ||
17 | */ | ||
18 | |||
19 | import QtQuick 2.7 | ||
20 | import QtQuick.Controls 2.0 | ||
21 | import QtQuick.Controls 1.4 as Controls | ||
22 | import QtQuick.Layouts 1.1 | ||
23 | |||
24 | import org.kde.kirigami 1.0 as Kirigami | ||
25 | |||
26 | Popup { | ||
27 | |||
28 | modal: true | ||
29 | |||
30 | Controls.SplitView { | ||
31 | anchors.fill: parent | ||
32 | |||
33 | Item { | ||
34 | height: parent.height | ||
35 | width: Kirigami.Units.gridUnit * 14 | ||
36 | |||
37 | Item { | ||
38 | id: toolBar | ||
39 | |||
40 | width: parent.width - scroll.width | ||
41 | height: Kirigami.Units.gridUnit * 2 | ||
42 | |||
43 | Rectangle { | ||
44 | |||
45 | anchors.centerIn: parent | ||
46 | |||
47 | height: Kirigami.Units.gridUnit * 1.5 | ||
48 | width: parent.width* 0.8 | ||
49 | |||
50 | color: "#27ae60" | ||
51 | |||
52 | clip: true | ||
53 | |||
54 | Text { | ||
55 | |||
56 | anchors.centerIn: parent | ||
57 | |||
58 | clip: true | ||
59 | |||
60 | text: "New Contact" | ||
61 | |||
62 | color: "white" | ||
63 | } | ||
64 | } | ||
65 | } | ||
66 | |||
67 | ListView { | ||
68 | id: listView | ||
69 | |||
70 | anchors { | ||
71 | top: toolBar.bottom | ||
72 | left: parent.left | ||
73 | right: parent.right | ||
74 | bottom: parent.bottom | ||
75 | topMargin: Kirigami.Units.smallSpacing | ||
76 | } | ||
77 | |||
78 | model: 15 | ||
79 | clip: true | ||
80 | |||
81 | ScrollBar.vertical: ScrollBar { | ||
82 | id: scroll | ||
83 | } | ||
84 | |||
85 | delegate: Kirigami.AbstractListItem { | ||
86 | height: Kirigami.Units.gridUnit * 2.5 | ||
87 | width: listView.width - scroll.width | ||
88 | |||
89 | clip: true | ||
90 | |||
91 | Avatar { | ||
92 | id: avatar | ||
93 | |||
94 | anchors { | ||
95 | verticalCenter: parent.verticalCenter | ||
96 | left: parent.left | ||
97 | leftMargin: Kirigami.Units.smallSpacing | ||
98 | } | ||
99 | |||
100 | height: parent.height * 0.9 | ||
101 | width: height | ||
102 | |||
103 | name: "Wolfgang Rosenzweig" | ||
104 | } | ||
105 | |||
106 | Text { | ||
107 | id: name | ||
108 | |||
109 | anchors { | ||
110 | left: avatar.right | ||
111 | leftMargin: Kirigami.Units.smallSpacing | ||
112 | verticalCenter: avatar.verticalCenter | ||
113 | } | ||
114 | |||
115 | text: "Wolfgang Rosenzweig" | ||
116 | color: Kirigami.Theme.textColor | ||
117 | } | ||
118 | } | ||
119 | } | ||
120 | } | ||
121 | |||
122 | Item { | ||
123 | height: parent.height | ||
124 | Layout.fillWidth: true | ||
125 | |||
126 | ToolBar { | ||
127 | |||
128 | width: parent.width | ||
129 | height: Kirigami.Units.gridUnit * 2 | ||
130 | } | ||
131 | } | ||
132 | } | ||
133 | } | ||
diff --git a/components/qmldir b/components/qmldir index fe1d542f..84015b1e 100644 --- a/components/qmldir +++ b/components/qmldir | |||
@@ -10,3 +10,4 @@ NewAccountDialog 1.0 NewAccountDialog.qml | |||
10 | EditAccountDialog 1.0 EditAccountDialog.qml | 10 | EditAccountDialog 1.0 EditAccountDialog.qml |
11 | OverlayDialog 1.0 OverlayDialog.qml | 11 | OverlayDialog 1.0 OverlayDialog.qml |
12 | Outbox 1.0 Outbox.qml | 12 | Outbox 1.0 Outbox.qml |
13 | People 1.0 People.qml | ||