Closed Bug 1591357 Opened 5 years ago Closed 5 years ago

folder-tooltip, chat-tooltip tooltips aren't working

Categories

(Thunderbird :: General, task)

task
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
Thunderbird 72.0

People

(Reporter: mkmelin, Assigned: mkmelin)

References

(Regression)

Details

(Keywords: regression)

Attachments

(3 files, 1 obsolete file)

folder-tooltip aren't working anymore after bug 1590074.
https://searchfox.org/comm-central/search?q=folder-tooltip&case=false&regexp=false&path=

If I change this to load like before (after DOMWindowCreated) it works.
The folder-tooltip is defined as a normal CE - no { extends: "tooltip" } - but used as a customized built-in (using <tooltip is="folder-tooltip">), so it's not quite right. But it can't be set up as a customized built-in either. If I do that I get "TypeError: Illegal constructor." at https://searchfox.org/comm-central/rev/3979888eb7841cb8774d099c087c12d0a44c1965/mozilla/toolkit/content/customElements.js#237

Is there some reason <tooltip> can't be extended like other elements?

Flags: needinfo?(bgrinstead)
Regressed by: 1588500

You've got the wrong dependency here.

Flags: needinfo?(mkmelin+mozilla)

Right, fixed now. It's bug 1590074

Flags: needinfo?(mkmelin+mozilla)
Regressed by: 1590074
No longer regressed by: 1588500

(In reply to Magnus Melin [:mkmelin] from comment #0)

folder-tooltip aren't working anymore after bug 1590074.
https://searchfox.org/comm-central/search?q=folder-tooltip&case=false&regexp=false&path=

If I change this to load like before (after DOMWindowCreated) it works.
The folder-tooltip is defined as a normal CE - no { extends: "tooltip" } - but used as a customized built-in (using <tooltip is="folder-tooltip">), so it's not quite right. But it can't be set up as a customized built-in either. If I do that I get "TypeError: Illegal constructor." at https://searchfox.org/comm-central/rev/3979888eb7841cb8774d099c087c12d0a44c1965/mozilla/toolkit/content/customElements.js#237

Is there some reason <tooltip> can't be extended like other elements?

The last searchfox link is a 404 for me, but my guess is that you need to have the class ultimately extend XULPopupElement and not XULElement (via MozXULElement). See for instance https://searchfox.org/mozilla-central/rev/7536d7f480a7f18c941a590a2d4c5119d9f52770/toolkit/content/widgets/autocomplete-popup.js#10.

Flags: needinfo?(bgrinstead)

Thanks Brian, that works!

Attached patch bug1591357_tooltips.patch (obsolete) (deleted) — Splinter Review
Attachment #9104413 - Flags: review?(khushil324)
Status: NEW → ASSIGNED
Comment on attachment 9104413 [details] [diff] [review] bug1591357_tooltips.patch Review of attachment 9104413 [details] [diff] [review]: ----------------------------------------------------------------- Looks good to me. r=khushil
Attachment #9104413 - Flags: review?(khushil324) → review+

Hmm, folder tooltips seem to work again with that patch, but somehow I don't get any tooltips of my RSS folders any more. I still get them in TB 71 beta 1, and we're less than a week after the branch date.

Also, should Local Folder has a tooltip?

It's hard to tell what should get a tooltip, I guess folders with new messages. Somehow some of my RSS folders get tooltips, but not on trunk with this patch. Maybe a different bug.

Attached image destroyed new mail notification.png (deleted) —

Sadly this obliterates the new mail notification. That's now empty in the TL corner when it should be BR and not empty. I popped the patch and it was back to normal.

Flags: needinfo?(mkmelin+mozilla)

The way folder tooltips work is if the folder has new (not just unread) messages, those are listed in a summary. If you have unexpanded subfolders with unread, it shows information about this.

Everything works the same for all types of folders as far as the tooltip is concerned.

Attached image tooltip on RSS folder.png (deleted) —

I agree, Magnus, and new means it arrived while the session was open. However, in TB 68 and TB 71 beta I get a tooltip on an RSS folder after starting the session, so there's nothing new in it. On trunk with your patch, that tooltip isn't there. Try it.

Grrrr, scrap that, it's because the folder name is so long.

EDIT:

Everything works the same for all types of folders as far as the tooltip is concerned.

Agreed.

Attached patch bug1591357_tooltips.patch (deleted) — Splinter Review

There's all sorts of ugly in here this file. These two classes should be even further decoupled, and the listener for the preview text is just awful.

I cleaned up some of the methods that didn't use this instead of event.target, but would always be the same, and added some more documentation. On return value was wrong too (but unused where it would have mattered).

I don't see an problem with RSS feeds.

Attachment #9104413 - Attachment is obsolete: true
Flags: needinfo?(mkmelin+mozilla)
Attachment #9104606 - Flags: review?(jorgk)
Comment on attachment 9104606 [details] [diff] [review] bug1591357_tooltips.patch OK, this seems to work. Tested folder tooltips for folders with new messages and also folders with long names which didn't fit into the folder pane (in case of my RSS folders). Also tested new message notification, also when message moved by filter (bug 1547202). I'm not sure which chat tooltips were broken, but they seem to work now. Given that I'm really no expert on all of this, let's have Khushil check it out as well, sadly PLR. s/loan/borrow/ as per IRC discussion with Magnus.
Attachment #9104606 - Flags: review?(khushil324)
Attachment #9104606 - Flags: review?(jorgk)
Attachment #9104606 - Flags: review+
Attachment #9104606 - Flags: approval-comm-beta+
Comment on attachment 9104606 [details] [diff] [review] bug1591357_tooltips.patch Oops, not broken in beta, sorry.
Attachment #9104606 - Flags: approval-comm-beta+
Target Milestone: --- → Thunderbird 72.0
Version: unspecified → 72

Pushed by mozilla@jorgk.com:
https://hg.mozilla.org/comm-central/rev/addbcedd8b4b
make folder-tooltip, chat-tooltip tooltips proper customized built-ins so they work. r=jorgk DONTBUILD

Status: ASSIGNED → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Attachment #9104606 - Flags: review?(khushil324)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: