Index: chrome/test/chromedriver/keycode_text_conversion_ozone.cc |
diff --git a/chrome/test/chromedriver/keycode_text_conversion_ozone.cc b/chrome/test/chromedriver/keycode_text_conversion_ozone.cc |
index 4ac8a002f9bcad8215aacf6029639542e8fff4c9..6d07880647e4570097582a376da2037dd9b0c28e 100644 |
--- a/chrome/test/chromedriver/keycode_text_conversion_ozone.cc |
+++ b/chrome/test/chromedriver/keycode_text_conversion_ozone.cc |
@@ -14,10 +14,15 @@ |
#include "ui/events/ozone/layout/keyboard_layout_engine.h" |
#include "ui/events/ozone/layout/keyboard_layout_engine_manager.h" |
-bool ConvertKeyCodeToText(ui::KeyboardCode key_code, |
- int modifiers, |
- std::string* text, |
- std::string* error_msg) { |
+#if defined(USE_X11) |
+bool ConvertKeyCodeToTextOzone |
+#else |
+bool ConvertKeyCodeToText |
+#endif |
+ (ui::KeyboardCode key_code, |
+ int modifiers, |
+ std::string* text, |
+ std::string* error_msg) { |
ui::KeyboardLayoutEngine* keyboard_layout_engine = |
ui::KeyboardLayoutEngineManager::GetKeyboardLayoutEngine(); |
ui::DomCode dom_code = ui::UsLayoutKeyboardCodeToDomCode(key_code); |
@@ -48,10 +53,15 @@ bool ConvertKeyCodeToText(ui::KeyboardCode key_code, |
return true; |
} |
-bool ConvertCharToKeyCode(base::char16 key, |
- ui::KeyboardCode* key_code, |
- int* necessary_modifiers, |
- std::string* error_msg) { |
+#if defined(USE_X11) |
+bool ConvertCharToKeyCodeOzone |
+#else |
+bool ConvertCharToKeyCode |
+#endif |
+ (base::char16 key, |
+ ui::KeyboardCode* key_code, |
+ int* necessary_modifiers, |
+ std::string* error_msg) { |
base::string16 key_string; |
key_string.push_back(key); |
std::string key_string_utf8 = base::UTF16ToUTF8(key_string); |