Reset GUI when airpods disconnect, show notification

This commit is contained in:
Tim Gromeyer
2025-04-15 19:55:40 +02:00
parent ecab6a9858
commit c94295ae1c
5 changed files with 63 additions and 7 deletions

View File

@@ -21,11 +21,17 @@ class Battery : public QObject
public:
explicit Battery(QObject *parent = nullptr) : QObject(parent)
{
reset();
}
void reset()
{
// Initialize all components to unknown state
states[Component::Left] = {};
states[Component::Right] = {};
states[Component::Case] = {};
emit batteryStatusChanged();
}
// Enum for AirPods components