diff options
author | Hal Canary <halcanary@google.com> | 2018-06-18 15:50:09 -0400 |
---|---|---|
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | 2018-06-20 15:20:11 +0000 |
commit | c36f7e735f0e059bab02405f9c4affc4b1bf7b92 (patch) | |
tree | 1279a20b2f8af12e0839fdeb41769aac4f4ee668 /src/gpu/gl/GrGLGpu.cpp | |
parent | ce6a5dcbb3c8cf9cffeed1f96c19fc8a6c0cf078 (diff) |
SkTypes.h: general cleanup
- SkToBool now inline function.
- SK_Invalid{Gen|Unique}ID, SK_MSecMax now constexpr.
- SkNoncopyable deleted methods marked private.
- Consistant comment style.
Change-Id: I1af6889fdf4274d6d698e8f11b29075dbe39ba12
Reviewed-on: https://skia-review.googlesource.com/135446
Reviewed-by: Cary Clark <caryclark@google.com>
Commit-Queue: Hal Canary <halcanary@google.com>
Diffstat (limited to 'src/gpu/gl/GrGLGpu.cpp')
-rw-r--r-- | src/gpu/gl/GrGLGpu.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/gpu/gl/GrGLGpu.cpp b/src/gpu/gl/GrGLGpu.cpp index 40d1c3bbbb..08bd168368 100644 --- a/src/gpu/gl/GrGLGpu.cpp +++ b/src/gpu/gl/GrGLGpu.cpp @@ -732,7 +732,8 @@ bool GrGLGpu::onTransferPixels(GrTexture* texture, int left, int top, int width, return false; } - if (width <= 0 || width > SK_MaxS32 || height <= 0 || height > SK_MaxS32) { + static_assert(sizeof(int) == sizeof(int32_t), ""); + if (width <= 0 || height <= 0) { return false; } |