[gnome-online-accounts] telepathyfactory: filter out MSN too



commit 1b6a9ef3b09bfe499d55e7d53909712ed2fc7cef
Author: Marco Barisione <marco barisione collabora co uk>
Date:   Wed Aug 28 15:41:45 2013 +0100

    telepathyfactory: filter out MSN too
    
    MSN is already handled by a specific provider in GOA, so no need to show
    it twice (even if the telepathy-haze one uses Windows Live's proprietary
    protocol, while the GOA one uses XMPP).
    
    https://bugzilla.gnome.org/show_bug.cgi?id=706987

 src/goabackend/goatelepathyfactory.c |    9 ++++++++-
 1 files changed, 8 insertions(+), 1 deletions(-)
---
diff --git a/src/goabackend/goatelepathyfactory.c b/src/goabackend/goatelepathyfactory.c
index f90e5f5..5f58800 100644
--- a/src/goabackend/goatelepathyfactory.c
+++ b/src/goabackend/goatelepathyfactory.c
@@ -69,7 +69,7 @@ get_protocols_cb (GObject      *source,
                   gpointer      user_data)
 {
   GSimpleAsyncResult *outer_result = user_data;
-  GQuark facebook_quark, google_talk_quark;
+  GQuark facebook_quark, google_talk_quark, msn_quark;
   GList *protocols = NULL;
   GList *ret;
   GList *l;
@@ -85,12 +85,15 @@ get_protocols_cb (GObject      *source,
 
   facebook_quark = g_quark_from_static_string ("facebook");
   google_talk_quark = g_quark_from_static_string ("google-talk");
+  msn_quark = g_quark_from_static_string ("msn");
 
   ret = NULL;
   for (l = protocols; l != NULL; l = l->next)
     {
       TpawProtocol *protocol = l->data;
+      const gchar *protocol_name = tpaw_protocol_get_protocol_name (protocol);
       const gchar *service_name = tpaw_protocol_get_service_name (protocol);
+      GQuark protocol_quark = g_quark_try_string (protocol_name);
       GQuark service_quark = g_quark_try_string (service_name);
       GoaTelepathyProvider *provider;
 
@@ -104,6 +107,10 @@ get_protocols_cb (GObject      *source,
       if (service_quark == google_talk_quark)
         continue;
 #endif
+#if GOA_WINDOWS_LIVE_ENABLED
+      if (protocol_quark == msn_quark)
+        continue;
+#endif
 
       provider = goa_telepathy_provider_new_from_protocol (protocol);
       ret = g_list_prepend (ret, provider);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]