mirror of
https://github.com/kossLAN/dots.git
synced 2025-11-04 22:49:50 -05:00
42 lines
1,015 B
QML
42 lines
1,015 B
QML
import QtQuick
|
|
import "../../mpris" as Mpris
|
|
import "../../widgets" as Widgets
|
|
import "../.."
|
|
|
|
Widgets.MaterialButton {
|
|
id: root
|
|
radius: 6
|
|
implicitWidth: mediaInfo.contentWidth + 8
|
|
implicitHeight: parent.height
|
|
// onClicked: {
|
|
// popup.visible = !popup.visible;
|
|
// }
|
|
|
|
required property var bar
|
|
property var player: Mpris.Controller.trackedPlayer
|
|
|
|
Text {
|
|
id: mediaInfo
|
|
text: root.player?.trackTitle ?? ""
|
|
color: root.containsMouse ? ShellSettings.colors["inverse_primary"] : ShellSettings.colors["inverse_surface"]
|
|
elide: Text.ElideRight
|
|
horizontalAlignment: Text.AlignHCenter
|
|
verticalAlignment: Text.AlignVCenter
|
|
font.pointSize: 11
|
|
anchors.centerIn: parent
|
|
|
|
Behavior on color {
|
|
ColorAnimation {
|
|
duration: 200
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
// WidgetWindow {
|
|
// id: popup
|
|
// visible: false
|
|
// parentWindow: root.bar
|
|
//
|
|
// // anchor.window: root.bar
|
|
// }
|