Summary: | RenderTextFragment: Tighten first-letter logic. | ||||||
---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Andreas Kling <kling> | ||||
Component: | Layout and Rendering | Assignee: | Andreas Kling <kling> | ||||
Status: | RESOLVED FIXED | ||||||
Severity: | Normal | CC: | kling | ||||
Priority: | P2 | ||||||
Version: | 528+ (Nightly build) | ||||||
Hardware: | Unspecified | ||||||
OS: | Unspecified | ||||||
Attachments: |
|
Description
Andreas Kling
2013-11-03 14:58:51 PST
Created attachment 215879 [details]
Patch
Comment on attachment 215879 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=215879&action=review > Source/WebCore/editing/TextIterator.cpp:672 > -static inline RenderText* firstRenderTextInFirstLetter(RenderObject* firstLetter) > +static inline RenderText* firstRenderTextInFirstLetter(RenderBoxModelObject* firstLetter) > { > if (!firstLetter) > - return 0; > + return nullptr; Maybe you could just remove this helper? Only one call site needs the null test. (In reply to comment #2) > (From update of attachment 215879 [details]) > View in context: https://bugs.webkit.org/attachment.cgi?id=215879&action=review > > > Source/WebCore/editing/TextIterator.cpp:672 > > -static inline RenderText* firstRenderTextInFirstLetter(RenderObject* firstLetter) > > +static inline RenderText* firstRenderTextInFirstLetter(RenderBoxModelObject* firstLetter) > > { > > if (!firstLetter) > > - return 0; > > + return nullptr; > > Maybe you could just remove this helper? Only one call site needs the null test. I like that it provides a home for the FIXME. I don't know what to do about that FIXME, otherwise I'd be fixing it. :( Committed r158551: <http://trac.webkit.org/changeset/158551> |