[Webkit-unassigned] [Bug 103510] Reduce the children repaints when moved multiple times during the layout
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Thu Nov 29 23:25:07 PST 2012
https://bugs.webkit.org/show_bug.cgi?id=103510
--- Comment #5 from Carlos Garcia Campos <cgarcia at igalia.com> 2012-11-29 23:27:23 PST ---
(In reply to comment #4)
> (From update of attachment 176463 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=176463&action=review
>
> > Source/WebCore/rendering/RenderFlexibleBox.cpp:385
> > + if (!selfNeedsLayout() && child->checkForRepaintDuringLayout())
> > + child->repaintDuringLayoutIfMoved(childrenOldRects.get(child));
>
> We should also make sure that the old position is different from the current position before repainting.
That check is already done by repaintDuringLayoutIfMoved().
> >>> Source/WebCore/rendering/RenderFlexibleBox.h:81
> >>> + typedef WTF::HashMap<const RenderBox*, LayoutRect> ChildrenFrameRect;
> >>
> >> Can we use a Vector<LayoutRect> instead of a HashMap?
> >
> > I used a hash map, because I'm iterating the children using the flexbox order, I'm not sure if it's important to repaint in that order, though.
>
> That's a good point, we have to iterate the children using the flexbox order. The existing order-painting.html test might cover this? Should be easy to test.
>
> I guess we don't have the order iterator when you saved the child boxes. Hmm, I think we could save the child boxes right before layoutFlexItems() and I think this will still work.
Right, I'll try that way. Thanks!
--
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
More information about the webkit-unassigned
mailing list