move Theme, SystemStats, Modules to shell/services/
This commit is contained in:
parent
197f6976e0
commit
989182d603
59 changed files with 432 additions and 388 deletions
|
|
@ -1,16 +1,17 @@
|
|||
import QtQuick
|
||||
import Quickshell
|
||||
import "." as M
|
||||
import "../services" as S
|
||||
import "../applets" as C
|
||||
|
||||
M.BarSection {
|
||||
id: root
|
||||
spacing: Math.max(1, M.Theme.moduleSpacing - 2)
|
||||
spacing: Math.max(1, S.Theme.moduleSpacing - 2)
|
||||
tooltip: ""
|
||||
|
||||
readonly property var _cores: M.SystemStats.cpuCores
|
||||
readonly property var _coreMaxFreq: M.SystemStats.cpuCoreMaxFreq
|
||||
readonly property var _coreTypes: M.SystemStats.cpuCoreTypes
|
||||
readonly property var _cores: S.SystemStats.cpuCores
|
||||
readonly property var _coreMaxFreq: S.SystemStats.cpuCoreMaxFreq
|
||||
readonly property var _coreTypes: S.SystemStats.cpuCoreTypes
|
||||
|
||||
property bool _pinned: false
|
||||
readonly property bool _anyHover: root._hovered || hoverPanel.panelHovered
|
||||
|
|
@ -21,10 +22,10 @@ M.BarSection {
|
|||
on_ShowPanelChanged: {
|
||||
if (_showPanel && !_coreConsumerActive) {
|
||||
_coreConsumerActive = true;
|
||||
M.SystemStats.coreConsumers++;
|
||||
S.SystemStats.coreConsumers++;
|
||||
} else if (!_showPanel && _coreConsumerActive) {
|
||||
_coreConsumerActive = false;
|
||||
M.SystemStats.coreConsumers--;
|
||||
S.SystemStats.coreConsumers--;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -56,7 +57,7 @@ M.BarSection {
|
|||
}
|
||||
}
|
||||
M.BarLabel {
|
||||
label: M.SystemStats.cpuUsage.toString().padStart(2) + "%@" + M.SystemStats.cpuFreqGhz.toFixed(2)
|
||||
label: S.SystemStats.cpuUsage.toString().padStart(2) + "%@" + S.SystemStats.cpuFreqGhz.toFixed(2)
|
||||
minText: "99%@9.99"
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
TapHandler {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue