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

Side by Side Diff: content/browser/renderer_host/input/input_router_impl.cc

Issue 140833005: Ensure touch handler state on Android is accurate after preload (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 11 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/input/input_router_impl.h" 5 #include "content/browser/renderer_host/input/input_router_impl.h"
6 6
7 #include "base/auto_reset.h" 7 #include "base/auto_reset.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/metrics/histogram.h" 9 #include "base/metrics/histogram.h"
10 #include "base/strings/string_number_conversions.h" 10 #include "base/strings/string_number_conversions.h"
(...skipping 480 matching lines...) Expand 10 before | Expand all | Expand 10 after
491 SendMoveCaret(next_move_caret_.Pass()); 491 SendMoveCaret(next_move_caret_.Pass());
492 } 492 }
493 493
494 void InputRouterImpl::OnSelectRangeAck() { 494 void InputRouterImpl::OnSelectRangeAck() {
495 select_range_pending_ = false; 495 select_range_pending_ = false;
496 if (next_selection_range_) 496 if (next_selection_range_)
497 SendSelectRange(next_selection_range_.Pass()); 497 SendSelectRange(next_selection_range_.Pass());
498 } 498 }
499 499
500 void InputRouterImpl::OnHasTouchEventHandlers(bool has_handlers) { 500 void InputRouterImpl::OnHasTouchEventHandlers(bool has_handlers) {
501 TRACE_EVENT1("input", "InputRouterImpl::OnHasTouchEventHandlers",
jdduke (slow) 2014/01/16 22:53:05 Is this spammy? If not, this should be fine, other
502 "has_handlers", has_handlers);
503
501 if (has_handlers == touch_event_queue_->has_handlers()) 504 if (has_handlers == touch_event_queue_->has_handlers())
502 return; 505 return;
503 touch_event_queue_->OnHasTouchEventHandlers(has_handlers); 506 touch_event_queue_->OnHasTouchEventHandlers(has_handlers);
504 client_->OnHasTouchEventHandlers(has_handlers); 507 client_->OnHasTouchEventHandlers(has_handlers);
505 } 508 }
506 509
507 void InputRouterImpl::OnSetTouchAction( 510 void InputRouterImpl::OnSetTouchAction(
508 content::TouchAction touch_action) { 511 content::TouchAction touch_action) {
509 // Synthetic touchstart events should get filtered out in RenderWidget. 512 // Synthetic touchstart events should get filtered out in RenderWidget.
510 DCHECK(touch_event_queue_->IsPendingAckTouchStart()); 513 DCHECK(touch_event_queue_->IsPendingAckTouchStart());
(...skipping 207 matching lines...) Expand 10 before | Expand all | Expand 10 after
718 break; 721 break;
719 } 722 }
720 } 723 }
721 724
722 bool InputRouterImpl::IsInOverscrollGesture() const { 725 bool InputRouterImpl::IsInOverscrollGesture() const {
723 OverscrollController* controller = client_->GetOverscrollController(); 726 OverscrollController* controller = client_->GetOverscrollController();
724 return controller && controller->overscroll_mode() != OVERSCROLL_NONE; 727 return controller && controller->overscroll_mode() != OVERSCROLL_NONE;
725 } 728 }
726 729
727 } // namespace content 730 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698