起動直後にタブバーがオーバーフローしない問題を修正
git-svn-id: http://www.cozmixng.org/repos/piro/treestyletab/trunk@3762 599a83e7-65a4-db11-8015-0010dcdd6dc2
This commit is contained in:
parent
680ae93d14
commit
5d697a72b7
@ -125,6 +125,20 @@ TreeStyleTabBrowser.prototype = {
|
||||
|
||||
var container = document.getAnonymousElementByAttribute(b.mTabContainer, 'class', 'tabs-container');
|
||||
if (container) container.removeAttribute('overflow');
|
||||
window.setTimeout(function() {
|
||||
var inner = document.getAnonymousElementByAttribute(b.mTabContainer, 'class', 'tabbrowser-arrowscrollbox');
|
||||
if (inner) inner = document.getAnonymousElementByAttribute(inner, 'anonid', 'scrollbox');
|
||||
if (inner) inner = document.getAnonymousNodes(inner)[0];
|
||||
if (
|
||||
inner &&
|
||||
(
|
||||
inner.boxObject.width > container.boxObject.width ||
|
||||
inner.boxObject.height > container.boxObject.height
|
||||
)
|
||||
) {
|
||||
container.setAttribute('overflow', true);
|
||||
}
|
||||
}, 100);
|
||||
|
||||
/* Closing collapsed last tree breaks selected tab.
|
||||
To solve this problem, I override the setter to
|
||||
|
Loading…
x
Reference in New Issue
Block a user