Closed
Bug 379922
Opened 19 years ago
Closed 19 years ago
Canvas frame's invalidation no longer correct
Categories
(Core :: Web Painting, defect)
Tracking
()
RESOLVED
FIXED
People
(Reporter: bzbarsky, Assigned: sharparrow1)
Details
(Keywords: regression)
Attachments
(1 file)
|
1.50 KB,
patch
|
dbaron
:
review+
dbaron
:
superreview+
|
Details | Diff | Splinter Review |
The block in nsCanvasFrame::Reflow which does:
589 // If the child frame was just inserted, then we're responsible for making sure
590 // it repaints
591 if (kidDirty) {
592 // But we have a new child, which will affect our background, so
593 // invalidate our whole rect.
594 // Note: Even though we request to be sized to our child's size, our
595 // scroll frame ensures that we are always the size of the viewport.
596 // Also note: GetPosition() on a CanvasFrame is always going to return
597 // (0, 0). We only want to invalidate GetRect() since GetOverflowRect()
598 // could also include overflow to our top and left (out of the viewport)
599 // which doesn't need to be painted.
600 Invalidate(GetRect(), PR_FALSE);
601 }
is no longer correct. In particular, the canvas frame is NOT the size of the viewport anymore. Not sure when this changed.
This is most visible with the testcase in bug 71191 on Linux. When I load it, the canvas background doesn't paint green until I move the mouse out of the window...
Flags: blocking1.9?
| Reporter | ||
Updated•19 years ago
|
Keywords: regression
Changed in bug 192767, maybe?
| Reporter | ||
Comment 2•19 years ago
|
||
That's possible.. it was some scrollframe change that changed this, yes.
Flags: blocking1.9? → blocking1.9+
| Assignee | ||
Comment 3•19 years ago
|
||
We shouldn't be depending on the canvas frame for background invalidation anyway... InvalidateCanvasIfNeeded is supposed to take care of that. I think it's buggy, though.
| Assignee | ||
Comment 4•19 years ago
|
||
Okay, so it looks like the canvas frame's invalidation is the only place we handle fixing the background after frame reconstruction. So I guess we should fix it.
| Assignee | ||
Comment 5•19 years ago
|
||
| Reporter | ||
Updated•19 years ago
|
Flags: in-testsuite?
| Assignee | ||
Comment 6•19 years ago
|
||
Note that we don't have any testing framework for catching invalidation bugs.
Comment on attachment 269921 [details] [diff] [review]
Patch
r+sr=dbaron
Attachment #269921 -
Flags: superreview+
Attachment #269921 -
Flags: review?(dbaron)
Attachment #269921 -
Flags: review+
| Assignee | ||
Comment 8•19 years ago
|
||
Checked in.
Status: ASSIGNED → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
Updated•8 years ago
|
Component: Layout: View Rendering → Layout: Web Painting
You need to log in
before you can comment on or make changes to this bug.
Description
•