mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-03 09:01:54 -05:00
simply use INTERFACE_Loop for the main-loop
This commit is contained in:
parent
4c2b6c7c91
commit
86dc0496a5
20 changed files with 73 additions and 61 deletions
|
|
@ -378,10 +378,14 @@ impl_init(const struct spa_handle_factory *factory,
|
|||
&impl_dbus, this);
|
||||
|
||||
for (i = 0; i < n_support; i++) {
|
||||
if (support[i].type == SPA_TYPE_INTERFACE_Log)
|
||||
switch (support[i].type) {
|
||||
case SPA_TYPE_INTERFACE_Log:
|
||||
this->log = support[i].data;
|
||||
else if (support[i].type == SPA_TYPE_INTERFACE_LoopUtils)
|
||||
break;
|
||||
case SPA_TYPE_INTERFACE_LoopUtils:
|
||||
this->utils = support[i].data;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (this->utils == NULL) {
|
||||
spa_log_error(this->log, "a LoopUtils is needed");
|
||||
|
|
|
|||
|
|
@ -45,6 +45,8 @@ struct impl {
|
|||
struct spa_handle handle;
|
||||
struct spa_log log;
|
||||
|
||||
struct spa_system *system;
|
||||
|
||||
bool colors;
|
||||
FILE *file;
|
||||
|
||||
|
|
@ -222,8 +224,14 @@ impl_init(const struct spa_handle_factory *factory,
|
|||
this->log.level = DEFAULT_LOG_LEVEL;
|
||||
|
||||
for (i = 0; i < n_support; i++) {
|
||||
if (support[i].type == SPA_TYPE_INTERFACE_MainLoop)
|
||||
switch (support[i].type) {
|
||||
case SPA_TYPE_INTERFACE_Loop:
|
||||
loop = support[i].data;
|
||||
break;
|
||||
case SPA_TYPE_INTERFACE_System:
|
||||
this->system = support[i].data;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (info) {
|
||||
if ((str = spa_dict_lookup(info, SPA_KEY_LOG_COLORS)) != NULL)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue