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

Side by Side Diff: src/effects/SkLayerDrawLooper.cpp

Issue 1361323002: Eliminate some clutter in SkFlattenable (Closed) Base URL: https://chromium.googlesource.com/skia.git@master
Patch Set: Remove unused SkLayerDrawLooper::fTopRec Created 5 years, 3 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 unified diff | Download patch
« no previous file with comments | « src/core/SkFlattenable.cpp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 1
2 /* 2 /*
3 * Copyright 2011 Google Inc. 3 * Copyright 2011 Google Inc.
4 * 4 *
5 * Use of this source code is governed by a BSD-style license that can be 5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file. 6 * found in the LICENSE file.
7 */ 7 */
8 #include "SkCanvas.h" 8 #include "SkCanvas.h"
9 #include "SkColor.h" 9 #include "SkColor.h"
10 #include "SkReadBuffer.h" 10 #include "SkReadBuffer.h"
11 #include "SkWriteBuffer.h" 11 #include "SkWriteBuffer.h"
12 #include "SkLayerDrawLooper.h" 12 #include "SkLayerDrawLooper.h"
13 #include "SkString.h" 13 #include "SkString.h"
14 #include "SkStringUtils.h" 14 #include "SkStringUtils.h"
15 #include "SkUnPreMultiply.h" 15 #include "SkUnPreMultiply.h"
16 16
17 SkLayerDrawLooper::LayerInfo::LayerInfo() { 17 SkLayerDrawLooper::LayerInfo::LayerInfo() {
18 fPaintBits = 0; // ignore our paint fields 18 fPaintBits = 0; // ignore our paint fields
19 fColorMode = SkXfermode::kDst_Mode; // ignore our color 19 fColorMode = SkXfermode::kDst_Mode; // ignore our color
20 fOffset.set(0, 0); 20 fOffset.set(0, 0);
21 fPostTranslate = false; 21 fPostTranslate = false;
22 } 22 }
23 23
24 SkLayerDrawLooper::SkLayerDrawLooper() 24 SkLayerDrawLooper::SkLayerDrawLooper()
25 : fRecs(nullptr), 25 : fRecs(nullptr),
26 fTopRec(nullptr),
27 fCount(0) { 26 fCount(0) {
28 } 27 }
29 28
30 SkLayerDrawLooper::~SkLayerDrawLooper() { 29 SkLayerDrawLooper::~SkLayerDrawLooper() {
31 Rec* rec = fRecs; 30 Rec* rec = fRecs;
32 while (rec) { 31 while (rec) {
33 Rec* next = rec->fNext; 32 Rec* next = rec->fNext;
34 delete rec; 33 delete rec;
35 rec = next; 34 rec = next;
36 } 35 }
(...skipping 312 matching lines...) Expand 10 before | Expand all | Expand 10 after
349 SkLayerDrawLooper* looper = new SkLayerDrawLooper; 348 SkLayerDrawLooper* looper = new SkLayerDrawLooper;
350 looper->fCount = fCount; 349 looper->fCount = fCount;
351 looper->fRecs = fRecs; 350 looper->fRecs = fRecs;
352 351
353 fCount = 0; 352 fCount = 0;
354 fRecs = nullptr; 353 fRecs = nullptr;
355 fTopRec = nullptr; 354 fTopRec = nullptr;
356 355
357 return looper; 356 return looper;
358 } 357 }
OLDNEW
« no previous file with comments | « src/core/SkFlattenable.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698