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

Side by Side Diff: third_party/WebKit/Source/core/layout/svg/LayoutSVGShape.cpp

Issue 2181953004: Changed ComputedStyle's EVisibility to be an enum class and fixed naming (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@_move_computedstyle_around
Patch Set: Rebase Created 4 years, 4 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2004, 2005, 2007 Nikolas Zimmermann <zimmermann@kde.org> 2 * Copyright (C) 2004, 2005, 2007 Nikolas Zimmermann <zimmermann@kde.org>
3 * Copyright (C) 2004, 2005, 2008 Rob Buis <buis@kde.org> 3 * Copyright (C) 2004, 2005, 2008 Rob Buis <buis@kde.org>
4 * Copyright (C) 2005, 2007 Eric Seidel <eric@webkit.org> 4 * Copyright (C) 2005, 2007 Eric Seidel <eric@webkit.org>
5 * Copyright (C) 2009 Google, Inc. 5 * Copyright (C) 2009 Google, Inc.
6 * Copyright (C) 2009 Dirk Schulze <krit@webkit.org> 6 * Copyright (C) 2009 Dirk Schulze <krit@webkit.org>
7 * Copyright (C) Research In Motion Limited 2010. All rights reserved. 7 * Copyright (C) Research In Motion Limited 2010. All rights reserved.
8 * Copyright (C) 2009 Jeff Schiller <codedread@gmail.com> 8 * Copyright (C) 2009 Jeff Schiller <codedread@gmail.com>
9 * Copyright (C) 2011 Renata Hodovan <reni@webkit.org> 9 * Copyright (C) 2011 Renata Hodovan <reni@webkit.org>
10 * Copyright (C) 2011 University of Szeged 10 * Copyright (C) 2011 University of Szeged
(...skipping 232 matching lines...) Expand 10 before | Expand all | Expand 10 after
243 updateHitTestResult(result, localLayoutPoint); 243 updateHitTestResult(result, localLayoutPoint);
244 if (result.addNodeToListBasedTestResult(element(), localLayoutPoint) == StopHitTesting) 244 if (result.addNodeToListBasedTestResult(element(), localLayoutPoint) == StopHitTesting)
245 return true; 245 return true;
246 } 246 }
247 247
248 return false; 248 return false;
249 } 249 }
250 250
251 bool LayoutSVGShape::nodeAtFloatPointInternal(const HitTestRequest& request, con st FloatPoint& localPoint, PointerEventsHitRules hitRules) 251 bool LayoutSVGShape::nodeAtFloatPointInternal(const HitTestRequest& request, con st FloatPoint& localPoint, PointerEventsHitRules hitRules)
252 { 252 {
253 bool isVisible = (style()->visibility() == VISIBLE); 253 bool isVisible = (style()->visibility() == EVisibility::Visible);
254 if (isVisible || !hitRules.requireVisible) { 254 if (isVisible || !hitRules.requireVisible) {
255 const SVGComputedStyle& svgStyle = style()->svgStyle(); 255 const SVGComputedStyle& svgStyle = style()->svgStyle();
256 WindRule fillRule = svgStyle.fillRule(); 256 WindRule fillRule = svgStyle.fillRule();
257 if (request.svgClipContent()) 257 if (request.svgClipContent())
258 fillRule = svgStyle.clipRule(); 258 fillRule = svgStyle.clipRule();
259 if ((hitRules.canHitBoundingBox && objectBoundingBox().contains(localPoi nt)) 259 if ((hitRules.canHitBoundingBox && objectBoundingBox().contains(localPoi nt))
260 || (hitRules.canHitStroke && (svgStyle.hasStroke() || !hitRules.requ ireStroke) && strokeContains(localPoint, hitRules.requireStroke)) 260 || (hitRules.canHitStroke && (svgStyle.hasStroke() || !hitRules.requ ireStroke) && strokeContains(localPoint, hitRules.requireStroke))
261 || (hitRules.canHitFill && (svgStyle.hasFill() || !hitRules.requireF ill) && fillContains(localPoint, hitRules.requireFill, fillRule))) 261 || (hitRules.canHitFill && (svgStyle.hasFill() || !hitRules.requireF ill) && fillContains(localPoint, hitRules.requireFill, fillRule)))
262 return true; 262 return true;
263 } 263 }
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
300 } 300 }
301 301
302 LayoutSVGShapeRareData& LayoutSVGShape::ensureRareData() const 302 LayoutSVGShapeRareData& LayoutSVGShape::ensureRareData() const
303 { 303 {
304 if (!m_rareData) 304 if (!m_rareData)
305 m_rareData = wrapUnique(new LayoutSVGShapeRareData()); 305 m_rareData = wrapUnique(new LayoutSVGShapeRareData());
306 return *m_rareData.get(); 306 return *m_rareData.get();
307 } 307 }
308 308
309 } // namespace blink 309 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698