Bug 345259 - [RTL UI] opening tabs in background moves tabs. patch from smontagu and me, r=mconnor.
git-svn-id: svn://10.0.0.236/trunk@232760 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
parent
e421975621
commit
ea3a9d2f6f
@ -1120,8 +1120,21 @@
|
||||
t.setAttribute("validate", "never");
|
||||
t.setAttribute("onerror", "this.parentNode.parentNode.parentNode.parentNode.addToMissedIconCache(this.getAttribute('image')); this.removeAttribute('image');");
|
||||
t.className = "tabbrowser-tab";
|
||||
|
||||
|
||||
this.mTabContainer.appendChild(t);
|
||||
|
||||
if (document.defaultView
|
||||
.getComputedStyle(this.mTabContainer, "")
|
||||
.direction == "rtl") {
|
||||
/* In RTL UI, the tab is visually added to the left side of the
|
||||
* tabstrip. This means the tabstip has to be scrolled back in
|
||||
* order to make sure the same set of tabs is visible before and
|
||||
* after the new tab is added */
|
||||
|
||||
this.mTabContainer.mTabstrip.scrollBoxObject
|
||||
.scrollBy(this.mTabContainer.firstChild.boxObject.width, 0);
|
||||
}
|
||||
|
||||
// invalidate cache, because mTabContainer is about to change
|
||||
this._browsers = null;
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user