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

Unified Diff: content/browser/renderer_host/input/touch_event_queue_unittest.cc

Issue 569793003: Remove unnecessary DCHECK in TouchEventQueue handler notification (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 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 | « content/browser/renderer_host/input/touch_event_queue.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/renderer_host/input/touch_event_queue_unittest.cc
diff --git a/content/browser/renderer_host/input/touch_event_queue_unittest.cc b/content/browser/renderer_host/input/touch_event_queue_unittest.cc
index 2ba5475de29d08aafefc9d7d423be76bca6c2077..ed4f8695fb5833987bbefadbeb51774de5ae5faa 100644
--- a/content/browser/renderer_host/input/touch_event_queue_unittest.cc
+++ b/content/browser/renderer_host/input/touch_event_queue_unittest.cc
@@ -388,6 +388,15 @@ TEST_F(TouchEventQueueTest, ActiveSequenceDroppedWhenHandlersRemoved) {
EXPECT_EQ(0U, GetAndResetAckedEventCount());
EXPECT_EQ(2U, queued_event_count());
+ // Repeated registration/unregstration of handlers should have no effect as
+ // we're still awaiting the ack arrival.
+ OnHasTouchEventHandlers(true);
+ EXPECT_EQ(0U, GetAndResetAckedEventCount());
+ EXPECT_EQ(2U, queued_event_count());
+ OnHasTouchEventHandlers(false);
+ EXPECT_EQ(0U, GetAndResetAckedEventCount());
+ EXPECT_EQ(2U, queued_event_count());
+
// The ack should be flush the queue.
SendTouchEventAck(INPUT_EVENT_ACK_STATE_NO_CONSUMER_EXISTS);
EXPECT_EQ(2U, GetAndResetAckedEventCount());
« no previous file with comments | « content/browser/renderer_host/input/touch_event_queue.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698