replace wraperRectangle with normal rectangle
This commit is contained in:
parent
bc0fab6cb0
commit
a62d313b29
9 changed files with 77 additions and 38 deletions
|
|
@ -6,8 +6,11 @@ import qs
|
|||
import qs.widgets
|
||||
import qs.settings
|
||||
|
||||
WrapperRectangle {
|
||||
Rectangle {
|
||||
id: root
|
||||
required property double moduleHeight
|
||||
implicitHeight: moduleHeight
|
||||
implicitWidth: songLayout.implicitWidth + 32
|
||||
property MprisPlayer spotify: {
|
||||
for (const player of Mpris.players.values) {
|
||||
if (player.identity === "Spotify")
|
||||
|
|
@ -16,16 +19,18 @@ WrapperRectangle {
|
|||
return null;
|
||||
}
|
||||
visible: spotify !== null && spotify.playbackState === MprisPlaybackState.Playing
|
||||
leftMargin: 8
|
||||
rightMargin: 8
|
||||
clip: true
|
||||
color: Colors.base01
|
||||
radius: Config.rounding
|
||||
child: RowLayout {
|
||||
RowLayout {
|
||||
id: songLayout
|
||||
anchors.centerIn: root
|
||||
MaterialIcon {
|
||||
text: "music_note_2"
|
||||
}
|
||||
StyledText {
|
||||
Layout.maximumWidth: 400
|
||||
Layout.maximumHeight: Config.barHeight / 1.6
|
||||
text: root.spotify?.trackTitle + " - " + root.spotify?.trackArtists
|
||||
elide: Text.ElideRight
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue