Index: gm/pixelsnap.cpp |
diff --git a/gm/pixelsnap.cpp b/gm/pixelsnap.cpp |
index 1711f5e36d950637bd46c50130f9531d70c0f57e..18fb7b2b7522aefe1b39ff3c9f05287340740654 100644 |
--- a/gm/pixelsnap.cpp |
+++ b/gm/pixelsnap.cpp |
@@ -17,15 +17,15 @@ public: |
protected: |
// kTrans should be even or checkboards wont agree in different test cases. |
- static const int kTrans = 14; |
- static const int kLabelPad = 4; |
+ static constexpr int kTrans = 14; |
+ static constexpr int kLabelPad = 4; |
// The inverse of this value should be a perfect SkScalar. |
- static const int kSubPixelSteps = 8; |
- static const int kLabelTextSize = 9; |
+ static constexpr int kSubPixelSteps = 8; |
+ static constexpr int kLabelTextSize = 9; |
static_assert(kSubPixelSteps < 99, "label_offset_too_small"); |
- static const int kLabelOffsetX = 2 * kLabelTextSize + kLabelPad; |
- static const int kLabelOffsetY = kLabelTextSize + kLabelPad; |
+ static constexpr int kLabelOffsetX = 2 * kLabelTextSize + kLabelPad; |
+ static constexpr int kLabelOffsetY = kLabelTextSize + kLabelPad; |
SkISize onISize() override { |
return SkISize::Make((kSubPixelSteps + 1) * kTrans + kLabelOffsetX + kLabelPad, |