[Webkit-unassigned] [Bug 52380] Lazily generate and store logical ordering of InlineBoxes

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Jan 13 14:42:06 PST 2011


https://bugs.webkit.org/show_bug.cgi?id=52380





--- Comment #4 from Levi Weintraub <leviw at google.com>  2011-01-13 14:42:05 PST ---
Thanks for taking a look at this!

(In reply to comment #3)
> (From update of attachment 78836 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=78836&action=review
> 
> I suspect this is not invalidating when necessary.
> 
> > Source/WebCore/editing/visible_units.cpp:1039
> > +    const Vector<InlineBox*> leafBoxesInLogicalOrder = rootBox->leafBoxesInLogicalOrder();
> 
> I don't think you want the const here. seems meaningless.
> 
> > Source/WebCore/rendering/RootInlineBox.cpp:219
> > +    m_leafBoxesInLogicalOrder.clear();
> 
> Don't we need to invalidate thsi when adding children too?

For sure. Currently we only ever add line boxes on line creation so we wouldn't get into this case, but not doing this would be leaving us open for future problems.

> > Source/WebCore/rendering/RootInlineBox.cpp:566
> > +void RootInlineBox::determineLogicalOrderOfLeafBoxes() const
> 
> I assume this is just copied from the previous location and otherwise not modified (except to store in a vector)?

Correct. The relevance of this patch is that it speeds up access to logical InlineBox ordering, which is information we iterate through in several places. Caching it and using this source should allow us to speed up and simplify these code paths.

-- 
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