diff options
Diffstat (limited to 'components/package/contents/ui')
-rw-r--r-- | components/package/contents/ui/AccountSwitcher.qml | 7 | ||||
-rw-r--r-- | components/package/contents/ui/MailListView.qml | 61 |
2 files changed, 61 insertions, 7 deletions
diff --git a/components/package/contents/ui/AccountSwitcher.qml b/components/package/contents/ui/AccountSwitcher.qml index 16e84931..6d1c0aa2 100644 --- a/components/package/contents/ui/AccountSwitcher.qml +++ b/components/package/contents/ui/AccountSwitcher.qml | |||
@@ -38,9 +38,6 @@ Controls2.Button { | |||
38 | id: folderController | 38 | id: folderController |
39 | } | 39 | } |
40 | 40 | ||
41 | Layout.fillWidth: true | ||
42 | height: parent.height | ||
43 | |||
44 | text: "Accounts" | 41 | text: "Accounts" |
45 | 42 | ||
46 | onClicked: { | 43 | onClicked: { |
@@ -54,8 +51,8 @@ Controls2.Button { | |||
54 | height: 300 | 51 | height: 300 |
55 | width: 600 | 52 | width: 600 |
56 | 53 | ||
57 | x: parent.x | 54 | x: 0 |
58 | y: parent.y + parent.height | 55 | y: - popup.height |
59 | 56 | ||
60 | modal: true | 57 | modal: true |
61 | focus: true | 58 | focus: true |
diff --git a/components/package/contents/ui/MailListView.qml b/components/package/contents/ui/MailListView.qml index cb0bd4bf..68db1c43 100644 --- a/components/package/contents/ui/MailListView.qml +++ b/components/package/contents/ui/MailListView.qml | |||
@@ -18,6 +18,7 @@ | |||
18 | 18 | ||
19 | import QtQuick 2.7 | 19 | import QtQuick 2.7 |
20 | import QtQuick.Controls 2.0 | 20 | import QtQuick.Controls 2.0 |
21 | import QtQuick.Controls 1.4 as Controls | ||
21 | import QtQuick.Layouts 1.1 | 22 | import QtQuick.Layouts 1.1 |
22 | import QtQml 2.2 as QtQml | 23 | import QtQml 2.2 as QtQml |
23 | 24 | ||
@@ -36,12 +37,68 @@ Item { | |||
36 | currentMail = null | 37 | currentMail = null |
37 | } | 38 | } |
38 | 39 | ||
39 | ListView { | 40 | ToolBar { |
41 | id: toolbar | ||
42 | |||
43 | width: parent.width | ||
44 | |||
45 | Row { | ||
46 | anchors.centerIn: parent | ||
47 | |||
48 | spacing: Kirigami.Units.smallSpacing | ||
49 | |||
50 | Controls.ToolButton { | ||
51 | iconName: "mail-mark-unread" | ||
52 | text: qsTr("Mark As Read") | ||
53 | enabled: mailController.markAsReadAction.enabled | ||
54 | tooltip: qsTr("mark mail as read") | ||
55 | onClicked: { | ||
56 | mailController.markAsReadAction.execute() | ||
57 | } | ||
58 | } | ||
59 | |||
60 | Controls.ToolButton { | ||
61 | iconName: "mail-mark-important" | ||
62 | text: qsTr("Mark Important") | ||
63 | enabled: mailController.markAsImportantAction.enabled | ||
64 | tooltip: qsTr("mark mail as important") | ||
65 | onClicked: { | ||
66 | mailController.markAsImportantAction.execute() | ||
67 | } | ||
68 | } | ||
69 | |||
70 | Controls.ToolButton { | ||
71 | iconName: "edit-delete" | ||
72 | text: qsTr("Delete Mail") | ||
73 | enabled: mailController.moveToTrashAction.enabled | ||
74 | tooltip: qsTr("delete email") | ||
75 | onClicked: { | ||
76 | mailController.moveToTrashAction.execute() | ||
77 | } | ||
78 | } | ||
79 | |||
80 | Controls.ToolButton { | ||
81 | iconName: "edit-undo" | ||
82 | text: qsTr("Restore Mail") | ||
83 | enabled: mailController.restoreFromTrashAction.enabled | ||
84 | tooltip: qsTr("restore email") | ||
85 | onClicked: { | ||
86 | mailController.restoreFromTrashAction.execute() | ||
87 | } | ||
88 | } | ||
89 | } | ||
90 | } | ||
91 | |||
92 | ListView { | ||
40 | id: listView | 93 | id: listView |
41 | 94 | ||
42 | anchors.fill: parent | 95 | anchors.top: toolbar.bottom |
96 | |||
97 | width: parent.width | ||
98 | height: parent.height - toolbar.height | ||
43 | 99 | ||
44 | focus: true | 100 | focus: true |
101 | clip: true | ||
45 | 102 | ||
46 | ScrollBar.vertical: ScrollBar{ | 103 | ScrollBar.vertical: ScrollBar{ |
47 | id: scrollbar | 104 | id: scrollbar |