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

Unified Diff: ui/events/keycodes/keyboard_code_conversion_x.h

Issue 336403005: Use XInput2 events for keyboard events. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address review comments (sadrul) 3 Created 6 years, 5 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
« no previous file with comments | « ui/events/event_constants.h ('k') | ui/events/keycodes/keyboard_code_conversion_x.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/events/keycodes/keyboard_code_conversion_x.h
diff --git a/ui/events/keycodes/keyboard_code_conversion_x.h b/ui/events/keycodes/keyboard_code_conversion_x.h
index f9186ca0c885701107feb19f746d54bcc88a3993..9708a1bde26bd86cae5d62ca77b56947e9bf66ad 100644
--- a/ui/events/keycodes/keyboard_code_conversion_x.h
+++ b/ui/events/keycodes/keyboard_code_conversion_x.h
@@ -13,14 +13,14 @@ typedef union _XEvent XEvent;
namespace ui {
-EVENTS_BASE_EXPORT KeyboardCode KeyboardCodeFromXKeyEvent(XEvent* xev);
+EVENTS_BASE_EXPORT KeyboardCode KeyboardCodeFromXKeyEvent(const XEvent* xev);
EVENTS_BASE_EXPORT KeyboardCode KeyboardCodeFromXKeysym(unsigned int keysym);
-EVENTS_BASE_EXPORT const char* CodeFromXEvent(XEvent* xev);
+EVENTS_BASE_EXPORT const char* CodeFromXEvent(const XEvent* xev);
// Returns a character on a standard US PC keyboard from an XEvent.
-EVENTS_BASE_EXPORT uint16 GetCharacterFromXEvent(XEvent* xev);
+EVENTS_BASE_EXPORT uint16 GetCharacterFromXEvent(const XEvent* xev);
// Converts a KeyboardCode into an X KeySym.
EVENTS_BASE_EXPORT int XKeysymForWindowsKeyCode(KeyboardCode keycode,
@@ -30,6 +30,10 @@ EVENTS_BASE_EXPORT int XKeysymForWindowsKeyCode(KeyboardCode keycode,
EVENTS_BASE_EXPORT KeyboardCode
DefaultKeyboardCodeFromHardwareKeycode(unsigned int hardware_code);
+// Initializes a core XKeyEvent from an XI2 key event.
+EVENTS_BASE_EXPORT void InitXKeyEventFromXIDeviceEvent(const XEvent& src,
+ XEvent* dst);
+
} // namespace ui
#endif // UI_EVENTS_KEYCODES_KEYBOARD_CODE_CONVERSION_X_H_
« no previous file with comments | « ui/events/event_constants.h ('k') | ui/events/keycodes/keyboard_code_conversion_x.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698