| 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/browser/renderer_host/render_widget_host_view_win.h" | 5 #include "content/browser/renderer_host/render_widget_host_view_win.h" |
| 6 | 6 |
| 7 #include <dwmapi.h> | 7 #include <dwmapi.h> |
| 8 #include <InputScope.h> | 8 #include <InputScope.h> |
| 9 #include <wtsapi32.h> | 9 #include <wtsapi32.h> |
| 10 #pragma comment(lib, "wtsapi32.lib") | 10 #pragma comment(lib, "wtsapi32.lib") |
| (...skipping 921 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 932 return; | 932 return; |
| 933 | 933 |
| 934 ui::EventResult result = (ack_result == | 934 ui::EventResult result = (ack_result == |
| 935 INPUT_EVENT_ACK_STATE_CONSUMED) ? ui::ER_HANDLED : ui::ER_UNHANDLED; | 935 INPUT_EVENT_ACK_STATE_CONSUMED) ? ui::ER_HANDLED : ui::ER_UNHANDLED; |
| 936 for (ScopedVector<ui::TouchEvent>::iterator iter = events.begin(), | 936 for (ScopedVector<ui::TouchEvent>::iterator iter = events.begin(), |
| 937 end = events.end(); iter != end; ++iter) { | 937 end = events.end(); iter != end; ++iter) { |
| 938 (*iter)->latency()->AddLatencyNumber( | 938 (*iter)->latency()->AddLatencyNumber( |
| 939 ui::INPUT_EVENT_LATENCY_ACKED_COMPONENT, | 939 ui::INPUT_EVENT_LATENCY_ACKED_COMPONENT, |
| 940 static_cast<int64>(ack_result), | 940 static_cast<int64>(ack_result), |
| 941 0); | 941 0); |
| 942 render_widget_host_->ComputeTouchLatency(*((*iter)->latency())); |
| 942 scoped_ptr<ui::GestureRecognizer::Gestures> gestures; | 943 scoped_ptr<ui::GestureRecognizer::Gestures> gestures; |
| 943 gestures.reset(gesture_recognizer_->ProcessTouchEventForGesture( | 944 gestures.reset(gesture_recognizer_->ProcessTouchEventForGesture( |
| 944 *(*iter), result, this)); | 945 *(*iter), result, this)); |
| 945 ProcessGestures(gestures.get()); | 946 ProcessGestures(gestures.get()); |
| 946 } | 947 } |
| 947 } | 948 } |
| 948 | 949 |
| 949 void RenderWidgetHostViewWin::UpdateDesiredTouchMode() { | 950 void RenderWidgetHostViewWin::UpdateDesiredTouchMode() { |
| 950 // Make sure that touch events even make sense. | 951 // Make sure that touch events even make sense. |
| 951 CommandLine* cmdline = CommandLine::ForCurrentProcess(); | 952 CommandLine* cmdline = CommandLine::ForCurrentProcess(); |
| (...skipping 2269 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3221 return new RenderWidgetHostViewWin(widget); | 3222 return new RenderWidgetHostViewWin(widget); |
| 3222 } | 3223 } |
| 3223 | 3224 |
| 3224 // static | 3225 // static |
| 3225 void RenderWidgetHostViewPort::GetDefaultScreenInfo( | 3226 void RenderWidgetHostViewPort::GetDefaultScreenInfo( |
| 3226 WebKit::WebScreenInfo* results) { | 3227 WebKit::WebScreenInfo* results) { |
| 3227 GetScreenInfoForWindow(0, results); | 3228 GetScreenInfoForWindow(0, results); |
| 3228 } | 3229 } |
| 3229 | 3230 |
| 3230 } // namespace content | 3231 } // namespace content |
| OLD | NEW |