Chromium Code Reviews| OLD | NEW |
|---|---|
| 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/renderer/render_widget.h" | 5 #include "content/renderer/render_widget.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
| 9 #include "base/debug/trace_event.h" | 9 #include "base/debug/trace_event.h" |
| 10 #include "base/logging.h" | 10 #include "base/logging.h" |
| (...skipping 770 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 781 return; | 781 return; |
| 782 } | 782 } |
| 783 | 783 |
| 784 // Continue painting if necessary... | 784 // Continue painting if necessary... |
| 785 DoDeferredUpdateAndSendInputAck(); | 785 DoDeferredUpdateAndSendInputAck(); |
| 786 } | 786 } |
| 787 | 787 |
| 788 void RenderWidget::OnHandleInputEvent(const WebKit::WebInputEvent* input_event, | 788 void RenderWidget::OnHandleInputEvent(const WebKit::WebInputEvent* input_event, |
| 789 const ui::LatencyInfo& latency_info, | 789 const ui::LatencyInfo& latency_info, |
| 790 bool is_keyboard_shortcut) { | 790 bool is_keyboard_shortcut) { |
| 791 const_cast<ui::LatencyInfo&>(latency_info).AddLatencyNumber( | |
|
nduca
2013/08/15 01:41:04
hmmm remember how we talked about fixing the way i
| |
| 792 ui::INPUT_EVENT_LATENCY_EVENT_RECEIVED_ON_MAIN_THREAD_COMPONENT, | |
| 793 routing_id(), 0); | |
| 794 | |
| 791 handling_input_event_ = true; | 795 handling_input_event_ = true; |
| 792 if (!input_event) { | 796 if (!input_event) { |
| 793 handling_input_event_ = false; | 797 handling_input_event_ = false; |
| 794 return; | 798 return; |
| 795 } | 799 } |
| 796 | 800 |
| 797 const char* const event_name = GetEventName(input_event->type); | 801 const char* const event_name = GetEventName(input_event->type); |
| 798 TRACE_EVENT1("renderer", "RenderWidget::OnHandleInputEvent", | 802 TRACE_EVENT1("renderer", "RenderWidget::OnHandleInputEvent", |
| 799 "event", event_name); | 803 "event", event_name); |
| 800 | 804 |
| (...skipping 1721 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 2522 | 2526 |
| 2523 if (!context->InitializeWithDefaultBufferSizes( | 2527 if (!context->InitializeWithDefaultBufferSizes( |
| 2524 attributes, | 2528 attributes, |
| 2525 false /* bind generates resources */, | 2529 false /* bind generates resources */, |
| 2526 CAUSE_FOR_GPU_LAUNCH_WEBGRAPHICSCONTEXT3DCOMMANDBUFFERIMPL_INITIALIZE) ) | 2530 CAUSE_FOR_GPU_LAUNCH_WEBGRAPHICSCONTEXT3DCOMMANDBUFFERIMPL_INITIALIZE) ) |
| 2527 return NULL; | 2531 return NULL; |
| 2528 return context.release(); | 2532 return context.release(); |
| 2529 } | 2533 } |
| 2530 | 2534 |
| 2531 } // namespace content | 2535 } // namespace content |
| OLD | NEW |