AutoHide ( http://www.krickelkrackel.de/autohide/ )と併用した時に、前回終了時の状態がフルスクリーンモードだと、次回起動時の初期状態がおかしくなる問題を修正
git-svn-id: http://www.cozmixng.org/repos/piro/treestyletab/trunk@6528 599a83e7-65a4-db11-8015-0010dcdd6dc2
This commit is contained in:
parent
e54c0b8098
commit
4119bed50c
@ -60,7 +60,9 @@ TreeStyleTabBrowserAutoHide.prototype = {
|
|||||||
this.end();
|
this.end();
|
||||||
// update internal property after the appearance of the tab bar is updated.
|
// update internal property after the appearance of the tab bar is updated.
|
||||||
window.setTimeout(function(aSelf) {
|
window.setTimeout(function(aSelf) {
|
||||||
aSelf.mode = aSelf.getTreePref('tabbar.autoHide.mode');
|
aSelf.mode = window.fullScreen && aSelf.getPref('browser.fullscreen.autohide') ?
|
||||||
|
aSelf.getTreePref('tabbar.autoHide.mode.fullscreen') :
|
||||||
|
aSelf.getTreePref('tabbar.autoHide.mode') ;
|
||||||
if (aSelf.mode != aSelf.kMODE_DISABLED)
|
if (aSelf.mode != aSelf.kMODE_DISABLED)
|
||||||
aSelf.start();
|
aSelf.start();
|
||||||
}, 0, this);
|
}, 0, this);
|
||||||
@ -74,6 +76,9 @@ TreeStyleTabBrowserAutoHide.prototype = {
|
|||||||
var sv = this.mOwner;
|
var sv = this.mOwner;
|
||||||
switch (this.mode)
|
switch (this.mode)
|
||||||
{
|
{
|
||||||
|
case this.kMODE_DISABLED:
|
||||||
|
return 0;
|
||||||
|
|
||||||
case this.kMODE_HIDE:
|
case this.kMODE_HIDE:
|
||||||
let offset = this.width + this.splitterWidth;
|
let offset = this.width + this.splitterWidth;
|
||||||
if (sv.mTabBrowser.getAttribute(sv.kTABBAR_POSITION) == 'left') {
|
if (sv.mTabBrowser.getAttribute(sv.kTABBAR_POSITION) == 'left') {
|
||||||
@ -183,8 +188,7 @@ TreeStyleTabBrowserAutoHide.prototype = {
|
|||||||
this.kMODE_DISABLED ;
|
this.kMODE_DISABLED ;
|
||||||
if (this.mode != this.kMODE_DISABLED) {
|
if (this.mode != this.kMODE_DISABLED) {
|
||||||
this.start();
|
this.start();
|
||||||
var sv = this.mOwner;
|
this.mOwner.removeTabbrowserAttribute('moz-collapsed');
|
||||||
sv.removeTabbrowserAttribute('moz-collapsed');
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -503,6 +507,7 @@ TreeStyleTabBrowserAutoHide.prototype = {
|
|||||||
|
|
||||||
switch (this.mode)
|
switch (this.mode)
|
||||||
{
|
{
|
||||||
|
case this.kMODE_DISABLED:
|
||||||
case this.kMODE_HIDE:
|
case this.kMODE_HIDE:
|
||||||
break;
|
break;
|
||||||
|
|
||||||
@ -530,6 +535,7 @@ TreeStyleTabBrowserAutoHide.prototype = {
|
|||||||
sv.container.style.margin = 0;
|
sv.container.style.margin = 0;
|
||||||
switch (this.mode)
|
switch (this.mode)
|
||||||
{
|
{
|
||||||
|
case this.kMODE_DISABLED:
|
||||||
case this.kMODE_HIDE:
|
case this.kMODE_HIDE:
|
||||||
sv.setTabbrowserAttribute(this.kAUTOHIDE, 'hidden');
|
sv.setTabbrowserAttribute(this.kAUTOHIDE, 'hidden');
|
||||||
sv.setTabbrowserAttribute(this.kSTATE, this.kSTATE_HIDDEN);
|
sv.setTabbrowserAttribute(this.kSTATE, this.kSTATE_HIDDEN);
|
||||||
@ -833,6 +839,7 @@ TreeStyleTabBrowserAutoHide.prototype = {
|
|||||||
switch (aPrefName)
|
switch (aPrefName)
|
||||||
{
|
{
|
||||||
case 'extensions.treestyletab.tabbar.autoHide.mode':
|
case 'extensions.treestyletab.tabbar.autoHide.mode':
|
||||||
|
case 'extensions.treestyletab.tabbar.autoHide.mode.fullscreen':
|
||||||
this.updateMode();
|
this.updateMode();
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user