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

Unified Diff: ui/aura/window_unittest.cc

Issue 393953012: Eager Gesture Recognition on Aura (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase. Created 6 years, 4 months 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/aura/window_event_dispatcher_unittest.cc ('k') | ui/events/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/aura/window_unittest.cc
diff --git a/ui/aura/window_unittest.cc b/ui/aura/window_unittest.cc
index 69f7ff93611e28f05af6965891538a6becbc2507..600dcaffb38618ec45e2bf494ab67936f2207b60 100644
--- a/ui/aura/window_unittest.cc
+++ b/ui/aura/window_unittest.cc
@@ -828,9 +828,9 @@ TEST_F(WindowTest, TouchCaptureCancelsOtherTouches) {
&delegate2, 0, gfx::Rect(50, 50, 50, 50), root_window()));
// Press on w1.
- ui::TouchEvent press(
+ ui::TouchEvent press1(
ui::ET_TOUCH_PRESSED, gfx::Point(10, 10), 0, getTime());
- DispatchEventUsingWindowDispatcher(&press);
+ DispatchEventUsingWindowDispatcher(&press1);
// We will get both GESTURE_BEGIN and GESTURE_TAP_DOWN.
EXPECT_EQ(2, delegate1.gesture_event_count());
delegate1.ResetCounts();
@@ -842,13 +842,13 @@ TEST_F(WindowTest, TouchCaptureCancelsOtherTouches) {
delegate1.ResetCounts();
delegate2.ResetCounts();
- // Events now go to w2.
+ // Events are ignored by w2, as it's receiving a partial touch stream.
ui::TouchEvent move(ui::ET_TOUCH_MOVED, gfx::Point(10, 20), 0, getTime());
DispatchEventUsingWindowDispatcher(&move);
EXPECT_EQ(0, delegate1.gesture_event_count());
EXPECT_EQ(0, delegate1.touch_event_count());
EXPECT_EQ(0, delegate2.gesture_event_count());
- EXPECT_EQ(1, delegate2.touch_event_count());
+ EXPECT_EQ(0, delegate2.touch_event_count());
ui::TouchEvent release(
ui::ET_TOUCH_RELEASED, gfx::Point(10, 20), 0, getTime());
« no previous file with comments | « ui/aura/window_event_dispatcher_unittest.cc ('k') | ui/events/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698