1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #include "content/public/browser/native_web_keyboard_event.h"
7 #include "content/browser/renderer_host/input/web_input_event_builders_win.h"
9 using WebKit::WebKeyboardEvent;
13 NativeWebKeyboardEvent::NativeWebKeyboardEvent()
14 : skip_in_browser(false) {
15 memset(&os_event, 0, sizeof(os_event));
18 NativeWebKeyboardEvent::NativeWebKeyboardEvent(gfx::NativeEvent native_event)
20 WebKeyboardEventBuilder::Build(native_event.hwnd,
23 native_event.lParam)),
24 os_event(native_event),
25 skip_in_browser(false) {
28 NativeWebKeyboardEvent::NativeWebKeyboardEvent(
29 const NativeWebKeyboardEvent& other)
30 : WebKeyboardEvent(other),
31 os_event(other.os_event),
32 skip_in_browser(other.skip_in_browser) {
35 NativeWebKeyboardEvent& NativeWebKeyboardEvent::operator=(
36 const NativeWebKeyboardEvent& other) {
37 WebKeyboardEvent::operator=(other);
39 os_event = other.os_event;
40 skip_in_browser = other.skip_in_browser;
45 NativeWebKeyboardEvent::~NativeWebKeyboardEvent() {
49 } // namespace content