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

Unified Diff: third_party/WebKit/Source/web/WebInputEvent.cpp

Issue 1945473002: Break dependencies of browser -> blink (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: android filter Created 4 years, 8 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: third_party/WebKit/Source/web/WebInputEvent.cpp
diff --git a/third_party/WebKit/Source/web/WebInputEvent.cpp b/third_party/WebKit/Source/web/WebInputEvent.cpp
index 32d8e045cf4342fcc30e1332cc96fa6ef0a807f8..f56d101b6b0142c4f7b88363b813df7db7b64a7d 100644
--- a/third_party/WebKit/Source/web/WebInputEvent.cpp
+++ b/third_party/WebKit/Source/web/WebInputEvent.cpp
@@ -31,6 +31,7 @@
#include "public/web/WebInputEvent.h"
#include "platform/KeyboardCodes.h"
+#include "wtf/ASCIICType.h"
#include "wtf/Assertions.h"
#include "wtf/StringExtras.h"
#include <ctype.h>
@@ -193,8 +194,9 @@ void WebKeyboardEvent::setKeyIdentifierFromWindowsKeyCode()
if (id) {
strncpy(keyIdentifier, id, sizeof(keyIdentifier) - 1);
keyIdentifier[sizeof(keyIdentifier) - 1] = '\0';
- } else
- snprintf(keyIdentifier, sizeof(keyIdentifier), "U+%04X", toupper(windowsKeyCode));
+ } else {
+ snprintf(keyIdentifier, sizeof(keyIdentifier), "U+%04X", toASCIIUpper(windowsKeyCode));
+ }
}
} // namespace blink

Powered by Google App Engine
This is Rietveld 408576698