• Skip to content
  • Skip to link menu
  • KDE API Reference
  • kdepimlibs-4.14.10 API Reference
  • KDE Home
  • Contact Us
 

akonadi

  • akonadi
CollectionDialogMobile.qml
1/*
2 Copyright 2010 Tobias Koenig <tokoe@kde.org>
3
4 This library is free software; you can redistribute it and/or modify it
5 under the terms of the GNU Library General Public License as published by
6 the Free Software Foundation; either version 2 of the License, or (at your
7 option) any later version.
8
9 This library is distributed in the hope that it will be useful, but WITHOUT
10 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public
12 License for more details.
13
14 You should have received a copy of the GNU Library General Public License
15 along with this library; see the file COPYING.LIB. If not, write to the
16 Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
17 02110-1301, USA.
18*/
19import Qt 4.7 as QML
20import org.kde.pim.mobileui 4.5 as KPIM
21
22QML.Rectangle {
23 width : 780
24 height : 460
25 color : palette.window
26
27 QML.SystemPalette {
28 id: palette
29 colorGroup: QML.SystemPalette.Active
30 }
31
32 QML.Text {
33 id : descriptionText
34 anchors.top : parent.top
35 anchors.left : parent.left
36 anchors.leftMargin : 15
37 height : text == "" ? 0 : 20
38 text : dialogController.descriptionText
39 font.bold : true
40 verticalAlignment : QML.Text.AlignVCenter
41 }
42
43 QML.ListView {
44 id : listView
45 anchors.top : descriptionText.bottom
46 anchors.topMargin : 20
47 anchors.left : parent.left
48 anchors.leftMargin : 15
49 anchors.right : parent.right
50 anchors.rightMargin : 15
51 anchors.bottom : filterLine.top
52 clip : true
53 boundsBehavior : QML.Flickable.StopAtBounds
54
55 model : collectionModel
56
57 delegate : QML.Rectangle {
58 width : listView.width
59 height : 35
60
61 QML.Rectangle {
62 anchors.fill : parent
63 color : "lightsteelblue"
64 opacity : QML.ListView.isCurrentItem ? 0.30 : 0
65 radius : 10
66 }
67
68 QML.Text {
69 anchors.fill : parent
70 anchors.leftMargin : 15
71 text : model.display
72 verticalAlignment : QML.Text.AlignVCenter
73 }
74
75 QML.MouseArea {
76 anchors.fill : parent
77 onClicked : listView.currentIndex = model.index
78 }
79 }
80
81 QML.Connections {
82 target : dialogController
83
84 onSelectionChanged : listView.currentIndex = row
85 }
86
87 onCurrentIndexChanged : dialogController.setCurrentIndex( currentIndex )
88 }
89
90 QML.TextInput {
91 id : filterLine
92 anchors.topMargin : 5
93 anchors.left : parent.left
94 anchors.leftMargin : 20
95 anchors.right : parent.right
96 anchors.rightMargin : 20
97 anchors.bottom : okButton.top
98 anchors.bottomMargin : 5
99
100 focus : true
101 height : text == "" ? 0 : 20
102 opacity : text == "" ? 0 : 1
103
104 onTextChanged : dialogController.setFilterText( text )
105
106 QML.Rectangle {
107 anchors.fill : parent
108 anchors.leftMargin : -5
109 anchors.rightMargin : -5
110 z: parent.z - 1
111 color : "lightsteelblue"
112 opacity : 0.50
113 radius : 5
114 }
115 }
116
117 KPIM.Button2 {
118 id : createButton
119 anchors.right : okButton.left
120 anchors.rightMargin : 100
121 anchors.bottom : parent.bottom
122 width : 150
123
124 buttonText : createButtonText
125 onClicked : dialogController.createClicked()
126 enabled : dialogController.createButtonEnabled
127 visible : dialogController.createButtonVisible
128 }
129
130 KPIM.Button2 {
131 id : okButton
132 anchors.right : cancelButton.left
133 anchors.bottom : parent.bottom
134 width : 150
135
136 buttonText : okButtonText
137 onClicked : dialogController.okClicked()
138 enabled : dialogController.okButtonEnabled
139 }
140
141 KPIM.Button2 {
142 id: cancelButton
143 anchors.right : parent.right
144 anchors.rightMargin: 15
145 anchors.bottom : parent.bottom
146 width : 150
147
148 buttonText : cancelButtonText
149 onClicked : dialogController.cancelClicked()
150 enabled : dialogController.cancelButtonEnabled
151 }
152}
This file is part of the KDE documentation.
Documentation copyright © 1996-2022 The KDE developers.
Generated on Thu Jul 21 2022 00:00:00 by doxygen 1.9.5 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

akonadi

Skip menu "akonadi"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • Modules
  • Related Pages

kdepimlibs-4.14.10 API Reference

Skip menu "kdepimlibs-4.14.10 API Reference"
  • akonadi
  •   contact
  •   kmime
  •   socialutils
  • kabc
  • kalarmcal
  • kblog
  • kcal
  • kcalcore
  • kcalutils
  • kholidays
  • kimap
  • kioslave
  •   imap4
  •   mbox
  •   nntp
  • kldap
  • kmbox
  • kmime
  • kontactinterface
  • kpimidentities
  • kpimtextedit
  • kpimutils
  • kresources
  • ktnef
  • kxmlrpcclient
  • mailtransport
  • microblog
  • qgpgme
  • syndication
  •   atom
  •   rdf
  •   rss2
Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal