diff --git a/content/treestyletab/config.js b/content/treestyletab/config.js index 0292d79f..ab8ead45 100644 --- a/content/treestyletab/config.js +++ b/content/treestyletab/config.js @@ -72,6 +72,14 @@ function initAppearancePane() sidebar.setAttribute('disabled', true); } + var hideAllTabsButton = document.getElementById('hideAlltabsButton-box'); + if (comparator.compare(XULAppInfo.version, '4.0b3') > 0) { + hideAllTabsButton.setAttribute('hidden', true); + } + else { + hideAllTabsButton.removeAttribute('hidden'); + } + var boxes = [ document.getElementById('extensions.treestyletab.tabbar.style-arrowscrollbox'), document.getElementById('extensions.treestyletab.twisty.style-arrowscrollbox') diff --git a/content/treestyletab/config.xul b/content/treestyletab/config.xul index d0663084..ffccb32f 100644 --- a/content/treestyletab/config.xul +++ b/content/treestyletab/config.xul @@ -132,7 +132,7 @@ preference="extensions.treestyletab.enableSubtreeIndent.vertical" label="&config.enableSubtreeIndent;"/> - + .close-button.tabs-closebutton { +#TabsToolbar[treestyletab-mode="vertical"] > toolbarbutton, +#TabsToolbar[treestyletab-mode="vertical"] > toolbarpaletteitem > toolbarbutton { max-width: none !important; } @@ -273,9 +273,7 @@ tabbrowser[treestyletab-tabbar-autohide-mode="1"][treestyletab-tabbar-autohide=" .tabbrowser-tabs[treestyletab-hide-alltabs-button="true"] .tabs-alltabs-stack, .tabbrowser-tabs[treestyletab-hide-alltabs-button="true"] - .tabbrowser-arrowscrollbox ~ stack, /* "all tabs" button in Firefox 3.0-3.5 */ -#TabsToolbar[treestyletab-hide-alltabs-button="true"] - .tabs-alltabs-button { + .tabbrowser-arrowscrollbox ~ stack /* "all tabs" button in Firefox 3.0-3.5 */ { visibility: collapse !important; } diff --git a/content/treestyletab/treestyletabbrowser.js b/content/treestyletab/treestyletabbrowser.js index 54d46e75..b5078cb9 100644 --- a/content/treestyletab/treestyletabbrowser.js +++ b/content/treestyletab/treestyletabbrowser.js @@ -1242,7 +1242,9 @@ TreeStyleTabBrowser.prototype = { this.setTabbrowserAttribute(this.kINDENTED, this.getTreePref('enableSubtreeIndent.'+orient) ? 'true' : null); this.setTabbrowserAttribute(this.kALLOW_COLLAPSE, this.getTreePref('allowSubtreeCollapseExpand.'+orient) ? 'true' : null); - this.setTabbrowserAttribute(this.kHIDE_ALLTABS, this.getTreePref('tabbar.hideAlltabsButton.'+orient) ? 'true' : null); + + if (!this.isFloating) + this.setTabbrowserAttribute(this.kHIDE_ALLTABS, this.getTreePref('tabbar.hideAlltabsButton.'+orient) ? 'true' : null); this.updateAllTabsIndent(); }, @@ -1498,17 +1500,21 @@ TreeStyleTabBrowser.prototype = { var oldState = { fixed : this.isFixed, indented : b.getAttribute(this.kINDENTED) == 'true', - canCollapse : b.getAttribute(this.kALLOW_COLLAPSE) == 'true', - alltabsButton : b.getAttribute(this.kHIDE_ALLTABS) != 'true' + canCollapse : b.getAttribute(this.kALLOW_COLLAPSE) == 'true' }; - oldState.allTabsButton = oldState.alltabsButton; + if (!this.isFloating) { + oldState.alltabsButton = b.getAttribute(this.kHIDE_ALLTABS) != 'true'; + oldState.allTabsButton = oldState.alltabsButton; + } var newState = { fixed : this.getTreePref('tabbar.fixed.'+orient), indented : this.getTreePref('enableSubtreeIndent.'+orient), - canCollapse : this.getTreePref('allowSubtreeCollapseExpand.'+orient), - alltabsButton : !this.getTreePref('tabbar.hideAlltabsButton.'+orient) + canCollapse : this.getTreePref('allowSubtreeCollapseExpand.'+orient) }; - newState.allTabsButton = newState.alltabsButton; + if (!this.isFloating) { + newState.alltabsButton = !this.getTreePref('tabbar.hideAlltabsButton.'+orient); + newState.allTabsButton = newState.alltabsButton; + } if (oldState.fixed == newState.fixed && oldState.indented == newState.indented && @@ -1532,10 +1538,12 @@ TreeStyleTabBrowser.prototype = { var state = { fixed : this.isFixed, indented : b.getAttribute(this.kINDENTED) == 'true', - canCollapse : b.getAttribute(this.kALLOW_COLLAPSE) == 'true', - alltabsButton : b.getAttribute(this.kHIDE_ALLTABS) != 'true' + canCollapse : b.getAttribute(this.kALLOW_COLLAPSE) == 'true' }; - state.allTabsButton = state.alltabsButton; + if (!this.isFloating) { + state.alltabsButton = b.getAttribute(this.kHIDE_ALLTABS) != 'true'; + state.allTabsButton = state.alltabsButton; + } /* PUBLIC API */ var event = document.createEvent('Events');