Effective TLDを使うかどうかの設定項目追加
git-svn-id: http://www.cozmixng.org/repos/piro/treestyletab/trunk@4207 599a83e7-65a4-db11-8015-0010dcdd6dc2
This commit is contained in:
parent
4feadd2e8d
commit
2fad74c0bf
@ -3,6 +3,23 @@ const XULAppInfo = Components.classes['@mozilla.org/xre/app-info;1']
|
|||||||
const comparator = Components.classes['@mozilla.org/xpcom/version-comparator;1']
|
const comparator = Components.classes['@mozilla.org/xpcom/version-comparator;1']
|
||||||
.getService(Components.interfaces.nsIVersionComparator);
|
.getService(Components.interfaces.nsIVersionComparator);
|
||||||
|
|
||||||
|
function init()
|
||||||
|
{
|
||||||
|
var useEffectiveTLD = document.getElementById('useEffectiveTLD');
|
||||||
|
var fx2Items = document.getElementsByAttribute('label-fx2', '*');
|
||||||
|
if (comparator.compare(XULAppInfo.version, '3.0') < 0) {
|
||||||
|
useEffectiveTLD.setAttribute('collapsed', true);
|
||||||
|
Array.slice(fx2Items).forEach(function(aItem) {
|
||||||
|
aItem.setAttribute('label', aItem.getAttribute('label-fx2'));
|
||||||
|
});
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
useEffectiveTLD.removeAttribute('collapsed');
|
||||||
|
}
|
||||||
|
|
||||||
|
sizeToContent();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
var gOuterLinkCheck,
|
var gOuterLinkCheck,
|
||||||
gAnyLinkCheck,
|
gAnyLinkCheck,
|
||||||
@ -50,13 +67,6 @@ function initTabPane()
|
|||||||
|
|
||||||
gLastStateIsVertical = document.getElementById('extensions.treestyletab.tabbar.position-radiogroup').value;
|
gLastStateIsVertical = document.getElementById('extensions.treestyletab.tabbar.position-radiogroup').value;
|
||||||
gLastStateIsVertical = gLastStateIsVertical == 'left' || gLastStateIsVertical == 'right';
|
gLastStateIsVertical = gLastStateIsVertical == 'left' || gLastStateIsVertical == 'right';
|
||||||
|
|
||||||
var fx2Items = document.getElementsByAttribute('label-fx2', '*');
|
|
||||||
if (comparator.compare(XULAppInfo.version, '3.0') < 0) {
|
|
||||||
Array.slice(fx2Items).forEach(function(aItem) {
|
|
||||||
aItem.setAttribute('label', aItem.getAttribute('label-fx2'));
|
|
||||||
});
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function onChangeGroupBookmarkRadio()
|
function onChangeGroupBookmarkRadio()
|
||||||
|
@ -9,7 +9,7 @@
|
|||||||
<prefwindow id="treestyletab-config"
|
<prefwindow id="treestyletab-config"
|
||||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
||||||
title="&config.title;"
|
title="&config.title;"
|
||||||
onload="sizeToContent();">
|
onload="init()">
|
||||||
|
|
||||||
<prefpane id="prefpane-appearance" label="&config.tabs.appearance;"
|
<prefpane id="prefpane-appearance" label="&config.tabs.appearance;"
|
||||||
onpaneload="onChangeTabbarPosition();">
|
onpaneload="onChangeTabbarPosition();">
|
||||||
@ -511,6 +511,9 @@
|
|||||||
<preference id="extensions.treestyletab.insertNewChildAt"
|
<preference id="extensions.treestyletab.insertNewChildAt"
|
||||||
name="extensions.treestyletab.insertNewChildAt"
|
name="extensions.treestyletab.insertNewChildAt"
|
||||||
type="int"/>
|
type="int"/>
|
||||||
|
<preference id="extensions.treestyletab.useEffectiveTLD"
|
||||||
|
name="extensions.treestyletab.useEffectiveTLD"
|
||||||
|
type="bool"/>
|
||||||
</preferences>
|
</preferences>
|
||||||
|
|
||||||
<vbox>
|
<vbox>
|
||||||
@ -548,6 +551,15 @@
|
|||||||
<radio value="1" label="&config.insertNewChildAt.last;"/>
|
<radio value="1" label="&config.insertNewChildAt.last;"/>
|
||||||
</radiogroup>
|
</radiogroup>
|
||||||
</groupbox>
|
</groupbox>
|
||||||
|
<groupbox id="useEffectiveTLD">
|
||||||
|
<caption label="&config.useEffectiveTLD.caption;"/>
|
||||||
|
<radiogroup id="extensions.treestyletab.useEffectiveTLD-radiogroup"
|
||||||
|
preference="extensions.treestyletab.useEffectiveTLD"
|
||||||
|
orient="vertical">
|
||||||
|
<radio value="true" label="&config.useEffectiveTLD.enabled;"/>
|
||||||
|
<radio value="false" label="&config.useEffectiveTLD.disabled;"/>
|
||||||
|
</radiogroup>
|
||||||
|
</groupbox>
|
||||||
|
|
||||||
</vbox>
|
</vbox>
|
||||||
</prefpane>
|
</prefpane>
|
||||||
|
@ -120,6 +120,10 @@ auf die Ebene des geschlossenen Tabs verschieben">
|
|||||||
<!ENTITY config.insertNewChildAt.first "Oben im Zweig einfügen">
|
<!ENTITY config.insertNewChildAt.first "Oben im Zweig einfügen">
|
||||||
<!ENTITY config.insertNewChildAt.last "Unten im Zweig einfügen">
|
<!ENTITY config.insertNewChildAt.last "Unten im Zweig einfügen">
|
||||||
|
|
||||||
|
<!ENTITY config.useEffectiveTLD.caption "Detecting method for "same website"">
|
||||||
|
<!ENTITY config.useEffectiveTLD.enabled "by Domain name ("aaa.example.com" and "bbb.example.com" are same website)">
|
||||||
|
<!ENTITY config.useEffectiveTLD.disabled "by Host name ("aaa.example.com" and "bbb.example.com" are different website)">
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -118,6 +118,10 @@
|
|||||||
<!ENTITY config.insertNewChildAt.first "Insert to the top of the sub tree, as the first child">
|
<!ENTITY config.insertNewChildAt.first "Insert to the top of the sub tree, as the first child">
|
||||||
<!ENTITY config.insertNewChildAt.last "Append to the last of the sub tree">
|
<!ENTITY config.insertNewChildAt.last "Append to the last of the sub tree">
|
||||||
|
|
||||||
|
<!ENTITY config.useEffectiveTLD.caption "Detecting method for "same website"">
|
||||||
|
<!ENTITY config.useEffectiveTLD.enabled "by Domain name ("aaa.example.com" and "bbb.example.com" are same website)">
|
||||||
|
<!ENTITY config.useEffectiveTLD.disabled "by Host name ("aaa.example.com" and "bbb.example.com" are different website)">
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -119,6 +119,10 @@
|
|||||||
<!ENTITY config.insertNewChildAt.first "Insertar arriba del todo en el árbol">
|
<!ENTITY config.insertNewChildAt.first "Insertar arriba del todo en el árbol">
|
||||||
<!ENTITY config.insertNewChildAt.last "Insertar abajo del todo en el árbol">
|
<!ENTITY config.insertNewChildAt.last "Insertar abajo del todo en el árbol">
|
||||||
|
|
||||||
|
<!ENTITY config.useEffectiveTLD.caption "Detecting method for "same website"">
|
||||||
|
<!ENTITY config.useEffectiveTLD.enabled "by Domain name ("aaa.example.com" and "bbb.example.com" are same website)">
|
||||||
|
<!ENTITY config.useEffectiveTLD.disabled "by Host name ("aaa.example.com" and "bbb.example.com" are different website)">
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -119,6 +119,10 @@
|
|||||||
<!ENTITY config.insertNewChildAt.first "Inserisci all'inizio del sottoalbero, come prima sottoscheda">
|
<!ENTITY config.insertNewChildAt.first "Inserisci all'inizio del sottoalbero, come prima sottoscheda">
|
||||||
<!ENTITY config.insertNewChildAt.last "Accoda all'ultimo sottoalbero">
|
<!ENTITY config.insertNewChildAt.last "Accoda all'ultimo sottoalbero">
|
||||||
|
|
||||||
|
<!ENTITY config.useEffectiveTLD.caption "Detecting method for "same website"">
|
||||||
|
<!ENTITY config.useEffectiveTLD.enabled "by Domain name ("aaa.example.com" and "bbb.example.com" are same website)">
|
||||||
|
<!ENTITY config.useEffectiveTLD.disabled "by Host name ("aaa.example.com" and "bbb.example.com" are different website)">
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -118,6 +118,10 @@
|
|||||||
<!ENTITY config.insertNewChildAt.first "サブツリーの最初の位置に挿入する">
|
<!ENTITY config.insertNewChildAt.first "サブツリーの最初の位置に挿入する">
|
||||||
<!ENTITY config.insertNewChildAt.last "サブツリーの末尾に追加する">
|
<!ENTITY config.insertNewChildAt.last "サブツリーの末尾に追加する">
|
||||||
|
|
||||||
|
<!ENTITY config.useEffectiveTLD.caption "同じサイトかどうかの判別方法">
|
||||||
|
<!ENTITY config.useEffectiveTLD.enabled "ドメイン名で判別する(aaa.example.comとbbb.example.comを同じサイトとして認識)">
|
||||||
|
<!ENTITY config.useEffectiveTLD.disabled "ホスト名で判別する(aaa.example.comとbbb.example.comを別のサイトとして認識)">
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!ENTITY context.openSelectionLinks.label "選択したリンクをすべてタブで開く">
|
<!ENTITY context.openSelectionLinks.label "選択したリンクをすべてタブで開く">
|
||||||
|
@ -118,6 +118,10 @@
|
|||||||
<!ENTITY config.insertNewChildAt.first "Wstaw jako pierwszą na górze drzewa">
|
<!ENTITY config.insertNewChildAt.first "Wstaw jako pierwszą na górze drzewa">
|
||||||
<!ENTITY config.insertNewChildAt.last "Wstaw na końcu drzewa">
|
<!ENTITY config.insertNewChildAt.last "Wstaw na końcu drzewa">
|
||||||
|
|
||||||
|
<!ENTITY config.useEffectiveTLD.caption "Detecting method for "same website"">
|
||||||
|
<!ENTITY config.useEffectiveTLD.enabled "by Domain name ("aaa.example.com" and "bbb.example.com" are same website)">
|
||||||
|
<!ENTITY config.useEffectiveTLD.disabled "by Host name ("aaa.example.com" and "bbb.example.com" are different website)">
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -119,6 +119,10 @@
|
|||||||
<!ENTITY config.insertNewChildAt.first "Вставлять первой в начало поддерева">
|
<!ENTITY config.insertNewChildAt.first "Вставлять первой в начало поддерева">
|
||||||
<!ENTITY config.insertNewChildAt.last "Добавлять в конце поддерева">
|
<!ENTITY config.insertNewChildAt.last "Добавлять в конце поддерева">
|
||||||
|
|
||||||
|
<!ENTITY config.useEffectiveTLD.caption "Detecting method for "same website"">
|
||||||
|
<!ENTITY config.useEffectiveTLD.enabled "by Domain name ("aaa.example.com" and "bbb.example.com" are same website)">
|
||||||
|
<!ENTITY config.useEffectiveTLD.disabled "by Host name ("aaa.example.com" and "bbb.example.com" are different website)">
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -119,6 +119,10 @@
|
|||||||
<!ENTITY config.insertNewChildAt.first "插入到子树顶部,成为首个子标签">
|
<!ENTITY config.insertNewChildAt.first "插入到子树顶部,成为首个子标签">
|
||||||
<!ENTITY config.insertNewChildAt.last "添加到子树的最后">
|
<!ENTITY config.insertNewChildAt.last "添加到子树的最后">
|
||||||
|
|
||||||
|
<!ENTITY config.useEffectiveTLD.caption "Detecting method for "same website"">
|
||||||
|
<!ENTITY config.useEffectiveTLD.enabled "by Domain name ("aaa.example.com" and "bbb.example.com" are same website)">
|
||||||
|
<!ENTITY config.useEffectiveTLD.disabled "by Host name ("aaa.example.com" and "bbb.example.com" are different website)">
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -116,6 +116,10 @@
|
|||||||
<!ENTITY config.insertNewChildAt.first "插入到子樹的開端">
|
<!ENTITY config.insertNewChildAt.first "插入到子樹的開端">
|
||||||
<!ENTITY config.insertNewChildAt.last "新增到子樹的末端">
|
<!ENTITY config.insertNewChildAt.last "新增到子樹的末端">
|
||||||
|
|
||||||
|
<!ENTITY config.useEffectiveTLD.caption "Detecting method for "same website"">
|
||||||
|
<!ENTITY config.useEffectiveTLD.enabled "by Domain name ("aaa.example.com" and "bbb.example.com" are same website)">
|
||||||
|
<!ENTITY config.useEffectiveTLD.disabled "by Host name ("aaa.example.com" and "bbb.example.com" are different website)">
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!ENTITY context.openSelectionLinks.label "用新分頁開啟所有選取的鏈結">
|
<!ENTITY context.openSelectionLinks.label "用新分頁開啟所有選取的鏈結">
|
||||||
|
Loading…
Reference in New Issue
Block a user