diff options
author | reed <reed@google.com> | 2016-03-18 10:00:32 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-03-18 10:00:32 -0700 |
commit | 9fbee18f691a0afed1e38a851048ce06063505ed (patch) | |
tree | cd647dad4bae251bbbadea7fdd85b8a4b22cecc7 /tools/debugger | |
parent | 1195260e22fc2e9c92b435491d4d19108a20df5c (diff) |
switch patheffects over to sk_sp
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1813553005
Review URL: https://codereview.chromium.org/1813553005
Diffstat (limited to 'tools/debugger')
-rw-r--r-- | tools/debugger/SkDrawCommand.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/tools/debugger/SkDrawCommand.cpp b/tools/debugger/SkDrawCommand.cpp index 847254a30f..ab9c9de53c 100644 --- a/tools/debugger/SkDrawCommand.cpp +++ b/tools/debugger/SkDrawCommand.cpp @@ -1106,10 +1106,10 @@ static void extract_json_paint_patheffect(Json::Value& jsonPaint, UrlDataManager SkPaint* target) { if (jsonPaint.isMember(SKDEBUGCANVAS_ATTRIBUTE_PATHEFFECT)) { Json::Value jsonPathEffect = jsonPaint[SKDEBUGCANVAS_ATTRIBUTE_PATHEFFECT]; - SkPathEffect* pathEffect = (SkPathEffect*) load_flattenable(jsonPathEffect, urlDataManager); + sk_sp<SkPathEffect> pathEffect((SkPathEffect*)load_flattenable(jsonPathEffect, + urlDataManager)); if (pathEffect != nullptr) { target->setPathEffect(pathEffect); - pathEffect->unref(); } } } @@ -1329,7 +1329,7 @@ static void extract_json_paint_dashing(Json::Value& jsonPaint, SkPaint* target) intervals[i] = jsonIntervals[i].asFloat(); } SkScalar phase = dash[SKDEBUGCANVAS_ATTRIBUTE_PHASE].asFloat(); - target->setPathEffect(SkDashPathEffect::Create(intervals, count, phase)); + target->setPathEffect(SkDashPathEffect::Make(intervals, count, phase)); sk_free(intervals); } } |