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

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

Issue 134683004: Disabled pinch zooming in non-browser Aura windows. (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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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_impl.h" 5 #include "content/browser/renderer_host/render_widget_host_impl.h"
6 6
7 #include <math.h> 7 #include <math.h>
8 #include <set> 8 #include <set>
9 #include <utility> 9 #include <utility>
10 10
(...skipping 959 matching lines...) Expand 10 before | Expand all | Expand 10 after
970 } 970 }
971 971
972 void RenderWidgetHostImpl::ForwardGestureEventWithLatencyInfo( 972 void RenderWidgetHostImpl::ForwardGestureEventWithLatencyInfo(
973 const blink::WebGestureEvent& gesture_event, 973 const blink::WebGestureEvent& gesture_event,
974 const ui::LatencyInfo& ui_latency) { 974 const ui::LatencyInfo& ui_latency) {
975 TRACE_EVENT0("input", "RenderWidgetHostImpl::ForwardGestureEvent"); 975 TRACE_EVENT0("input", "RenderWidgetHostImpl::ForwardGestureEvent");
976 // Early out if necessary, prior to performing latency logic. 976 // Early out if necessary, prior to performing latency logic.
977 if (IgnoreInputEvents()) 977 if (IgnoreInputEvents())
978 return; 978 return;
979 979
980 if (delegate_->PreHandleGestureEvent(gesture_event))
981 return;
982
980 ui::LatencyInfo latency_info = 983 ui::LatencyInfo latency_info =
981 CreateRWHLatencyInfoIfNotExist(&ui_latency, gesture_event.type); 984 CreateRWHLatencyInfoIfNotExist(&ui_latency, gesture_event.type);
982 985
983 if (gesture_event.type == blink::WebInputEvent::GestureScrollUpdate) { 986 if (gesture_event.type == blink::WebInputEvent::GestureScrollUpdate) {
984 latency_info.AddLatencyNumber( 987 latency_info.AddLatencyNumber(
985 ui::INPUT_EVENT_LATENCY_SCROLL_UPDATE_RWH_COMPONENT, 988 ui::INPUT_EVENT_LATENCY_SCROLL_UPDATE_RWH_COMPONENT,
986 GetLatencyComponentId(), 989 GetLatencyComponentId(),
987 ++last_input_number_); 990 ++last_input_number_);
988 991
989 // Make a copy of the INPUT_EVENT_LATENCY_ORIGINAL_COMPONENT with a 992 // Make a copy of the INPUT_EVENT_LATENCY_ORIGINAL_COMPONENT with a
(...skipping 1478 matching lines...) Expand 10 before | Expand all | Expand 10 after
2468 continue; 2471 continue;
2469 } 2472 }
2470 RenderWidgetHostImpl* rwhi = RenderWidgetHostImpl::From(rwh); 2473 RenderWidgetHostImpl* rwhi = RenderWidgetHostImpl::From(rwh);
2471 if (rwhi_set.insert(rwhi).second) 2474 if (rwhi_set.insert(rwhi).second)
2472 rwhi->FrameSwapped(latency_info); 2475 rwhi->FrameSwapped(latency_info);
2473 } 2476 }
2474 } 2477 }
2475 } 2478 }
2476 2479
2477 } // namespace content 2480 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698