Summary: | REGRESSION: Incomplete repaint when block with clipping grows | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | mitz | ||||||||||||
Component: | Layout and Rendering | Assignee: | Nobody <webkit-unassigned> | ||||||||||||
Status: | RESOLVED FIXED | ||||||||||||||
Severity: | Normal | CC: | alice.barraclough, hyatt | ||||||||||||
Priority: | P1 | Keywords: | HasReduction, InRadar, Regression | ||||||||||||
Version: | 420+ | ||||||||||||||
Hardware: | Mac | ||||||||||||||
OS: | OS X 10.4 | ||||||||||||||
Attachments: |
|
Description
mitz
2006-01-24 13:20:40 PST
Created attachment 5926 [details]
Testcase
Created attachment 7750 [details]
Possible fix
I think this patch does not add a lot of painting, and what it does add can be divided between
1) what's needed to fix the bug: the layer did not need layout, but ended up resizing because of a child.
2) addressing the fact that the selfNeedsLayout() condition in repaintAfterLayoutIfNeeded() is always false when called from the layer.
Created attachment 7751 [details]
Possible fix
Please see my previous comment.
Created attachment 7752 [details]
Possible fix
Sorry, uploaded the wrong file.
Comment on attachment 7752 [details]
Possible fix
This sure looks good to me, but I think it's something Hyatt will want to review himself.
Won't this cause way too much repainting? Turn on paint flashing and try loading a huge file like: http://lxr.mozilla.org/seamonkey/source/layout/base/nsCSSFrameConstructor.cpp Do you see the whole window repainting now with this fix as chunks of data come in? It seems like this fix will cause the root block's layer to repaint whenever new chunks of data come in that make the root block's layer grow. (In reply to comment #7) > It seems like this fix will cause the root block's layer to repaint whenever > new chunks of data come in that make the root block's layer grow. Oh boy, I overlooked that! I think instead of + m_fullRepaintOnResize = m_object->selfNeedsLayout() || m_object->normalChildNeedsLayout(); it should be + m_fullRepaintOnResize = m_object->selfNeedsLayout() || m_object->hasOverflowClip() && m_object->normalChildNeedsLayout(); Comment on attachment 7752 [details]
Possible fix
Even that change will still cause overflow blocks to repaint over and over as they load content.
(In reply to comment #9) > (From update of attachment 7752 [details] [edit]) > Even that change will still cause overflow blocks to repaint over and over as > they load content. In what case, other than when adding content causes their layer to resize (which is what this bug is about)? Created attachment 7810 [details]
Patch, including change log and manual test
Added the hasOverflowClip() check and renamed the flag per Hyatt's suggestion.
Comment on attachment 7810 [details]
Patch, including change log and manual test
r=me
Landed in r13982. |