From 55071230532ec2a7a5b59b7d1da19a11e4ad4435 Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=A9r=C3=A9my=20Zurcher?= Date: Thu, 14 Feb 2013 20:27:51 +0000 Subject: [PATCH] e_mixer: struct channel_info becomes E_Mixer_Channel_Info defined in e_mod_system.h SVN revision: 83904 --- src/modules/mixer/app_mixer.c | 24 ++++++++---------------- src/modules/mixer/e_mod_system.h | 15 ++++++++++++--- 2 files changed, 20 insertions(+), 19 deletions(-) diff --git a/src/modules/mixer/app_mixer.c b/src/modules/mixer/app_mixer.c index 1405111..13abff2 100644 --- a/src/modules/mixer/app_mixer.c +++ b/src/modules/mixer/app_mixer.c @@ -10,7 +10,7 @@ typedef struct E_Mixer_App_Dialog_Data int lock_sliders; Eina_List *cards; Eina_List *channels_infos; - struct channel_info *channel_info; + E_Mixer_Channel_Info *channel_info; E_Mixer_Channel_State state; struct e_mixer_app_ui @@ -51,14 +51,6 @@ typedef struct E_Mixer_App_Dialog_Data } del; } E_Mixer_App_Dialog_Data; -struct channel_info -{ - int has_capture; - const char *name; - E_Mixer_Channel *id; - E_Mixer_App_Dialog_Data *app; -}; - static void _cb_changed_left(void *data, Evas_Object *obj __UNUSED__) { @@ -203,7 +195,7 @@ _populate_channel_editor(E_Mixer_App_Dialog_Data *app) static void _cb_channel_selected(void *data) { - struct channel_info *info = data; + E_Mixer_Channel_Info *info = data; E_Mixer_App_Dialog_Data *app; app = info->app; @@ -214,7 +206,7 @@ _cb_channel_selected(void *data) static int _channel_info_cmp(const void *data_a, const void *data_b) { - const struct channel_info *a = data_a, *b = data_b; + const E_Mixer_Channel_Info *a = data_a, *b = data_b; if (a->has_capture < b->has_capture) return -1; @@ -233,7 +225,7 @@ _channels_info_new(E_Mixer_System *sys) channels_infos = NULL; for (l = channels; l; l = l->next) { - struct channel_info *info; + E_Mixer_Channel_Info *info; info = malloc(sizeof(*info)); info->id = l->data; @@ -250,7 +242,7 @@ _channels_info_new(E_Mixer_System *sys) static void _channels_info_free(Eina_List *list) { - struct channel_info *info; + E_Mixer_Channel_Info *info; EINA_LIST_FREE(list, info) { @@ -302,7 +294,7 @@ _populate_channels(E_Mixer_App_Dialog_Data *app) if (app->channels_infos) { - struct channel_info *info = app->channels_infos->data; + E_Mixer_Channel_Info *info = app->channels_infos->data; if (info->has_capture) { e_widget_ilist_header_append(ilist, NULL, _("Input")); @@ -319,7 +311,7 @@ _populate_channels(E_Mixer_App_Dialog_Data *app) for (l = app->channels_infos; l; l = l->next, i++) { - struct channel_info *info = l->data; + E_Mixer_Channel_Info *info = l->data; if ((!header_input) && info->has_capture) { @@ -577,7 +569,7 @@ _find_card_by_name(E_Mixer_App_Dialog_Data *app, const char *card_name) static inline int _find_channel_by_name(E_Mixer_App_Dialog_Data *app, const char *channel_name) { - struct channel_info *info; + E_Mixer_Channel_Info *info; Eina_List *l; int i = 0; int header_input; diff --git a/src/modules/mixer/e_mod_system.h b/src/modules/mixer/e_mod_system.h index 7a401c4..6237e33 100644 --- a/src/modules/mixer/e_mod_system.h +++ b/src/modules/mixer/e_mod_system.h @@ -5,14 +5,23 @@ typedef void E_Mixer_System; typedef void E_Mixer_Channel; +typedef void E_Mixer_App; -struct E_Mixer_Channel_State + +typedef struct _E_Mixer_Channel_State { int mute; int left; int right; -}; -typedef struct E_Mixer_Channel_State E_Mixer_Channel_State; +} E_Mixer_Channel_State; + +typedef struct _E_Mixer_Channel_Info +{ + int has_capture; + const char *name; + E_Mixer_Channel *id; + E_Mixer_App *app; +} E_Mixer_Channel_Info; Eina_List *e_mixer_system_get_cards(void); void e_mixer_system_free_cards(Eina_List *cards); -- 2.7.4