OH_Input_RemoveKeyEventMonitor

Function OH_Input_RemoveKeyEventMonitor 

Source
pub unsafe extern "C" fn OH_Input_RemoveKeyEventMonitor(
    callback: Input_KeyEventCallback,
) -> Input_Result
Available on crate feature api-12 only.
Expand description

Removes a key event listener.

ohos.permission.INPUT_MONITORING

§Arguments

  • callback - - Callback for the key event listener.

§Returns

  • OH_Input_RemoveKeyEventMonitor function result code. [INPUT_SUCCESS] Removes a key event listener success.

[INPUT_PERMISSION_DENIED] Permission verification failed.

[INPUT_PARAMETER_ERROR] The callback is NULL or has not been added.

[INPUT_SERVICE_EXCEPTION] Fail to remove the monitor because the service is exception.

Required System Capabilities: SystemCapability.MultimodalInput.Input.Core

Available since API-level: 12