Enlightenment CVS committal Author : devilhorns Project : e_modules Module : mixer
Dir : e_modules/mixer Modified Files: e_mod_config.c alsa_mixer.c Log Message: Allow setting any channel. =================================================================== RCS file: /cvs/e/e_modules/mixer/e_mod_config.c,v retrieving revision 1.23 retrieving revision 1.24 diff -u -3 -r1.23 -r1.24 --- e_mod_config.c 19 Nov 2007 11:04:59 -0000 1.23 +++ e_mod_config.c 12 Dec 2007 23:24:14 -0000 1.24 @@ -96,6 +96,7 @@ Config_Item *ci; E_Radio_Group *cg, *mg; Mixer_Card *card; + int i = 0; ci = cfd->data; @@ -137,16 +138,22 @@ card->channels = mixer->mix_sys->get_channels(card); if (card->channels) { - of = e_widget_framelist_add(evas, D_("Available Mixers"), 0); + of = e_widget_frametable_add(evas, D_("Available Mixers"), 0); mg = e_widget_radio_group_new(&cfdata->channel_id); - for (chans = card->channels; chans; chans = chans->next) + for (i = 0, chans = card->channels; chans; chans = chans->next, i++) { Mixer_Channel *chan; chan = chans->data; if (!chan) continue; - ob = e_widget_radio_add(evas, (char *)chan->name, chan->id, mg); - e_widget_framelist_object_append(of, ob); + ob = e_widget_radio_add(evas, (char *)chan->name, + chan->id, mg); + if (!(i % 2)) + e_widget_frametable_object_append(of, ob, 0, i, 1, 1, + 1, 0, 1, 0); + else + e_widget_frametable_object_append(of, ob, 1, (i - 1), 1, 1, + 1, 0, 1, 0); } e_widget_list_object_append(o, of, 1, 1, 0.5); } =================================================================== RCS file: /cvs/e/e_modules/mixer/alsa_mixer.c,v retrieving revision 1.33 retrieving revision 1.34 diff -u -3 -r1.33 -r1.34 --- alsa_mixer.c 20 Nov 2007 21:03:57 -0000 1.33 +++ alsa_mixer.c 12 Dec 2007 23:24:14 -0000 1.34 @@ -197,17 +197,11 @@ const char *name; name = snd_mixer_selem_id_get_name(sid); - if ((!strcmp(name, "Master")) || (!strcmp(name, "PCM")) || - (!strcmp(name, "DAC")) || (!strcmp(name, "Wave"))) - { - ac = E_NEW(Mixer_Channel, 1); - if (!ac) continue; - - ac->name = evas_stringshare_add(name); - ac->id = _alsa_get_mixer_id(ac->name); - - channels = evas_list_append(channels, ac); - } + ac = E_NEW(Mixer_Channel, 1); + if (!ac) continue; + ac->name = evas_stringshare_add(name); + ac->id = _alsa_get_mixer_id(ac->name); + channels = evas_list_append(channels, ac); } } snd_mixer_close(handle); ------------------------------------------------------------------------- SF.Net email is sponsored by: Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace _______________________________________________ enlightenment-cvs mailing list enlightenment-cvs@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs