diff options
| author | Tarja Sundqvist <tarja.sundqvist@qt.io> | 2025-10-12 23:00:20 +0300 |
|---|---|---|
| committer | Tarja Sundqvist <tarja.sundqvist@qt.io> | 2025-10-12 23:00:20 +0300 |
| commit | 4826f86e274f1b29bd769e6790824f9e62a40f62 (patch) | |
| tree | c2cc4bb09ca91951a2641e33c3b0a65deb0af877 /src/quickcontrols/material/TreeViewDelegate.qml | |
| parent | 0f0972d542d9869c2dcfaf9c963d42ff32766460 (diff) | |
| parent | 844f9b9b376838bcb44324984876f8bf99d85d38 (diff) | |
Merge tag 'v6.5.7-lts-lgpl' into 6.56.5
Qt 6.5.7-lts-lgpl release
Diffstat (limited to 'src/quickcontrols/material/TreeViewDelegate.qml')
| -rw-r--r-- | src/quickcontrols/material/TreeViewDelegate.qml | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/src/quickcontrols/material/TreeViewDelegate.qml b/src/quickcontrols/material/TreeViewDelegate.qml index 9f1d444383..7a9976b021 100644 --- a/src/quickcontrols/material/TreeViewDelegate.qml +++ b/src/quickcontrols/material/TreeViewDelegate.qml @@ -42,7 +42,7 @@ T.TreeViewDelegate { y: (parent.height - height) / 2 rotation: control.expanded ? 90 : (control.mirrored ? 180 : 0) source: "qrc:/qt-project.org/imports/QtQuick/Controls/Material/images/arrow-indicator.png" - color: control.palette.windowText + color: control.enabled ? control.Material.foreground : control.Material.hintTextColor defaultColor: "#353637" } } @@ -50,9 +50,16 @@ T.TreeViewDelegate { background: Rectangle { implicitHeight: control.Material.buttonHeight color: control.highlighted - ? control.palette.highlight + ? control.Material.accentColor : (control.treeView.alternatingRows && control.row % 2 !== 0 - ? control.palette.alternateBase : control.palette.base) + ? control.Material.background + // The Material.shade() is used as the alternate background color for rows + // based on the Material.theme value. + : control.Material.shade(control.Material.background, + control.Material.theme === Material.Dark + ? Material.Shade100 // the lighter background color + : Material.Shade700 // the darker background color + )) } contentItem: Label { |
