From e7bf1751690025f1fec8601003f4fdaecc2c22b9 Mon Sep 17 00:00:00 2001 From: Damocles Date: Mon, 27 Apr 2026 18:21:32 +0200 Subject: [PATCH] fix duplicate onActiveChanged in cpu applet --- shell/applets/CpuApplet.qml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/shell/applets/CpuApplet.qml b/shell/applets/CpuApplet.qml index f1e75d2..427f251 100644 --- a/shell/applets/CpuApplet.qml +++ b/shell/applets/CpuApplet.qml @@ -11,6 +11,7 @@ Column { required property color accentColor property bool active: true + property bool locked: false property bool _coreActive: false onActiveChanged: { @@ -21,6 +22,8 @@ Column { _coreActive = false; S.SystemStats.coreConsumers--; } + if (active) + _cpuHistory = []; } Component.onDestruction: if (_coreActive) S.SystemStats.coreConsumers-- @@ -171,8 +174,6 @@ Column { } property var _cpuHistory: [] - onActiveChanged: if (active) - _cpuHistory = [] Connections { target: S.SystemStats function onCpuUsageChanged() {