There is no callback feature in Audacious < 2.2 that moves the UI's volume
slider when external volume controls are used. Hence stick to the internal
volume level and don't get confused when trying to save/restore external
volume levels.
diff -Nur audacious-plugins-fedora-2.1-orig/src/pulse_audio/pulse_audio.c audacious-plugins-fedora-2.1-pulseaudio/src/pulse_audio/pulse_audio.c
--- audacious-plugins-fedora-2.1-orig/src/pulse_audio/pulse_audio.c 2009-07-07 00:40:36.000000000 +0200
+++ audacious-plugins-fedora-2.1-pulseaudio/src/pulse_audio/pulse_audio.c 2009-10-21 22:44:06.149809732 +0200
@@ -80,6 +80,8 @@
}
static void info_cb(struct pa_context *c, const struct pa_sink_input_info *i, int is_last, void *userdata) {
+ return; /* we don't do anything useful with this callback */
+
assert(c);
if (!i)
@@ -709,6 +711,18 @@
goto unlock_and_fail;
}
+ pa_operation_unref(o);
+ /* set initial volume */
+ if (!(o = pa_context_set_sink_input_volume(context, pa_stream_get_index(stream), &volume, NULL, NULL))) {
+ g_warning("pa_context_set_sink_input_volume() failed: %s", pa_strerror(pa_context_errno(context)));
+ goto unlock_and_fail;
+ }
+ while (pa_operation_get_state(o) != PA_OPERATION_DONE) {
+ CHECK_DEAD_GOTO(fail, 1);
+ pa_threaded_mainloop_wait(mainloop);
+ }
+ pa_operation_unref(o);
+
do_trigger = 0;
written = 0;
time_offset_msec = 0;