mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-10-29 05:40:23 -04:00
make proplist inheritance scheme automatic and implicit
This commit is contained in:
parent
e68e4a57bf
commit
47a2b17d01
6 changed files with 12 additions and 4 deletions
|
|
@ -422,7 +422,6 @@ static int esd_proto_stream_play(connection *c, esd_proto_t request, const void
|
|||
sdata.module = c->options->module;
|
||||
sdata.client = c->client;
|
||||
sdata.sink = sink;
|
||||
pa_proplist_update(sdata.proplist, PA_UPDATE_MERGE, c->client->proplist);
|
||||
pa_sink_input_new_data_set_sample_spec(&sdata, &ss);
|
||||
|
||||
c->sink_input = pa_sink_input_new(c->protocol->core, &sdata, 0);
|
||||
|
|
@ -525,7 +524,6 @@ static int esd_proto_stream_record(connection *c, esd_proto_t request, const voi
|
|||
sdata.module = c->options->module;
|
||||
sdata.client = c->client;
|
||||
sdata.source = source;
|
||||
pa_proplist_update(sdata.proplist, PA_UPDATE_MERGE, c->client->proplist);
|
||||
pa_source_output_new_data_set_sample_spec(&sdata, &ss);
|
||||
|
||||
c->source_output = pa_source_output_new(c->protocol->core, &sdata, 0);
|
||||
|
|
|
|||
|
|
@ -601,7 +601,6 @@ static record_stream* record_stream_new(
|
|||
pa_source_output_new_data_init(&data);
|
||||
|
||||
pa_proplist_update(data.proplist, PA_UPDATE_REPLACE, p);
|
||||
pa_proplist_update(data.proplist, PA_UPDATE_MERGE, c->client->proplist);
|
||||
data.driver = __FILE__;
|
||||
data.module = c->options->module;
|
||||
data.client = c->client;
|
||||
|
|
@ -1001,7 +1000,6 @@ static playback_stream* playback_stream_new(
|
|||
pa_sink_input_new_data_init(&data);
|
||||
|
||||
pa_proplist_update(data.proplist, PA_UPDATE_REPLACE, p);
|
||||
pa_proplist_update(data.proplist, PA_UPDATE_MERGE, c->client->proplist);
|
||||
data.driver = __FILE__;
|
||||
data.module = c->options->module;
|
||||
data.client = c->client;
|
||||
|
|
|
|||
|
|
@ -190,6 +190,9 @@ pa_sink_input* pa_sink_input_new(
|
|||
|
||||
pa_return_null_if_fail(data->resample_method < PA_RESAMPLER_MAX);
|
||||
|
||||
if (data->client)
|
||||
pa_proplist_update(data->proplist, PA_UPDATE_MERGE, data->client->proplist);
|
||||
|
||||
if (pa_hook_fire(&core->hooks[PA_CORE_HOOK_SINK_INPUT_FIXATE], data) < 0)
|
||||
return NULL;
|
||||
|
||||
|
|
|
|||
|
|
@ -167,6 +167,9 @@ pa_sink* pa_sink_new(
|
|||
if (!data->muted_is_set)
|
||||
data->muted = FALSE;
|
||||
|
||||
if (data->card)
|
||||
pa_proplist_update(data->proplist, PA_UPDATE_MERGE, data->card->proplist);
|
||||
|
||||
if (pa_hook_fire(&core->hooks[PA_CORE_HOOK_SINK_FIXATE], data) < 0) {
|
||||
pa_xfree(s);
|
||||
pa_namereg_unregister(core, name);
|
||||
|
|
|
|||
|
|
@ -153,6 +153,9 @@ pa_source_output* pa_source_output_new(
|
|||
|
||||
pa_return_null_if_fail(data->resample_method < PA_RESAMPLER_MAX);
|
||||
|
||||
if (data->client)
|
||||
pa_proplist_update(data->proplist, PA_UPDATE_MERGE, data->client->proplist);
|
||||
|
||||
if (pa_hook_fire(&core->hooks[PA_CORE_HOOK_SOURCE_OUTPUT_FIXATE], data) < 0)
|
||||
return NULL;
|
||||
|
||||
|
|
|
|||
|
|
@ -158,6 +158,9 @@ pa_source* pa_source_new(
|
|||
if (!data->muted_is_set)
|
||||
data->muted = FALSE;
|
||||
|
||||
if (data->card)
|
||||
pa_proplist_update(data->proplist, PA_UPDATE_MERGE, data->card->proplist);
|
||||
|
||||
if (pa_hook_fire(&core->hooks[PA_CORE_HOOK_SOURCE_FIXATE], data) < 0) {
|
||||
pa_xfree(s);
|
||||
pa_namereg_unregister(core, name);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue