X-Git-Url: http://git.maemo.org/git/?a=blobdiff_plain;f=src%2Fmdictionary%2Fqml%2FDictTypeSelectDialog.qml;h=e57069ab0203401c011a1ca954c152a0b0c9b2e0;hb=6e43150fac4affb7e2cb3f6d50ee727bcddba9a1;hp=5bf3b73fa645cd7f6599ea260f765a92bb23f068;hpb=d6bf5664a12c5a809096f1f12e9b38bdf2dd74df;p=mdictionary
diff --git a/src/mdictionary/qml/DictTypeSelectDialog.qml b/src/mdictionary/qml/DictTypeSelectDialog.qml
index 5bf3b73..e57069a 100644
--- a/src/mdictionary/qml/DictTypeSelectDialog.qml
+++ b/src/mdictionary/qml/DictTypeSelectDialog.qml
@@ -1,33 +1,67 @@
+/*******************************************************************************
+
+ This file is part of mDictionary.
+
+ mDictionary is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ mDictionary is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with mDictionary. If not, see .
+
+ Copyright 2010 Comarch S.A.
+
+*******************************************************************************/
+/*!
+ author: Marcin Kaźmierczak
+*/
+
import Qt 4.7
Rectangle {
SystemPalette { id: myPalette; colorGroup: SystemPalette.Active }
+ signal selectedRow(int nr)
id: rectangle1
- //width: (helloText.width > logo.width) ? (helloText.width) : (logo.width)
- //height: logo.height + helloText.height
- color: myPalette.window
+ color: myPalette.base
anchors.fill: parent
- DictTypeListView{
+ ElementsListView{
id: dictTypeList
+ width: rectangle1.width
+ height: rectangle1.height
+ highlightResizeSpeed: 1000
+ delegate: Component{
+ id: dictTypeListDelegate
+ Item {
+ width: rectangle1.width
+ height: typeText.height
+ MouseArea{
+ anchors.fill: parent
+ onClicked: {
+ dictTypeList.currentIndex = number
+ }
+ onDoubleClicked: {
+ selectedRow(number)
+ }
+ }
+ Row {
+ Text {
+ id: typeText
+ text: type
+ width: rectangle1.width
+ }
+ }
+ }
+ }
+ model: dictTypeModel
}
-// Image {
-// id: logo
-// source: "qrc:/icons/logo/mdictionary.png"
-// width: 240
-// height: 200
-// anchors.horizontalCenter: parent.horizontalCenter
-// fillMode: Image.PreserveAspectFit
-// anchors.top: parent.top
-// }
-
-// Text {
-// id: helloText
-// text: qsTr("Welcome in mDictionary!
")
-// anchors.bottom: parent.bottom
-// }
-
}