pub unsafe extern "C" fn OH_Input_InjectKeyEvent(
keyEvent: *const Input_KeyEvent,
) -> i32Available on crate feature
api-12 only.Expand description
Inject system keys.
§Arguments
keyEvent- - the key event to be injected.
§Returns
- OH_Input_InjectKeyEvent function result code.
[
INPUT_SUCCESS] inject keyEvent success.
[INPUT_PERMISSION_DENIED] Permission verification failed.
[INPUT_PARAMETER_ERROR] keyCode is less 0, can not process.
Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
Available since API-level: 12