diff --git a/content/treestyletab/treestyletab-3.1.css b/content/treestyletab/treestyletab-3.1.css index c7ae056a..3257e831 100644 --- a/content/treestyletab/treestyletab-3.1.css +++ b/content/treestyletab/treestyletab-3.1.css @@ -1,6 +1,10 @@ @namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"); @namespace html url("http://www.w3.org/1999/xhtml"); +tabbrowser[treestyletab-hide-newtab-button="true"] .tabs-newtab-button { + visibility: collapse !important; +} + tabbrowser .tabs-container > .tabbrowser-arrowscrollbox { -moz-binding: url("chrome://treestyletab/content/treestyletab.xml#tabbrowser-arrowscrollbox"); } diff --git a/content/treestyletab/treestyletab.css b/content/treestyletab/treestyletab.css index d6c2bf0a..57bf3c20 100644 --- a/content/treestyletab/treestyletab.css +++ b/content/treestyletab/treestyletab.css @@ -28,7 +28,6 @@ tabbrowser[treestyletab-tabbar-fixed="true"] .tabbrowser-strip+splitter { tabbrowser:not([treestyletab-mode="horizontal"]) .tabbrowser-arrowscrollbox > .scrollbutton-up, tabbrowser:not([treestyletab-mode="horizontal"]) .tabbrowser-arrowscrollbox > .scrollbutton-down-stack, tabbrowser:not([treestyletab-mode="horizontal"]) .tabbrowser-arrowscrollbox > .scrollbutton-down, /* Firefox 3 */ -tabbrowser[treestyletab-hide-newtab-button="true"] .tabs-newtab-button, /* "open a new tab" button in Firefox 3.1 */ tabbrowser[treestyletab-hide-alltabs-button="true"] .tabs-alltabs-stack, tabbrowser[treestyletab-hide-alltabs-button="true"] .tabbrowser-arrowscrollbox ~ stack, /* "all tabs" button in Firefox 3 and 3.1 */ tabbrowser[treestyletab-mode="vertical"] .tabs-closebutton-box, @@ -39,10 +38,6 @@ tabbrowser:not([treestyletab-mode="horizontal"]) #alltabs-place-holder, /* Tab M tabbrowser:not([treestyletab-mode="horizontal"]) .tabs-scroll /* Tab Mix Plus */ { display: none !important; } -tabbrowser[treestyletab-hide-newtab-button="true"] .tabbrowser-arrowscrollbox .tabs-newtab-button /* "all tabs" button in Firefox 3 and 3.1 */ { - display: -moz-box !important; - visibility: collapse !important; -} #appcontent { /* position: relative;*/ diff --git a/content/treestyletab/treestyletab.js b/content/treestyletab/treestyletab.js index db195cbe..8a0181b4 100644 --- a/content/treestyletab/treestyletab.js +++ b/content/treestyletab/treestyletab.js @@ -23,6 +23,7 @@ var TreeStyleTabService = { kFIXED : 'treestyletab-tabbar-fixed', kRESIZING : 'treestyletab-tabbar-resizing', kTRANSPARENT : 'treestyletab-tabbar-transparent', + kDROP_SHADOW : 'treestyletab-tabbar-dropshadow', kTWISTY : 'treestyletab-twisty', kTWISTY_CONTAINER : 'treestyletab-twisty-container', diff --git a/content/treestyletab/treestyletabbrowser.js b/content/treestyletab/treestyletabbrowser.js index 7eb7ffd9..99d6b304 100644 --- a/content/treestyletab/treestyletabbrowser.js +++ b/content/treestyletab/treestyletabbrowser.js @@ -462,6 +462,7 @@ TreeStyleTabBrowser.prototype = { this.observe(null, 'nsPref:changed', 'extensions.treestyletab.allowSubtreeCollapseExpand'); this.observe(null, 'nsPref:changed', 'extensions.treestyletab.tabbar.fixed'); this.observe(null, 'nsPref:changed', 'extensions.treestyletab.tabbar.transparent.style'); + this.observe(null, 'nsPref:changed', 'extensions.treestyletab.tabbar.dropshadow'); window.setTimeout(function() { b.treeStyleTab.observe(null, 'nsPref:changed', 'extensions.treestyletab.tabbar.autoHide.mode'); }, 0); @@ -1040,6 +1041,13 @@ TreeStyleTabBrowser.prototype = { this.checkTabsIndentOverflow(); break; + case 'extensions.treestyletab.tabbar.dropshadow': + if (value) + b.setAttribute(this.kDROP_SHADOW, true); + else + b.removeAttribute(this.kDROP_SHADOW); + break; + default: break; } diff --git a/defaults/preferences/treestyletab.js b/defaults/preferences/treestyletab.js index 108037ea..ff9cf9eb 100644 --- a/defaults/preferences/treestyletab.js +++ b/defaults/preferences/treestyletab.js @@ -28,6 +28,7 @@ pref("extensions.treestyletab.tabbar.autoShow.feedback", false); pref("extensions.treestyletab.tabbar.autoShow.feedback.delay", 3000); pref("extensions.treestyletab.tabbar.fixed", false); pref("extensions.treestyletab.tabbar.syncRelatedPrefsForDynamicPosition", true); +pref("extensions.treestyletab.tabbar.dropshadow", true); pref("extensions.treestyletab.enableSubtreeIndent", true); pref("extensions.treestyletab.enableSubtreeIndent.allTabsPopup", true); pref("extensions.treestyletab.allowSubtreeCollapseExpand", true); diff --git a/skin/classic/treestyletab/treestyletab-3.1.css b/skin/classic/treestyletab/treestyletab-3.1.css index 8a4dfae1..ca54b309 100644 --- a/skin/classic/treestyletab/treestyletab-3.1.css +++ b/skin/classic/treestyletab/treestyletab-3.1.css @@ -1,20 +1,37 @@ @namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"); +/* new-tab button */ + +tabbrowser[treestyletab-mode="vertical"] .tabbrowser-arrowscrollbox .tabs-newtab-button { + border-style: none solid solid !important; + border-width: 0 0 1px 1px !important; + border-bottom: 1px solid ThreeDShadow !important; + -moz-border-bottom-colors: ThreeDShadow !important; + -moz-border-radius: 0 0 2px 2px; +} +tabbrowser[treestyletab-mode="vertical"][treestyletab-appearance-inverted="true"] .tabbrowser-arrowscrollbox .tabs-newtab-button { + border-width: 0 1px 1px 0 !important; +} +tabbrowser[treestyletab-mode="vertical"][treestyletab-style="vertigo"] .tabbrowser-arrowscrollbox .tabs-newtab-button { + border-style: none !important; +} + + /* Shadow of vertival tabs */ -tabbrowser[treestyletab-mode="vertical"][treestyletab-style="default"] .tabbrowser-tab, -tabbrowser[treestyletab-mode="vertical"][treestyletab-style="mixed"] .tabbrowser-tab { +tabbrowser[treestyletab-mode="vertical"][treestyletab-tabbar-dropshadow="true"][treestyletab-style="default"] .tabbrowser-tab, +tabbrowser[treestyletab-mode="vertical"][treestyletab-tabbar-dropshadow="true"][treestyletab-style="mixed"] .tabbrowser-tab { -moz-box-shadow: -5px 5px 5px rgba(0, 0, 0, 0.15) !important; } -tabbrowser[treestyletab-mode="vertical"][treestyletab-style="default"][treestyletab-appearance-inverted="true"] .tabbrowser-tab, -tabbrowser[treestyletab-mode="vertical"][treestyletab-style="mixed"][treestyletab-appearance-inverted="true"] .tabbrowser-tab { +tabbrowser[treestyletab-mode="vertical"][treestyletab-tabbar-dropshadow="true"][treestyletab-style="default"][treestyletab-appearance-inverted="true"] .tabbrowser-tab, +tabbrowser[treestyletab-mode="vertical"][treestyletab-tabbar-dropshadow="true"][treestyletab-style="mixed"][treestyletab-appearance-inverted="true"] .tabbrowser-tab { -moz-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15) !important; } -tabbrowser[treestyletab-mode="vertical"][treestyletab-style="default"]:not([treestyletab-hide-newtab-button]) .tabs-container:not([overflow="true"]) .scrollbox-innerbox, -tabbrowser[treestyletab-mode="vertical"][treestyletab-style="mixed"]:not([treestyletab-hide-newtab-button]) .tabs-container:not([overflow="true"]) .scrollbox-innerbox { +tabbrowser[treestyletab-mode="vertical"][treestyletab-tabbar-dropshadow="true"][treestyletab-style="default"]:not([treestyletab-hide-newtab-button]) .tabs-container:not([overflow="true"]) .scrollbox-innerbox, +tabbrowser[treestyletab-mode="vertical"][treestyletab-tabbar-dropshadow="true"][treestyletab-style="mixed"]:not([treestyletab-hide-newtab-button]) .tabs-container:not([overflow="true"]) .scrollbox-innerbox { background: url("dropshadow.png") repeat-x bottom !important; } -tabbrowser[treestyletab-mode="vertical"][treestyletab-style="default"]:not([treestyletab-hide-newtab-button="true"]) .tabs-container:not([overflow="true"]) .tabbrowser-arrowscrollbox .tabs-newtab-button, -tabbrowser[treestyletab-mode="vertical"][treestyletab-style="mixed"]:not([treestyletab-hide-newtab-button="true"]) .tabs-container:not([overflow="true"]) .tabbrowser-arrowscrollbox .tabs-newtab-button { +tabbrowser[treestyletab-mode="vertical"][treestyletab-tabbar-dropshadow="true"][treestyletab-style="default"]:not([treestyletab-hide-newtab-button="true"]) .tabs-container:not([overflow="true"]) .tabbrowser-arrowscrollbox .tabs-newtab-button, +tabbrowser[treestyletab-mode="vertical"][treestyletab-tabbar-dropshadow="true"][treestyletab-style="mixed"]:not([treestyletab-hide-newtab-button="true"]) .tabs-container:not([overflow="true"]) .tabbrowser-arrowscrollbox .tabs-newtab-button { margin-bottom: 5px !important; } diff --git a/skin/classic/treestyletab/treestyletab.css b/skin/classic/treestyletab/treestyletab.css index ec85dd5b..016ad61c 100644 --- a/skin/classic/treestyletab/treestyletab.css +++ b/skin/classic/treestyletab/treestyletab.css @@ -414,7 +414,6 @@ tabbrowser[treestyletab-tabbar-position="bottom"] .tabbrowser-tab[treestyletab-d /* vertical tab bar */ -/* Firefox 2 or later */ tabbrowser[treestyletab-mode="vertical"] .tabs-alltabs-stack > hbox { position: static !important; } @@ -445,21 +444,6 @@ tabbrowser[treestyletab-mode="vertical"] .tabs-alltabs-button { height: 16px !important; } -/* Firefox 3.1 new-tab button */ -tabbrowser[treestyletab-mode="vertical"] .tabbrowser-arrowscrollbox .tabs-newtab-button { - border-style: none solid solid !important; - border-width: 0 0 1px 1px !important; - border-bottom: 1px solid ThreeDShadow !important; - -moz-border-bottom-colors: ThreeDShadow !important; - -moz-border-radius: 0 0 2px 2px; -} -tabbrowser[treestyletab-mode="vertical"][treestyletab-appearance-inverted="true"] .tabbrowser-arrowscrollbox .tabs-newtab-button { - border-width: 0 1px 1px 0 !important; -} -tabbrowser[treestyletab-mode="vertical"][treestyletab-style="vertigo"] .tabbrowser-arrowscrollbox .tabs-newtab-button { - border-style: none !important; -} - /* transaprent tab bar */ tabbrowser[treestyletab-tabbar-transparent] .tabbrowser-tab {