Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1170)

Unified Diff: Source/core/rendering/svg/RenderSVGText.cpp

Issue 411613002: [SVG] Reject hit-test queries when the element has a singular transform (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/rendering/svg/RenderSVGShape.cpp ('k') | Source/core/rendering/svg/SVGRenderSupport.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/rendering/svg/RenderSVGText.cpp
diff --git a/Source/core/rendering/svg/RenderSVGText.cpp b/Source/core/rendering/svg/RenderSVGText.cpp
index 23d7ecb23fa5fc0e3e94e018a8fce3e331da01dd..1a8cc11e0d637a78f294ee0b17ab847f5d0532bd 100644
--- a/Source/core/rendering/svg/RenderSVGText.cpp
+++ b/Source/core/rendering/svg/RenderSVGText.cpp
@@ -429,10 +429,10 @@ bool RenderSVGText::nodeAtFloatPoint(const HitTestRequest& request, HitTestResul
if ((hitRules.canHitBoundingBox && !objectBoundingBox().isEmpty())
|| (hitRules.canHitStroke && (style()->svgStyle().hasStroke() || !hitRules.requireStroke))
|| (hitRules.canHitFill && (style()->svgStyle().hasFill() || !hitRules.requireFill))) {
- FloatPoint localPoint = localToParentTransform().inverse().mapPoint(pointInParent);
-
- if (!SVGRenderSupport::pointInClippingArea(this, localPoint))
+ FloatPoint localPoint;
+ if (!SVGRenderSupport::transformToUserSpaceAndCheckClipping(this, localToParentTransform(), pointInParent, localPoint))
return false;
+
if (hitRules.canHitBoundingBox && !objectBoundingBox().contains(localPoint))
return false;
« no previous file with comments | « Source/core/rendering/svg/RenderSVGShape.cpp ('k') | Source/core/rendering/svg/SVGRenderSupport.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698