Commit ff68a2ec authored by Martin Straka's avatar Martin Straka Committed by Karel Slaný

Refactoring account detail page

parent 9309c6ab
......@@ -22,7 +22,7 @@
*/
import QtQuick 2.7
import QtQuick.Controls 2.0
import QtQuick.Controls 2.1
import cz.nic.mobileDatovka 1.0
Component {
......@@ -70,38 +70,19 @@ Component {
}
}
}
}
Text {
id: emptyList
visible: true
color: datovkaPalette.text
anchors.centerIn: parent
text: qsTr("Account info has not been downloaded yet.")
}
Rectangle {
id: accountDetail
} // PageHeader
Flickable {
id: flickable
z: 0
anchors.top: headerBar.bottom
width: parent.width
height: parent.height
visible: false
color: datovkaPalette.base
ListModel {
id: accountDetailModel
ListElement {
text: ""
}
}
ListView {
id: accountDetailList
anchors.right: parent.right
anchors.left: parent.left
anchors.bottom: parent.bottom
contentHeight: flickContent.implicitHeight
Pane {
id: flickContent
anchors.fill: parent
anchors.margins: defaultMargin
clip: true
spacing: 0
opacity: 1
visible: true
interactive: true
model: accountDetailModel
delegate: Text {
Text {
id: accountDetailText
color: datovkaPalette.text
width: parent.width
......@@ -111,13 +92,20 @@ Component {
target: accounts
onAccountDetailChanged: {
emptyList.visible = false
accountDetail.visible = true
flickable.visible = true
accountDetailText.text = txt
}
}
}
}
}
} // Pane
ScrollIndicator.vertical: ScrollIndicator {}
} // Flickable
Text {
id: emptyList
visible: true
color: datovkaPalette.text
anchors.centerIn: parent
text: qsTr("Account info has not been downloaded yet.")
} // Text
}
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment