Closed Bug 971266 Opened 11 years ago Closed 9 years ago

Sync tooltip in Australis menu for signed-in users should say “Open Sync Preferences”

Categories

(Firefox :: Sync, defect, P1)

defect

Tracking

()

VERIFIED FIXED
Firefox 42
Iteration:
42.1 - Jul 13
Tracking Status
firefox42 --- verified

People

(Reporter: rfeeley, Assigned: eoger)

References

Details

(Whiteboard: [fxsync][bugday-20150722])

Attachments

(1 file)

When the user is known, the Sync menu item tooltip currently repeats the email address for the signed-in user: https://www.dropbox.com/s/gchlu315syulu5j/what-should-tooltip-say.png It should instead say “Open Sync Preferences” (not in quotes).
Can't fix this in 29, no string. Let's fix it on trunk (30) though.
OS: Mac OS X → All
Hardware: x86 → All
have tried finding the file where the exact code has been written but i didn't find the file all i got is the UI for different things and the function for the sing in and sync
have tried finding the file where the exact code has been written but i didn't find the file all i got is the UI for different things and the function for the sing in and sync
Asking Ryan for details.
Flags: needinfo?(rfeeley)
I can't find it myself, Gavin, know of this strings whereabouts?
Flags: needinfo?(rfeeley) → needinfo?(gavin.sharp)
That label's tooltip text is set here: http://hg.mozilla.org/mozilla-central/annotate/0e19655e93df/browser/base/content/browser-fxaccounts.js#l194 It should be set to a new string rather than userData.email. That requires adding the string in question from comment 0 to sync.properties and accessing it via a string bundle here.
Flags: needinfo?(gavin.sharp)
Attached patch bug971266.diffSplinter Review
Attachment #8537334 - Flags: review?(mak77)
Assignee: nobody → shubhamjindal18
Comment on attachment 8537334 [details] [diff] [review] bug971266.diff Looks good to me! I think you can use gSyncUI._stringBundle instead of calling createBundle again. If you did that, it would probably also make sense to change it to just gSyncUI.stringBundle ("_" prefix suggests and internal property, and there's no reason for this to be). But those things are not necessary changes, this looks good as-is.
Attachment #8537334 - Flags: feedback+
Comment on attachment 8537334 [details] [diff] [review] bug971266.diff Review of attachment 8537334 [details] [diff] [review]: ----------------------------------------------------------------- ::: browser/base/content/browser-fxaccounts.js @@ +191,5 @@ > this.button.setAttribute("signedin", "true"); > this.button.setAttribute("label", userData.email); > + this.button.setAttribute("tooltiptext", Services.strings.createBundle( > + "chrome://browser/locale/sync.properties") > + .GetStringFromName("client.tooltiptext.email")); I agree with Gavin, but rather than exposing gSyncUI._stringBundle as an API, I'd prefer a gSyncUI.getString("name-of-string") using _stringBundle internally, it would read better. ::: services/sync/locales/en-US/sync.properties @@ +45,5 @@ > # %1: the app name (Firefox) > error.sync.eol.description = Your Firefox Sync service is no longer available. You need to upgrade %1$S to keep syncing. > sync.eol.learnMore.label = Learn more > sync.eol.learnMore.accesskey = L > +client.tooltiptext.email = Open Sync Preferences We should have a better name for this, client and email here don't point out anything useful for the localizer. something like: menuwidget.signedin.tooltip would do. A LOCALIZAZION NOTE() explaining where it is used, would also we welcome.
Attachment #8537334 - Flags: review?(mak77)
I will change the name and submit the patch. I didn't get the part of A LOCALIZATION NOTE().
(In reply to Shubham Jindal [:shubham] from comment #10) > I will change the name and submit the patch. I didn't get the part of A > LOCALIZATION NOTE(). A note explaining where the string is used. Something like this : # LOCALIZATION NOTE : [...]
Status: NEW → ASSIGNED
(In reply to Marco Bonardo [::mak] (needinfo? me) from comment #9) > I agree with Gavin, but rather than exposing gSyncUI._stringBundle as an > API, I'd prefer a gSyncUI.getString("name-of-string") using _stringBundle > internally, it would read better. I didn't get this part. I used DXR to search gSyncUI and see if there is anything like gSyncUI.getString or gSyncUI.getStringFromName, but I was not able to find such function. How should I use this to get the String?
Flags: needinfo?(mak77)
(In reply to Shubham Jindal [:shubham] from comment #12) > I didn't get this part. I used DXR to search gSyncUI and see if there is > anything like gSyncUI.getString or gSyncUI.getStringFromName, but I was not > able to find such function. How should I use this to get the String? You'll have to add it. That involves adding a function somewhere around here: https://hg.mozilla.org/mozilla-central/annotate/67872ce17918/browser/base/content/browser-syncui.js#l98 That looks like this: getString: function (stringName) { return this._stringBundle.GetStringFromName(stringName); } Then you can have your newly added code just call gSyncUI.getString("client.tooltiptext.email") instead of .createBundle().getStringFromName() etc. You could also then change other callers of this._stringBundle.GetStringFromName in browser-syncui.js to use the new function.
Flags: needinfo?(mak77)
Priority: -- → P1
Blocks: 1182288
Rank: 15
This is fixed in bug 1139698.
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Whiteboard: [fxsync]
Iteration: --- → 42.1 - Jul 13
Assignee: shubhamjindal18 → edouard.oger
Depends on: 1139698
Target Milestone: --- → Firefox 42
QA Whiteboard: [good first verify]
Reproduced this bug in Nightly 30.0a1 (2014-02-11) on Linux x64 by following comment 0's instruction! Bug is now fixed on Latest Nightly 42.0a1 (2015-07-21) Build ID: 20150721030212 User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:42.0) Gecko/20100101 Firefox/42.0
QA Whiteboard: [good first verify] → [good first verify][bugday-20150722]
Whiteboard: [fxsync] → [fxsync][bugday-20150722]
Status: RESOLVED → VERIFIED
I have seen the bug windows 7, 64 bit with Nightly 36.0a1 (2014-11-04)! This Bugs fix is verified now on Latest Nightly 42.0a1 (2015-07-21) Build ID : 20150721030212 User Agent : Mozilla/5.0 (Windows NT 6.1; WOW64; rv:42.0) Gecko/20100101 Firefox/42.0
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: