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

Unified Diff: chrome/browser/devtools/devtools_window.cc

Issue 2033403005: Eradicate keyIndentifier from devtools/* (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add keyIdentifier getter/setter if keyIdentifier is not defined Created 4 years, 6 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: chrome/browser/devtools/devtools_window.cc
diff --git a/chrome/browser/devtools/devtools_window.cc b/chrome/browser/devtools/devtools_window.cc
index dc11e77319d3faf25d5ba74e794f85ea2e8526eb..cae11c016eef67209064222661da9da653f30bf2 100644
--- a/chrome/browser/devtools/devtools_window.cc
+++ b/chrome/browser/devtools/devtools_window.cc
@@ -51,6 +51,7 @@
#include "net/base/escape.h"
#include "third_party/WebKit/public/web/WebInputEvent.h"
#include "ui/base/page_transition_types.h"
+#include "ui/events/keycodes/dom/keycode_converter.h"
#include "ui/events/keycodes/keyboard_code_conversion.h"
#include "ui/events/keycodes/keyboard_codes.h"
@@ -273,6 +274,10 @@ bool DevToolsEventForwarder::ForwardEvent(
base::DictionaryValue event_data;
event_data.SetString("type", event_type);
event_data.SetString("keyIdentifier", event.keyIdentifier);
+ event_data.SetString("key", ui::KeycodeConverter::DomKeyToKeyString(
+ static_cast<ui::DomKey>(event.domKey)));
+ event_data.SetString("code", ui::KeycodeConverter::DomCodeToCodeString(
+ static_cast<ui::DomCode>(event.domCode)));
event_data.SetInteger("keyCode", key_code);
event_data.SetInteger("modifiers", modifiers);
devtools_window_->bindings_->CallClientFunction(

Powered by Google App Engine
This is Rietveld 408576698