OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2012 Google Inc. | 2 * Copyright 2012 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 "SkBlurImageFilter.h" | 8 #include "SkBlurImageFilter.h" |
9 #include "SkCanvas.h" | 9 #include "SkCanvas.h" |
10 #include "SkColorPriv.h" | 10 #include "SkColorPriv.h" |
(...skipping 915 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
926 , fSaveLayerCount(0) | 926 , fSaveLayerCount(0) |
927 , fRestoreCount(0){ | 927 , fRestoreCount(0){ |
928 } | 928 } |
929 | 929 |
930 virtual SaveLayerStrategy willSaveLayer(const SkRect* bounds, const SkPaint*
paint, | 930 virtual SaveLayerStrategy willSaveLayer(const SkRect* bounds, const SkPaint*
paint, |
931 SaveFlags flags) SK_OVERRIDE { | 931 SaveFlags flags) SK_OVERRIDE { |
932 ++fSaveLayerCount; | 932 ++fSaveLayerCount; |
933 return this->INHERITED::willSaveLayer(bounds, paint, flags); | 933 return this->INHERITED::willSaveLayer(bounds, paint, flags); |
934 } | 934 } |
935 | 935 |
936 virtual void willSave(SaveFlags flags) SK_OVERRIDE { | 936 virtual void willSave() SK_OVERRIDE { |
937 ++fSaveCount; | 937 ++fSaveCount; |
938 this->INHERITED::willSave(flags); | 938 this->INHERITED::willSave(); |
939 } | 939 } |
940 | 940 |
941 virtual void willRestore() SK_OVERRIDE { | 941 virtual void willRestore() SK_OVERRIDE { |
942 ++fRestoreCount; | 942 ++fRestoreCount; |
943 this->INHERITED::willRestore(); | 943 this->INHERITED::willRestore(); |
944 } | 944 } |
945 | 945 |
946 unsigned int getSaveCount() const { return fSaveCount; } | 946 unsigned int getSaveCount() const { return fSaveCount; } |
947 unsigned int getSaveLayerCount() const { return fSaveLayerCount; } | 947 unsigned int getSaveLayerCount() const { return fSaveLayerCount; } |
948 unsigned int getRestoreCount() const { return fRestoreCount; } | 948 unsigned int getRestoreCount() const { return fRestoreCount; } |
(...skipping 650 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1599 SkAutoTUnref<SkPicture> picture(recorder.endRecording()); | 1599 SkAutoTUnref<SkPicture> picture(recorder.endRecording()); |
1600 } | 1600 } |
1601 | 1601 |
1602 DEF_TEST(Canvas_EmptyBitmap, r) { | 1602 DEF_TEST(Canvas_EmptyBitmap, r) { |
1603 SkBitmap dst; | 1603 SkBitmap dst; |
1604 dst.allocN32Pixels(10, 10); | 1604 dst.allocN32Pixels(10, 10); |
1605 SkCanvas canvas(dst); | 1605 SkCanvas canvas(dst); |
1606 | 1606 |
1607 test_draw_bitmaps(&canvas); | 1607 test_draw_bitmaps(&canvas); |
1608 } | 1608 } |
OLD | NEW |