Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: bdf08cf8d7889d8990a601ff576fad7c06b89e3f
      
https://github.com/WebKit/WebKit/commit/bdf08cf8d7889d8990a601ff576fad7c06b89e3f
  Author: Alan Baradlay <[email protected]>
  Date:   2026-06-30 (Tue, 30 Jun 2026)

  Changed paths:
    M Source/WebCore/rendering/RenderBox.cpp
    M Source/WebCore/rendering/svg/RenderSVGRoot.cpp
    M Source/WebCore/style/values/transforms/StyleTransformList.cpp

  Log Message:
  -----------
  [cleanup] Use RenderBox::borderBoxSize() in size-only callers of 
borderBoxRect()
https://bugs.webkit.org/show_bug.cgi?id=318020

Reviewed by Antti Koivisto.

These call sites only read the size of borderBoxRect(); none of them use its
location. borderBoxRect() is { 0, 0, borderBoxSize() }, so constructing the
positioned rect just to call .size()/.width()/.height()/.isEmpty() is wasteful
and hides the intent. Use the direct accessor (borderBoxSize(), 
borderBoxWidth(),
borderBoxHeight()) instead. No behavior change.

* Source/WebCore/rendering/RenderBox.cpp:
(RenderBox::reflectionOffset):
* Source/WebCore/rendering/svg/RenderSVGRoot.cpp:
(RenderSVGRoot::paint):
(RenderSVGRoot::boundingRects):
* Source/WebCore/style/values/transforms/StyleTransformList.cpp:
(Blending<TransformList>::blend):

Canonical link: https://commits.webkit.org/316123@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to