summaryrefslogtreecommitdiffstats
path: root/components/mailviewer/contents/ui/EncryptionPart.qml
diff options
context:
space:
mode:
Diffstat (limited to 'components/mailviewer/contents/ui/EncryptionPart.qml')
-rw-r--r--components/mailviewer/contents/ui/EncryptionPart.qml75
1 files changed, 75 insertions, 0 deletions
diff --git a/components/mailviewer/contents/ui/EncryptionPart.qml b/components/mailviewer/contents/ui/EncryptionPart.qml
new file mode 100644
index 00000000..058c9af7
--- /dev/null
+++ b/components/mailviewer/contents/ui/EncryptionPart.qml
@@ -0,0 +1,75 @@
1/*
2 Copyright (C) 2016 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
19import QtQuick 2.4
20
21Item {
22 id: encryption
23 property alias rootIndex: visualModel.rootIndex
24 property bool debug: true
25 height: partListView.height
26 width: parent.width
27
28 MailDataModel {
29 id: visualModel
30 debug: encryption.debug
31 model: messageParser.newTree
32 }
33
34 Column {
35 id: partListView
36 anchors {
37 top: parent.top
38 left: parent.left
39 }
40 width: parent.width
41 spacing: 5
42 Text {
43 width: parent.width
44 visible: encryption.debug
45 text: model.type
46 }
47 Text {
48 visible: model.errorType || encryption.debug
49 text: model.errorType + ": " + model.errorString
50 }
51 BorderImage {
52 width: parent.width
53 height: childrenRect.height + 40
54 border { left: 5; top: 5; right: 6; bottom: 6 }
55 horizontalTileMode: BorderImage.Round
56 verticalTileMode: BorderImage.Round
57
58 source: /* "securityborders"+ */ model.securityLevel +".png"
59 ListView {
60 model: visualModel
61 anchors {
62 top: parent.top
63 left: parent.left
64 margins: 20
65 }
66 height: contentHeight
67 width: parent.width - 40
68
69 spacing: 20
70
71 interactive: false
72 }
73 }
74 }
75}