Mercurial > audlegacy-plugins
comparison src/skins/ui_equalizer.c @ 2668:a1431a900f28
introduce ui_skinned_button_set_inside
author | Tomasz Mon <desowin@gmail.com> |
---|---|
date | Fri, 30 May 2008 21:02:12 +0200 |
parents | ba91ea50f214 |
children | 438597b1f669 |
comparison
equal
deleted
inserted
replaced
2667:84d34cd6aa71 | 2668:a1431a900f28 |
---|---|
428 | 428 |
429 equalizerwin_on = ui_skinned_button_new(); | 429 equalizerwin_on = ui_skinned_button_new(); |
430 ui_skinned_toggle_button_setup(equalizerwin_on, SKINNED_WINDOW(equalizerwin)->fixed, | 430 ui_skinned_toggle_button_setup(equalizerwin_on, SKINNED_WINDOW(equalizerwin)->fixed, |
431 14, 18, 25, 12, 10, 119, 128, 119, 69, 119, 187, 119, SKIN_EQMAIN); | 431 14, 18, 25, 12, 10, 119, 128, 119, 69, 119, 187, 119, SKIN_EQMAIN); |
432 g_signal_connect(equalizerwin_on, "clicked", equalizerwin_on_pushed, NULL); | 432 g_signal_connect(equalizerwin_on, "clicked", equalizerwin_on_pushed, NULL); |
433 UI_SKINNED_BUTTON(equalizerwin_on)->inside = aud_cfg->equalizer_active; | 433 ui_skinned_button_set_inside(equalizerwin_on, aud_cfg->equalizer_active); |
434 | 434 |
435 equalizerwin_auto = ui_skinned_button_new(); | 435 equalizerwin_auto = ui_skinned_button_new(); |
436 ui_skinned_toggle_button_setup(equalizerwin_auto, SKINNED_WINDOW(equalizerwin)->fixed, | 436 ui_skinned_toggle_button_setup(equalizerwin_auto, SKINNED_WINDOW(equalizerwin)->fixed, |
437 39, 18, 33, 12, 35, 119, 153, 119, 94, 119, 212, 119, SKIN_EQMAIN); | 437 39, 18, 33, 12, 35, 119, 153, 119, 94, 119, 212, 119, SKIN_EQMAIN); |
438 g_signal_connect(equalizerwin_auto, "clicked", equalizerwin_auto_pushed, NULL); | 438 g_signal_connect(equalizerwin_auto, "clicked", equalizerwin_auto_pushed, NULL); |
439 UI_SKINNED_BUTTON(equalizerwin_auto)->inside = aud_cfg->equalizer_autoload; | 439 ui_skinned_button_set_inside(equalizerwin_auto, aud_cfg->equalizer_autoload); |
440 | 440 |
441 equalizerwin_presets = ui_skinned_button_new(); | 441 equalizerwin_presets = ui_skinned_button_new(); |
442 ui_skinned_push_button_setup(equalizerwin_presets, SKINNED_WINDOW(equalizerwin)->fixed, | 442 ui_skinned_push_button_setup(equalizerwin_presets, SKINNED_WINDOW(equalizerwin)->fixed, |
443 217, 18, 44, 12, 224, 164, 224, 176, SKIN_EQMAIN); | 443 217, 18, 44, 12, 224, 164, 224, 176, SKIN_EQMAIN); |
444 g_signal_connect(equalizerwin_presets, "clicked", equalizerwin_presets_pushed, NULL ); | 444 g_signal_connect(equalizerwin_presets, "clicked", equalizerwin_presets_pushed, NULL ); |
562 ((config.equalizer_shaded ? 14 : 116) * config.scale_factor)); | 562 ((config.equalizer_shaded ? 14 : 116) * config.scale_factor)); |
563 else | 563 else |
564 gtk_widget_set_size_request(equalizerwin, 275, | 564 gtk_widget_set_size_request(equalizerwin, 275, |
565 (config.equalizer_shaded ? 14 : 116)); | 565 (config.equalizer_shaded ? 14 : 116)); |
566 config.equalizer_visible = TRUE; | 566 config.equalizer_visible = TRUE; |
567 UI_SKINNED_BUTTON(mainwin_eq)->inside = TRUE; | 567 ui_skinned_button_set_inside(mainwin_eq, TRUE); |
568 gtk_widget_show_all(equalizerwin); | 568 gtk_widget_show_all(equalizerwin); |
569 | 569 |
570 if (!config.equalizer_shaded) { | 570 if (!config.equalizer_shaded) { |
571 gtk_widget_hide(equalizerwin_volume); | 571 gtk_widget_hide(equalizerwin_volume); |
572 gtk_widget_hide(equalizerwin_balance); | 572 gtk_widget_hide(equalizerwin_balance); |
588 * This function should only be called from the | 588 * This function should only be called from the |
589 * main menu signal handler | 589 * main menu signal handler |
590 */ | 590 */ |
591 gtk_widget_hide(equalizerwin); | 591 gtk_widget_hide(equalizerwin); |
592 config.equalizer_visible = FALSE; | 592 config.equalizer_visible = FALSE; |
593 UI_SKINNED_BUTTON(mainwin_eq)->inside = FALSE; | 593 ui_skinned_button_set_inside(mainwin_eq, FALSE); |
594 gtk_widget_queue_draw(mainwin_eq); | 594 gtk_widget_queue_draw(mainwin_eq); |
595 } | 595 } |
596 | 596 |
597 static EqualizerPreset * | 597 static EqualizerPreset * |
598 equalizerwin_find_preset(GList * list, const gchar * name) | 598 equalizerwin_find_preset(GList * list, const gchar * name) |
1524 | 1524 |
1525 void | 1525 void |
1526 equalizer_activate(gboolean active) | 1526 equalizer_activate(gboolean active) |
1527 { | 1527 { |
1528 aud_cfg->equalizer_active = active; | 1528 aud_cfg->equalizer_active = active; |
1529 UI_SKINNED_BUTTON(equalizerwin_on)->inside = active; | 1529 ui_skinned_button_set_inside(equalizerwin_on, active); |
1530 gtk_widget_queue_draw(equalizerwin_on); | |
1531 | 1530 |
1532 equalizerwin_eq_changed(); | 1531 equalizerwin_eq_changed(); |
1533 } | 1532 } |