Closed Bug 1685985 Opened 5 years ago Closed 5 years ago

Toolbox error count hides the Toolbox Toolbar Chevron

Categories

(DevTools :: Console, defect, P3)

defect

Tracking

(firefox-esr78 unaffected, firefox84 unaffected, firefox85 unaffected, firefox86 fixed)

RESOLVED FIXED
86 Branch
Tracking Status
firefox-esr78 --- unaffected
firefox84 --- unaffected
firefox85 --- unaffected
firefox86 --- fixed

People

(Reporter: jdescottes, Assigned: nchevobbe)

References

(Regression)

Details

(Keywords: regression)

Attachments

(3 files)

STRs:
this will only happen for certain widths, so I will give settings that work for me but it might be different depending on OSes, zoom levels etc.

  • in about:config set devtools.toolbox.sidebar.width to "651"
  • in about:config set devtools.toolbox.host to "right"
  • open devtools
  • run console.error(1)

ER: The chevron should be fully visible
AR: The chevron is partially hidden behind the error count

Note, it you try to play with other dynamic buttons (eg the frame picker) they will correctly trigger an update of the toolbar when they get displayed. Handling the error count icon in a more consistent manner as mentioned in https://phabricator.services.mozilla.com/D100668#inline-567164 would probably address this.

Set release status flags based on info from the regressing bug 1109362

Assignee: nobody → nchevobbe
Status: NEW → ASSIGNED
  • switch to add_task + registerCleanupFunction
  • reorder functions so they match the order they're called in the main function
  • remove global variables in favor of explicit parameters
  • switch from Promise chains to await where possible

A button configuration is now created from _buildButtons so the error count button
is part of the toolbarButtons property on the toolbox.
An updateErrorCountButton updates the property of the button, and we call it
from the function that updates the error count, from which we also trigger a new
render for the toolbar.

This way updating the error count will go through the overflow logic we have in
the toolbar (to show the chevron or not).

A "side effect" of this is that an item is automatically created in the options
panel to disable the error count button. In order for it to work properly, we
need to add a preference to store its enabled state, as well as a specific
localized string for the input label.

browser_toolbox_error_count is updated to ensure that the error button isn't
displayed if it was disabled in the option panel, even if new errors are emitted.

browser_toolbox_options_disable_buttons was updated to reflect the changes made
to the error count button.

Depends on D101568

Pushed by nchevobbe@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/1a662cc2614d [devtools] Refactor browser_toolbox_options_disable_buttons. r=bomsy. https://hg.mozilla.org/integration/autoland/rev/3ff621cea4dc [devtools] Handle error count button like other toolbox buttons. r=jdescottes.
Status: ASSIGNED → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → 86 Branch
Pushed by mkmelin@iki.fi: https://hg.mozilla.org/comm-central/rev/8b549b44b488 Add the "devtools.command-button-errorcount.enabled" pref to Thunderbird. r=mkmelin
Regressions: 1686036
Has Regression Range: --- → yes
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: