diff options
author | Sjoerd Simons <sjoerd.simons@collabora.co.uk> | 2009-03-09 04:18:31 +0800 |
---|---|---|
committer | Xavier Claessens <xclaesse@src.gnome.org> | 2009-03-09 04:18:31 +0800 |
commit | dafe7cf1759fb206760d84157d4695cec6cd826c (patch) | |
tree | 4068d29834ff96b4eab697583f487d15aff3ea20 /libempathy/empathy-call-handler.c | |
parent | 87c7a840467687a189135cddf31ca64c440e4a95 (diff) | |
download | gsoc2013-empathy-dafe7cf1759fb206760d84157d4695cec6cd826c.tar gsoc2013-empathy-dafe7cf1759fb206760d84157d4695cec6cd826c.tar.gz gsoc2013-empathy-dafe7cf1759fb206760d84157d4695cec6cd826c.tar.bz2 gsoc2013-empathy-dafe7cf1759fb206760d84157d4695cec6cd826c.tar.lz gsoc2013-empathy-dafe7cf1759fb206760d84157d4695cec6cd826c.tar.xz gsoc2013-empathy-dafe7cf1759fb206760d84157d4695cec6cd826c.tar.zst gsoc2013-empathy-dafe7cf1759fb206760d84157d4695cec6cd826c.zip |
Forward resource requests
From: Sjoerd Simons <sjoerd.simons@collabora.co.uk>
svn path=/trunk/; revision=2638
Diffstat (limited to 'libempathy/empathy-call-handler.c')
-rw-r--r-- | libempathy/empathy-call-handler.c | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/libempathy/empathy-call-handler.c b/libempathy/empathy-call-handler.c index 8d159cdd4..072542c82 100644 --- a/libempathy/empathy-call-handler.c +++ b/libempathy/empathy-call-handler.c @@ -39,6 +39,7 @@ enum { CONFERENCE_ADDED, SRC_PAD_ADDED, SINK_PAD_ADDED, + REQUEST_RESOURCE, CLOSED, LAST_SIGNAL }; @@ -197,6 +198,13 @@ empathy_call_handler_class_init (EmpathyCallHandlerClass *klass) G_TYPE_NONE, 2, GST_TYPE_PAD, G_TYPE_UINT); + signals[REQUEST_RESOURCE] = + g_signal_new ("request-resource", G_TYPE_FROM_CLASS (klass), + G_SIGNAL_RUN_LAST, 0, + g_signal_accumulator_true_handled, NULL, + _empathy_marshal_BOOLEAN__UINT_UINT, + G_TYPE_BOOLEAN, 2, G_TYPE_UINT, G_TYPE_UINT); + signals[CLOSED] = g_signal_new ("closed", G_TYPE_FROM_CLASS (klass), G_SIGNAL_RUN_LAST, 0, NULL, NULL, @@ -257,7 +265,15 @@ static gboolean empathy_call_handler_tf_stream_request_resource_cb (TfStream *stream, guint direction, EmpathyTpCall *call) { - return TRUE; + gboolean ret; + guint media_type; + + g_object_get (G_OBJECT (stream), "media-type", &media_type, NULL); + + g_signal_emit (G_OBJECT (call), + signals[REQUEST_RESOURCE], 0, media_type, direction, &ret); + + return ret; } static void |