Last Comment Bug 763522 - Show presence information in email headers
: Show presence information in email headers
Status: RESOLVED FIXED
:
Product: Thunderbird
Classification: Client Software
Component: Instant Messaging (show other bugs)
: Trunk
: All All
: -- enhancement (vote)
: Thunderbird 16.0
Assigned To: Florian Quèze [:florian] [:flo] (PTO until August 29th)
:
Mentors:
: 788496 (view as bug list)
Depends on: 775105
Blocks:
  Show dependency treegraph
 
Reported: 2012-06-11 09:25 PDT by Florian Quèze [:florian] [:flo] (PTO until August 29th)
Modified: 2012-10-10 01:05 PDT (History)
5 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
fixed


Attachments
Patch v1 (12.31 KB, patch)
2012-06-11 09:25 PDT, Florian Quèze [:florian] [:flo] (PTO until August 29th)
bwinton: review+
bwinton: ui‑review-
Details | Diff | Splinter Review
Screenshot (22.77 KB, image/png)
2012-06-11 09:26 PDT, Florian Quèze [:florian] [:flo] (PTO until August 29th)
no flags Details
Patch v2 (13.46 KB, patch)
2012-06-19 10:00 PDT, Florian Quèze [:florian] [:flo] (PTO until August 29th)
bwinton: ui‑review-
Details | Diff | Splinter Review
Screenshot of patch v2 (15.95 KB, image/png)
2012-06-19 10:01 PDT, Florian Quèze [:florian] [:flo] (PTO until August 29th)
no flags Details
Patch v3 (13.42 KB, patch)
2012-06-27 04:16 PDT, Florian Quèze [:florian] [:flo] (PTO until August 29th)
bwinton: ui‑review+
standard8: approval‑comm‑aurora+
Details | Diff | Splinter Review
Screenshot of patch v3 (11.81 KB, image/png)
2012-06-27 04:18 PDT, Florian Quèze [:florian] [:flo] (PTO until August 29th)
no flags Details
Additionnal fix (702 bytes, patch)
2012-06-28 08:52 PDT, Florian Quèze [:florian] [:flo] (PTO until August 29th)
florian: review+
Details | Diff | Splinter Review

Description Florian Quèze [:florian] [:flo] (PTO until August 29th) 2012-06-11 09:25:07 PDT
Created attachment 631912 [details] [diff] [review]
Patch v1

The attached patch will display the green dot icon next to names of online contacts, and the red dot icon next to away/unavailable contacts. No presence icon will be displayed for offline contacts or email addresses for which we don't know the chat username.

The chat username used for the presence detection is either the email address itself, or the Gtalk or Jabber Id field of the address book card; if one exists.

The chat username we will use is displayed in a tooltip on the first line, and the status is displayed on the second line.

Clicking the presence icon will open or select the Chat tab, and create or select & focus the conversation for this contact.
Comment 1 Florian Quèze [:florian] [:flo] (PTO until August 29th) 2012-06-11 09:26:03 PDT
Created attachment 631913 [details]
Screenshot
Comment 2 Blake Winton (:bwinton) (:☕️) 2012-06-18 12:14:41 PDT
Comment on attachment 631912 [details] [diff] [review]
Patch v1

So, the blue star and green dot make the address seem a little too busy to me.  I think I would prefer replacing the blue star with the green dot instead, since we'll never have a green (or red) dot if we don't have an address book entry (as I understand it).

I also think we need some way of making the tooltip more obviously chat-related, since hovering over the name shows [blaketestwinton@gmail.com], and hovering over the dot shows essentially the same thing (with an "Available" beneath it).  I think putting the network there (i.e. [GTalk]) instead might be more unique and useful information for the user.  Oh, also, what do we do if the user is connected to more than one network?

>+++ b/mail/base/content/msgHdrViewOverlay.js
>@@ -1211,16 +1251,41 @@ function UpdateEmailNodeDetails(aEmailAd
>+function UpdateEmailPresenceDetails(aDocumentNode, aChatContact) {
>+  let {Status: statusUtils} =
>+    Components.utils.import("resource:///modules/imStatusUtils.jsm");

Why not hoist this up to the top-level, so that we don't re-import it all the time?

Other than that, I'm pretty happy with it.  So r=me, but I'm going to say ui-r-, so that I can double-check how well the changes I asked for above work.

Thanks,
Blake.
Comment 3 Florian Quèze [:florian] [:flo] (PTO until August 29th) 2012-06-18 13:29:36 PDT
(In reply to Blake Winton (:bwinton - Thunderbird UX) from comment #2)

> since we'll never have a green (or red) dot if we don't have an
> address book entry (as I understand it).

This isn't true. The patch uses either the email address, or if an address book card exists, the Gtalk field, or the Jabber ID field.
So if someone for whom you don't have an address book card (or haven't filed any chat field in his card) is on your Gtalk contact list and online, the presence indicator will be displayed.

> Oh, also, what do we do if the user is connected to more than one
> network?

We use the first usable one we find. The presence indicators currently only work for Gtalk/Jabber, so it's unlikely that the same chat username (which is alwasy an email address for these networks) could match 2 different people on different networks.
Comment 4 Blake Winton (:bwinton) (:☕️) 2012-06-18 13:31:01 PDT
(In reply to Florian Quèze from comment #3)
> (In reply to Blake Winton (:bwinton - Thunderbird UX) from comment #2)
> 
> > since we'll never have a green (or red) dot if we don't have an
> > address book entry (as I understand it).
> 
> This isn't true. The patch uses either the email address, or if an address
> book card exists, the Gtalk field, or the Jabber ID field.
> So if someone for whom you don't have an address book card (or haven't filed
> any chat field in his card) is on your Gtalk contact list and online, the
> presence indicator will be displayed.

In that case, how do you propose to get rid of the confusing multiple icons?

Thanks,
Blake.
Comment 5 Florian Quèze [:florian] [:flo] (PTO until August 29th) 2012-06-18 13:37:26 PDT
(In reply to Blake Winton (:bwinton - Thunderbird UX) from comment #4)

> In that case, how do you propose to get rid of the confusing multiple icons?

We could move the presence icon to before the email address text. The downside is that the text would jump when the contact becomes offline.
Comment 6 Florian Quèze [:florian] [:flo] (PTO until August 29th) 2012-06-19 10:00:42 PDT
Created attachment 634482 [details] [diff] [review]
Patch v2
Comment 7 Florian Quèze [:florian] [:flo] (PTO until August 29th) 2012-06-19 10:01:23 PDT
Created attachment 634483 [details]
Screenshot of patch v2
Comment 8 Magnus Melin 2012-06-19 23:16:29 PDT
I haven't tried this, but can't we always use just one icon? Hovering on it can show "Not yet in your addressbook" in the tooltip or something if that's the case. (And do what the star does now.)
Comment 9 Florian Quèze [:florian] [:flo] (PTO until August 29th) 2012-06-20 02:31:16 PDT
(In reply to Magnus Melin from comment #8)
> I haven't tried this, but can't we always use just one icon? Hovering on it
> can show "Not yet in your addressbook" in the tooltip or something if that's
> the case. (And do what the star does now.)

- We indent to land this in aurora so that it's part of Thunderbird 15, which will be the first release with instant messaging pref'ed on, so we are looking for a solution that doesn't require new localizable strings.

- Clicking the presence icon starts a new chat conversation (or selects the existing one) with the contact, so it would be difficult to put another action on that icon.

- I'm not a fan of putting 2 unrelated things (presence, and whether the email is in the address book) on the same icon, but really that's up to Blake.
Comment 10 Magnus Melin 2012-06-20 05:09:30 PDT
Other issues aside, limiting what you do based on release target is definitely not something we should do.
Comment 11 Blake Winton (:bwinton) (:☕️) 2012-06-21 07:32:03 PDT
Comment on attachment 634482 [details] [diff] [review]
Patch v2

Yeah, I don't really like the way it makes the addresses de-align with the subject…  Argh, coming up with good UI is hard!
Comment 12 Florian Quèze [:florian] [:flo] (PTO until August 29th) 2012-06-27 04:16:18 PDT
Created attachment 637070 [details] [diff] [review]
Patch v3

Blake convinced me that if a contact is already in the chat contact list but not in the address book, it's likely the user isn't interested in adding contacts to the address book, so hiding the star and showing only the presence icon when a contact is online is acceptable. It's still possible to add the contact to the address book from the popup menu that appears when clicking on the text of the address instead of the icon.
Comment 13 Florian Quèze [:florian] [:flo] (PTO until August 29th) 2012-06-27 04:18:39 PDT
Created attachment 637071 [details]
Screenshot of patch v3
Comment 14 Blake Winton (:bwinton) (:☕️) 2012-06-27 12:36:46 PDT
Comment on attachment 637070 [details] [diff] [review]
Patch v3

I've played around with it a bit, and I like it!  ui-r=me!

Thanks,
Blake.
Comment 15 Florian Quèze [:florian] [:flo] (PTO until August 29th) 2012-06-28 08:52:11 PDT
Created attachment 637532 [details] [diff] [review]
Additionnal fix

When testing attachment 637070 [details] [diff] [review] again just before doing the check-in, I noticed that it causes errors in the case of the standalone message window. The attached patch will work-around this until implement a real solution in another bug.
rs=bwinton over IRC for this additional change.
Comment 16 Florian Quèze [:florian] [:flo] (PTO until August 29th) 2012-06-28 09:01:12 PDT
Pushed attachment 637070 [details] [diff] [review] and attachment 637532 [details] [diff] [review] as https://hg.mozilla.org/comm-central/rev/98534b8f5aa5
Comment 17 Florian Quèze [:florian] [:flo] (PTO until August 29th) 2012-07-16 05:38:35 PDT
https://hg.mozilla.org/releases/comm-aurora/rev/e54040b9ca53
Comment 18 Sören Hentzschel 2012-07-24 14:26:52 PDT
one question, just for clarification: the google talk id is an e-mail address? and online on google plus it's the same like online on google talk? I ask because one of my buddies is online on google plus. I see him in the chat tab as online. But I don't see the presence information in the mail header. I added his address as google talk id in the address book, but there is no green or red dot, there is just the star icon. I tested on Windows 7 with TB 16 Earlybird and TB 17 Daily and I tested on Mac OS X 10.7 with TB 16 Earlybird and TB 17 Daily.
Comment 19 Vincent (caméléon) 2012-10-05 09:08:47 PDT
*** Bug 788496 has been marked as a duplicate of this bug. ***

Note You need to log in before you can comment on or make changes to this bug.