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

Side by Side Diff: content/browser/renderer_host/render_widget_host_input_event_router.cc

Issue 2269163002: Remove DumpWithoutCrashing in RouteGestureEvent. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2785
Patch Set: Created 4 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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/browser/renderer_host/render_widget_host_input_event_router.h" 5 #include "content/browser/renderer_host/render_widget_host_input_event_router.h"
6 6
7 #include "base/debug/dump_without_crashing.h"
8 #include "cc/quads/surface_draw_quad.h" 7 #include "cc/quads/surface_draw_quad.h"
9 #include "cc/surfaces/surface_id_allocator.h" 8 #include "cc/surfaces/surface_id_allocator.h"
10 #include "cc/surfaces/surface_manager.h" 9 #include "cc/surfaces/surface_manager.h"
11 #include "content/browser/renderer_host/render_widget_host_view_base.h" 10 #include "content/browser/renderer_host/render_widget_host_view_base.h"
12 #include "content/common/frame_messages.h" 11 #include "content/common/frame_messages.h"
13 #include "third_party/WebKit/public/web/WebInputEvent.h" 12 #include "third_party/WebKit/public/web/WebInputEvent.h"
14 13
15 namespace { 14 namespace {
16 15
17 void TransformEventTouchPositions(blink::WebTouchEvent* event, 16 void TransformEventTouchPositions(blink::WebTouchEvent* event,
(...skipping 266 matching lines...) Expand 10 before | Expand all | Expand 10 after
284 // means the GestureFlingCancel that always comes between ET_GESTURE_BEGIN and 283 // means the GestureFlingCancel that always comes between ET_GESTURE_BEGIN and
285 // GestureTapDown is sent to the previous target, in case it is still in a 284 // GestureTapDown is sent to the previous target, in case it is still in a
286 // fling. 285 // fling.
287 if (event->type == blink::WebInputEvent::GestureTapDown) { 286 if (event->type == blink::WebInputEvent::GestureTapDown) {
288 if (touchscreen_gesture_target_queue_.empty()) { 287 if (touchscreen_gesture_target_queue_.empty()) {
289 LOG(ERROR) << "Gesture sequence start detected with no target available."; 288 LOG(ERROR) << "Gesture sequence start detected with no target available.";
290 // Ignore this gesture sequence as no target is available. 289 // Ignore this gesture sequence as no target is available.
291 // TODO(wjmaclean): this only happens on Windows, and should not happen. 290 // TODO(wjmaclean): this only happens on Windows, and should not happen.
292 // https://crbug.com/595422 291 // https://crbug.com/595422
293 touchscreen_gesture_target_.target = nullptr; 292 touchscreen_gesture_target_.target = nullptr;
294 base::debug::DumpWithoutCrashing();
295 return; 293 return;
296 } 294 }
297 295
298 touchscreen_gesture_target_ = touchscreen_gesture_target_queue_.front(); 296 touchscreen_gesture_target_ = touchscreen_gesture_target_queue_.front();
299 touchscreen_gesture_target_queue_.pop_front(); 297 touchscreen_gesture_target_queue_.pop_front();
300 } 298 }
301 299
302 if (!touchscreen_gesture_target_.target) 300 if (!touchscreen_gesture_target_.target)
303 return; 301 return;
304 302
(...skipping 26 matching lines...) Expand all
331 if (!touchpad_gesture_target_.target) 329 if (!touchpad_gesture_target_.target)
332 return; 330 return;
333 331
334 // TODO(mohsen): Add tests to check event location. 332 // TODO(mohsen): Add tests to check event location.
335 event->x += touchpad_gesture_target_.delta.x(); 333 event->x += touchpad_gesture_target_.delta.x();
336 event->y += touchpad_gesture_target_.delta.y(); 334 event->y += touchpad_gesture_target_.delta.y();
337 touchpad_gesture_target_.target->ProcessGestureEvent(*event, latency); 335 touchpad_gesture_target_.target->ProcessGestureEvent(*event, latency);
338 } 336 }
339 337
340 } // namespace content 338 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698