twistyのスタイルとして「OS X」追加、sidebarスタイルではこれを標準に

git-svn-id: http://www.cozmixng.org/repos/piro/treestyletab/trunk@6191 599a83e7-65a4-db11-8015-0010dcdd6dc2
This commit is contained in:
piro 2010-02-02 06:02:08 +00:00
parent 5de9f1e3d6
commit e7e2972245
16 changed files with 42 additions and 52 deletions

View File

@ -40,7 +40,6 @@ function init()
function initAppearancePane()
{
onChangeTabbarPosition();
onChangeTabbarStyle();
var sidebarItem = document.getElementById('extensions.treestyletab.tabbar.style-sidebar');
if (comparator.compare(XULAppInfo.version, '3.6') >= 0)
@ -201,33 +200,6 @@ function onChangeTabbarPosition(aOnChange)
gTabbarPlacePositionInitialized = true;
}
function onChangeTabbarStyle()
{
var twisty = document.getElementById('extensions.treestyletab.twisty.style');
var twistyRadio = document.getElementById('extensions.treestyletab.twisty.style-radiogroup');
var disabledItems = ['retro', 'modern-white', 'modern-black']
.map(function(aStyle) {
return twistyRadio.getElementsByAttribute('value', aStyle)[0];
});
var style = document.getElementById('extensions.treestyletab.tabbar.style-radiogroup').value;
if (style == 'sidebar') {
if (twistyRadio.value != 'auto' &&
twistyRadio.value != 'none') {
twistyRadio.value = twisty.value = 'auto';
}
disabledItems.forEach(function(aNode) {
aNode.setAttribute('disabled', true);
});
}
else {
disabledItems.forEach(function(aNode) {
aNode.removeAttribute('disabled');
});
}
}
var gAutoHideModeRadio,
gAutoHideModeToggle,

View File

@ -147,8 +147,7 @@
<caption label="&config.tabbar.style.caption;"/>
<radiogroup id="extensions.treestyletab.tabbar.style-radiogroup"
preference="extensions.treestyletab.tabbar.style"
orient="vertical"
oncommand="onChangeTabbarStyle();">
orient="vertical">
<hbox align="center">
<radio value="default" label="&config.tabbar.style.default;"
class="image" align="center"
@ -185,6 +184,9 @@
<radio value="modern-white" label="&config.twisty.style.modern.white;"
class="image" align="center"
src="chrome://treestyletab/content/res/twisty-modern-w.png"/>
<radio value="osx" label="&config.twisty.style.osx;"
class="image" align="center"
src="chrome://treestyletab/content/res/twisty-osx.png"/>
<radio value="none" label="&config.twisty.style.none;"/>
</radiogroup>
</groupbox>

Binary file not shown.

After

Width:  |  Height:  |  Size: 414 B

View File

@ -1257,7 +1257,10 @@ TreeStyleTabBrowser.prototype = {
case 'extensions.treestyletab.twisty.style':
if (value == 'auto') {
if (
if (this.getTreePref('tabbar.style') == 'sidebar') {
value = 'osx';
}
else if (
window['piro.sakura.ne.jp'].extensions.isAvailable('informationaltab@piro.sakura.ne.jp') &&
this.getPref('extensions.informationaltab.thumbnail.enabled') &&
this.getPref('extensions.informationaltab.thumbnail.position') < 100

View File

@ -33,6 +33,7 @@
<!ENTITY config.twisty.style.retro "Retro">
<!ENTITY config.twisty.style.modern.black "Schwarz Modern">
<!ENTITY config.twisty.style.modern.white "Weiß Modern">
<!ENTITY config.twisty.style.osx "OS X">
<!ENTITY config.tabs.menu "Menü">

View File

@ -33,6 +33,7 @@
<!ENTITY config.twisty.style.retro "Retro">
<!ENTITY config.twisty.style.modern.black "Black Modern">
<!ENTITY config.twisty.style.modern.white "White Modern">
<!ENTITY config.twisty.style.osx "OS X">
<!ENTITY config.tabs.menu "Menu">

View File

@ -33,6 +33,7 @@
<!ENTITY config.twisty.style.retro "Retro">
<!ENTITY config.twisty.style.modern.black "Negro moderno">
<!ENTITY config.twisty.style.modern.white "Blanco moderno">
<!ENTITY config.twisty.style.osx "OS X">
<!ENTITY config.tabs.menu "Menú">

View File

@ -33,6 +33,7 @@
<!ENTITY config.twisty.style.retro "Retro">
<!ENTITY config.twisty.style.modern.black "Black Modern">
<!ENTITY config.twisty.style.modern.white "White Modern">
<!ENTITY config.twisty.style.osx "OS X">
<!ENTITY config.tabs.menu "Menu contestuale">

View File

@ -33,6 +33,7 @@
<!ENTITY config.twisty.style.retro "レトロ">
<!ENTITY config.twisty.style.modern.black "モダン黒">
<!ENTITY config.twisty.style.modern.white "モダン白">
<!ENTITY config.twisty.style.osx "OS X">
<!ENTITY config.tabs.menu "メニュー">

View File

@ -34,6 +34,7 @@
<!ENTITY config.twisty.style.retro "Retro">
<!ENTITY config.twisty.style.modern.black "Czarny nowoczesny">
<!ENTITY config.twisty.style.modern.white "Biały nowoczesny">
<!ENTITY config.twisty.style.osx "OS X">
<!ENTITY config.tabs.menu "Menu">

View File

@ -33,6 +33,7 @@
<!ENTITY config.twisty.style.retro "Ретро">
<!ENTITY config.twisty.style.modern.black "Черный новый">
<!ENTITY config.twisty.style.modern.white "Белый новый">
<!ENTITY config.twisty.style.osx "OS X">
<!ENTITY config.tabs.menu "Меню">

View File

@ -33,6 +33,7 @@
<!ENTITY config.twisty.style.retro "怀旧">
<!ENTITY config.twisty.style.modern.black "黑色现代">
<!ENTITY config.twisty.style.modern.white "白色现代">
<!ENTITY config.twisty.style.osx "OS X">
<!ENTITY config.tabs.menu "菜单">

View File

@ -33,6 +33,7 @@
<!ENTITY config.twisty.style.retro "懷舊">
<!ENTITY config.twisty.style.modern.black "現代黑色">
<!ENTITY config.twisty.style.modern.white "現代白色">
<!ENTITY config.twisty.style.osx "OS X">
<!ENTITY config.tabs.menu "選單">

Binary file not shown.

After

Width:  |  Height:  |  Size: 697 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 684 B

View File

@ -13,14 +13,14 @@ tabbrowser[treestyletab-tab-contents-inverted="true"]
}
tabbrowser[treestyletab-twisty-style^="modern"]
.treestyletab-twisty-container,
tabbrowser[treestyletab-style="sidebar"]
tabbrowser[treestyletab-twisty-style^="osx"]
.treestyletab-twisty-container {
position: relative;
margin: 0 14px 0 -14px;
}
tabbrowser[treestyletab-twisty-style^="modern"][treestyletab-tab-contents-inverted="true"]
.treestyletab-twisty-container,
tabbrowser[treestyletab-style="sidebar"][treestyletab-tab-contents-inverted="true"]
tabbrowser[treestyletab-twisty-style^="osx"][treestyletab-tab-contents-inverted="true"]
.treestyletab-twisty-container {
margin: 0 -14px 0 14px;
}
@ -38,19 +38,19 @@ tabbrowser[treestyletab-twisty-style="retro"][treestyletab-mode="horizontal"][tr
}
tabbrowser[treestyletab-twisty-style^="modern"][treestyletab-allow-subtree-collapse="true"][treestyletab-mode="horizontal"]
.tab-icon,
tabbrowser[treestyletab-style="sidebar"][treestyletab-allow-subtree-collapse="true"][treestyletab-mode="horizontal"]
tabbrowser[treestyletab-twisty-style^="osx"][treestyletab-allow-subtree-collapse="true"][treestyletab-mode="horizontal"]
.tab-icon {
margin-left: 12px;
}
tabbrowser[treestyletab-twisty-style^="modern"][treestyletab-allow-subtree-collapse="true"]:not([treestyletab-tab-contents-inverted="true"])
.tab-icon,
tabbrowser[treestyletab-style="sidebar"][treestyletab-allow-subtree-collapse="true"]:not([treestyletab-tab-contents-inverted="true"])
tabbrowser[treestyletab-twisty-style^="osx"][treestyletab-allow-subtree-collapse="true"]:not([treestyletab-tab-contents-inverted="true"])
.tab-icon {
margin-left: 9px;
}
tabbrowser[treestyletab-twisty-style^="modern"][treestyletab-allow-subtree-collapse="true"][treestyletab-tab-contents-inverted="true"]
.tab-icon,
tabbrowser[treestyletab-style="sidebar"][treestyletab-allow-subtree-collapse="true"][treestyletab-tab-contents-inverted="true"]
tabbrowser[treestyletab-twisty-style^="osx"][treestyletab-allow-subtree-collapse="true"][treestyletab-tab-contents-inverted="true"]
.tab-icon {
margin-right: 9px;
}
@ -60,40 +60,44 @@ tabbrowser[treestyletab-style="sidebar"][treestyletab-allow-subtree-collapse="tr
-moz-image-region: rect(0, 32px, 16px, 16px);
}
tabbrowser[treestyletab-twisty-style="modern-black"]
.treestyletab-twisty,
tabbrowser[treestyletab-style="sidebar"]
.tabbrowser-tab:not([selected="true"]) .treestyletab-twisty {
.treestyletab-twisty {
list-style-image: url("twisty-modern-b-l.png");
}
tabbrowser[treestyletab-twisty-style="modern-black"][treestyletab-tab-contents-inverted="true"]
.treestyletab-twisty,
tabbrowser[treestyletab-style="sidebar"][treestyletab-tab-contents-inverted="true"]
.tabbrowser-tab:not([selected="true"]) .treestyletab-twisty {
.treestyletab-twisty {
list-style-image: url("twisty-modern-b-r.png");
}
tabbrowser[treestyletab-twisty-style="modern-white"]
.treestyletab-twisty,
tabbrowser[treestyletab-style="sidebar"]
.tabbrowser-tab[selected="true"] .treestyletab-twisty {
.treestyletab-twisty {
list-style-image: url("twisty-modern-w-l.png");
}
tabbrowser[treestyletab-twisty-style="modern-white"][treestyletab-tab-contents-inverted="true"]
.treestyletab-twisty,
tabbrowser[treestyletab-style="sidebar"][treestyletab-tab-contents-inverted="true"]
.tabbrowser-tab[selected="true"] .treestyletab-twisty {
.treestyletab-twisty {
list-style-image: url("twisty-modern-w-r.png");
}
tabbrowser[treestyletab-twisty-style="osx"]
.treestyletab-twisty {
list-style-image: url("twisty-osx-l.png");
}
tabbrowser[treestyletab-twisty-style="osx"][treestyletab-tab-contents-inverted="true"]
.treestyletab-twisty {
list-style-image: url("twisty-osx-r.png");
}
.tabbrowser-tab[treestyletab-subtree-collapsed="true"]
.treestyletab-twisty {
-moz-image-region: rect(0, 16px, 16px, 0);
}
.tabbrowser-tab[treestyletab-twisty-hover="true"]
.treestyletab-twisty {
tabbrowser:not([treestyletab-twisty-style="osx"])
.tabbrowser-tab[treestyletab-twisty-hover="true"] .treestyletab-twisty,
tabbrowser[treestyletab-twisty-style="osx"]
.tabbrowser-tab[selected="true"] .treestyletab-twisty {
-moz-image-region: rect(16px, 32px, 32px, 16px);
}
.tabbrowser-tab[treestyletab-subtree-collapsed="true"][treestyletab-twisty-hover="true"]
.treestyletab-twisty {
tabbrowser:not([treestyletab-twisty-style="osx"])
.tabbrowser-tab[treestyletab-subtree-collapsed="true"][treestyletab-twisty-hover="true"] .treestyletab-twisty,
tabbrowser[treestyletab-twisty-style="osx"]
.tabbrowser-tab[treestyletab-subtree-collapsed="true"][selected="true"] .treestyletab-twisty {
-moz-image-region: rect(16px, 16px, 32px, 0);
}