Avoid filling a rounded rect when radii are zero
authorsimon.fraser@apple.com <simon.fraser@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 20 Jan 2013 20:36:54 +0000 (20:36 +0000)
committersimon.fraser@apple.com <simon.fraser@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 20 Jan 2013 20:36:54 +0000 (20:36 +0000)
commita037d9ab661f9b3ba474f724f6c4e3b305acd8c2
treec0d7d7ba172a777daa1f0c77875fa9940e82aa68
parent2b6b4ed41c4a381ec25a848c8d3553848b655857
Avoid filling a rounded rect when radii are zero
https://bugs.webkit.org/show_bug.cgi?id=107402
<rdar://problem/12793315>

Reviewed by Sam Weinig.

It's more efficient to clip and fill rects than rounded rects,
so optimize for the case where rounded rect radii are zero.

* platform/graphics/GraphicsContext.cpp:
(WebCore::GraphicsContext::clipRoundedRect):
(WebCore::GraphicsContext::clipOutRoundedRect):
(WebCore::GraphicsContext::fillRoundedRect):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@140279 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebCore/ChangeLog
Source/WebCore/platform/graphics/GraphicsContext.cpp