Calendar/Task toolbar not shown in menu View > Toolbars or toolbar context menu

ASSIGNED
Assigned to

Status

Calendar
Lightning Only
ASSIGNED
6 years ago
4 years ago

People

(Reporter: Stefan Sitter, Assigned: Decathlon, NeedInfo)

Tracking

(Blocks: 1 bug)

Lightning 1.3
Dependency tree / graph

Details

Attachments

(2 attachments, 1 obsolete attachment)

(Reporter)

Description

6 years ago
Lightning 1.4a1 (BuildID: 20120114040802) 
Mozilla/5.0 (Windows NT 6.1; rv:12.0a1) Gecko/20120115 Thunderbird/12.0a1

Steps to reprocude:
1) Try to switch off Calendar toolbar or Task toolbar or both in menu View > Toolbars
2) Try to switch off Calendar toolbar or Task toolbar in toolbars context menu

Actual results:
Calendar toolbar and Task toolbar are not shown in menu.

Expected results:
Calendar toolbar and Task toolbar are shown in menu.
(Reporter)

Comment 1

6 years ago
Same problem in 1.3b1.
Blocks: 709572
Version: Lightning 1.4 → Lightning 1.3
(Reporter)

Updated

6 years ago
Duplicate of this bug: 729540

Comment 3

5 years ago
Is there any way to remove the toolbars by editing userChrome.css ?
This should work:

#calendar-toolbox,
#task-toolbox {
  display: none;
}

Comment 5

5 years ago
Thanks! Just figured out the same thing using DOM inspector.
Created attachment 687534 [details]
unremovable toolbar

Is this the toolbar this bug is referring to? If yes, color me interested.
In the meanwhile, the CSS above works to achieve the goal. I'm applying it with Stylish.
(Assignee)

Updated

5 years ago
Assignee: nobody → bv1578
OS: Windows 7 → All
Hardware: x86 → All
(Reporter)

Updated

5 years ago
Blocks: 866370
(Assignee)

Comment 8

5 years ago
Created attachment 747937 [details] [diff] [review]
patch - v1

I've tried different ways to fix this, but this one seems the simplest (if everything is right).

IMHO it would also need to disable the context menu (on toolbars and menubar) when the "Customize toolbar" window is open, but I see that the same feature doesn't exist on Thunderbird.
 
This patch also fixes bug 866370.
Attachment #747937 - Flags: review?(philipp)
(Assignee)

Updated

5 years ago
Status: NEW → ASSIGNED
(Assignee)

Comment 9

5 years ago
Created attachment 749846 [details] [diff] [review]
patch - v2

I've just realize that there also is a menu item for the toolbars in the AppMenu (but it is under the "Options..." item instead of "View").
This patch sorts out the menu items in that menu too.
Attachment #747937 - Attachment is obsolete: true
Attachment #747937 - Flags: review?(philipp)
Attachment #749846 - Flags: review?(philipp)
(Reporter)

Comment 10

5 years ago
Did you test that it works or at least doesn't break in SeaMonkey?
Comment on attachment 749846 [details] [diff] [review]
patch - v2

Review of attachment 749846 [details] [diff] [review]:
-----------------------------------------------------------------

r=philipp
Attachment #749846 - Flags: review?(philipp) → review+
(Assignee)

Comment 12

4 years ago
(In reply to Stefan Sitter from comment #10)
> Did you test that it works or at least doesn't break in SeaMonkey?

I've installed SeaMonkey and tested the patch which doesn't work because SeaMonkey has a different structure (e.g. the mail toolbar stays on the window together with the calendar or the task toolbars, the function that adds the items in the menu is different, etc.), but it doesn't break any element in SeaMonkey so I think we can push it in the repository.
If it's fine, I leave this bug open and I will try to make another patch for SeaMonkey.
(Assignee)

Comment 13

4 years ago
patch - v2 pushed on comm-central:
https://hg.mozilla.org/comm-central/rev/6ea5e19539b8

Comment 14

4 years ago
Please make sure you don't regress:
Bug 721330 - Make Customizing Lightning Toolbars work in SeaMonkey.
Bug 753683 - Simplify SeaMonkey handling of Lightnings customizable toolbars, Lightning part.

Comment 15

4 years ago
> +  <menupopup id="toolbar-context-menu"
> +             onpopupshowing="onToolbarsPopupShowingWithMode(event);"/>

This clobbers the SeaMonkey onpopupshowing attribute:

  <menupopup id="toolbar-context-menu"
         onpopupshowing="onViewToolbarsPopupShowing(event);"

> +function onToolbarsPopupShowingWithMode(aEvent, aInsertPoint) {
> +    let toolbox = [gCurrentMode + "-toolbox"];
> +    if (gCurrentMode != "mail") {
> +        toolbox.push("navigation-toolbox");
> +    }
> +    onViewToolbarsPopupShowing(aEvent, toolbox, aInsertPoint);

This almost works. Unfortunately the SeaMonkey onViewToolbarsPopupShowing() follows the Firefox version which puts aInsertPoint as the second parameter.

Comment 16

4 years ago
Wouldn't it have been simpler if you just added the Lightning toolbars to the externalToolbars property of the mail toolbox?

http://hg.mozilla.org/comm-central/annotate/32140632beac/mail/base/content/mailCore.js#l257
Flags: needinfo?(bv1578)

Updated

4 years ago
Depends on: 879845
Target Milestone: --- → 2.6
You need to log in before you can comment on or make changes to this bug.