mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-10-31 22:25:33 -04:00
core: add a suspend cause flags field
This commit is contained in:
parent
3af5f8cb55
commit
00797b8b6e
16 changed files with 83 additions and 40 deletions
|
|
@ -1278,7 +1278,7 @@ static int pa_cli_command_suspend_sink(pa_core *c, pa_tokenizer *t, pa_strbuf *b
|
|||
return -1;
|
||||
}
|
||||
|
||||
if ((r = pa_sink_suspend(sink, suspend)) < 0)
|
||||
if ((r = pa_sink_suspend(sink, suspend, PA_SUSPEND_USER)) < 0)
|
||||
pa_strbuf_printf(buf, "Failed to resume/suspend sink: %s\n", pa_strerror(r));
|
||||
|
||||
return 0;
|
||||
|
|
@ -1314,7 +1314,7 @@ static int pa_cli_command_suspend_source(pa_core *c, pa_tokenizer *t, pa_strbuf
|
|||
return -1;
|
||||
}
|
||||
|
||||
if ((r = pa_source_suspend(source, suspend)) < 0)
|
||||
if ((r = pa_source_suspend(source, suspend, PA_SUSPEND_USER)) < 0)
|
||||
pa_strbuf_printf(buf, "Failed to resume/suspend source: %s\n", pa_strerror(r));
|
||||
|
||||
return 0;
|
||||
|
|
@ -1339,10 +1339,10 @@ static int pa_cli_command_suspend(pa_core *c, pa_tokenizer *t, pa_strbuf *buf, p
|
|||
return -1;
|
||||
}
|
||||
|
||||
if ((r = pa_sink_suspend_all(c, suspend)) < 0)
|
||||
if ((r = pa_sink_suspend_all(c, suspend, PA_SUSPEND_USER)) < 0)
|
||||
pa_strbuf_printf(buf, "Failed to resume/suspend all sinks: %s\n", pa_strerror(r));
|
||||
|
||||
if ((r = pa_source_suspend_all(c, suspend)) < 0)
|
||||
if ((r = pa_source_suspend_all(c, suspend, PA_SUSPEND_USER)) < 0)
|
||||
pa_strbuf_printf(buf, "Failed to resume/suspend all sources: %s\n", pa_strerror(r));
|
||||
|
||||
return 0;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue