diff options
author | Ben Wagner <bungeman@google.com> | 2018-07-16 17:44:06 -0400 |
---|---|---|
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | 2018-07-17 21:39:51 +0000 |
commit | d5148e331436b69e3de1a35d4bfa8492e89b3cce (patch) | |
tree | fdf0a1dc5c8347ea75d57b0ed55af835f3a31d40 /modules/sksg | |
parent | 21a99d42c34f44dac4a71cace9572dc244cad583 (diff) |
Move SkNoncopyable to include/private.
Change-Id: I62f60ea52faeebddecacf03d9429ac3f7c516b8e
Reviewed-on: https://skia-review.googlesource.com/141823
Commit-Queue: Ben Wagner <bungeman@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
Diffstat (limited to 'modules/sksg')
-rw-r--r-- | modules/sksg/include/SkSGInvalidationController.h | 6 | ||||
-rw-r--r-- | modules/sksg/include/SkSGScene.h | 13 |
2 files changed, 9 insertions, 10 deletions
diff --git a/modules/sksg/include/SkSGInvalidationController.h b/modules/sksg/include/SkSGInvalidationController.h index df3857c1fe..d6f7bd3019 100644 --- a/modules/sksg/include/SkSGInvalidationController.h +++ b/modules/sksg/include/SkSGInvalidationController.h @@ -21,9 +21,11 @@ namespace sksg { * * Tracks dirty regions for repaint. */ -class InvalidationController : public SkNoncopyable { +class InvalidationController { public: InvalidationController(); + InvalidationController(const InvalidationController&) = delete; + InvalidationController& operator=(const InvalidationController&) = delete; void inval(const SkRect&, const SkMatrix& ctm = SkMatrix::I()); @@ -34,8 +36,6 @@ public: private: SkTDArray<SkRect> fRects; SkRect fBounds; - - typedef SkNoncopyable INHERITED; }; } // namespace sksg diff --git a/modules/sksg/include/SkSGScene.h b/modules/sksg/include/SkSGScene.h index 2081c1d747..95bee3029b 100644 --- a/modules/sksg/include/SkSGScene.h +++ b/modules/sksg/include/SkSGScene.h @@ -24,9 +24,11 @@ class RenderNode; * Base class for animators. * */ -class Animator : public SkNoncopyable { +class Animator { public: virtual ~Animator(); + Animator(const Animator&) = delete; + Animator& operator=(const Animator&) = delete; void tick(float t); @@ -34,9 +36,6 @@ protected: Animator(); virtual void onTick(float t) = 0; - -private: - using INHERITED = SkNoncopyable; }; using AnimatorList = std::vector<std::unique_ptr<Animator>>; @@ -59,10 +58,12 @@ private: * Provides high-level mehods for driving rendering and animations. * */ -class Scene final : SkNoncopyable { +class Scene final { public: static std::unique_ptr<Scene> Make(sk_sp<RenderNode> root, AnimatorList&& animators); ~Scene(); + Scene(const Scene&) = delete; + Scene& operator=(const Scene&) = delete; void render(SkCanvas*) const; void animate(float t); @@ -76,8 +77,6 @@ private: const AnimatorList fAnimators; bool fShowInval = false; - - using INHERITED = SkNoncopyable; }; } // namespace sksg |