Bug 1918681 - part 1: Allow moving the list-all-tabs button again r=dao

In bug 878551, the ability to move the list-all-tabs button was	removed
for a few reasons:

> Moving this widget to the navbar gives it a tiny scaled version of Toolbar.png (like a horizontal line).

> Moving it back to the tab strip make it misbehave. It disappears, but sometimes flickers into view when opening/closing a tab.

These issues are no longer present, so we should be able to allow moving
the list-all-tabs button once again.

Differential Revision: https://phabricator.services.mozilla.com/D224623
This commit is contained in:
Gregory Pappas 2024-10-09 02:35:42 +00:00
parent 1487fa209f
commit 0d2086383e
4 changed files with 5 additions and 9 deletions

View File

@ -154,10 +154,7 @@ var gBrowserInit = {
// We don't want these normally non-removable elements to get put back into the
// tabstrip if we're initializing with vertical tabs
if (isVerticalTabs && !isPopup) {
nonRemovables = [
gBrowser.tabContainer,
document.getElementById("alltabs-button"),
];
nonRemovables = [gBrowser.tabContainer];
for (let elem of nonRemovables) {
elem.setAttribute("removable", "true");
// tell CUI to ignore this element when it builds the toolbar areas

View File

@ -90,7 +90,7 @@
delegatesanchor="true"
badged="true"
data-l10n-id="tabs-toolbar-list-all-tabs"
removable="false"/>
removable="true"/>
</hbox>
</hbox>

View File

@ -4194,7 +4194,6 @@ var CustomizableUIInternal = {
// Normally these aren't removable, but for this operation only we need to move them
changeWidgetRemovability("tabbrowser-tabs", true);
changeWidgetRemovability("alltabs-button", true);
if (toVertical) {
lazy.log.debug(
@ -4249,7 +4248,6 @@ var CustomizableUIInternal = {
);
this.setToolbarVisibility(CustomizableUI.AREA_TABSTRIP, !toVertical);
changeWidgetRemovability("tabbrowser-tabs", false);
changeWidgetRemovability("alltabs-button", false);
for (let [win] of gBuildWindows) {
win.TabBarVisibility.update(true);

View File

@ -203,6 +203,7 @@ add_task(async function widgetPositions() {
"stop-reload-button",
"tabbrowser-tabs",
"personal-bookmarks",
"alltabs-button",
],
"nav-bar": [
@ -249,7 +250,7 @@ add_task(async function customizeMode() {
organizeToolbars({
PersonalToolbar: ["personal-bookmarks"],
TabsToolbar: ["tabbrowser-tabs", "new-tab-button"],
TabsToolbar: ["tabbrowser-tabs", "new-tab-button", "alltabs-button"],
"nav-bar": [
"back-button",
@ -344,7 +345,7 @@ add_task(async function contextMenus() {
organizeToolbars({
PersonalToolbar: ["personal-bookmarks"],
TabsToolbar: ["tabbrowser-tabs", "new-tab-button"],
TabsToolbar: ["tabbrowser-tabs", "new-tab-button", "alltabs-button"],
"nav-bar": [
"back-button",