Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(12)

Side by Side Diff: ui/android/overscroll_refresh_unittest.cc

Issue 1419123002: android: move overscroll effects to ui/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix exports for component build Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « ui/android/overscroll_refresh.cc ('k') | ui/android/ui_android.gyp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "cc/layers/layer.h" 5 #include "cc/layers/layer.h"
6 #include "content/browser/android/overscroll_refresh.h"
7 #include "testing/gtest/include/gtest/gtest.h" 6 #include "testing/gtest/include/gtest/gtest.h"
7 #include "ui/android/overscroll_refresh.h"
8 8
9 namespace content { 9 namespace ui {
10 10
11 class OverscrollRefreshTest : public OverscrollRefreshHandler, 11 class OverscrollRefreshTest : public OverscrollRefreshHandler,
12 public testing::Test { 12 public testing::Test {
13 public: 13 public:
14 OverscrollRefreshTest() {} 14 OverscrollRefreshTest() {}
15 15
16 // OverscrollRefreshHandler implementation. 16 // OverscrollRefreshHandler implementation.
17 bool PullStart() override { 17 bool PullStart() override {
18 started_ = true; 18 started_ = true;
19 return true; 19 return true;
(...skipping 211 matching lines...) Expand 10 before | Expand all | Expand 10 after
231 ASSERT_TRUE(effect.IsActive()); 231 ASSERT_TRUE(effect.IsActive());
232 EXPECT_TRUE(GetAndResetPullStarted()); 232 EXPECT_TRUE(GetAndResetPullStarted());
233 233
234 // An early reset should prevent the refresh action from firing. 234 // An early reset should prevent the refresh action from firing.
235 effect.Reset(); 235 effect.Reset();
236 EXPECT_TRUE(GetAndResetPullReset()); 236 EXPECT_TRUE(GetAndResetPullReset());
237 effect.OnScrollEnd(gfx::Vector2dF()); 237 effect.OnScrollEnd(gfx::Vector2dF());
238 EXPECT_FALSE(GetAndResetPullReleased()); 238 EXPECT_FALSE(GetAndResetPullReleased());
239 } 239 }
240 240
241 } // namespace content 241 } // namespace ui
OLDNEW
« no previous file with comments | « ui/android/overscroll_refresh.cc ('k') | ui/android/ui_android.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698