diff options
Diffstat (limited to 'src/imports/controls/material/SwitchDelegate.qml')
-rw-r--r-- | src/imports/controls/material/SwitchDelegate.qml | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/imports/controls/material/SwitchDelegate.qml b/src/imports/controls/material/SwitchDelegate.qml index 2ff03b69..3fdab2da 100644 --- a/src/imports/controls/material/SwitchDelegate.qml +++ b/src/imports/controls/material/SwitchDelegate.qml @@ -44,9 +44,9 @@ import QtQuick.Controls.Material.impl 2.5 T.SwitchDelegate { id: control - implicitWidth: Math.max(background ? background.implicitWidth : 0, + implicitWidth: Math.max(implicitBackgroundWidth, contentItem.implicitWidth + leftPadding + rightPadding) - implicitHeight: Math.max(background ? background.implicitHeight : 0, + implicitHeight: Math.max(implicitBackgroundHeight, Math.max(contentItem.implicitHeight, indicator ? indicator.implicitHeight : 0) + topPadding + bottomPadding) |