IKeyboardHandler.OnKeyEvent Method |
Version 81.3.100
Called after the renderer and JavaScript in the page has had a chance to
handle the event. Return true if the keyboard event was handled or false otherwise.
Namespace:
CefSharp
Assembly:
CefSharp (in CefSharp.dll) Version: 81.3.100.0 (81.3.100.0)
Syntaxbool OnKeyEvent(
IWebBrowser chromiumWebBrowser,
IBrowser browser,
KeyType type,
int windowsKeyCode,
int nativeKeyCode,
CefEventFlags modifiers,
bool isSystemKey
)
bool OnKeyEvent(
IWebBrowser^ chromiumWebBrowser,
IBrowser^ browser,
KeyType type,
int windowsKeyCode,
int nativeKeyCode,
CefEventFlags modifiers,
bool isSystemKey
)
Parameters
- chromiumWebBrowser
- Type: CefSharp.IWebBrowser
the ChromiumWebBrowser control - browser
- Type: CefSharp.IBrowser
The browser instance. - type
- Type: CefSharp.KeyType
Whether this was a key up/down/raw/etc... - windowsKeyCode
- Type: System.Int32
The Windows key code for the key event. This value is used by the DOM
specification. Sometimes it comes directly from the event (i.e. on
Windows) and sometimes it's determined using a mapping function. See
WebCore/platform/chromium/KeyboardCodes.h for the list of values.
- nativeKeyCode
- Type: System.Int32
The native key code. On Windows this appears to be in the format of WM_KEYDOWN/WM_KEYUP/etc... lParam data. - modifiers
- Type: CefSharp.CefEventFlags
What other modifier keys are currently down: Shift/Control/Alt/OS X Command/etc... - isSystemKey
- Type: System.Boolean
Indicates whether the event is considered a "system key" event (see
http://msdn.microsoft.com/en-us/library/ms646286(VS.85).aspx for details).
Return Value
Type:
BooleanReturn true if the keyboard event was handled or false otherwise.
See Also