Replace CAN_DRAW_IN_TITLEBAR with a run-time check

RESOLVED FIXED in Firefox 61

Status

()

enhancement
RESOLVED FIXED
a year ago
a year ago

People

(Reporter: dao, Assigned: dao)

Tracking

(Blocks 1 bug)

Trunk
Firefox 61
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(firefox61 fixed)

Details

Attachments

(1 attachment)

(Assignee)

Description

a year ago
Currently we show the title bar checkboxes even for Gtk versions where we can't draw in the title bar. We should hide them in that case.
Comment hidden (mozreview-request)

Comment 2

a year ago
(Sorry, public holidays here, I won't be able to review this before Tuesday.)

Comment 3

a year ago
mozreview-review
Comment on attachment 8963970 [details]
Bug 1450279 - Replace CAN_DRAW_IN_TITLEBAR with a run-time check.

https://reviewboard.mozilla.org/r/232782/#review238698

::: browser/base/content/browser-tabsintitlebar.js:69
(Diff revision 1)
> +      case "windows":
> +      case "cocoa":
> +        isSupported = true;
> +        break;
> +      case "gtk3":
> +        isSupported = window.matchMedia("(-moz-gtk-csd-available)");

It's unfortunate we don't have an easy way to share this across windows, to avoid each window checking the media query itself...

::: browser/components/customizableui/CustomizeMode.jsm:105
(Diff revision 1)
>  
>    // There are two palettes - there's the palette that can be overlayed with
>    // toolbar items in browser.xul. This is invisible, and never seen by the
>    // user. Then there's the visible palette, which gets populated and displayed
>    // to the user when in customizing mode.
> -  this.visiblePalette = this.document.getElementById(kPaletteId);
> +  this.visiblePalette = this.$(kPaletteId);

Can you file a good-first-bug to update the remaining uses of `this.document.getElementById` in CustomizeMode.jsm to use this new helper thing?
Attachment #8963970 - Flags: review?(gijskruitbosch+bugs) → review+

Comment 4

a year ago
Pushed by dgottwald@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/9fe6dc8bc9f0
Replace CAN_DRAW_IN_TITLEBAR with a run-time check. r=Gijs

Comment 5

a year ago
bugherder
https://hg.mozilla.org/mozilla-central/rev/9fe6dc8bc9f0
Status: ASSIGNED → RESOLVED
Last Resolved: a year ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 61
(Assignee)

Updated

a year ago
Blocks: 1451242
You need to log in before you can comment on or make changes to this bug.