Closed
Bug 485841
Opened 16 years ago
Closed 16 years ago
Get rid of some timeouts and avoid boxObject where appropriate in tabbrowser
Categories
(Firefox :: Tabbed Browser, defect)
Tracking
()
VERIFIED
FIXED
Firefox 3.6a1
People
(Reporter: dao, Assigned: dao)
References
Details
Attachments
(1 file, 3 obsolete files)
14.84 KB,
patch
|
enndeakin
:
review+
|
Details | Diff | Splinter Review |
Example A:
1. open lots of tabs
2. scroll to the end of the tabstrip
3. select the tab that's visible on the left end of the tabstrip, so that the last tab will be partially hidden
4. close the last tab using middle click
--or--
2. select the last tab
3. scroll a bit, so that the the tab that's visible on the left end of the tabstrip becomes fully visible and the last tab becomes partially hidden
4. close the last tab using the close button or accel+w
--> the closed tab leaves a gap that should have been filled
Example B:
1. enable session restoring ("When Minfield starts: Show my tabs and windows from last time"...)
2. open lots of tabs
3. select the last tab
4. exit the browser
5. start the browser
--> the selected tab isn't fully visible, it's cut off by the width of the right scrolling button
Assignee | ||
Comment 1•16 years ago
|
||
Attachment #372424 -
Flags: review?(gavin.sharp)
Assignee | ||
Comment 2•16 years ago
|
||
Morphing a bit, since the flushing that's interesting for the examples from comment 0 has been done in bug 483552. The patch here is still needed to fully fix the cases.
Summary: Need to flush layout for some operations on the tabstrip → Get rid of some timeouts and avoid boxObject where appropriate in tabbrowser
Assignee | ||
Comment 3•16 years ago
|
||
updated to trunk
Attachment #372424 -
Attachment is obsolete: true
Attachment #374830 -
Flags: review?(gavin.sharp)
Attachment #372424 -
Flags: review?(gavin.sharp)
Assignee | ||
Comment 4•16 years ago
|
||
updated to latest trunk
Attachment #374830 -
Attachment is obsolete: true
Attachment #375192 -
Flags: review?(gavin.sharp)
Attachment #374830 -
Flags: review?(gavin.sharp)
Assignee | ||
Comment 5•16 years ago
|
||
Gavin: ping?
Comment 6•16 years ago
|
||
There are a few places in that patch that use rect.left+rect.width (or clientWidth) instead of just using rect.right.
How did you determine that the setTimeout wasn't necessary for the adjustTabstrip/updateScrollButtonsDisabledState calls?
Looks good to me otherwise, but Neil Deakin may be a better reviewer for this since I think he's more familiar with the differences between client* properties and boxObjects.
Assignee | ||
Comment 7•16 years ago
|
||
(In reply to comment #6)
> There are a few places in that patch that use rect.left+rect.width (or
> clientWidth) instead of just using rect.right.
I see this only in one place, but I'll double-check.
> How did you determine that the setTimeout wasn't necessary for the
> adjustTabstrip/updateScrollButtonsDisabledState calls?
clientWidth in adjustTabstrip flushes layout, and so does _updateScrollButtonsDisabledState as of bug 483552.
Comment 8•16 years ago
|
||
(In reply to comment #7)
> (In reply to comment #6)
> > There are a few places in that patch that use rect.left+rect.width (or
> > clientWidth) instead of just using rect.right.
>
> I see this only in one place, but I'll double-check.
>+ ib.getBoundingClientRect().left + ib.clientWidth -
>+ newMargin = tabRect.left - rect.left + tabRect.width;
>+ newMargin = rect.left - tabRect.left + rect.width;
>+ newMargin = rect.left - tabRect.left + rect.width - tabRect.width;
Assignee | ||
Comment 9•16 years ago
|
||
what Gavin said
Attachment #375192 -
Attachment is obsolete: true
Attachment #387231 -
Flags: review?(enndeakin)
Attachment #375192 -
Flags: review?(gavin.sharp)
Comment 10•16 years ago
|
||
Comment on attachment 387231 [details] [diff] [review]
patch v2
> Looks good to me otherwise, but Neil Deakin may be a better reviewer for this
> since I think he's more familiar with the differences between client*
> properties and boxObjects.
The difference is that getBoundingClientRect returns border-boxes, and boxObject.x/y does something odd where it excludes the border, (but boxObject.width/height does not).
Regardless, you may wish to test with larger borders on tabs, tabstrip, etc, just in case some theme has that.
Attachment #387231 -
Flags: review?(enndeakin) → review+
Assignee | ||
Comment 11•16 years ago
|
||
Status: ASSIGNED → RESOLVED
Closed: 16 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 3.6a1
Assignee | ||
Comment 12•16 years ago
|
||
leak test boxes are acting up, backed out...
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Assignee | ||
Comment 13•16 years ago
|
||
Landed in various steps:
http://hg.mozilla.org/mozilla-central/rev/be001dd56987
http://hg.mozilla.org/mozilla-central/rev/c4fe058e760c
http://hg.mozilla.org/mozilla-central/rev/03a6732c66b3 [1]
http://hg.mozilla.org/mozilla-central/rev/af27eba56973 [2]
http://hg.mozilla.org/mozilla-central/rev/9e51ab5a80ee
1: this leaks
2: this fixed the leak, somehow
Status: REOPENED → RESOLVED
Closed: 16 years ago → 16 years ago
Resolution: --- → FIXED
Comment 14•15 years ago
|
||
Verified fixed with the steps in comment 0. Looks good on 1.9.2 with builds on all platforms like
Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2b3pre) Gecko/20091112 Namoroka/3.6b3pre (.NET CLR 3.5.30729) ID:20091112051557
Status: RESOLVED → VERIFIED
You need to log in
before you can comment on or make changes to this bug.
Description
•