summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Surrel <[email protected]>2018-12-07 12:21:30 +0100
committerThomas Surrel <[email protected]>2018-12-07 15:53:00 +0100
commit66e05cb9c0972b32e8821330de2b9bd0a0e03b57 (patch)
tree38b1ad9f9b204da6111ee1f3d88e48f87a970e81
parent9ac9e0a15de9413728a619bb982654dbc5c84bcb (diff)
[Device Automounter KCM] Improve the tree view header spacing
Test Plan: {F6461039} {F6461040} Reviewers: #vdg, davidedmundson, ngraham Reviewed By: #vdg, davidedmundson, ngraham Subscribers: ngraham, plasma-devel Tags: #plasma Differential Revision: https://phabricator.kde.org/D17401
-rw-r--r--solid-device-automounter/kcm/DeviceAutomounterKCM.cpp3
-rw-r--r--solid-device-automounter/kcm/DeviceAutomounterKCM.ui5
2 files changed, 7 insertions, 1 deletions
diff --git a/solid-device-automounter/kcm/DeviceAutomounterKCM.cpp b/solid-device-automounter/kcm/DeviceAutomounterKCM.cpp
index 00dea0f..10a408b 100644
--- a/solid-device-automounter/kcm/DeviceAutomounterKCM.cpp
+++ b/solid-device-automounter/kcm/DeviceAutomounterKCM.cpp
@@ -57,6 +57,9 @@ DeviceAutomounterKCM::DeviceAutomounterKCM(QWidget *parent, const QVariantList &
m_devices = new DeviceModel(this);
deviceView->setModel(m_devices);
+ deviceView->header()->setSectionResizeMode(QHeaderView::ResizeToContents);
+ deviceView->header()->setSectionResizeMode(0, QHeaderView::Stretch);
+
auto emitChanged = [this] {
emit changed();
};
diff --git a/solid-device-automounter/kcm/DeviceAutomounterKCM.ui b/solid-device-automounter/kcm/DeviceAutomounterKCM.ui
index 3827e95..35a0dfb 100644
--- a/solid-device-automounter/kcm/DeviceAutomounterKCM.ui
+++ b/solid-device-automounter/kcm/DeviceAutomounterKCM.ui
@@ -122,7 +122,10 @@ If &quot;Enable automatic mounting of removable media&quot; is unchecked, the ov
<bool>false</bool>
</property>
<attribute name="headerShowSortIndicator" stdset="0">
- <bool>true</bool>
+ <bool>false</bool>
+ </attribute>
+ <attribute name="headerStretchLastSection">
+ <bool>false</bool>
</attribute>
</widget>
</item>