[empathy: 1/13] stop handling internally stream media channels
- From: Guillaume Desmottes <gdesmott src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [empathy: 1/13] stop handling internally stream media channels
- Date: Tue, 22 Jun 2010 15:26:26 +0000 (UTC)
commit f43fbe8cdb7adf761c2b23206b4c13ee5efc3332
Author: Guillaume Desmottes <guillaume desmottes collabora co uk>
Date: Mon Jun 21 13:14:35 2010 +0200
stop handling internally stream media channels
We are going to do it properly using TpSimpleHandler.
libempathy/empathy-dispatch-operation.c | 30 -------------------------
src/empathy.c | 36 +------------------------------
2 files changed, 1 insertions(+), 65 deletions(-)
---
diff --git a/libempathy/empathy-dispatch-operation.c b/libempathy/empathy-dispatch-operation.c
index 83cf724..65fe4b1 100644
--- a/libempathy/empathy-dispatch-operation.c
+++ b/libempathy/empathy-dispatch-operation.c
@@ -442,17 +442,6 @@ empathy_dispatcher_operation_tp_chat_ready_cb (GObject *object,
}
static void
-call_status_changed_cb (EmpathyTpCall *call,
- GParamSpec *spec,
- EmpathyDispatchOperation *self)
-{
- if (empathy_tp_call_get_status (call) <= EMPATHY_TP_CALL_STATUS_READYING)
- return;
-
- channel_wrapper_ready (self);
-}
-
-static void
empathy_dispatch_operation_channel_ready_cb (TpChannel *channel,
const GError *error, gpointer user_data)
{
@@ -488,25 +477,6 @@ empathy_dispatch_operation_channel_ready_cb (TpChannel *channel,
goto out;
}
}
- else if (channel_type == TP_IFACE_QUARK_CHANNEL_TYPE_STREAMED_MEDIA)
- {
- gboolean requested;
- EmpathyTpCall *call = empathy_tp_call_new (channel);
- priv->channel_wrapper = G_OBJECT (call);
-
- requested = tp_asv_get_boolean (tp_channel_borrow_immutable_properties (
- channel), TP_PROP_CHANNEL_REQUESTED, NULL);
-
- if (!requested &&
- empathy_tp_call_get_status (call) <= EMPATHY_TP_CALL_STATUS_READYING)
- {
- /* For incoming calls, we have to wait that the TpCall is ready as
- * the call-handler rely on it. */
- priv->ready_handler = g_signal_connect (call,
- "notify::status", G_CALLBACK (call_status_changed_cb), self);
- goto out;
- }
- }
else if (channel_type == TP_IFACE_QUARK_CHANNEL_TYPE_FILE_TRANSFER)
{
EmpathyTpFile *file = empathy_tp_file_new (channel, priv->incoming);
diff --git a/src/empathy.c b/src/empathy.c
index 2c7ea2a..85c0ea8 100644
--- a/src/empathy.c
+++ b/src/empathy.c
@@ -140,13 +140,6 @@ dispatch_cb (EmpathyDispatcher *dispatcher,
empathy_dispatch_operation_claim (operation);
}
- else if (channel_type == TP_IFACE_QUARK_CHANNEL_TYPE_STREAMED_MEDIA)
- {
- EmpathyCallFactory *factory;
-
- factory = empathy_call_factory_get ();
- empathy_call_factory_claim_channel (factory, operation);
- }
else if (channel_type == TP_IFACE_QUARK_CHANNEL_TYPE_FILE_TRANSFER)
{
EmpathyFTFactory *factory;
@@ -396,15 +389,9 @@ setup_dispatcher (void)
{ TP_IFACE_CHANNEL_TYPE_TEXT, TP_HANDLE_TYPE_ROOM },
/* file transfer to contacts */
{ TP_IFACE_CHANNEL_TYPE_FILE_TRANSFER, TP_HANDLE_TYPE_CONTACT },
- /* stream media to contacts */
- { TP_IFACE_CHANNEL_TYPE_STREAMED_MEDIA, TP_HANDLE_TYPE_CONTACT },
/* roomlists */
{ TP_IFACE_CHANNEL_TYPE_ROOM_LIST, TP_HANDLE_TYPE_NONE },
};
- gchar *capabilities[] = {
- "org.freedesktop.Telepathy.Channel.Interface.MediaSignalling/ice-udp",
- "org.freedesktop.Telepathy.Channel.Interface.MediaSignalling/gtalk-p2p",
- NULL };
GHashTable *asv;
guint i;
@@ -435,29 +422,8 @@ setup_dispatcher (void)
g_ptr_array_add (filters, asv);
}
- asv = tp_asv_new (
- TP_IFACE_CHANNEL ".ChannelType",
- G_TYPE_STRING, TP_IFACE_CHANNEL_TYPE_STREAMED_MEDIA,
- TP_IFACE_CHANNEL ".TargetHandleType",
- G_TYPE_INT, TP_HANDLE_TYPE_CONTACT,
- TP_IFACE_CHANNEL_TYPE_STREAMED_MEDIA ".InitialAudio",
- G_TYPE_BOOLEAN, TRUE,
- NULL);
- g_ptr_array_add (filters, asv);
-
- asv = tp_asv_new (
- TP_IFACE_CHANNEL ".ChannelType",
- G_TYPE_STRING, TP_IFACE_CHANNEL_TYPE_STREAMED_MEDIA,
- TP_IFACE_CHANNEL ".TargetHandleType",
- G_TYPE_INT, TP_HANDLE_TYPE_CONTACT,
- TP_IFACE_CHANNEL_TYPE_STREAMED_MEDIA ".InitialVideo",
- G_TYPE_BOOLEAN, TRUE,
- NULL);
- g_ptr_array_add (filters, asv);
-
-
empathy_dispatcher_add_handler (d, PACKAGE_NAME"MoreThanMeetsTheEye",
- filters, capabilities);
+ filters, NULL);
g_ptr_array_foreach (filters, (GFunc) g_hash_table_destroy, NULL);
g_ptr_array_free (filters, TRUE);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]