+static gboolean
+event_wrap (GstPad * pad, GstObject * object, GstEvent * event)
+{
+ GstFlowReturn ret;
+
+ ret = GST_PAD_EVENTFULLFUNC (pad) (pad, object, event);
+ if (ret == GST_FLOW_OK)
+ return TRUE;
+ return FALSE;
+}
+
+/**
+ * gst_pad_set_event_full_function:
+ * @p: a #GstPad of either direction.
+ * @f: the #GstPadEventFullFunction to set.
+ *
+ * Calls gst_pad_set_event_full_function_full() with %NULL for the user_data and
+ * notify.
+ */
+/**
+ * gst_pad_set_event_full_function_full:
+ * @pad: a #GstPad of either direction.
+ * @event: the #GstPadEventFullFunction to set.
+ * @user_data: user_data passed to @notify
+ * @notify: notify called when @event will not be used anymore.
+ *
+ * Sets the given event handler for the pad.
+ *
+ * Since: 1.8
+ */
+void
+gst_pad_set_event_full_function_full (GstPad * pad,
+ GstPadEventFullFunction event, gpointer user_data, GDestroyNotify notify)
+{
+ g_return_if_fail (GST_IS_PAD (pad));
+
+ if (pad->eventnotify)
+ pad->eventnotify (pad->eventdata);
+ GST_PAD_EVENTFULLFUNC (pad) = event;
+ GST_PAD_EVENTFUNC (pad) = event_wrap;
+ pad->eventdata = user_data;
+ pad->eventnotify = notify;
+
+ GST_CAT_DEBUG_OBJECT (GST_CAT_PADS, pad, "eventfullfunc for set to %s",
+ GST_DEBUG_FUNCPTR_NAME (event));
+}
+