From 4f16a4fb6dd6efc460fa5b516057b9cb2c47dcd7 Mon Sep 17 00:00:00 2001 From: Patrick Ziegler Date: Mon, 15 Feb 2021 23:49:21 +0100 Subject: [PATCH] alsa: Call action_epilogue (#2381) --- src/modules/alsa.cpp | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/modules/alsa.cpp b/src/modules/alsa.cpp index da432494..7a886ba4 100644 --- a/src/modules/alsa.cpp +++ b/src/modules/alsa.cpp @@ -235,24 +235,27 @@ namespace modules { if (!m_mixer[mixer::MASTER]) { return; } - auto mixers = get_mixers(); + const auto& mixers = get_mixers(); for (auto&& mixer : mixers) { mixer->set_mute(m_muted || mixers[0]->is_muted()); } + + action_epilogue(mixers); } void alsa_module::change_volume(int interval) { if (!m_mixer[mixer::MASTER]) { return; } - auto mixers = get_mixers(); + const auto& mixers = get_mixers(); for (auto&& mixer : mixers) { m_mapped ? mixer->set_normalized_volume(math_util::cap(mixer->get_normalized_volume() + interval, 0, 100)) : mixer->set_volume(math_util::cap(mixer->get_volume() + interval, 0, 100)); } + action_epilogue(mixers); } - void action_epilogue(const vector& mixers) { + void alsa_module::action_epilogue(const vector& mixers) { for (auto&& mixer : mixers) { if (mixer->wait(0)) { mixer->process_events();