Closed Bug 1509389 Opened Last year Closed Last year

Installation of extension with browser_action destroys toolbar


(Thunderbird :: Add-Ons: General, defect)

Not set


(thunderbird64 fixed, thunderbird65 fixed)

Thunderbird 65.0
Tracking Status
thunderbird64 --- fixed
thunderbird65 --- fixed


(Reporter: brummolix, Assigned: darktrojan)



(2 files, 1 obsolete file)

Attached image empty toolbar.jpg
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:63.0) Gecko/20100101 Firefox/63.0

Steps to reproduce:

- use TB64.0b2 (it was also in beta 1)
- Install an addon which includes a browser_action, for example

Actual results:

The main toolbar (with reply, create, address book, hamburger menu etc.) is emptied, only the extension action is visible (see attached screenshot).

If you close Thunderbird and reopen it, the original toolbar is restored. If you edit the toolbar before closing, the broken state is saved.

Expected results:

The toolbar should be as before (I'm not sure if the extension icon should be added or not)
I *think* I know what causes this, in which case there's already a fix on the way. Was your toolbar in the default state before installing the extension?
You are right, it was in default state. I tried it again. If the toolbar is already changed, the extension button is correctly added at the right side fof the toolbar.
Attached patch 1509389-empty-toolbar-1.diff (obsolete) — Splinter Review
Even though I have this in bug 1509246, it won't be happening there any time soon.
Assignee: nobody → geoff
Ever confirmed: true
Attachment #9027441 - Flags: review?(mkmelin+mozilla)
Attachment #9027441 - Flags: approval-comm-beta?
Comment on attachment 9027441 [details] [diff] [review]

Review of attachment 9027441 [details] [diff] [review]:

::: mail/components/extensions/ExtensionToolbarButtons.jsm
@@ +144,5 @@
>      }
> +    let currentSet = toolbar.getAttribute("currentset");
> +    if (!currentSet) {
> +      currentSet = toolbar.getAttribute("defaultset");
> +    }

could just make it

let currentSet = toolbar.getAttribute("currentset") || toolbar.getAttribute("defaultset");
Attachment #9027441 - Flags: review?(mkmelin+mozilla) → review+
I suppose the toolbar *could* have an empty current set, so we'd better account for that.
Attachment #9027441 - Attachment is obsolete: true
Attachment #9027441 - Flags: approval-comm-beta?
Attachment #9027774 - Flags: review?(mkmelin+mozilla)
Attachment #9027774 - Flags: approval-comm-beta?
Comment on attachment 9027774 [details] [diff] [review]

Review of attachment 9027774 [details] [diff] [review]:

My suggestion handles that (since falsy...)
No, you misunderstand, the toolbar might be *deliberately empty*. Why, I've no idea, but people are weird.
Attachment #9027774 - Flags: review?(mkmelin+mozilla) → review+
Keywords: checkin-needed
Attachment #9027774 - Flags: approval-comm-beta? → approval-comm-beta+
Pushed by
Use toolbar default set if current set doesn't exist. r=mkmelin
Closed: Last year
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → Thunderbird 65.0
You need to log in before you can comment on or make changes to this bug.