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

Side by Side Diff: Source/core/rendering/svg/RenderSVGEllipse.h

Issue 745383007: Fix an issue where hit detection could fail on rect and ellipse shapes (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years 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) 2012 Google, Inc. 2 * Copyright (C) 2012 Google, Inc.
3 * All rights reserved. 3 * All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 28 matching lines...) Expand all
39 virtual ShapeGeometryCodePath geometryCodePath() const override { return m_u sePathFallback ? PathGeometry : EllipseGeometryFastPath; } 39 virtual ShapeGeometryCodePath geometryCodePath() const override { return m_u sePathFallback ? PathGeometry : EllipseGeometryFastPath; }
40 40
41 private: 41 private:
42 virtual const char* renderName() const override { return "RenderSVGEllipse"; } 42 virtual const char* renderName() const override { return "RenderSVGEllipse"; }
43 43
44 virtual void updateShapeFromElement() override; 44 virtual void updateShapeFromElement() override;
45 virtual bool isShapeEmpty() const override { return m_usePathFallback ? Rend erSVGShape::isShapeEmpty() : m_fillBoundingBox.isEmpty(); } 45 virtual bool isShapeEmpty() const override { return m_usePathFallback ? Rend erSVGShape::isShapeEmpty() : m_fillBoundingBox.isEmpty(); }
46 virtual bool shapeDependentStrokeContains(const FloatPoint&) override; 46 virtual bool shapeDependentStrokeContains(const FloatPoint&) override;
47 virtual bool shapeDependentFillContains(const FloatPoint&, const WindRule) c onst override; 47 virtual bool shapeDependentFillContains(const FloatPoint&, const WindRule) c onst override;
48 void calculateRadiiAndCenter(); 48 void calculateRadiiAndCenter();
49 bool hasContinuousStroke() const;
49 50
50 private: 51 private:
51 FloatPoint m_center; 52 FloatPoint m_center;
52 FloatSize m_radii; 53 FloatSize m_radii;
53 bool m_usePathFallback; 54 bool m_usePathFallback;
54 }; 55 };
55 56
56 } 57 }
57 58
58 #endif 59 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698