fix: buttons not respecting shapeMorph prop
This commit is contained in:
parent
0210f98686
commit
362863dd74
2 changed files with 4 additions and 1 deletions
|
|
@ -43,7 +43,7 @@ StyledRect {
|
|||
property color disabledOnColour: Qt.alpha(Colours.palette.m3onSurface, 0.38)
|
||||
|
||||
property bool internalChecked
|
||||
property real shapeMorphExpansion: pressed ? 1.16 : 1
|
||||
property real shapeMorphExpansion: shapeMorph && pressed ? 1.16 : 1
|
||||
readonly property color onColour: disabled ? disabledOnColour : internalChecked ? activeOnColour : inactiveOnColour
|
||||
|
||||
signal clicked
|
||||
|
|
|
|||
|
|
@ -135,6 +135,7 @@ Item {
|
|||
type: IconButton.Tonal
|
||||
icon: "skip_previous"
|
||||
isRound: true
|
||||
shapeMorph: true
|
||||
disabled: !Players.active?.canGoPrevious
|
||||
onClicked: Players.active?.previous()
|
||||
}
|
||||
|
|
@ -143,6 +144,7 @@ Item {
|
|||
fillWidth: true
|
||||
icon: Players.active?.isPlaying ? "pause" : "play_arrow"
|
||||
isRound: true
|
||||
shapeMorph: true
|
||||
checked: Players.active?.isPlaying ?? false
|
||||
disabled: !Players.active?.canTogglePlaying
|
||||
onClicked: Players.active?.togglePlaying()
|
||||
|
|
@ -152,6 +154,7 @@ Item {
|
|||
type: IconButton.Tonal
|
||||
icon: "skip_next"
|
||||
isRound: true
|
||||
shapeMorph: true
|
||||
disabled: !Players.active?.canGoNext
|
||||
onClicked: Players.active?.next()
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue