From 12f7ce92376ffcafdadc1078d81cd1a8d8fb0661 Mon Sep 17 00:00:00 2001 From: Christian Mollekopf Date: Thu, 11 Jan 2018 15:45:03 +0100 Subject: Keep the delegate full width without scrollbar. --- framework/qml/ListView.qml | 3 ++- framework/qml/MailListView.qml | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/framework/qml/ListView.qml b/framework/qml/ListView.qml index eafa428d..52942b65 100644 --- a/framework/qml/ListView.qml +++ b/framework/qml/ListView.qml @@ -24,9 +24,10 @@ import org.kube.framework 1.0 as Kube ListView { id: root property Item mouseProxy: scrollHelper + property int availableWidth: scrollBar.visible ? width - scrollBar.width: width clip: true - ScrollBar.vertical: Kube.ScrollBar {} + ScrollBar.vertical: Kube.ScrollBar { id: scrollBar } Kube.ScrollHelper { id: scrollHelper diff --git a/framework/qml/MailListView.qml b/framework/qml/MailListView.qml index f3e6a7a6..96cf30bc 100644 --- a/framework/qml/MailListView.qml +++ b/framework/qml/MailListView.qml @@ -152,7 +152,7 @@ FocusScope { //Required for D&D property var mail: model.mail - width: listView.width - Kube.Units.smallSpacing + width: listView.availableWidth height: Kube.Units.gridUnit * 5 color: Kube.Colors.viewBackgroundColor -- cgit v1.2.3