After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 642036 - No way to pass a message when adding a contact
No way to pass a message when adding a contact
Status: RESOLVED FIXED
Product: folks
Classification: Platform
Component: Telepathy backend
git master
Other Linux
: Normal normal
: folks-0.3.5
Assigned To: folks-maint
folks-maint
Depends on:
Blocks: 642332
 
 
Reported: 2011-02-10 14:54 UTC by Guillaume Desmottes
Modified: 2011-02-14 22:38 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Add support for passing messages to personas being added (6.59 KB, patch)
2011-02-14 22:22 UTC, Philip Withnall
committed Details | Review

Description Guillaume Desmottes 2011-02-10 14:54:46 UTC
When adding a new contact, Empathy uses folks_individual_aggregator_add_persona_from_details() and if I understand this code correctly, we don't have API to pass a message when doing so.

This can be used if we want to add UI to let user type a small presentation message.
Comment 1 Travis Reitter 2011-02-10 16:14:49 UTC
We'll be breaking that API in this release cycle already (with bug #629078), so now would be a good time to fix this as well.
Comment 2 Philip Withnall 2011-02-14 21:58:33 UTC
Could a message not be passed in via the "details" hash table? That said, for consistency with the other methods in IndividualAggregator, having it take a "string? details" would be better.
Comment 3 Philip Withnall 2011-02-14 22:22:35 UTC
Created attachment 180862 [details] [review]
Add support for passing messages to personas being added

After discussing this with Travis on IRC, it was decided to go with using a "message" key in the hash table, rather than breaking API.

Here's a branch which documents that, and adds (untested) support for it in the Telepathy backend.

http://git.collabora.co.uk/?p=user/pwith/folks;a=shortlog;h=refs/heads/642036-add-persona-message
Comment 4 Philip Withnall 2011-02-14 22:24:50 UTC
Argh, and once more I forget to update the NEWS file.
Comment 5 Philip Withnall 2011-02-14 22:38:33 UTC
Reviewed by Travis on IRC.

commit d4ec25154f72711c9c1e5e81f224051ab12c5e82
Author: Philip Withnall <philip.withnall@collabora.co.uk>
Date:   Mon Feb 14 22:18:36 2011 +0000

    Bug 642036 — No way to pass a message when adding a contact
    
    Document that the "message" key in the details hash table passed to
    IndividualAggregator.add_persona_from_details() may (by convention) be used
    to pass a human-readable message to the persona being added.
    
    Implement this in the Telepathy backend. Closes: bgo#642036

 backends/telepathy/lib/tp-lowlevel.c          |    5 +++--
 backends/telepathy/lib/tp-lowlevel.h          |    9 +++++++++
 backends/telepathy/lib/tpf-persona-store.vala |   22 ++++++++++++++--------
 folks/individual-aggregator.vala              |    1 +
 4 files changed, 27 insertions(+), 10 deletions(-)