[webkit-reviews] review denied: [Bug 115149] Implement ruby-align : [Attachment 199625] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Apr 30 14:59:10 PDT 2013


Dave Hyatt <hyatt at apple.com> has denied Yuki Sekiguchi
<yuki.sekiguchi at access-company.com>'s request for review:
Bug 115149: Implement ruby-align
https://bugs.webkit.org/show_bug.cgi?id=115149

Attachment 199625: Patch
https://bugs.webkit.org/attachment.cgi?id=199625&action=review

------- Additional Comments from Dave Hyatt <hyatt at apple.com>
View in context: https://bugs.webkit.org/attachment.cgi?id=199625&action=review


r-

Don't forget to patch RenderStyle::diff to do a relayout if ruby-align changes.
You should add a test that dynamically changes ruby-align in order to test
this.

> Source/WebCore/rendering/RenderBlockLineLayout.cpp:671
> +	       if (rubyRun->rubyBase())
> +		   rubyRun->rubyBase()->layoutIfNeeded();

Can't you fold this code into setIsEndEdge?

> Source/WebCore/rendering/RenderBlockLineLayout.cpp:734
> +	   rubyRun->setIsEndEdge(true);
> +	   if (rubyRun->rubyBase())
> +	       rubyRun->rubyBase()->layoutIfNeeded();

Same here.

> Source/WebCore/rendering/RenderRubyRun.cpp:243
> -    
> +

Remove this accidental whitespace change.

> Source/WebCore/rendering/RenderRubyRun.h:83
> +    void setIsStartEdge(bool isEdge)
> +    {
> +	   if (m_isStartEdge != isEdge && rubyBase())
> +	       rubyBase()->setNeedsLayout(true, MarkOnlyThis);
> +	   m_isStartEdge = isEdge;
> +    }
> +    bool isEndEdge() const { return m_isEndEdge; }
> +    void setIsEndEdge(bool isEdge)
> +    {
> +	   if (m_isEndEdge != isEdge && rubyBase())
> +	       rubyBase()->setNeedsLayout(true, MarkOnlyThis);
> +	   m_isEndEdge = isEdge;
> +    }

Go ahead and do the layoutIfNeeded directly inside the set methods. I would
un-inline them also and put them in the .cpp file.

> Source/WebCore/rendering/RenderRubyRun.h:96
> +    bool m_isStartEdge;
> +    bool m_isEndEdge;

I know you set these to false on every layout, but just to avoid future issues
in case things change, let's init them to false in the constructor as well.


More information about the webkit-reviews mailing list