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

Unified Diff: third_party/WebKit/Source/core/paint/ClipPathClipper.h

Issue 2322343003: Add support for <basic-shape> to 'clip-path' on SVG elements (Closed)
Patch Set: Update SPv2 expectations Created 4 years, 3 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
Index: third_party/WebKit/Source/core/paint/ClipPathClipper.h
diff --git a/third_party/WebKit/Source/core/paint/ClipPathClipper.h b/third_party/WebKit/Source/core/paint/ClipPathClipper.h
index 37c640102ac41bf3a8d25d5cb76dbf9dc34344c6..cb445a1c0757a2de6e6fe42d8be9cfc56166735e 100644
--- a/third_party/WebKit/Source/core/paint/ClipPathClipper.h
+++ b/third_party/WebKit/Source/core/paint/ClipPathClipper.h
@@ -5,32 +5,41 @@
#ifndef ClipPathClipper_h
#define ClipPathClipper_h
-#include "core/paint/SVGClipPainter.h"
#include "platform/graphics/paint/ClipPathRecorder.h"
#include "wtf/Optional.h"
namespace blink {
+class ClipPathOperation;
class FloatPoint;
class FloatRect;
class GraphicsContext;
class LayoutSVGResourceClipper;
class LayoutObject;
+enum class ClipperState {
+ NotApplied,
+ AppliedPath,
+ AppliedMask
+};
+
class ClipPathClipper {
DISALLOW_NEW_EXCEPT_PLACEMENT_NEW();
public:
ClipPathClipper(
GraphicsContext&,
+ ClipPathOperation&,
const LayoutObject&,
const FloatRect& referenceBox,
const FloatPoint& origin);
~ClipPathClipper();
+ bool usingMask() const { return m_clipperState == ClipperState::AppliedMask; }
+
private:
LayoutSVGResourceClipper* m_resourceClipper;
Optional<ClipPathRecorder> m_clipPathRecorder;
- SVGClipPainter::ClipperState m_clipperState;
+ ClipperState m_clipperState;
const LayoutObject& m_layoutObject;
GraphicsContext& m_context;
};
« no previous file with comments | « third_party/WebKit/Source/core/layout/svg/SVGResources.cpp ('k') | third_party/WebKit/Source/core/paint/ClipPathClipper.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698