forked from mirrors/gecko-dev
Bug 1364166 - Only update combined buttons style in the customizableUI panel. r=Gijs
This Photon-specific workaround styles the zoom and edit button combinations when the user switches back to the old menu panel. Before this patch, it used to apply the panel style even if the buttons were in the toolbar. This patch fixes that by not even updating the style if the buttons are not in the panel. MozReview-Commit-ID: JZZUTudSDeZ --HG-- extra : rebase_source : 6ea20aba09bfe12a558dc20a6e65f324292ca0f2
This commit is contained in:
parent
2a4dbde4b8
commit
5f95ff6cfd
1 changed files with 4 additions and 2 deletions
|
|
@ -756,8 +756,9 @@ const CustomizableWidgets = [
|
|||
// We need it right now for the case where we re-register the old-style
|
||||
// main menu panel if photon is disabled at runtime, and we automatically
|
||||
// put the widgets in there, so they get the right style in the panel.
|
||||
onAreaNodeRegistered(aArea, aContainer) {
|
||||
onAreaNodeRegistered: (aArea, aContainer) => {
|
||||
if (aContainer.ownerDocument == node.ownerDocument &&
|
||||
aArea == this.currentArea &&
|
||||
aArea == CustomizableUI.AREA_PANEL) {
|
||||
updateCombinedWidgetStyle(node, aArea, true);
|
||||
}
|
||||
|
|
@ -863,8 +864,9 @@ const CustomizableWidgets = [
|
|||
// We need it right now for the case where we re-register the old-style
|
||||
// main menu panel if photon is disabled at runtime, and we automatically
|
||||
// put the widgets in there, so they get the right style in the panel.
|
||||
onAreaNodeRegistered(aArea, aContainer) {
|
||||
onAreaNodeRegistered: (aArea, aContainer) => {
|
||||
if (aContainer.ownerDocument == node.ownerDocument &&
|
||||
aArea == this.currentArea &&
|
||||
aArea == CustomizableUI.AREA_PANEL) {
|
||||
updateCombinedWidgetStyle(node, aArea);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue