revert
git-svn-id: http://www.cozmixng.org/repos/piro/treestyletab/trunk@5058 599a83e7-65a4-db11-8015-0010dcdd6dc2
This commit is contained in:
parent
03be1e5236
commit
bdb8a27b56
@ -142,77 +142,97 @@ var TreeStyleTabService = {
|
|||||||
},
|
},
|
||||||
|
|
||||||
get SessionStore() {
|
get SessionStore() {
|
||||||
delete this.SessionStore;
|
if (!this._SessionStore) {
|
||||||
return (this.SessionStore = Components
|
this._SessionStore = Components
|
||||||
.classes['@mozilla.org/browser/sessionstore;1']
|
.classes['@mozilla.org/browser/sessionstore;1']
|
||||||
.getService(Components.interfaces.nsISessionStore));
|
.getService(Components.interfaces.nsISessionStore);
|
||||||
|
}
|
||||||
|
return this._SessionStore;
|
||||||
},
|
},
|
||||||
|
_SessionStore : null,
|
||||||
|
|
||||||
get ObserverService() {
|
get ObserverService() {
|
||||||
delete this.ObserverService;
|
if (!this._ObserverService) {
|
||||||
return (this.ObserverService = Components
|
this._ObserverService = Components
|
||||||
.classes['@mozilla.org/observer-service;1']
|
.classes['@mozilla.org/observer-service;1']
|
||||||
.getService(Components.interfaces.nsIObserverService));
|
.getService(Components.interfaces.nsIObserverService);
|
||||||
|
}
|
||||||
|
return this._ObserverService;
|
||||||
},
|
},
|
||||||
|
_ObserverService : null,
|
||||||
|
|
||||||
get IOService() {
|
get IOService() {
|
||||||
delete this.IOService;
|
if (!this._IOService) {
|
||||||
return (this.IOService = Components
|
this._IOService = Components
|
||||||
.classes['@mozilla.org/network/io-service;1']
|
.classes['@mozilla.org/network/io-service;1']
|
||||||
.getService(Components.interfaces.nsIIOService));
|
.getService(Components.interfaces.nsIIOService);
|
||||||
|
}
|
||||||
|
return this._IOService;
|
||||||
},
|
},
|
||||||
|
_IOService : null,
|
||||||
|
|
||||||
get WindowMediator() {
|
get WindowMediator() {
|
||||||
delete this.WindowMediator;
|
if (!this._WindowMediator) {
|
||||||
return (this.WindowMediator = Components
|
this._WindowMediator = Components
|
||||||
.classes['@mozilla.org/appshell/window-mediator;1']
|
.classes['@mozilla.org/appshell/window-mediator;1']
|
||||||
.getService(Components.interfaces.nsIWindowMediator));
|
.getService(Components.interfaces.nsIWindowMediator);
|
||||||
|
}
|
||||||
|
return this._WindowMediator;
|
||||||
},
|
},
|
||||||
|
_WindowMediator : null,
|
||||||
|
|
||||||
get EffectiveTLD()
|
get EffectiveTLD()
|
||||||
{
|
{
|
||||||
delete this.EffectiveTLD;
|
if (!('_EffectiveTLD' in this)) {
|
||||||
return (this.EffectiveTLD = (
|
this._EffectiveTLD = 'nsIEffectiveTLDService' in Components.interfaces ?
|
||||||
'nsIEffectiveTLDService' in Components.interfaces ?
|
|
||||||
Components
|
Components
|
||||||
.classes['@mozilla.org/network/effective-tld-service;1']
|
.classes['@mozilla.org/network/effective-tld-service;1']
|
||||||
.getService(Components.interfaces.nsIEffectiveTLDService) :
|
.getService(Components.interfaces.nsIEffectiveTLDService) :
|
||||||
null
|
null ;
|
||||||
));
|
}
|
||||||
|
return this._EffectiveTLD;
|
||||||
},
|
},
|
||||||
|
// _EffectiveTLD : null,
|
||||||
|
|
||||||
get PromptService()
|
get PromptService()
|
||||||
{
|
{
|
||||||
delete this.PromptService;
|
if (!this._PromptService) {
|
||||||
return (this.PromptService = Components
|
this._PromptService = Components
|
||||||
.classes['@mozilla.org/embedcomp/prompt-service;1']
|
.classes['@mozilla.org/embedcomp/prompt-service;1']
|
||||||
.getService(Components.interfaces.nsIPromptService));
|
.getService(Components.interfaces.nsIPromptService);
|
||||||
|
}
|
||||||
|
return this._PromptService;
|
||||||
},
|
},
|
||||||
|
_PromptService : null,
|
||||||
|
|
||||||
get XULAppInfo() {
|
get XULAppInfo() {
|
||||||
delete this.XULAppInfo;
|
if (!this._XULAppInfo) {
|
||||||
return (this.XULAppInfo = Components
|
this._XULAppInfo = Components
|
||||||
.classes['@mozilla.org/xre/app-info;1']
|
.classes['@mozilla.org/xre/app-info;1']
|
||||||
.getService(Components.interfaces.nsIXULAppInfo));
|
.getService(Components.interfaces.nsIXULAppInfo);
|
||||||
|
}
|
||||||
|
return this._XULAppInfo;
|
||||||
},
|
},
|
||||||
|
_XULAppInfo : null,
|
||||||
get Comparator() {
|
get Comparator() {
|
||||||
delete this.Comparator;
|
if (!this._Comparator) {
|
||||||
return (this.Comparator = Components
|
this._Comparator = Components
|
||||||
.classes['@mozilla.org/xpcom/version-comparator;1']
|
.classes['@mozilla.org/xpcom/version-comparator;1']
|
||||||
.getService(Components.interfaces.nsIVersionComparator));
|
.getService(Components.interfaces.nsIVersionComparator);
|
||||||
|
}
|
||||||
|
return this._Comparator;
|
||||||
},
|
},
|
||||||
|
_Comparator : null,
|
||||||
|
|
||||||
get treeBundle() {
|
get treeBundle() {
|
||||||
delete this.treeBundle;
|
return window['piro.sakura.ne.jp']
|
||||||
return (this.treeBundle = window['piro.sakura.ne.jp']
|
|
||||||
.stringBundle
|
.stringBundle
|
||||||
.get('chrome://treestyletab/locale/treestyletab.properties'));
|
.get('chrome://treestyletab/locale/treestyletab.properties');
|
||||||
},
|
},
|
||||||
get tabbrowserBundle() {
|
get tabbrowserBundle() {
|
||||||
delete this.tabbrowserBundle;
|
return window['piro.sakura.ne.jp']
|
||||||
return (this.tabbrowserBundle = window['piro.sakura.ne.jp']
|
|
||||||
.stringBundle
|
.stringBundle
|
||||||
.get('chrome://browser/locale/tabbrowser.properties'));
|
.get('chrome://browser/locale/tabbrowser.properties');
|
||||||
},
|
},
|
||||||
|
|
||||||
/* API */
|
/* API */
|
||||||
|
@ -54,17 +54,22 @@ TreeStyleTabBrowser.prototype = {
|
|||||||
|
|
||||||
get container()
|
get container()
|
||||||
{
|
{
|
||||||
delete this.container;
|
if (!this._container) {
|
||||||
return (this.container = document.getElementById('appcontent'));
|
this._container = document.getElementById('appcontent');
|
||||||
|
}
|
||||||
|
return this._container;
|
||||||
},
|
},
|
||||||
|
_container : null,
|
||||||
|
|
||||||
get scrollBox()
|
get scrollBox()
|
||||||
{
|
{
|
||||||
delete this.scrollBox;
|
if (!this._scrollBox) {
|
||||||
var scrollBox = document.getAnonymousElementByAttribute(this.mTabBrowser.mTabContainer, 'class', 'tabs-frame') || // Tab Mix Plus
|
this._scrollBox = document.getAnonymousElementByAttribute(this.mTabBrowser.mTabContainer, 'class', 'tabs-frame') || // Tab Mix Plus
|
||||||
this.mTabBrowser.mTabContainer.mTabstrip;
|
this.mTabBrowser.mTabContainer.mTabstrip;
|
||||||
return (this.scrollBox = scrollBox);
|
}
|
||||||
|
return this._scrollBox;
|
||||||
},
|
},
|
||||||
|
_scrollBox : null,
|
||||||
get scrollBoxObject()
|
get scrollBoxObject()
|
||||||
{
|
{
|
||||||
return (this.scrollBox.scrollBoxObject || this.scrollBox.boxObject)
|
return (this.scrollBox.scrollBoxObject || this.scrollBox.boxObject)
|
||||||
@ -1024,9 +1029,9 @@ TreeStyleTabBrowser.prototype = {
|
|||||||
b.mPanelContainer.removeEventListener('dragdrop', this, false);
|
b.mPanelContainer.removeEventListener('dragdrop', this, false);
|
||||||
|
|
||||||
this.tabbarDNDObserver.destroy();
|
this.tabbarDNDObserver.destroy();
|
||||||
delete this.tabbarDNDObserver;
|
delete this._tabbarDNDObserver;
|
||||||
this.panelDNDObserver.destroy();
|
this.panelDNDObserver.destroy();
|
||||||
delete this.panelDNDObserver;
|
delete this._panelDNDObserver;
|
||||||
|
|
||||||
this.scrollBox.removeEventListener('overflow', this, true);
|
this.scrollBox.removeEventListener('overflow', this, true);
|
||||||
this.scrollBox.removeEventListener('underflow', this, true);
|
this.scrollBox.removeEventListener('underflow', this, true);
|
||||||
@ -2345,14 +2350,12 @@ TreeStyleTabBrowser.prototype = {
|
|||||||
|
|
||||||
get tabbarDNDObserver()
|
get tabbarDNDObserver()
|
||||||
{
|
{
|
||||||
delete this.tabbarDNDObserver;
|
return this._tabbarDNDObserver || (this._tabbarDNDObserver = new TreeStyleTabBrowserTabbarDNDObserver(this));
|
||||||
return (this.tabbarDNDObserver = new TreeStyleTabBrowserTabbarDNDObserver(this));
|
|
||||||
},
|
},
|
||||||
|
|
||||||
get panelDNDObserver()
|
get panelDNDObserver()
|
||||||
{
|
{
|
||||||
delete this.panelDNDObserver;
|
return this._panelDNDObserver || (this._panelDNDObserver = new TreeStyleTabBrowserTabpanelDNDObserver(this));
|
||||||
return (this.panelDNDObserver = new TreeStyleTabBrowserTabpanelDNDObserver(this));
|
|
||||||
},
|
},
|
||||||
|
|
||||||
getCurrentDragSession : function()
|
getCurrentDragSession : function()
|
||||||
|
Loading…
Reference in New Issue
Block a user