diff options
Diffstat (limited to 'libempathy')
-rw-r--r-- | libempathy/empathy-contact.c | 19 | ||||
-rw-r--r-- | libempathy/empathy-contact.h | 2 |
2 files changed, 9 insertions, 12 deletions
diff --git a/libempathy/empathy-contact.c b/libempathy/empathy-contact.c index 6c703acde..718274a59 100644 --- a/libempathy/empathy-contact.c +++ b/libempathy/empathy-contact.c @@ -85,6 +85,8 @@ static void empathy_contact_set_location (EmpathyContact *contact, static void set_capabilities_from_tp_caps (EmpathyContact *self, TpCapabilities *caps); +static void contact_set_avatar (EmpathyContact *contact, + EmpathyAvatar *avatar); static void contact_set_avatar_from_tp_contact (EmpathyContact *contact); G_DEFINE_TYPE (EmpathyContact, empathy_contact, G_TYPE_OBJECT); @@ -266,7 +268,7 @@ empathy_contact_class_init (EmpathyContactClass *class) "Avatar image", "The avatar image", EMPATHY_TYPE_AVATAR, - G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS)); + G_PARAM_READABLE | G_PARAM_STATIC_STRINGS)); g_object_class_install_property (object_class, PROP_PRESENCE, @@ -478,9 +480,6 @@ contact_set_property (GObject *object, case PROP_ALIAS: empathy_contact_set_alias (contact, g_value_get_string (value)); break; - case PROP_AVATAR: - empathy_contact_set_avatar (contact, g_value_get_boxed (value)); - break; case PROP_PRESENCE: empathy_contact_set_presence (contact, g_value_get_uint (value)); break; @@ -724,9 +723,9 @@ empathy_contact_get_avatar (EmpathyContact *contact) return priv->avatar; } -void -empathy_contact_set_avatar (EmpathyContact *contact, - EmpathyAvatar *avatar) +static void +contact_set_avatar (EmpathyContact *contact, + EmpathyAvatar *avatar) { EmpathyContactPriv *priv; @@ -1199,7 +1198,7 @@ empathy_contact_load_avatar_cache (EmpathyContact *contact, DEBUG ("Avatar loaded from %s", filename); avatar = empathy_avatar_new ((guchar *) data, len, NULL, g_strdup (token), filename); - empathy_contact_set_avatar (contact, avatar); + contact_set_avatar (contact, avatar); empathy_avatar_unref (avatar); } else @@ -1668,12 +1667,12 @@ contact_set_avatar_from_tp_contact (EmpathyContact *contact) g_file_load_contents (file, NULL, &data, &len, NULL, NULL); avatar = empathy_avatar_new ((guchar *) data, len, g_strdup (mime), g_strdup (token), g_file_get_path (file)); - empathy_contact_set_avatar (contact, avatar); + contact_set_avatar (contact, avatar); empathy_avatar_unref (avatar); } else { - empathy_contact_set_avatar (contact, NULL); + contact_set_avatar (contact, NULL); } } diff --git a/libempathy/empathy-contact.h b/libempathy/empathy-contact.h index c65e0871f..1117d7f82 100644 --- a/libempathy/empathy-contact.h +++ b/libempathy/empathy-contact.h @@ -83,8 +83,6 @@ void empathy_contact_set_alias (EmpathyContact *contact, const gchar *alias); void empathy_contact_change_group (EmpathyContact *contact, const gchar *group, gboolean is_member); EmpathyAvatar * empathy_contact_get_avatar (EmpathyContact *contact); -void empathy_contact_set_avatar (EmpathyContact *contact, - EmpathyAvatar *avatar); TpAccount * empathy_contact_get_account (EmpathyContact *contact); FolksPersona * empathy_contact_get_persona (EmpathyContact *contact); void empathy_contact_set_persona (EmpathyContact *contact, |