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

Unified Diff: content/renderer/render_widget.cc

Issue 157003005: Replace std::map with base::SmallMap in ui::LatencyInfo (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 6 years, 9 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/renderer/render_widget.h ('k') | ipc/ipc_message_utils.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/render_widget.cc
diff --git a/content/renderer/render_widget.cc b/content/renderer/render_widget.cc
index 9b0e73eecc46b46fe72c1752703e02c35a135eae..16edbc3a2d89dc5b03951179e38f0f06d5bd6672 100644
--- a/content/renderer/render_widget.cc
+++ b/content/renderer/render_widget.cc
@@ -1037,7 +1037,7 @@ void RenderWidget::OnSwapBuffersComplete() {
}
void RenderWidget::OnHandleInputEvent(const blink::WebInputEvent* input_event,
- ui::LatencyInfo latency_info,
+ const ui::LatencyInfo& latency_info,
bool is_keyboard_shortcut) {
handling_input_event_ = true;
if (!input_event) {
@@ -1056,10 +1056,11 @@ void RenderWidget::OnHandleInputEvent(const blink::WebInputEvent* input_event,
TRACE_EVENT_SYNTHETIC_DELAY_BEGIN("blink.HandleInputEvent");
scoped_ptr<cc::SwapPromiseMonitor> latency_info_swap_promise_monitor;
-
+ ui::LatencyInfo swap_latency_info(latency_info);
if (compositor_) {
latency_info_swap_promise_monitor =
- compositor_->CreateLatencyInfoSwapPromiseMonitor(&latency_info).Pass();
+ compositor_->CreateLatencyInfoSwapPromiseMonitor(&swap_latency_info)
+ .Pass();
} else {
latency_info_.push_back(latency_info);
}
@@ -1169,7 +1170,7 @@ void RenderWidget::OnHandleInputEvent(const blink::WebInputEvent* input_event,
new InputHostMsg_HandleInputEvent_ACK(routing_id_,
input_event->type,
ack_result,
- latency_info));
+ swap_latency_info));
if (rate_limiting_wanted && event_type_can_be_rate_limited &&
frame_pending && !is_hidden_) {
// We want to rate limit the input events in this case, so we'll wait for
« no previous file with comments | « content/renderer/render_widget.h ('k') | ipc/ipc_message_utils.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698