[Bug 52938] TpAccount is missing an avatar-changed signal

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Wed Oct 23 13:37:13 CEST 2013


https://bugs.freedesktop.org/show_bug.cgi?id=52938

--- Comment #2 from Simon McVittie <simon.mcvittie at collabora.co.uk> ---
(In reply to comment #1)
> I'd like to fix this to simplify Empathy code before porting to next.

Does Empathy really want to be tracking the avatar (= pull it into memory
whenever it changes) *all the time*, or only when the account editor is
actually open?

> Question: how should we expose the avatar on the TpAccount?
> - a (GFile, const gchar *mime_type) as TpContact does (2 properties)? But
> then we should write the file to disk first.

I don't think this should happen unless we replace A.I.Avatar with something
URI-based at the D-Bus level (Bug #33409). Random UIs copying the avatar to a
separate file on disk seems rather pointless.

> - a (GArray, const gchar *mime_type) to stay coherent with
> tp_account_get_avatar_finish()?
> - a GVariant packing these 2 values into one?

Or a GBytes and a string, maybe? But I don't think random UIs keeping our
avatar in memory is desirable, if they're not actually actively using it.

Until Bug #33409 is done, I'd be tempted to do the straightforward binding of
the current D-Bus API:

    /**
     * TpAccount::avatar-changed:
     *
     * Emitted when the avatar changes. Call tp_account_get_avatar_async()
     * to get the new avatar data.
     */

If you're going to load a GFile from disk, with current GIO best-practices it's
going to be an async operation *anyway*... so we might as well use the current
D-Bus API?

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.


More information about the telepathy-bugs mailing list