diff --git a/content/treestyletab/config.xul b/content/treestyletab/config.xul index 9301fcf1..0ea3aa62 100644 --- a/content/treestyletab/config.xul +++ b/content/treestyletab/config.xul @@ -24,6 +24,12 @@ + + @@ -129,7 +135,11 @@ label="&config.allowSubtreeCollapseExpand;"/> + label="&config.enableSubtreeIndent;" + oncommand=" + if (document.getElementById('extensions.treestyletab.tabbar.syncRelatedPrefsForDynamicPosition').value) + document.getElementById('extensions.treestyletab.tabbar.fixed.horizontal').value = !this.checked; + "/> diff --git a/content/treestyletab/treestyletab.js b/content/treestyletab/treestyletab.js index d20aea90..24161bf0 100644 --- a/content/treestyletab/treestyletab.js +++ b/content/treestyletab/treestyletab.js @@ -467,7 +467,7 @@ var TreeStyleTabService = { var pref = isVertical ? 'tabbar.fixed.vertical' : 'tabbar.fixed.horizontal' ; this.setTreePref(pref, !this.getTreePref(pref)); - if (!this.getTreePref('syncRelatedPrefs')) return; + if (!this.getTreePref('tabbar.syncRelatedPrefsForDynamicPosition')) return; if (!isVertical) this.setTreePref('enableSubtreeIndent.horizontal', !this.getTreePref(pref)); diff --git a/content/treestyletab/treestyletabbrowser.js b/content/treestyletab/treestyletabbrowser.js index 03f59e2f..3a87f09a 100644 --- a/content/treestyletab/treestyletabbrowser.js +++ b/content/treestyletab/treestyletabbrowser.js @@ -1208,12 +1208,15 @@ TreeStyleTabBrowser.prototype = { break; case 'extensions.treestyletab.enableSubtreeIndent.horizontal': - case 'extensions.treestyletab.enableSubtreeIndent.vertical': case 'extensions.treestyletab.allowSubtreeCollapseExpand.horizontal': + case 'extensions.treestyletab.tabbar.fixed.horizontal': + if (!this.isVertical) this.updateTabbarState(); + break; + + case 'extensions.treestyletab.enableSubtreeIndent.vertical': case 'extensions.treestyletab.allowSubtreeCollapseExpand.vertical': case 'extensions.treestyletab.tabbar.fixed.vertical': - case 'extensions.treestyletab.tabbar.fixed.horizontal': - this.updateTabbarState(); + if (this.isVertical) this.updateTabbarState(); break; case 'extensions.treestyletab.tabbar.transparent.style': diff --git a/defaults/preferences/treestyletab.js b/defaults/preferences/treestyletab.js index 4588f8ae..3b2fbbcf 100644 --- a/defaults/preferences/treestyletab.js +++ b/defaults/preferences/treestyletab.js @@ -38,7 +38,7 @@ pref("extensions.treestyletab.tabbar.autoShow.keepShownOnMouseover", true); pref("extensions.treestyletab.tabbar.togglerSize", 5); pref("extensions.treestyletab.tabbar.fixed.horizontal", true); pref("extensions.treestyletab.tabbar.fixed.vertical", false); -pref("extensions.treestyletab.syncRelatedPrefs", true); +pref("extensions.treestyletab.tabbar.syncRelatedPrefsForDynamicPosition", true); pref("extensions.treestyletab.enableSubtreeIndent.horizontal", false); pref("extensions.treestyletab.enableSubtreeIndent.vertical", true); pref("extensions.treestyletab.enableSubtreeIndent.allTabsPopup", true);