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/auto_reset.h" | 7 #include "base/auto_reset.h" |
8 #include "base/bind.h" | 8 #include "base/bind.h" |
9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
10 #include "base/logging.h" | 10 #include "base/logging.h" |
(...skipping 1271 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1282 input_event->type == WebInputEvent::MouseUp)) { | 1282 input_event->type == WebInputEvent::MouseUp)) { |
1283 UpdateTextInputState(SHOW_IME_IF_NEEDED, FROM_IME); | 1283 UpdateTextInputState(SHOW_IME_IF_NEEDED, FROM_IME); |
1284 } | 1284 } |
1285 #endif | 1285 #endif |
1286 | 1286 |
1287 if (!prevent_default) { | 1287 if (!prevent_default) { |
1288 if (WebInputEvent::isKeyboardEventType(input_event->type)) | 1288 if (WebInputEvent::isKeyboardEventType(input_event->type)) |
1289 DidHandleKeyEvent(); | 1289 DidHandleKeyEvent(); |
1290 if (WebInputEvent::isMouseEventType(input_event->type)) | 1290 if (WebInputEvent::isMouseEventType(input_event->type)) |
1291 DidHandleMouseEvent(*(static_cast<const WebMouseEvent*>(input_event))); | 1291 DidHandleMouseEvent(*(static_cast<const WebMouseEvent*>(input_event))); |
1292 if (WebInputEvent::isTouchEventType(input_event->type)) | |
1293 DidHandleTouchEvent(*(static_cast<const WebTouchEvent*>(input_event))); | |
1294 } | 1292 } |
1295 | 1293 |
1296 // TODO(rouslan): Fix ChromeOS and Windows 8 behavior of autofill popup with | 1294 // TODO(rouslan): Fix ChromeOS and Windows 8 behavior of autofill popup with |
1297 // virtual keyboard. | 1295 // virtual keyboard. |
1298 #if !defined(OS_ANDROID) | 1296 #if !defined(OS_ANDROID) |
1299 // Virtual keyboard is not supported, so react to focus change immediately. | 1297 // Virtual keyboard is not supported, so react to focus change immediately. |
1300 if (processed && (input_event->type == WebInputEvent::TouchEnd || | 1298 if (processed && (input_event->type == WebInputEvent::TouchEnd || |
1301 input_event->type == WebInputEvent::MouseUp)) { | 1299 input_event->type == WebInputEvent::MouseUp)) { |
1302 FocusChangeComplete(); | 1300 FocusChangeComplete(); |
1303 } | 1301 } |
(...skipping 1136 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2440 void RenderWidget::RegisterVideoHoleFrame(RenderFrameImpl* frame) { | 2438 void RenderWidget::RegisterVideoHoleFrame(RenderFrameImpl* frame) { |
2441 video_hole_frames_.AddObserver(frame); | 2439 video_hole_frames_.AddObserver(frame); |
2442 } | 2440 } |
2443 | 2441 |
2444 void RenderWidget::UnregisterVideoHoleFrame(RenderFrameImpl* frame) { | 2442 void RenderWidget::UnregisterVideoHoleFrame(RenderFrameImpl* frame) { |
2445 video_hole_frames_.RemoveObserver(frame); | 2443 video_hole_frames_.RemoveObserver(frame); |
2446 } | 2444 } |
2447 #endif // defined(VIDEO_HOLE) | 2445 #endif // defined(VIDEO_HOLE) |
2448 | 2446 |
2449 } // namespace content | 2447 } // namespace content |
OLD | NEW |