diff options
Diffstat (limited to 'src/imports/controls/SwipeDelegate.qml')
-rw-r--r-- | src/imports/controls/SwipeDelegate.qml | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/src/imports/controls/SwipeDelegate.qml b/src/imports/controls/SwipeDelegate.qml index f9a8ef0e..acbabe2c 100644 --- a/src/imports/controls/SwipeDelegate.qml +++ b/src/imports/controls/SwipeDelegate.qml @@ -52,19 +52,22 @@ T.SwipeDelegate { padding: 12 spacing: 12 + icon.width: 24 + icon.height: 24 + icon.color: enabled ? undefined : Default.textDisabledLightColor + swipe.transition: Transition { SmoothedAnimation { velocity: 3; easing.type: Easing.InOutCubic } } - contentItem: Text { - leftPadding: control.mirrored ? (control.indicator ? control.indicator.width : 0) + control.spacing : 0 - rightPadding: !control.mirrored ? (control.indicator ? control.indicator.width : 0) + control.spacing : 0 + contentItem: IconLabel { + spacing: control.spacing + mirrored: control.mirrored + display: control.display + alignment: control.display === IconLabel.IconOnly || control.display === IconLabel.TextUnderIcon ? Qt.AlignCenter : Qt.AlignLeft + icon: control.icon text: control.text font: control.font color: control.enabled ? Default.textDarkColor : Default.textDisabledColor - elide: Text.ElideRight - visible: control.text - horizontalAlignment: Text.AlignLeft - verticalAlignment: Text.AlignVCenter } background: Rectangle { |