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

Unified Diff: content/browser/renderer_host/native_web_keyboard_event_mac.mm

Issue 2387353004: Delay Input.dispatchKeyEvent response until after key event ack. (Closed)
Patch Set: add test, address review comments about docs Created 4 years, 2 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
Index: content/browser/renderer_host/native_web_keyboard_event_mac.mm
diff --git a/content/browser/renderer_host/native_web_keyboard_event_mac.mm b/content/browser/renderer_host/native_web_keyboard_event_mac.mm
index beed79ae54f8d8cffb5bf62f7c262f5b27dc32b0..ee572c48689957a39c3b024c5f9b5a4ad9a5bf0a 100644
--- a/content/browser/renderer_host/native_web_keyboard_event_mac.mm
+++ b/content/browser/renderer_host/native_web_keyboard_event_mac.mm
@@ -13,13 +13,15 @@ namespace content {
NativeWebKeyboardEvent::NativeWebKeyboardEvent()
: os_event(NULL),
- skip_in_browser(false) {
+ skip_in_browser(false),
+ is_synthetic(false) {
}
NativeWebKeyboardEvent::NativeWebKeyboardEvent(gfx::NativeEvent native_event)
: WebKeyboardEvent(WebKeyboardEventBuilder::Build(native_event)),
os_event([native_event retain]),
- skip_in_browser(false) {}
+ skip_in_browser(false),
+ is_synthetic(false) {}
NativeWebKeyboardEvent::NativeWebKeyboardEvent(const ui::KeyEvent& key_event)
: NativeWebKeyboardEvent(key_event.native_event()) {
@@ -29,7 +31,8 @@ NativeWebKeyboardEvent::NativeWebKeyboardEvent(
const NativeWebKeyboardEvent& other)
: WebKeyboardEvent(other),
os_event([other.os_event retain]),
- skip_in_browser(other.skip_in_browser) {
+ skip_in_browser(other.skip_in_browser),
+ is_synthetic(false) {
}
NativeWebKeyboardEvent& NativeWebKeyboardEvent::operator=(
@@ -41,6 +44,7 @@ NativeWebKeyboardEvent& NativeWebKeyboardEvent::operator=(
[previous release];
skip_in_browser = other.skip_in_browser;
+ is_synthetic = other.is_synthetic;
return *this;
}

Powered by Google App Engine
This is Rietveld 408576698