Chromium Code Reviews| Index: skia/ext/skia_utils_mac.h |
| diff --git a/skia/ext/skia_utils_mac.h b/skia/ext/skia_utils_mac.h |
| index d15fa568447482847e8014fd9dd8f34870da020b..44e673f30089fa793aae89776c61319094b3298d 100644 |
| --- a/skia/ext/skia_utils_mac.h |
| +++ b/skia/ext/skia_utils_mac.h |
| @@ -97,8 +97,12 @@ SK_API NSImage* SkBitmapToNSImage(const SkBitmap& icon); |
| // Converts a SkCanvas temporarily to a CGContext |
| class SK_API SkiaBitLocker { |
| public: |
| - // TODO(ccameron): delete this constructor |
| - explicit SkiaBitLocker(SkCanvas* canvas); |
| + /** |
| + User clip rect is an *additional* clip to be applied in addition to the |
| + current state of the canvas, in *local* rather than device coordinates. |
| + If no additional clipping is desired, pass in |
| + SkIRect::MakeSize(canvas->getBaseLayerSize()). |
|
f(malita)
2016/06/08 13:16:54
If the clip is in local coords, then the last part
tomhudson
2016/06/08 14:19:35
Done.
|
| + */ |
| SkiaBitLocker(SkCanvas* canvas, |
| const SkIRect& userClipRect, |
|
f(malita)
2016/06/08 13:27:17
Not new to this CL, but userClipRect should be an
tomhudson
2016/06/08 14:19:36
Blink has always provided an IntRect.
|
| SkScalar bitmapScaleFactor = 1); |
| @@ -112,11 +116,6 @@ class SK_API SkiaBitLocker { |
| SkCanvas* canvas_; |
| - // If the user specified a clip rect it would draw into then the locker may |
| - // skip the step of searching for a rect bounding the pixels that the user |
| - // has drawn into. |
| - bool userClipRectSpecified_; |
| - |
| CGContextRef cgContext_; |
| // offscreen_ is only valid if useDeviceBits_ is false |
| SkBitmap offscreen_; |