mpd: Implement idle events for Playing state

This commit is contained in:
Desuwa
2026-05-16 15:41:09 -07:00
parent 05945748dc
commit 546b53d675
2 changed files with 102 additions and 16 deletions
+4
View File
@@ -82,6 +82,7 @@ class Idle : public State {
class Playing : public State {
Context* const ctx_;
sigc::connection timer_connection_;
sigc::connection idle_connection_;
public:
Playing(Context* const ctx) : ctx_{ctx} {}
@@ -98,7 +99,10 @@ class Playing : public State {
Playing(Playing const&) = delete;
Playing& operator=(Playing const&) = delete;
void timer() noexcept;
void idle() noexcept;
bool on_timer();
bool on_io(Glib::IOCondition const&);
};
class Paused : public State {