diff options
author | Lionel Landwerlin <llandwerlin@gmail.com> | 2015-09-26 11:54:50 +0100 |
---|---|---|
committer | Lionel Landwerlin <llandwerlin@gmail.com> | 2015-09-26 11:55:34 +0100 |
commit | f1d410c04f0008203383bd2cc797a8ccf2d3f554 (patch) | |
tree | d5cfff2fbe96635c5758d0baefdcd146762fe42e | |
parent | 778af2dcc9a32b6aef083c5c9a61abdf42827a4e (diff) | |
download | clutter-gst-f1d410c04f0008203383bd2cc797a8ccf2d3f554.tar.gz |
video-sink: forward navigation event upstream
-rw-r--r-- | clutter-gst/clutter-gst-video-sink.c | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/clutter-gst/clutter-gst-video-sink.c b/clutter-gst/clutter-gst-video-sink.c index 8f0bedb..8a74557 100644 --- a/clutter-gst/clutter-gst-video-sink.c +++ b/clutter-gst/clutter-gst-video-sink.c @@ -693,8 +693,20 @@ static void clutter_gst_video_sink_navigation_send_event (GstNavigation *navigation, GstStructure *structure) { - // TODO: how do we feed the events back to the UI layer? New - // signals? + GstEvent *event; + GstPad *pad = NULL; + + event = gst_event_new_navigation (structure); + + pad = gst_pad_get_peer (GST_VIDEO_SINK_PAD (navigation)); + + if (GST_IS_PAD (pad)) + { + gst_pad_send_event (pad, event); + gst_object_unref (pad); + } + else + gst_event_unref (event); } static void |