mirror of
https://github.com/Rafostar/clapper.git
synced 2025-08-30 07:42:23 +02:00
API: let client decide what to do on EOS #52
This commit is contained in:
7
lib/gst/clapper/gstclapper.c
vendored
7
lib/gst/clapper/gstclapper.c
vendored
@@ -1323,14 +1323,13 @@ eos_cb (G_GNUC_UNUSED GstBus * bus, G_GNUC_UNUSED GstMessage * msg,
|
|||||||
tick_cb (self);
|
tick_cb (self);
|
||||||
remove_tick_source (self);
|
remove_tick_source (self);
|
||||||
|
|
||||||
|
/* When connected client should handle what to do (stop/repeat) */
|
||||||
if (g_signal_handler_find (self, G_SIGNAL_MATCH_ID,
|
if (g_signal_handler_find (self, G_SIGNAL_MATCH_ID,
|
||||||
signals[SIGNAL_END_OF_STREAM], 0, NULL, NULL, NULL) != 0) {
|
signals[SIGNAL_END_OF_STREAM], 0, NULL, NULL, NULL) != 0) {
|
||||||
gst_clapper_signal_dispatcher_dispatch (self->signal_dispatcher, self,
|
gst_clapper_signal_dispatcher_dispatch (self->signal_dispatcher, self,
|
||||||
eos_dispatch, g_object_ref (self), (GDestroyNotify) g_object_unref);
|
eos_dispatch, g_object_ref (self), (GDestroyNotify) g_object_unref);
|
||||||
}
|
} else
|
||||||
|
gst_clapper_stop_internal (self, FALSE);
|
||||||
/* TODO: repeat instead of stop */
|
|
||||||
gst_clapper_stop_internal (self, FALSE);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
typedef struct
|
typedef struct
|
||||||
|
@@ -568,6 +568,10 @@ class ClapperPlayer extends GstClapper.Clapper
|
|||||||
this.quitOnStop = true;
|
this.quitOnStop = true;
|
||||||
this._performCloseCleanup(this.widget.get_root());
|
this._performCloseCleanup(this.widget.get_root());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* When this signal is connected player
|
||||||
|
* wants us to decide if it should stop */
|
||||||
|
this.stop();
|
||||||
}
|
}
|
||||||
|
|
||||||
_onUriLoaded(player, uri)
|
_onUriLoaded(player, uri)
|
||||||
|
Reference in New Issue
Block a user