Compare commits

..
11 changed files with 41 additions and 38 deletions

View file

@ -5,9 +5,6 @@ Column {
id: root id: root
required property color accentColor required property color accentColor
property bool active: true
onActiveChanged: if (active)
S.BluetoothService.refresh()
Repeater { Repeater {
model: S.BluetoothService.devices model: S.BluetoothService.devices

View file

@ -12,19 +12,6 @@ Column {
property bool active: true property bool active: true
property bool _coreActive: false
onActiveChanged: {
if (active && !_coreActive) {
_coreActive = true;
S.SystemStats.coreConsumers++;
} else if (!active && _coreActive) {
_coreActive = false;
S.SystemStats.coreConsumers--;
}
}
Component.onDestruction: if (_coreActive)
S.SystemStats.coreConsumers--
// Per-core rows // Per-core rows
Repeater { Repeater {
model: root.cores.length model: root.cores.length

View file

@ -5,9 +5,6 @@ Column {
id: root id: root
required property color accentColor required property color accentColor
property bool active: true
onActiveChanged: if (active)
S.NetworkService.refresh()
Repeater { Repeater {
model: S.NetworkService.networks model: S.NetworkService.networks

View file

@ -251,7 +251,7 @@ PanelWindow {
devices: S.SystemStats.tempDevices devices: S.SystemStats.tempDevices
accentColor: root._accent accentColor: root._accent
deviceFilter: S.Modules.temperature.device || "" deviceFilter: S.Modules.temperature.device || ""
active: parent.expanded active: parent.parent.expanded
} }
} }
@ -296,7 +296,6 @@ PanelWindow {
C.NetworkApplet { C.NetworkApplet {
width: parent.width width: parent.width
accentColor: root._accent accentColor: root._accent
active: parent.expanded
} }
} }
@ -311,7 +310,6 @@ PanelWindow {
C.BluetoothApplet { C.BluetoothApplet {
width: parent.width width: parent.width
accentColor: root._accent accentColor: root._accent
active: parent.expanded
} }
} }
@ -376,7 +374,6 @@ PanelWindow {
players: S.MprisService.players players: S.MprisService.players
playing: S.MprisService.playing playing: S.MprisService.playing
accentColor: root._accent accentColor: root._accent
cachedArt: S.MprisService.cachedArt
playerIdx: S.MprisService.playerIdx playerIdx: S.MprisService.playerIdx
onPlayerSwitched: idx => S.MprisService.switchPlayer(idx) onPlayerSwitched: idx => S.MprisService.switchPlayer(idx)
} }

View file

@ -89,10 +89,9 @@ Rectangle {
} }
} }
// Content area - expanded propagated so children can bind `active: parent.expanded` // Content area
Column { Column {
id: _contentColumn id: _contentColumn
property bool expanded: root.expanded
anchors.top: _header.bottom anchors.top: _header.bottom
anchors.topMargin: 4 anchors.topMargin: 4
width: parent.width width: parent.width

View file

@ -54,6 +54,9 @@ M.BarModule {
} }
} }
on_ShowPanelChanged: if (_showPanel)
S.BluetoothService.refresh()
Connections { Connections {
target: S.BluetoothService target: S.BluetoothService
function onDevicesChanged() { function onDevicesChanged() {

View file

@ -27,6 +27,18 @@ M.BarModule {
readonly property var _coreMaxFreq: S.SystemStats.cpuCoreMaxFreq readonly property var _coreMaxFreq: S.SystemStats.cpuCoreMaxFreq
readonly property var _coreTypes: S.SystemStats.cpuCoreTypes readonly property var _coreTypes: S.SystemStats.cpuCoreTypes
property bool _coreConsumerActive: false
on_ShowPanelChanged: {
if (_showPanel && !_coreConsumerActive) {
_coreConsumerActive = true;
S.SystemStats.coreConsumers++;
} else if (!_showPanel && _coreConsumerActive) {
_coreConsumerActive = false;
S.SystemStats.coreConsumers--;
}
}
property M.ProcessList _procs: M.ProcessList { property M.ProcessList _procs: M.ProcessList {
sortBy: "cpu" sortBy: "cpu"
active: root._showPanel active: root._showPanel

View file

@ -22,7 +22,7 @@ M.BarModule {
players: root._players players: root._players
playing: root.playing playing: root.playing
accentColor: root.accentColor accentColor: root.accentColor
cachedArt: S.MprisService.cachedArt cachedArt: root._cachedArt
cavaBars: root._cavaBars cavaBars: root._cavaBars
playerIdx: S.MprisService.playerIdx playerIdx: S.MprisService.playerIdx
onPlayerSwitched: idx => { onPlayerSwitched: idx => {
@ -35,6 +35,25 @@ M.BarModule {
readonly property var _players: S.MprisService.players readonly property var _players: S.MprisService.players
readonly property MprisPlayer player: S.MprisService.player readonly property MprisPlayer player: S.MprisService.player
readonly property bool playing: S.MprisService.playing readonly property bool playing: S.MprisService.playing
property string _cachedArt: ""
property string _artTrack: ""
readonly property string _artUrl: player?.trackArtUrl ?? ""
readonly property string _currentTrack: player?.trackTitle ?? ""
on_ArtUrlChanged: if (_artUrl)
_cachedArt = _artUrl
on_CurrentTrackChanged: if (_currentTrack !== _artTrack) {
_artTrack = _currentTrack;
_cachedArt = _artUrl || "";
}
// Preload art while panel is hidden
Image {
visible: false
source: root._cachedArt
asynchronous: true
}
// Cava visualizer - 16 bars, raw output mode // Cava visualizer - 16 bars, raw output mode
property var _cavaBars: Array(16).fill(0) property var _cavaBars: Array(16).fill(0)
property bool _cavaActive: false property bool _cavaActive: false

View file

@ -56,6 +56,9 @@ M.BarModule {
readonly property string state: S.NetworkService.state readonly property string state: S.NetworkService.state
on_ShowPanelChanged: if (_showPanel)
S.NetworkService.refresh()
Connections { Connections {
target: S.NetworkService target: S.NetworkService
function onNetworksChanged() { function onNetworksChanged() {

View file

@ -118,18 +118,6 @@ QtObject {
_selectedIdentity = players[chosen].identity ?? ""; _selectedIdentity = players[chosen].identity ?? "";
} }
// Album art caching - persists across panel/dock collapse
property string cachedArt: ""
property string _artTrack: ""
readonly property string _artUrl: player?.trackArtUrl ?? ""
readonly property string _currentTrack: player?.trackTitle ?? ""
on_ArtUrlChanged: if (_artUrl)
cachedArt = _artUrl
on_CurrentTrackChanged: if (_currentTrack !== _artTrack) {
_artTrack = _currentTrack;
cachedArt = _artUrl || "";
}
function switchPlayer(idx) { function switchPlayer(idx) {
playerIdx = idx; playerIdx = idx;
if (players[idx]) if (players[idx])

View file

@ -18,6 +18,7 @@ shell/applets/PowerApplet.qml: Unqualified access [unqualified]
shell/applets/TemperatureApplet.qml: Unqualified access [unqualified] shell/applets/TemperatureApplet.qml: Unqualified access [unqualified]
shell/applets/VolumeApplet.qml: Unqualified access [unqualified] shell/applets/VolumeApplet.qml: Unqualified access [unqualified]
shell/dock/AppletDock.qml: Could not find property "top". [missing-property] shell/dock/AppletDock.qml: Could not find property "top". [missing-property]
shell/dock/AppletDock.qml: Member "expanded" not found on type "QQuickItem" [missing-property]
shell/dock/AppletDock.qml: Type margins is used but it is not resolved [unresolved-type] shell/dock/AppletDock.qml: Type margins is used but it is not resolved [unresolved-type]
shell/dock/AppletDock.qml: Type PanelWindow is not creatable. [uncreatable-type] shell/dock/AppletDock.qml: Type PanelWindow is not creatable. [uncreatable-type]
shell/dock/AppletDock.qml: unknown grouped property scope margins. [unqualified] shell/dock/AppletDock.qml: unknown grouped property scope margins. [unqualified]