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

Side by Side Diff: content/common/input/gesture_event_stream_validator.cc

Issue 729533003: Remove GestureScrollUpdateWithoutPropagation event (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: remove hard count from the test Created 6 years 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
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 "content/common/input/gesture_event_stream_validator.h" 5 #include "content/common/input/gesture_event_stream_validator.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/strings/stringprintf.h" 8 #include "base/strings/stringprintf.h"
9 #include "content/common/input/web_input_event_traits.h" 9 #include "content/common/input/web_input_event_traits.h"
10 #include "third_party/WebKit/public/web/WebInputEvent.h" 10 #include "third_party/WebKit/public/web/WebInputEvent.h"
(...skipping 19 matching lines...) Expand all
30 } 30 }
31 switch (event.type) { 31 switch (event.type) {
32 case WebInputEvent::GestureScrollBegin: 32 case WebInputEvent::GestureScrollBegin:
33 if (scrolling_) 33 if (scrolling_)
34 error_msg->append("Scroll begin during scroll\n"); 34 error_msg->append("Scroll begin during scroll\n");
35 if (pinching_) 35 if (pinching_)
36 error_msg->append("Scroll begin during pinch\n"); 36 error_msg->append("Scroll begin during pinch\n");
37 scrolling_ = true; 37 scrolling_ = true;
38 break; 38 break;
39 case WebInputEvent::GestureScrollUpdate: 39 case WebInputEvent::GestureScrollUpdate:
40 case WebInputEvent::GestureScrollUpdateWithoutPropagation:
41 if (!scrolling_) 40 if (!scrolling_)
42 error_msg->append("Scroll update outside of scroll\n"); 41 error_msg->append("Scroll update outside of scroll\n");
43 break; 42 break;
44 case WebInputEvent::GestureScrollEnd: 43 case WebInputEvent::GestureScrollEnd:
45 case WebInputEvent::GestureFlingStart: 44 case WebInputEvent::GestureFlingStart:
46 if (!scrolling_) 45 if (!scrolling_)
47 error_msg->append("Scroll end outside of scroll\n"); 46 error_msg->append("Scroll end outside of scroll\n");
48 if (pinching_) 47 if (pinching_)
49 error_msg->append("Ending scroll while pinching\n"); 48 error_msg->append("Ending scroll while pinching\n");
50 scrolling_ = false; 49 scrolling_ = false;
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
87 // preceding TapDown. 86 // preceding TapDown.
88 waiting_for_tap_end_ = false; 87 waiting_for_tap_end_ = false;
89 break; 88 break;
90 default: 89 default:
91 break; 90 break;
92 } 91 }
93 return error_msg->empty(); 92 return error_msg->empty();
94 } 93 }
95 94
96 } // namespace content 95 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/renderer_host/input/input_router_impl_unittest.cc ('k') | content/renderer/input/input_handler_proxy.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698