mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Translate additional CEF modifiers to EF_* flags (see issue #2597)
This commit is contained in:
committed by
Marshall Greenblatt
parent
103fe12b72
commit
2be59f6edd
@@ -192,26 +192,30 @@ int CefBrowserPlatformDelegateNativeAura::TranslateUiEventModifiers(
|
||||
uint32 cef_modifiers) {
|
||||
int result = 0;
|
||||
// Set modifiers based on key state.
|
||||
if (cef_modifiers & EVENTFLAG_CAPS_LOCK_ON)
|
||||
result |= ui::EF_CAPS_LOCK_ON;
|
||||
if (cef_modifiers & EVENTFLAG_SHIFT_DOWN)
|
||||
result |= ui::EF_SHIFT_DOWN;
|
||||
if (cef_modifiers & EVENTFLAG_CONTROL_DOWN)
|
||||
result |= ui::EF_CONTROL_DOWN;
|
||||
if (cef_modifiers & EVENTFLAG_ALT_DOWN)
|
||||
result |= ui::EF_ALT_DOWN;
|
||||
if (cef_modifiers & EVENTFLAG_COMMAND_DOWN)
|
||||
result |= ui::EF_COMMAND_DOWN;
|
||||
if (cef_modifiers & EVENTFLAG_LEFT_MOUSE_BUTTON)
|
||||
result |= ui::EF_LEFT_MOUSE_BUTTON;
|
||||
if (cef_modifiers & EVENTFLAG_MIDDLE_MOUSE_BUTTON)
|
||||
result |= ui::EF_MIDDLE_MOUSE_BUTTON;
|
||||
if (cef_modifiers & EVENTFLAG_RIGHT_MOUSE_BUTTON)
|
||||
result |= ui::EF_RIGHT_MOUSE_BUTTON;
|
||||
if (cef_modifiers & EVENTFLAG_CAPS_LOCK_ON)
|
||||
result |= ui::EF_CAPS_LOCK_ON;
|
||||
if (cef_modifiers & EVENTFLAG_COMMAND_DOWN)
|
||||
result |= ui::EF_COMMAND_DOWN;
|
||||
if (cef_modifiers & EVENTFLAG_NUM_LOCK_ON)
|
||||
result |= ui::EF_NUM_LOCK_ON;
|
||||
if (cef_modifiers & EVENTFLAG_IS_KEY_PAD)
|
||||
result |= ui::EF_IS_EXTENDED_KEY;
|
||||
if (cef_modifiers & EVENTFLAG_ALTGR_DOWN)
|
||||
result |= ui::EF_ALTGR_DOWN;
|
||||
if (cef_modifiers & EVENTFLAG_IS_REPEAT)
|
||||
result |= ui::EF_IS_REPEAT;
|
||||
return result;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user