Commit 9cfd9d7c authored by Max Kellermann's avatar Max Kellermann

Merge branch 'v0.18.x'

parents 66d90dd4 42a09ff1
......@@ -47,10 +47,22 @@ class AlsaMixerMonitor final : private MultiSocketMonitor {
public:
AlsaMixerMonitor(EventLoop &_loop, snd_mixer_t *_mixer)
:MultiSocketMonitor(_loop), mixer(_mixer) {
BlockingCall(_loop, [this](){ InvalidateSockets(); });
#ifdef USE_INTERNAL_EVENTLOOP
_loop.AddCall([this](){ InvalidateSockets(); });
#else
_loop.AddIdle(InitAlsaMixerMonitor, this);
#endif
}
private:
#ifndef USE_INTERNAL_EVENTLOOP
static gboolean InitAlsaMixerMonitor(gpointer data) {
AlsaMixerMonitor &amm = *(AlsaMixerMonitor *)data;
amm.InvalidateSockets();
return false;
}
#endif
virtual int PrepareSockets() override;
virtual void DispatchSockets() override;
};
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment