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

Side by Side Diff: src/utils/debugger/SkDebugCanvas.cpp

Issue 174593003: override new virtual onDrawDRRect in util canvas subclasses (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 6 years, 10 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/utils/debugger/SkDebugCanvas.h ('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 2012 Google Inc. 3 * Copyright 2012 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 #include "SkColorPriv.h" 10 #include "SkColorPriv.h"
(...skipping 383 matching lines...) Expand 10 before | Expand all | Expand 10 after
394 394
395 void SkDebugCanvas::drawRect(const SkRect& rect, const SkPaint& paint) { 395 void SkDebugCanvas::drawRect(const SkRect& rect, const SkPaint& paint) {
396 // NOTE(chudy): Messing up when renamed to DrawRect... Why? 396 // NOTE(chudy): Messing up when renamed to DrawRect... Why?
397 addDrawCommand(new SkDrawRectCommand(rect, paint)); 397 addDrawCommand(new SkDrawRectCommand(rect, paint));
398 } 398 }
399 399
400 void SkDebugCanvas::drawRRect(const SkRRect& rrect, const SkPaint& paint) { 400 void SkDebugCanvas::drawRRect(const SkRRect& rrect, const SkPaint& paint) {
401 addDrawCommand(new SkDrawRRectCommand(rrect, paint)); 401 addDrawCommand(new SkDrawRRectCommand(rrect, paint));
402 } 402 }
403 403
404 void SkDebugCanvas::onDrawDRRect(const SkRRect& outer, const SkRRect& inner,
405 const SkPaint& paint) {
406 // TODO: add DRRect to debugger
407 }
408
404 void SkDebugCanvas::drawSprite(const SkBitmap& bitmap, int left, int top, 409 void SkDebugCanvas::drawSprite(const SkBitmap& bitmap, int left, int top,
405 const SkPaint* paint = NULL) { 410 const SkPaint* paint = NULL) {
406 addDrawCommand(new SkDrawSpriteCommand(bitmap, left, top, paint)); 411 addDrawCommand(new SkDrawSpriteCommand(bitmap, left, top, paint));
407 } 412 }
408 413
409 void SkDebugCanvas::drawText(const void* text, size_t byteLength, SkScalar x, 414 void SkDebugCanvas::drawText(const void* text, size_t byteLength, SkScalar x,
410 SkScalar y, const SkPaint& paint) { 415 SkScalar y, const SkPaint& paint) {
411 addDrawCommand(new SkDrawTextCommand(text, byteLength, x, y, paint)); 416 addDrawCommand(new SkDrawTextCommand(text, byteLength, x, y, paint));
412 } 417 }
413 418
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
461 466
462 bool SkDebugCanvas::translate(SkScalar dx, SkScalar dy) { 467 bool SkDebugCanvas::translate(SkScalar dx, SkScalar dy) {
463 addDrawCommand(new SkTranslateCommand(dx, dy)); 468 addDrawCommand(new SkTranslateCommand(dx, dy));
464 return true; 469 return true;
465 } 470 }
466 471
467 void SkDebugCanvas::toggleCommand(int index, bool toggle) { 472 void SkDebugCanvas::toggleCommand(int index, bool toggle) {
468 SkASSERT(index < fCommandVector.count()); 473 SkASSERT(index < fCommandVector.count());
469 fCommandVector[index]->setVisible(toggle); 474 fCommandVector[index]->setVisible(toggle);
470 } 475 }
OLDNEW
« no previous file with comments | « src/utils/debugger/SkDebugCanvas.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698