1 // Copyright 2018 The Chromium Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style license that can be 3 // found in the LICENSE file. 4 5 #ifndef CONTENT_PUBLIC_TEST_SCOPED_OVERSCROLL_MODES_H_ 6 #define CONTENT_PUBLIC_TEST_SCOPED_OVERSCROLL_MODES_H_ 7 8 #include "base/macros.h" 9 #include "content/public/browser/overscroll_configuration.h" 10 11 namespace content { 12 13 // Helper class to set the pull-to-refresh mode temporarily in tests. 14 class ScopedPullToRefreshMode { 15 public: 16 explicit ScopedPullToRefreshMode(OverscrollConfig::PullToRefreshMode mode); 17 ~ScopedPullToRefreshMode(); 18 19 private: 20 DISALLOW_COPY_AND_ASSIGN(ScopedPullToRefreshMode); 21 }; 22 23 } // namespace content 24 25 #endif // CONTENT_PUBLIC_TEST_SCOPED_OVERSCROLL_MODES_H_ 26