From d75596c2aec0c1a63b4eff788de1826fab601c64 Mon Sep 17 00:00:00 2001 From: Michal Ratajsky Date: Sun, 9 Nov 2014 14:25:11 +0100 Subject: Update according to changes in libmatemixer --- mate-volume-control/gvc-mixer-dialog.c | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) (limited to 'mate-volume-control/gvc-mixer-dialog.c') diff --git a/mate-volume-control/gvc-mixer-dialog.c b/mate-volume-control/gvc-mixer-dialog.c index b6525fb..938c57a 100644 --- a/mate-volume-control/gvc-mixer-dialog.c +++ b/mate-volume-control/gvc-mixer-dialog.c @@ -143,13 +143,11 @@ find_stream_port_switch (MateMixerStream *stream) switches = mate_mixer_stream_list_switches (stream); while (switches != NULL) { - MateMixerSwitch *swtch = MATE_MIXER_SWITCH (switches->data); - MateMixerSwitchFlags flags; + MateMixerStreamSwitch *swtch = MATE_MIXER_STREAM_SWITCH (switches->data); - flags = mate_mixer_switch_get_flags (swtch); - if ((flags & MATE_MIXER_SWITCH_TOGGLE) == 0 && - mate_mixer_switch_get_role (swtch) == MATE_MIXER_SWITCH_ROLE_PORT) - return swtch; + if (!MATE_MIXER_IS_TOGGLE (swtch) && + mate_mixer_stream_switch_get_role (swtch) == MATE_MIXER_STREAM_SWITCH_ROLE_PORT) + return MATE_MIXER_SWITCH (swtch); switches = switches->next; } @@ -163,10 +161,10 @@ find_device_profile_switch (MateMixerDevice *device) switches = mate_mixer_device_list_switches (device); while (switches != NULL) { - MateMixerSwitch *swtch = MATE_MIXER_SWITCH (switches->data); + MateMixerDeviceSwitch *swtch = MATE_MIXER_DEVICE_SWITCH (switches->data); - if (mate_mixer_switch_get_role (swtch) == MATE_MIXER_SWITCH_ROLE_DEVICE_PROFILE) - return swtch; + if (mate_mixer_device_switch_get_role (swtch) == MATE_MIXER_DEVICE_SWITCH_ROLE_PROFILE) + return MATE_MIXER_SWITCH (swtch); switches = switches->next; } -- cgit v1.2.1