Index: include/core/SkXfermode.h |
diff --git a/include/core/SkXfermode.h b/include/core/SkXfermode.h |
index 31b8081f85b0f05a2904f20d9ae22f07900634cd..86c08dd6b7bb43d86731b85def691248a7d515b8 100644 |
--- a/include/core/SkXfermode.h |
+++ b/include/core/SkXfermode.h |
@@ -32,8 +32,6 @@ class SK_API SkXfermode : public SkFlattenable { |
public: |
SK_DECLARE_INST_COUNT(SkXfermode) |
- SkXfermode() {} |
- |
virtual void xfer32(SkPMColor dst[], const SkPMColor src[], int count, |
const SkAlpha aa[]) const; |
virtual void xfer16(uint16_t dst[], const SkPMColor src[], int count, |
@@ -230,6 +228,11 @@ protected: |
*/ |
virtual SkPMColor xferColor(SkPMColor src, SkPMColor dst) const; |
+#ifdef SK_SUPPORT_LEGACY_PUBLICEFFECTCONSTRUCTORS |
+public: |
+#endif |
+ SkXfermode() {} |
+ |
private: |
enum { |
kModeCount = kLastMode + 1 |
@@ -250,7 +253,9 @@ private: |
*/ |
class SkProcXfermode : public SkXfermode { |
public: |
- SkProcXfermode(SkXfermodeProc proc) : fProc(proc) {} |
+ static SkProcXfermode* Create(SkXfermodeProc proc) { |
+ return SkNEW_ARGS(SkProcXfermode, (proc)); |
+ } |
// overrides from SkXfermode |
virtual void xfer32(SkPMColor dst[], const SkPMColor src[], int count, |
@@ -276,6 +281,11 @@ protected: |
return fProc; |
} |
+#ifdef SK_SUPPORT_LEGACY_PUBLICEFFECTCONSTRUCTORS |
+public: |
+#endif |
+ SkProcXfermode(SkXfermodeProc proc) : fProc(proc) {} |
+ |
private: |
SkXfermodeProc fProc; |