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

Side by Side Diff: src/record/SkRecorder.cpp

Issue 249253003: Hide SaveFlags from the public SkCanvas API. (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Suppress the canvas-state GM. Created 6 years, 8 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 | Annotate | Revision Log
« no previous file with comments | « src/record/SkRecordOpts.cpp ('k') | src/record/SkRecords.h » ('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 * Copyright 2014 Google Inc. 2 * Copyright 2014 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #include "SkRecorder.h" 8 #include "SkRecorder.h"
9 #include "SkPicture.h" 9 #include "SkPicture.h"
10 10
(...skipping 177 matching lines...) Expand 10 before | Expand all | Expand 10 after
188 this->copy(vertices, vertexCount), 188 this->copy(vertices, vertexCount),
189 texs ? this->copy(texs, vertexCount) : NULL, 189 texs ? this->copy(texs, vertexCount) : NULL,
190 colors ? this->copy(colors, vertexCount) : NULL, 190 colors ? this->copy(colors, vertexCount) : NULL,
191 xmode, 191 xmode,
192 this->copy(indices, indexCount), 192 this->copy(indices, indexCount),
193 indexCount, 193 indexCount,
194 delay_copy(paint)); 194 delay_copy(paint));
195 } 195 }
196 196
197 void SkRecorder::willSave(SkCanvas::SaveFlags flags) { 197 void SkRecorder::willSave(SkCanvas::SaveFlags flags) {
198 APPEND(Save, flags); 198 APPEND(Save
199 #ifdef SK_SUPPORT_LEGACY_SAVEFLAGS
200 , flags
201 #endif
202 );
199 INHERITED(willSave, flags); 203 INHERITED(willSave, flags);
200 } 204 }
201 205
202 SkCanvas::SaveLayerStrategy SkRecorder::willSaveLayer(const SkRect* bounds, 206 SkCanvas::SaveLayerStrategy SkRecorder::willSaveLayer(const SkRect* bounds,
203 const SkPaint* paint, 207 const SkPaint* paint,
204 SkCanvas::SaveFlags flags) { 208 SkCanvas::SaveFlags flags) {
205 APPEND(SaveLayer, this->copy(bounds), this->copy(paint), flags); 209 APPEND(SaveLayer, this->copy(bounds), this->copy(paint)
210 #ifdef SK_SUPPORT_LEGACY_SAVEFLAGS
211 , flags
212 #endif
213 );
206 INHERITED(willSaveLayer, bounds, paint, flags); 214 INHERITED(willSaveLayer, bounds, paint, flags);
207 return SkCanvas::kNoLayer_SaveLayerStrategy; 215 return SkCanvas::kNoLayer_SaveLayerStrategy;
208 } 216 }
209 217
210 void SkRecorder::willRestore() { 218 void SkRecorder::willRestore() {
211 APPEND(Restore); 219 APPEND(Restore);
212 INHERITED(willRestore); 220 INHERITED(willRestore);
213 } 221 }
214 222
215 void SkRecorder::onPushCull(const SkRect& rect) { 223 void SkRecorder::onPushCull(const SkRect& rect) {
(...skipping 26 matching lines...) Expand all
242 250
243 void SkRecorder::onClipPath(const SkPath& path, SkRegion::Op op, ClipEdgeStyle e dgeStyle) { 251 void SkRecorder::onClipPath(const SkPath& path, SkRegion::Op op, ClipEdgeStyle e dgeStyle) {
244 APPEND(ClipPath, delay_copy(path), op, edgeStyle == kSoft_ClipEdgeStyle); 252 APPEND(ClipPath, delay_copy(path), op, edgeStyle == kSoft_ClipEdgeStyle);
245 INHERITED(updateClipConservativelyUsingBounds, path.getBounds(), op, path.is InverseFillType()); 253 INHERITED(updateClipConservativelyUsingBounds, path.getBounds(), op, path.is InverseFillType());
246 } 254 }
247 255
248 void SkRecorder::onClipRegion(const SkRegion& deviceRgn, SkRegion::Op op) { 256 void SkRecorder::onClipRegion(const SkRegion& deviceRgn, SkRegion::Op op) {
249 APPEND(ClipRegion, delay_copy(deviceRgn), op); 257 APPEND(ClipRegion, delay_copy(deviceRgn), op);
250 INHERITED(onClipRegion, deviceRgn, op); 258 INHERITED(onClipRegion, deviceRgn, op);
251 } 259 }
OLDNEW
« no previous file with comments | « src/record/SkRecordOpts.cpp ('k') | src/record/SkRecords.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698