aboutsummaryrefslogtreecommitdiff
path: root/audio/gnomoradio/files/patch-roboradio-audio_prober.cc
diff options
context:
space:
mode:
Diffstat (limited to 'audio/gnomoradio/files/patch-roboradio-audio_prober.cc')
-rw-r--r--audio/gnomoradio/files/patch-roboradio-audio_prober.cc58
1 files changed, 58 insertions, 0 deletions
diff --git a/audio/gnomoradio/files/patch-roboradio-audio_prober.cc b/audio/gnomoradio/files/patch-roboradio-audio_prober.cc
new file mode 100644
index 000000000000..d03d1e8c686b
--- /dev/null
+++ b/audio/gnomoradio/files/patch-roboradio-audio_prober.cc
@@ -0,0 +1,58 @@
+--- roboradio/audio/prober.cc.orig 2007-12-06 15:39:58.000000000 +0100
++++ roboradio/audio/prober.cc 2007-12-06 15:40:19.000000000 +0100
+@@ -21,6 +21,30 @@
+ #include "../mp3/esd-audio.h"
+ }
+
++namespace Roboradio
++{
++ namespace Audio
++ {
++ gboolean probe (gpointer s)
++ {
++ Prober *sng = static_cast<Prober*>(s);
++ if (esdout_playing()) {
++ int pos = sng->get_position();
++ if (pos >= 0)
++ sng->signal_position_changed(pos);
++ return true;
++ } else if (sng->get_position() >= 0) {
++ return true;
++ } else {
++ sng->stop();
++ sng->signal_done();
++ sng->activated = false;
++ return false;
++ }
++ }
++ }
++}
++
+ Roboradio::Audio::Prober::Prober ()
+ : activated(false)
+ {
+@@ -31,24 +55,6 @@
+ stop_prober();
+ }
+
+-gboolean Roboradio::Audio::probe (gpointer s)
+-{
+- Prober *sng = static_cast<Prober*>(s);
+- if (esdout_playing()) {
+- int pos = sng->get_position();
+- if (pos >= 0)
+- sng->signal_position_changed(pos);
+- return true;
+- } else if (sng->get_position() >= 0) {
+- return true;
+- } else {
+- sng->stop();
+- sng->signal_done();
+- sng->activated = false;
+- return false;
+- }
+-}
+-
+ void Roboradio::Audio::Prober::start_prober ()
+ {
+ if (activated)