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

Side by Side Diff: src/pipe/SkGPipePriv.h

Issue 1316123003: Style Change: SkNEW->new; SkDELETE->delete (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: 2015-08-26 (Wednesday) 15:59:00 EDT 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/pdf/SkPDFTypes.cpp ('k') | src/pipe/SkGPipeRead.cpp » ('j') | 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 8
9 9
10 10
(...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after
172 : fBitmap(bitmap) 172 : fBitmap(bitmap)
173 , fGenID(genID) 173 , fGenID(genID)
174 , fBytesAllocated(0) 174 , fBytesAllocated(0)
175 , fMoreRecentlyUsed(NULL) 175 , fMoreRecentlyUsed(NULL)
176 , fLessRecentlyUsed(NULL) 176 , fLessRecentlyUsed(NULL)
177 , fToBeDrawnCount(toBeDrawnCount) 177 , fToBeDrawnCount(toBeDrawnCount)
178 {} 178 {}
179 179
180 ~BitmapInfo() { 180 ~BitmapInfo() {
181 SkASSERT(0 == fToBeDrawnCount); 181 SkASSERT(0 == fToBeDrawnCount);
182 SkDELETE(fBitmap); 182 delete fBitmap;
183 } 183 }
184 184
185 void addDraws(int drawsToAdd) { 185 void addDraws(int drawsToAdd) {
186 if (0 == fToBeDrawnCount) { 186 if (0 == fToBeDrawnCount) {
187 // The readers will only ever decrement the count, so once the 187 // The readers will only ever decrement the count, so once the
188 // count is zero, the writer will be the only one modifying it, 188 // count is zero, the writer will be the only one modifying it,
189 // so it does not need to be an atomic operation. 189 // so it does not need to be an atomic operation.
190 fToBeDrawnCount = drawsToAdd; 190 fToBeDrawnCount = drawsToAdd;
191 } else { 191 } else {
192 sk_atomic_add(&fToBeDrawnCount, drawsToAdd); 192 sk_atomic_add(&fToBeDrawnCount, drawsToAdd);
(...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after
305 SkASSERT(0 == (op & ~PAINTOPS_OP_MASK)); 305 SkASSERT(0 == (op & ~PAINTOPS_OP_MASK));
306 SkASSERT(0 == (flags & ~PAINTOPS_FLAG_MASK)); 306 SkASSERT(0 == (flags & ~PAINTOPS_FLAG_MASK));
307 SkASSERT(0 == (data & ~PAINTOPS_DATA_MASK)); 307 SkASSERT(0 == (data & ~PAINTOPS_DATA_MASK));
308 308
309 return (op << (PAINTOPS_FLAG_BITS + PAINTOPS_DATA_BITS)) | 309 return (op << (PAINTOPS_FLAG_BITS + PAINTOPS_DATA_BITS)) |
310 (flags << PAINTOPS_DATA_BITS) | 310 (flags << PAINTOPS_DATA_BITS) |
311 data; 311 data;
312 } 312 }
313 313
314 #endif 314 #endif
OLDNEW
« no previous file with comments | « src/pdf/SkPDFTypes.cpp ('k') | src/pipe/SkGPipeRead.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698