Closed Bug 1650835 Opened 4 years ago Closed 4 years ago

Support toolbar buttons that have a default action, and a drop marker to open a panel with more options

Categories

(Firefox :: Toolbars and Customization, enhancement, P5)

enhancement

Tracking

()

RESOLVED FIXED
86 Branch
Tracking Status
firefox86 --- fixed

People

(Reporter: florian, Assigned: mstange)

References

(Regressed 1 open bug)

Details

Attachments

(2 files)

I hacked this in bug 1621015 for the profiler toolbar icon, so that the profiler icon itself starts/stops the profiler, and a dropmarker opens a panel to configure the profiler.

It would be nice to support this more generically so that other buttons could use it. The devtools button would most likely also want to use this, when the click on the icon would open/close devtools, and the dropmarker would open the current menu which lists various developer tools.

Probably low priority as we have something that currently works well enough for the profiler button.

Severity: -- → N/A
Type: task → enhancement
Priority: -- → P5
Assignee: nobody → mstange.moz
Status: NEW → ASSIGNED
Depends on: 1679843

I'm taking a stab at this because bug 1650833 is bothering me personally.

This widget will be used for the profiler button. The profiler button is a
two-part widget with both a command and a view. The command starts/stops the
profiler, but the starting/stopping can also be performed from inside the view.
The dropmarker button shows the view.
When this widget is located in the panel, the start/stop action is only
accessible via the view and there is no "quick-action" command.

The structure of the widget is as follows:

toolbaritem.toolbaritem-combined-buttons

  • toolbarbutton.toolbarbutton-1
  • toolbarbutton.toolbarbutton-1.toolbarbutton-combined-buttons-dropmarker

The dropmarker icon is the toolbarbutton icon of the second toolbarbutton.
The dropmarker button is only shown in the toolbar or in the customize palette.
It is hidden when the widget is located in the panel.
In the toolbar, the hover effect of the dropmarker needs to have the same height
as the hover effect of the regular button. However, due to the different image
size (12x12 instead of 16x16) it requires more vertical padding.

Depends on D98214

Attachment #9190355 - Attachment description: Bug 1650835 - WIP: Add support for a "button-and-view" widget type. → Bug 1650835 - Add support for a "button-and-view" widget type. r=jaws
Attachment #9190356 - Attachment description: Bug 1650835 - WIP: Use a "button-and-view" widget for the profiler button. → Bug 1650835 - Use a "button-and-view" widget for the profiler button. r=florian
Pushed by mstange@themasta.com: https://hg.mozilla.org/integration/autoland/rev/1580fce94a2d Add support for a "button-and-view" widget type. r=jaws https://hg.mozilla.org/integration/autoland/rev/9d54a5418434 Use a "button-and-view" widget for the profiler button. r=florian
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → 86 Branch
Blocks: 1650833
Blocks: 1650832
Blocks: 1669350
Regressions: 1696621
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: