# HG changeset patch # User Matti Hamalainen # Date 1191263124 -10800 # Node ID fbe7468efaea3c3320cc202b795e69e5e4a293df # Parent c3d2de7c4151345ce8da3f0865be5e8c4cb0fed9# Parent 30ef1287da19a7abf6388b5c1db41a6e8bc54f72 Automated merge with file:/home/ccr/audacious/core diff -r c3d2de7c4151 -r fbe7468efaea src/audacious/effect.c --- a/src/audacious/effect.c Sun Sep 30 19:00:59 2007 +0300 +++ b/src/audacious/effect.c Mon Oct 01 21:25:24 2007 +0300 @@ -83,7 +83,6 @@ if (!node || !(node->data)) return; ep = node->data; - ep->enabled = enable; if (enable && !ep->enabled) { ep_data.enabled_list = g_list_append(ep_data.enabled_list, ep); @@ -95,6 +94,8 @@ if (ep->cleanup) ep->cleanup(); } + + ep->enabled = enable; } GList * diff -r c3d2de7c4151 -r fbe7468efaea src/audacious/playback.c --- a/src/audacious/playback.c Sun Sep 30 19:00:59 2007 +0300 +++ b/src/audacious/playback.c Mon Oct 01 21:25:24 2007 +0300 @@ -59,8 +59,20 @@ #include "playback.h" #include "playback_evlisteners.h" -static int song_info_timeout_source = 0; +static gint song_info_timeout_source = 0; +static gint update_vis_timeout_source = 0; +/* XXX: there has to be a better way than polling here! */ +static gboolean +playback_update_vis_func(gpointer unused) +{ + if (!playback_get_playing()) + return FALSE; + + input_update_vis(playback_get_time()); + + return TRUE; +} static gint playback_set_pb_ready(InputPlayback *playback) @@ -153,6 +165,9 @@ song_info_timeout_source = g_timeout_add(1000, (GSourceFunc) mainwin_update_song_info, NULL); + update_vis_timeout_source = g_timeout_add(10, + (GSourceFunc) playback_update_vis_func, NULL); + if (cfg.player_shaded) { gtk_widget_show(mainwin_stime_min); gtk_widget_show(mainwin_stime_sec); diff -r c3d2de7c4151 -r fbe7468efaea src/audacious/ui_main.c --- a/src/audacious/ui_main.c Sun Sep 30 19:00:59 2007 +0300 +++ b/src/audacious/ui_main.c Mon Oct 01 21:25:24 2007 +0300 @@ -2666,9 +2666,6 @@ { static gint count = 0; - if (playback_get_playing()) - input_update_vis(playback_get_time()); - GDK_THREADS_ENTER(); if (!count) { diff -r c3d2de7c4151 -r fbe7468efaea src/audacious/ui_main.h --- a/src/audacious/ui_main.h Sun Sep 30 19:00:59 2007 +0300 +++ b/src/audacious/ui_main.h Mon Oct 01 21:25:24 2007 +0300 @@ -35,7 +35,7 @@ #define MAINWIN_SHADED_WIDTH MAINWIN_WIDTH #define MAINWIN_SHADED_HEIGHT MAINWIN_TITLEBAR_HEIGHT -#define MAINWIN_UPDATE_INTERVAL 10 +#define MAINWIN_UPDATE_INTERVAL 100 #define MAINWIN_DEFAULT_POS_X 20 #define MAINWIN_DEFAULT_POS_Y 20