summaryrefslogtreecommitdiffstats
path: root/ui/aura/gestures
diff options
context:
space:
mode:
authorben@chromium.org <ben@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-02-26 01:11:49 +0000
committerben@chromium.org <ben@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-02-26 01:11:49 +0000
commit45d8ab2e5999947afd517625949f93846fb2d0c7 (patch)
treebd7105ba55d3cb8a7407c266d1ef842034ae0ea1 /ui/aura/gestures
parent137e7cd989d44bf12e57bf4d554fd36e3278f68f (diff)
downloadchromium_src-45d8ab2e5999947afd517625949f93846fb2d0c7.zip
chromium_src-45d8ab2e5999947afd517625949f93846fb2d0c7.tar.gz
chromium_src-45d8ab2e5999947afd517625949f93846fb2d0c7.tar.bz2
Remove a bunch more uses of RootWindow::GetInstance()
http://crbug.com/112131 TEST=none Review URL: https://chromiumcodereview.appspot.com/9460025 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@123681 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ui/aura/gestures')
-rw-r--r--ui/aura/gestures/gesture_recognizer_unittest.cc20
1 files changed, 10 insertions, 10 deletions
diff --git a/ui/aura/gestures/gesture_recognizer_unittest.cc b/ui/aura/gestures/gesture_recognizer_unittest.cc
index ffe8e59..b5734fc 100644
--- a/ui/aura/gestures/gesture_recognizer_unittest.cc
+++ b/ui/aura/gestures/gesture_recognizer_unittest.cc
@@ -437,10 +437,10 @@ TEST_F(GestureRecognizerTest, GestureEventLongPress) {
static_cast<TimerTestGestureSequence*>(
gesture_recognizer->GetGestureSequenceForTesting());
- RootWindow::GetInstance()->SetGestureRecognizerForTesting(gesture_recognizer);
+ root_window()->SetGestureRecognizerForTesting(gesture_recognizer);
TouchEvent press1(ui::ET_TOUCH_PRESSED, gfx::Point(101, 201), 0);
- RootWindow::GetInstance()->DispatchTouchEvent(&press1);
+ root_window()->DispatchTouchEvent(&press1);
EXPECT_TRUE(delegate->tap_down());
// We haven't pressed long enough for a long press to occur
@@ -453,7 +453,7 @@ TEST_F(GestureRecognizerTest, GestureEventLongPress) {
delegate->Reset();
TouchEvent release1(ui::ET_TOUCH_RELEASED, gfx::Point(101, 201), 0);
- RootWindow::GetInstance()->DispatchTouchEvent(&release1);
+ root_window()->DispatchTouchEvent(&release1);
EXPECT_FALSE(delegate->long_press());
}
@@ -475,10 +475,10 @@ TEST_F(GestureRecognizerTest, GestureEventLongPressCancelledByScroll) {
static_cast<TimerTestGestureSequence*>(
gesture_recognizer->GetGestureSequenceForTesting());
- RootWindow::GetInstance()->SetGestureRecognizerForTesting(gesture_recognizer);
+ root_window()->SetGestureRecognizerForTesting(gesture_recognizer);
TouchEvent press1(ui::ET_TOUCH_PRESSED, gfx::Point(101, 201), 0);
- RootWindow::GetInstance()->DispatchTouchEvent(&press1);
+ root_window()->DispatchTouchEvent(&press1);
EXPECT_TRUE(delegate->tap_down());
// We haven't pressed long enough for a long press to occur
@@ -492,7 +492,7 @@ TEST_F(GestureRecognizerTest, GestureEventLongPressCancelledByScroll) {
delegate->Reset();
TouchEvent release1(ui::ET_TOUCH_RELEASED, gfx::Point(101, 201), 0);
- RootWindow::GetInstance()->DispatchTouchEvent(&release1);
+ root_window()->DispatchTouchEvent(&release1);
EXPECT_FALSE(delegate->long_press());
}
@@ -512,11 +512,11 @@ TEST_F(GestureRecognizerTest, GestureEventLongPressCancelledByPinch) {
static_cast<TimerTestGestureSequence*>(
gesture_recognizer->GetGestureSequenceForTesting());
- RootWindow::GetInstance()->SetGestureRecognizerForTesting(gesture_recognizer);
+ root_window()->SetGestureRecognizerForTesting(gesture_recognizer);
delegate->Reset();
TouchEvent press(ui::ET_TOUCH_PRESSED, gfx::Point(101, 201), 0);
- RootWindow::GetInstance()->DispatchTouchEvent(&press);
+ root_window()->DispatchTouchEvent(&press);
EXPECT_TRUE(delegate->tap_down());
// We haven't pressed long enough for a long press to occur
@@ -525,7 +525,7 @@ TEST_F(GestureRecognizerTest, GestureEventLongPressCancelledByPinch) {
// Pinch, to cancel the long press
delegate->Reset();
TouchEvent press2(ui::ET_TOUCH_PRESSED, gfx::Point(10, 10), 1);
- RootWindow::GetInstance()->DispatchTouchEvent(&press2);
+ root_window()->DispatchTouchEvent(&press2);
EXPECT_TRUE(delegate->tap_down());
EXPECT_TRUE(delegate->pinch_begin());
@@ -537,7 +537,7 @@ TEST_F(GestureRecognizerTest, GestureEventLongPressCancelledByPinch) {
delegate->Reset();
TouchEvent release1(ui::ET_TOUCH_RELEASED, gfx::Point(101, 201), 0);
- RootWindow::GetInstance()->DispatchTouchEvent(&release1);
+ root_window()->DispatchTouchEvent(&release1);
EXPECT_FALSE(delegate->long_press());
}