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

Unified Diff: bench/RectBench.cpp

Issue 1832223002: switch xfermodes over to sk_sp (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: rebase Created 4 years, 9 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
« no previous file with comments | « no previous file | bench/Xfer4fBench.cpp » ('j') | include/effects/SkXfermodeImageFilter.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: bench/RectBench.cpp
diff --git a/bench/RectBench.cpp b/bench/RectBench.cpp
index edd5ac7de21d9476d1e67156f8bbcd23b4cb3518..46a515de299705f5c7ce77222057929aee28e5bc 100644
--- a/bench/RectBench.cpp
+++ b/bench/RectBench.cpp
@@ -85,11 +85,7 @@ private:
class SrcModeRectBench : public RectBench {
public:
SrcModeRectBench() : INHERITED(1, 0) {
- fMode = SkXfermode::Create(SkXfermode::kSrc_Mode);
- }
-
- virtual ~SrcModeRectBench() {
- SkSafeUnref(fMode);
+ fMode = SkXfermode::Make(SkXfermode::kSrc_Mode);
}
protected:
@@ -108,7 +104,7 @@ protected:
private:
SkString fName;
- SkXfermode* fMode;
+ sk_sp<SkXfermode> fMode;
typedef RectBench INHERITED;
};
« no previous file with comments | « no previous file | bench/Xfer4fBench.cpp » ('j') | include/effects/SkXfermodeImageFilter.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698