summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristian Mollekopf <chrigi_1@fastmail.fm>2018-06-30 11:20:38 +0200
committerChristian Mollekopf <chrigi_1@fastmail.fm>2018-06-30 11:20:38 +0200
commit88616288d8541397776b54c5546d61af835483af (patch)
tree9c97d997836f68cd4f7a6e851cb6fed79b89fecb
parent845e2e99fd869be1d8d12f69590131bdfb988768 (diff)
downloadkube-88616288d8541397776b54c5546d61af835483af.tar.gz
kube-88616288d8541397776b54c5546d61af835483af.zip
Fixed the problem where the text could take the background color
The issue was that isActive != selected. The folder remains active even if we select a mail, but it doesn't remain selected.
-rw-r--r--framework/qml/FolderListView.qml4
1 files changed, 3 insertions, 1 deletions
diff --git a/framework/qml/FolderListView.qml b/framework/qml/FolderListView.qml
index bf1f52e5..fe91aacc 100644
--- a/framework/qml/FolderListView.qml
+++ b/framework/qml/FolderListView.qml
@@ -41,6 +41,8 @@ Kube.TreeView {
41 title: "Name" 41 title: "Name"
42 role: "name" 42 role: "name"
43 delegate: Item { 43 delegate: Item {
44 id: delegateRoot
45 property bool isActive: root.activeIndex === root.indexFromRow(styleData.row)
44 DropArea { 46 DropArea {
45 anchors.fill: parent 47 anchors.fill: parent
46 Rectangle { 48 Rectangle {
@@ -64,7 +66,7 @@ Kube.TreeView {
64 } 66 }
65 text: styleData.value 67 text: styleData.value
66 elide: Qt.ElideRight 68 elide: Qt.ElideRight
67 color: (model.hasNewData && !styleData.selected) ? Kube.Colors.highlightColor : Kube.Colors.viewBackgroundColor 69 color: (model.hasNewData && !delegateRoot.isActive) ? Kube.Colors.highlightColor : Kube.Colors.viewBackgroundColor
68 } 70 }
69 } 71 }
70 } 72 }