Commit f8d0a491 authored by Chris Talbot's avatar Chris Talbot
Browse files

mm-account: Set mms-feature to true when mmsd-tng service loads

parent bde6303b
Pipeline #71284 passed with stages
in 11 minutes and 15 seconds
......@@ -91,6 +91,7 @@ struct _ChattyMmAccount
guint mm_watch_id;
gboolean mm_loaded;
gboolean has_mms;
ChattyMmsd *mmsd_struct;
};
......@@ -978,6 +979,7 @@ chatty_mm_account_init (ChattyMmAccount *self)
self->mmsd_struct = chatty_mmsd_new(self);
self->pending_sms = g_hash_table_new_full (g_direct_hash, g_direct_equal,
NULL, g_object_unref);
self->has_mms = FALSE;
}
ChattyMmAccount *
......@@ -1251,8 +1253,15 @@ chatty_mm_account_has_mms_feature (ChattyMmAccount *self)
{
g_return_val_if_fail (CHATTY_IS_MM_ACCOUNT (self), FALSE);
/* TODO */
return FALSE;
return self->has_mms;
}
void
chatty_mm_account_set_mms_feature (ChattyMmAccount *self, gboolean mms_feature)
{
g_return_if_fail (CHATTY_IS_MM_ACCOUNT (self));
self->has_mms = mms_feature;
}
void
......
......@@ -45,6 +45,8 @@ ChattyChat *chatty_mm_account_start_chat (ChattyMmAccount *sel
void chatty_mm_account_delete_chat (ChattyMmAccount *self,
ChattyChat *chat);
gboolean chatty_mm_account_has_mms_feature (ChattyMmAccount *self);
void chatty_mm_account_set_mms_feature (ChattyMmAccount *self,
gboolean mms_feature);
void chatty_mm_account_send_message_async (ChattyMmAccount *self,
ChattyChat *chat,
ChattyMmBuddy *buddy,
......
......@@ -1305,6 +1305,7 @@ chatty_mmsd_get_service_cb (GObject *service,
} else {
g_debug ("Got MMSD Service");
chatty_mm_account_set_mms_feature (self->mm_account, TRUE);
self->mmsd_service_proxy_watch_id =
g_dbus_connection_signal_subscribe (self->connection,
MMSD_SERVICE,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment