RESOLVED FIXED 120402
Don't use NodeRenderingContext when attaching text renderers
https://bugs.webkit.org/show_bug.cgi?id=120402
Summary Don't use NodeRenderingContext when attaching text renderers
Antti Koivisto
Reported 2013-08-28 04:46:58 PDT
Simplify.
Attachments
patch (26.37 KB, patch)
2013-08-28 05:00 PDT, Antti Koivisto
kling: review+
Antti Koivisto
Comment 1 2013-08-28 05:00:48 PDT
Andreas Kling
Comment 2 2013-08-28 05:31:49 PDT
Comment on attachment 209865 [details] patch View in context: https://bugs.webkit.org/attachment.cgi?id=209865&action=review r=me > Source/WebCore/style/StyleResolveTree.cpp:210 > +static void crateTextRendererIfNeeded(Text* textNode) Typo, cr_e_ate. > Source/WebCore/style/StyleResolveTree.cpp:276 > + RenderText* textRenderer = toRenderText(textNode->renderer()); We could add a tightly-typed override and avoid casts like this: RenderText* Text::renderer() const; > Source/WebCore/style/StyleResolveTree.h:56 > +void attachTextRenderer(Text*); > +void detachTextRenderer(Text*); > +void updateTextRendererAfterContentChange(Text*, unsigned offsetOfReplacedData, unsigned lengthOfReplacedData); Can we make these take Text& instead? They shouldn't have to deal with null inputs.
Antti Koivisto
Comment 3 2013-08-28 06:13:02 PDT
Note You need to log in before you can comment on or make changes to this bug.