mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-11-04 13:29:59 -05:00
sink-input: change bool save_sink to char *preferred_sink
The finial objective is to store the preferred sink name in the sink-input struct, and use module-stream-restore to save and restore it. This patch just replaces the save_sink with preferred_sink, and tries to keep the original logic. Signed-off-by: Hui Wang <hui.wang@canonical.com>
This commit is contained in:
parent
26a66d103f
commit
fbf8716685
6 changed files with 55 additions and 28 deletions
|
|
@ -656,14 +656,14 @@ static void route_sink_input(struct userdata *u, pa_sink_input *si) {
|
|||
pa_assert(u);
|
||||
pa_assert(u->do_routing);
|
||||
|
||||
/* Don't override user or application routing requests. */
|
||||
if (si->save_sink || si->sink_requested_by_application)
|
||||
return;
|
||||
|
||||
/* Skip this if it is already in the process of being moved anyway */
|
||||
if (!si->sink)
|
||||
return;
|
||||
|
||||
/* Don't override user or application routing requests. */
|
||||
if (pa_safe_streq(si->sink->name, si->preferred_sink) || si->sink_requested_by_application)
|
||||
return;
|
||||
|
||||
auto_filtered_prop = pa_proplist_gets(si->proplist, "module-device-manager.auto_filtered");
|
||||
if (auto_filtered_prop)
|
||||
auto_filtered = (pa_parse_boolean(auto_filtered_prop) == 1);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue