diff options
author | bungeman <bungeman@google.com> | 2016-02-07 14:37:23 -0800 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-02-07 14:37:23 -0800 |
commit | ccce0e02576100e1baaab6b18d91acaff624753e (patch) | |
tree | d04046132d107c6b6adea55365992279c7a1c591 /include | |
parent | 4e79f334525d722358adc62c0d0b14c38853812d (diff) |
Make SkPaint movable.
This adds a move constructor and move assignment to SkPaint. This
allows elision of atomic increments and decrements on the reference
counted fields.
Review URL: https://codereview.chromium.org/1676843002
Diffstat (limited to 'include')
-rw-r--r-- | include/core/SkPaint.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/core/SkPaint.h b/include/core/SkPaint.h index 51e8848a00..a0def42f12 100644 --- a/include/core/SkPaint.h +++ b/include/core/SkPaint.h @@ -52,9 +52,11 @@ class SK_API SkPaint { public: SkPaint(); SkPaint(const SkPaint& paint); + SkPaint(SkPaint&& paint); ~SkPaint(); SkPaint& operator=(const SkPaint&); + SkPaint& operator=(SkPaint&&); /** operator== may give false negatives: two paints that draw equivalently may return false. It will never give false positives: two paints that |