return cmp;
}
-static const char *
-protocol_chooser_proto_name_to_display_name (const gchar *proto_name)
-{
- int i;
- static struct {
- const gchar *proto;
- const gchar *display;
- } names[] = {
- { "jabber", "Jabber" },
- { "msn", "MSN" },
- { "local-xmpp", N_("People Nearby") },
- { "irc", "IRC" },
- { "icq", "ICQ" },
- { "aim", "AIM" },
- { "yahoo", "Yahoo!" },
- { "groupwise", "GroupWise" },
- { "sip", "SIP" },
- { NULL, NULL }
- };
-
- for (i = 0; names[i].proto != NULL; i++)
- {
- if (!tp_strdiff (proto_name, names[i].proto))
- return names[i].display;
- }
-
- return NULL;
-}
-
static void
protocol_choosers_add_cm (EmpathyProtocolChooser *chooser,
TpConnectionManager *cm)
g_strdup (proto->name), g_strdup (cm->name));
icon_name = empathy_protocol_icon_name (proto->name);
- display_name = protocol_chooser_proto_name_to_display_name (proto->name);
+ display_name = empathy_protocol_name_to_display_name (proto->name);
if (display_name == NULL)
display_name = proto->name;
return t;
}
+
+const char *
+empathy_protocol_name_to_display_name (const gchar *proto_name)
+{
+ int i;
+ static struct {
+ const gchar *proto;
+ const gchar *display;
+ } names[] = {
+ { "jabber", "Jabber" },
+ { "msn", "MSN" },
+ { "local-xmpp", N_("People Nearby") },
+ { "irc", "IRC" },
+ { "icq", "ICQ" },
+ { "aim", "AIM" },
+ { "yahoo", "Yahoo!" },
+ { "groupwise", "GroupWise" },
+ { "sip", "SIP" },
+ { NULL, NULL }
+ };
+
+ for (i = 0; names[i].proto != NULL; i++)
+ {
+ if (!tp_strdiff (proto_name, names[i].proto))
+ return names[i].display;
+ }
+
+ return NULL;
+}
+
gconstpointer b);
gchar *empathy_protocol_icon_name (const gchar *protocol);
+const gchar *empathy_protocol_name_to_display_name (const gchar *proto_name);
#define EMPATHY_ARRAY_TYPE_OBJECT (empathy_type_dbus_ao ())
GType empathy_type_dbus_ao (void);