Chromium Code Reviews| Index: third_party/WebKit/Source/core/paint/PaintControllerPaintTest.h |
| diff --git a/third_party/WebKit/Source/core/paint/PaintControllerPaintTest.h b/third_party/WebKit/Source/core/paint/PaintControllerPaintTest.h |
| index be331873d0639082719fee4c2b3f251d88263591..cbab772a11f167f78fcb2de452e0b512f29a6fa6 100644 |
| --- a/third_party/WebKit/Source/core/paint/PaintControllerPaintTest.h |
| +++ b/third_party/WebKit/Source/core/paint/PaintControllerPaintTest.h |
| @@ -18,10 +18,17 @@ namespace blink { |
| class PaintControllerPaintTestBase : public RenderingTest { |
| public: |
| PaintControllerPaintTestBase(bool enableSlimmingPaintV2) |
| - : m_originalSlimmingPaintInvalidationEnabled(RuntimeEnabledFeatures::slimmingPaintInvalidationEnabled()) |
| - , m_originalSlimmingPaintV2Enabled(RuntimeEnabledFeatures::slimmingPaintV2Enabled()) |
| + : m_originalSlimmingPaintV2Enabled(RuntimeEnabledFeatures::slimmingPaintV2Enabled()) |
| , m_enableSlimmingPaintV2(enableSlimmingPaintV2) |
| - { } |
| + { |
| + RuntimeEnabledFeatures::setSlimmingPaintV2Enabled(enableSlimmingPaintV2); |
| + } |
| + |
| + ~PaintControllerPaintTestBase() |
| + { |
| + CHECK_EQ(m_enableSlimmingPaintV2, RuntimeEnabledFeatures::slimmingPaintV2Enabled()); |
| + RuntimeEnabledFeatures::setSlimmingPaintV2Enabled(m_originalSlimmingPaintV2Enabled); |
| + } |
| protected: |
| LayoutView& layoutView() { return *document().layoutView(); } |
| @@ -31,12 +38,6 @@ protected: |
| { |
| RenderingTest::SetUp(); |
| enableCompositing(); |
| - RuntimeEnabledFeatures::setSlimmingPaintV2Enabled(m_enableSlimmingPaintV2); |
| - } |
| - void TearDown() override |
| - { |
| - RuntimeEnabledFeatures::setSlimmingPaintInvalidationEnabled(m_originalSlimmingPaintInvalidationEnabled); |
| - RuntimeEnabledFeatures::setSlimmingPaintV2Enabled(m_originalSlimmingPaintV2Enabled); |
| } |
| bool paintWithoutCommit(const IntRect* interestRect = nullptr) |
| @@ -76,7 +77,6 @@ protected: |
| int numCachedNewItems() { return rootPaintController().m_numCachedNewItems; } |
| private: |
| - bool m_originalSlimmingPaintInvalidationEnabled; |
|
esprehn
2016/08/25 23:59:24
is this unrelated, why did this change in this pat
trchen
2016/08/26 00:15:11
Yes, it is a drive-by change.
This flag wasn't to
|
| bool m_originalSlimmingPaintV2Enabled; |
| bool m_enableSlimmingPaintV2; |
| }; |