diff options
author | Edward Hervey <edward@centricular.com> | 2015-04-02 16:10:32 +0200 |
---|---|---|
committer | Edward Hervey <bilboed@bilboed.com> | 2015-04-29 15:47:49 +0200 |
commit | c90a3ac468fcb99587b10cd77efae2acfb17d7fa (patch) | |
tree | b1be376023bed0758287d30c38a6051788664b85 /sys | |
parent | 01e2a2152d8650ef676aa6ea016aa46552cb7023 (diff) | |
download | gst-plugins-base-c90a3ac468fcb99587b10cd77efae2acfb17d7fa.tar.gz gst-plugins-base-c90a3ac468fcb99587b10cd77efae2acfb17d7fa.tar.xz |
xvimagesink: Post unhandled navigation events on the bus
https://bugzilla.gnome.org/show_bug.cgi?id=747245
Diffstat (limited to 'sys')
-rw-r--r-- | sys/xvimage/xvimagesink.c | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/sys/xvimage/xvimagesink.c b/sys/xvimage/xvimagesink.c index a0d62a06d..38f9de845 100644 --- a/sys/xvimage/xvimagesink.c +++ b/sys/xvimage/xvimagesink.c @@ -1127,9 +1127,10 @@ gst_xvimagesink_navigation_send_event (GstNavigation * navigation, { GstXvImageSink *xvimagesink = GST_XVIMAGESINK (navigation); GstPad *peer; + gboolean handled = FALSE; + GstEvent *event = NULL; if ((peer = gst_pad_get_peer (GST_VIDEO_SINK_PAD (xvimagesink)))) { - GstEvent *event; GstVideoRectangle src = { 0, }; GstVideoRectangle dst = { 0, }; GstVideoRectangle result; @@ -1182,9 +1183,17 @@ gst_xvimagesink_navigation_send_event (GstNavigation * navigation, (gdouble) y * yscale, NULL); } - gst_pad_send_event (peer, event); + gst_event_ref (event); + handled = gst_pad_send_event (peer, event); + if (handled) + gst_event_unref (event); gst_object_unref (peer); } + + if (!handled && event) { + gst_element_post_message ((GstElement *) xvimagesink, + gst_navigation_message_new_event ((GstObject *) xvimagesink, event)); + } } static void |