ohos_input_sys/input_manager/
input_manager_ffi.rs

1// automatically generated by rust-bindgen 0.71.1
2
3#![allow(non_upper_case_globals)]
4#![allow(non_camel_case_types)]
5#![allow(non_snake_case)]
6use crate::axis_type::{InputEvent_AxisAction, InputEvent_AxisEventType, InputEvent_AxisType};
7
8#[cfg(feature = "api-12")]
9#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
10impl Input_KeyStateAction {
11    /// Default
12    pub const KEY_DEFAULT: Input_KeyStateAction = Input_KeyStateAction(-1);
13    /// Pressing of a key
14    pub const KEY_PRESSED: Input_KeyStateAction = Input_KeyStateAction(0);
15    /// Release of a key
16    pub const KEY_RELEASED: Input_KeyStateAction = Input_KeyStateAction(1);
17    /// Key switch enabled
18    pub const KEY_SWITCH_ON: Input_KeyStateAction = Input_KeyStateAction(2);
19    /// Key switch disabled
20    pub const KEY_SWITCH_OFF: Input_KeyStateAction = Input_KeyStateAction(3);
21}
22#[repr(transparent)]
23/// Enumerated values of key event action.
24///
25///
26/// Available since API-level: 12
27#[cfg(feature = "api-12")]
28#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
29#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
30pub struct Input_KeyStateAction(pub ::core::ffi::c_int);
31#[cfg(feature = "api-12")]
32#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
33impl Input_KeyEventAction {
34    /// Cancellation of a key action.
35    pub const KEY_ACTION_CANCEL: Input_KeyEventAction = Input_KeyEventAction(0);
36    /// Pressing of a key.
37    pub const KEY_ACTION_DOWN: Input_KeyEventAction = Input_KeyEventAction(1);
38    /// Release of a key.
39    pub const KEY_ACTION_UP: Input_KeyEventAction = Input_KeyEventAction(2);
40}
41#[repr(transparent)]
42/// Enumerates key event types.
43///
44///
45/// Available since API-level: 12
46#[cfg(feature = "api-12")]
47#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
48#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
49pub struct Input_KeyEventAction(pub ::core::ffi::c_uint);
50#[cfg(feature = "api-12")]
51#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
52impl Input_MouseEventAction {
53    /// Cancel.
54    pub const MOUSE_ACTION_CANCEL: Input_MouseEventAction = Input_MouseEventAction(0);
55    /// Moving of the mouse pointer.
56    pub const MOUSE_ACTION_MOVE: Input_MouseEventAction = Input_MouseEventAction(1);
57    /// Pressing down of the mouse.
58    pub const MOUSE_ACTION_BUTTON_DOWN: Input_MouseEventAction = Input_MouseEventAction(2);
59    /// Lifting of the mouse button.
60    pub const MOUSE_ACTION_BUTTON_UP: Input_MouseEventAction = Input_MouseEventAction(3);
61    /// Beginning of the mouse axis event
62    pub const MOUSE_ACTION_AXIS_BEGIN: Input_MouseEventAction = Input_MouseEventAction(4);
63    /// Updating of the mouse axis event
64    pub const MOUSE_ACTION_AXIS_UPDATE: Input_MouseEventAction = Input_MouseEventAction(5);
65    /// End of the mouse axis event
66    pub const MOUSE_ACTION_AXIS_END: Input_MouseEventAction = Input_MouseEventAction(6);
67}
68#[repr(transparent)]
69/// Enumerated values of mouse event action.
70///
71///
72/// Available since API-level: 12
73#[cfg(feature = "api-12")]
74#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
75#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
76pub struct Input_MouseEventAction(pub ::core::ffi::c_uint);
77#[cfg(feature = "api-12")]
78#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
79impl InputEvent_MouseAxis {
80    /// Vertical scroll axis
81    pub const MOUSE_AXIS_SCROLL_VERTICAL: InputEvent_MouseAxis = InputEvent_MouseAxis(0);
82    /// Horizontal scroll axis
83    pub const MOUSE_AXIS_SCROLL_HORIZONTAL: InputEvent_MouseAxis = InputEvent_MouseAxis(1);
84}
85#[repr(transparent)]
86/// Mouse axis types.
87///
88///
89/// Available since API-level: 12
90#[cfg(feature = "api-12")]
91#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
92#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
93pub struct InputEvent_MouseAxis(pub ::core::ffi::c_uint);
94#[cfg(feature = "api-12")]
95#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
96impl Input_MouseEventButton {
97    /// Invalid button
98    pub const MOUSE_BUTTON_NONE: Input_MouseEventButton = Input_MouseEventButton(-1);
99    /// Left button on the mouse.
100    pub const MOUSE_BUTTON_LEFT: Input_MouseEventButton = Input_MouseEventButton(0);
101    /// Middle button on the mouse.
102    pub const MOUSE_BUTTON_MIDDLE: Input_MouseEventButton = Input_MouseEventButton(1);
103    /// Right button on the mouse.
104    pub const MOUSE_BUTTON_RIGHT: Input_MouseEventButton = Input_MouseEventButton(2);
105    /// Forward button on the mouse.
106    pub const MOUSE_BUTTON_FORWARD: Input_MouseEventButton = Input_MouseEventButton(3);
107    /// Back button on the mouse.
108    pub const MOUSE_BUTTON_BACK: Input_MouseEventButton = Input_MouseEventButton(4);
109}
110#[repr(transparent)]
111/// Enumerated values of mouse event button.
112///
113///
114/// Available since API-level: 12
115#[cfg(feature = "api-12")]
116#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
117#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
118pub struct Input_MouseEventButton(pub ::core::ffi::c_int);
119#[cfg(feature = "api-12")]
120#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
121impl Input_TouchEventAction {
122    /// Touch cancelled.
123    pub const TOUCH_ACTION_CANCEL: Input_TouchEventAction = Input_TouchEventAction(0);
124    /// Touch pressed.
125    pub const TOUCH_ACTION_DOWN: Input_TouchEventAction = Input_TouchEventAction(1);
126    /// Touch moved.
127    pub const TOUCH_ACTION_MOVE: Input_TouchEventAction = Input_TouchEventAction(2);
128    /// Touch lifted.
129    pub const TOUCH_ACTION_UP: Input_TouchEventAction = Input_TouchEventAction(3);
130}
131#[repr(transparent)]
132/// Enumerated values of touch event action.
133///
134///
135/// Available since API-level: 12
136#[cfg(feature = "api-12")]
137#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
138#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
139pub struct Input_TouchEventAction(pub ::core::ffi::c_uint);
140#[cfg(feature = "api-13")]
141#[cfg_attr(docsrs, doc(cfg(feature = "api-13")))]
142impl Input_KeyboardType {
143    /// Keyboard without keys
144    pub const KEYBOARD_TYPE_NONE: Input_KeyboardType = Input_KeyboardType(0);
145    /// Keyboard with unknown keys
146    pub const KEYBOARD_TYPE_UNKNOWN: Input_KeyboardType = Input_KeyboardType(1);
147    /// Full keyboard
148    pub const KEYBOARD_TYPE_ALPHABETIC: Input_KeyboardType = Input_KeyboardType(2);
149    /// Digital keyboard
150    pub const KEYBOARD_TYPE_DIGITAL: Input_KeyboardType = Input_KeyboardType(3);
151    /// Stylus
152    pub const KEYBOARD_TYPE_STYLUS: Input_KeyboardType = Input_KeyboardType(4);
153    /// Remote control
154    pub const KEYBOARD_TYPE_REMOTE_CONTROL: Input_KeyboardType = Input_KeyboardType(5);
155}
156#[repr(transparent)]
157/// Enumerates keyboard types.
158///
159///
160/// Available since API-level: 13
161#[cfg(feature = "api-13")]
162#[cfg_attr(docsrs, doc(cfg(feature = "api-13")))]
163#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
164pub struct Input_KeyboardType(pub ::core::ffi::c_uint);
165#[cfg(feature = "api-12")]
166#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
167impl InputEvent_SourceType {
168    /// Indicates that the input source generates events similar to mouse cursor movement,
169    /// button press and release, and wheel scrolling.
170    ///
171    ///
172    /// Available since API-level: 12
173    #[cfg(feature = "api-12")]
174    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
175    pub const SOURCE_TYPE_MOUSE: InputEvent_SourceType = InputEvent_SourceType(1);
176    /// Indicates that the input source generates a touchscreen multi-touch event.
177    ///
178    ///
179    /// Available since API-level: 12
180    #[cfg(feature = "api-12")]
181    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
182    pub const SOURCE_TYPE_TOUCHSCREEN: InputEvent_SourceType = InputEvent_SourceType(2);
183    /// Indicates that the input source generates a touchpad multi-touch event.
184    ///
185    ///
186    /// Available since API-level: 12
187    #[cfg(feature = "api-12")]
188    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
189    pub const SOURCE_TYPE_TOUCHPAD: InputEvent_SourceType = InputEvent_SourceType(3);
190}
191#[repr(transparent)]
192/// Enumerates event source types.
193///
194///
195/// Available since API-level: 12
196#[cfg(feature = "api-12")]
197#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
198#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
199pub struct InputEvent_SourceType(pub ::core::ffi::c_uint);
200/// Defines key information, which identifies a key pressing behavior. For example, the Ctrl key information contains the key value and key type.
201///
202///
203/// Available since API-level: 12
204#[cfg(feature = "api-12")]
205#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
206#[repr(C)]
207pub struct Input_KeyState {
208    _unused: [u8; 0],
209}
210/// The key event to be injected.
211///
212///
213/// Available since API-level: 12
214#[cfg(feature = "api-12")]
215#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
216#[repr(C)]
217pub struct Input_KeyEvent {
218    _unused: [u8; 0],
219}
220/// The mouse event to be injected.
221///
222///
223/// Available since API-level: 12
224#[cfg(feature = "api-12")]
225#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
226#[repr(C)]
227pub struct Input_MouseEvent {
228    _unused: [u8; 0],
229}
230/// The touch event to be injected.
231///
232///
233/// Available since API-level: 12
234#[cfg(feature = "api-12")]
235#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
236#[repr(C)]
237pub struct Input_TouchEvent {
238    _unused: [u8; 0],
239}
240/// Enumerates axis events.
241///
242///
243/// Available since API-level: 12
244#[cfg(feature = "api-12")]
245#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
246#[repr(C)]
247pub struct Input_AxisEvent {
248    _unused: [u8; 0],
249}
250/// Defines the hot key structure.
251///
252///
253/// Available since API-level: 14
254#[cfg(feature = "api-14")]
255#[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
256#[repr(C)]
257pub struct Input_Hotkey {
258    _unused: [u8; 0],
259}
260pub type Input_Result = Result<(), InputErrorCode>;
261#[cfg(feature = "api-12")]
262#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
263impl InputErrorCode {
264    /// Permission verification failed
265    pub const PERMISSION_DENIED: InputErrorCode =
266        InputErrorCode(const { core::num::NonZero::new(201).unwrap() });
267    /// Non-system application
268    pub const NOT_SYSTEM_APPLICATION: InputErrorCode =
269        InputErrorCode(const { core::num::NonZero::new(202).unwrap() });
270    /// Parameter check failed
271    pub const PARAMETER_ERROR: InputErrorCode =
272        InputErrorCode(const { core::num::NonZero::new(401).unwrap() });
273    /// Device not support
274    pub const DEVICE_NOT_SUPPORTED: InputErrorCode =
275        InputErrorCode(const { core::num::NonZero::new(801).unwrap() });
276    /// Service error
277    pub const SERVICE_EXCEPTION: InputErrorCode =
278        InputErrorCode(const { core::num::NonZero::new(3800001).unwrap() });
279    /// Interceptor repeatedly created for an application
280    pub const REPEAT_INTERCEPTOR: InputErrorCode =
281        InputErrorCode(const { core::num::NonZero::new(4200001).unwrap() });
282    /// Already occupied by the system
283    ///
284    /// Available since API-level: 14
285    #[cfg(feature = "api-14")]
286    #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
287    pub const OCCUPIED_BY_SYSTEM: InputErrorCode =
288        InputErrorCode(const { core::num::NonZero::new(4200002).unwrap() });
289    /// Already occupied by the other
290    ///
291    /// Available since API-level: 14
292    #[cfg(feature = "api-14")]
293    #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
294    pub const OCCUPIED_BY_OTHER: InputErrorCode =
295        InputErrorCode(const { core::num::NonZero::new(4200003).unwrap() });
296}
297#[repr(transparent)]
298/// Enumerates error codes.
299///
300///
301/// Available since API-level: 12
302#[cfg(feature = "api-12")]
303#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
304#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
305pub struct InputErrorCode(pub core::num::NonZero<::core::ffi::c_uint>);
306/// Callback used to return shortcut key events.
307///
308/// Available since API-level: 14
309#[cfg(feature = "api-14")]
310#[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
311pub type Input_HotkeyCallback =
312    ::core::option::Option<unsafe extern "C" fn(hotkey: *mut Input_Hotkey)>;
313/// Represents information about the input device.
314///
315///
316/// Available since API-level: 13
317#[cfg(feature = "api-13")]
318#[cfg_attr(docsrs, doc(cfg(feature = "api-13")))]
319#[repr(C)]
320pub struct Input_DeviceInfo {
321    _unused: [u8; 0],
322}
323/// Defines a lifecycle callback for keyEvent. If the callback is triggered, keyEvent will be destroyed.
324///
325/// # Arguments
326///
327/// * `keyEvent` - Key event object.
328///
329/// Available since API-level: 12
330#[cfg(feature = "api-12")]
331#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
332pub type Input_KeyEventCallback =
333    ::core::option::Option<unsafe extern "C" fn(keyEvent: *const Input_KeyEvent)>;
334/// Defines a lifecycle callback for mouseEvent. If the callback is triggered, mouseEvent will be destroyed.
335///
336/// # Arguments
337///
338/// * `mouseEvent` - Mouse event object.
339///
340/// Available since API-level: 12
341#[cfg(feature = "api-12")]
342#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
343pub type Input_MouseEventCallback =
344    ::core::option::Option<unsafe extern "C" fn(mouseEvent: *const Input_MouseEvent)>;
345/// Defines a lifecycle callback for touchEvent. If the callback is triggered, touchEvent will be destroyed.
346///
347/// # Arguments
348///
349/// * `touchEvent` - Touch event object.
350///
351/// Available since API-level: 12
352#[cfg(feature = "api-12")]
353#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
354pub type Input_TouchEventCallback =
355    ::core::option::Option<unsafe extern "C" fn(touchEvent: *const Input_TouchEvent)>;
356/// Defines a lifecycle callback for axisEvent. If the callback is triggered, axisEvent will be destroyed.
357///
358/// # Arguments
359///
360/// * `axisEvent` - Axis event object.
361///
362/// Available since API-level: 12
363#[cfg(feature = "api-12")]
364#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
365pub type Input_AxisEventCallback =
366    ::core::option::Option<unsafe extern "C" fn(axisEvent: *const Input_AxisEvent)>;
367/// Defines the callback for device addition events.
368/// # Arguments
369///
370/// * `deviceId` - Device ID.
371///
372/// Available since API-level: 13
373#[cfg(feature = "api-13")]
374#[cfg_attr(docsrs, doc(cfg(feature = "api-13")))]
375pub type Input_DeviceAddedCallback = ::core::option::Option<unsafe extern "C" fn(deviceId: i32)>;
376/// Defines the callback for device removal events.
377/// # Arguments
378///
379/// * `deviceId` - Device ID.
380///
381/// Available since API-level: 13
382#[cfg(feature = "api-13")]
383#[cfg_attr(docsrs, doc(cfg(feature = "api-13")))]
384pub type Input_DeviceRemovedCallback = ::core::option::Option<unsafe extern "C" fn(deviceId: i32)>;
385/// Defines the structure for the interceptor of event callbacks,
386/// including mouseCallback, touchCallback, and axisCallback.
387///
388/// Available since API-level: 12
389#[cfg(feature = "api-12")]
390#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
391#[repr(C)]
392#[derive(Debug, Copy, Clone)]
393pub struct Input_InterceptorEventCallback {
394    /// Defines a lifecycle callback for **mouseEvent**.
395    pub mouseCallback: Input_MouseEventCallback,
396    /// Defines a lifecycle callback for **touchEvent**.
397    pub touchCallback: Input_TouchEventCallback,
398    /// Defines a lifecycle callback for **axisEvent**.
399    pub axisCallback: Input_AxisEventCallback,
400}
401/// Defines a listener for device insertion and removal events.
402///
403/// Available since API-level: 13
404#[cfg(feature = "api-13")]
405#[cfg_attr(docsrs, doc(cfg(feature = "api-13")))]
406#[repr(C)]
407#[derive(Debug, Copy, Clone)]
408pub struct Input_DeviceListener {
409    /// Callback for device addition events
410    pub deviceAddedCallback: Input_DeviceAddedCallback,
411    /// Callback for device removal events
412    pub deviceRemovedCallback: Input_DeviceRemovedCallback,
413}
414/// Defines event interceptor options.
415///
416/// Available since API-level: 12
417#[cfg(feature = "api-12")]
418#[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
419#[repr(C)]
420pub struct Input_InterceptorOptions {
421    _unused: [u8; 0],
422}
423extern "C" {
424    /// Queries the key state.
425    ///
426    /// # Arguments
427    ///
428    /// * `keyState` - Key state.
429    ///
430    /// # Returns
431    ///
432    /// * OH_Input_GetKeyState function result code.
433    /// [`INPUT_SUCCESS`] get KeyState success.
434    ///
435    /// [`INPUT_PARAMETER_ERROR`] keyCode is invalid.
436    ///
437    ///
438    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
439    ///
440    /// Available since API-level: 12
441    #[cfg(feature = "api-12")]
442    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
443    pub fn OH_Input_GetKeyState(keyState: *mut Input_KeyState) -> Input_Result;
444    /// Creates a key status enumeration object.
445    ///
446    ///
447    /// # Returns
448    ///
449    /// * Returns an [`Input_KeyState`] pointer object if the operation is successful.
450    /// Otherwise, a null pointer is returned. The possible cause is memory allocation failure.
451    ///
452    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
453    ///
454    /// Available since API-level: 12
455    #[cfg(feature = "api-12")]
456    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
457    pub fn OH_Input_CreateKeyState() -> *mut Input_KeyState;
458    /// Destroys a key status enumeration object.
459    ///
460    /// # Arguments
461    ///
462    /// * `keyState` - Key status enumeration object.
463    ///
464    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
465    ///
466    /// Available since API-level: 12
467    #[cfg(feature = "api-12")]
468    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
469    pub fn OH_Input_DestroyKeyState(keyState: *mut *mut Input_KeyState);
470    /// Sets the key value of a key status enumeration object.
471    ///
472    /// # Arguments
473    ///
474    /// * `keyState` - Key status enumeration object.
475    ///
476    /// * `keyCode` - Key value of the key status enumeration object.
477    ///
478    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
479    ///
480    /// Available since API-level: 12
481    #[cfg(feature = "api-12")]
482    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
483    pub fn OH_Input_SetKeyCode(keyState: *mut Input_KeyState, keyCode: i32);
484    /// Obtains the key value of a key status enumeration object.
485    ///
486    /// # Arguments
487    ///
488    /// * `keyState` - Key status enumeration object.
489    ///
490    /// # Returns
491    ///
492    /// * Key value of the key status enumeration object.
493    ///
494    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
495    ///
496    /// Available since API-level: 12
497    #[cfg(feature = "api-12")]
498    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
499    pub fn OH_Input_GetKeyCode(keyState: *const Input_KeyState) -> i32;
500    /// Sets whether the key specific to a key status enumeration object is pressed.
501    ///
502    /// # Arguments
503    ///
504    /// * `keyState` - Key status enumeration object.
505    ///
506    /// * `keyAction` - Whether the key is pressed.
507    ///
508    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
509    ///
510    /// Available since API-level: 12
511    #[cfg(feature = "api-12")]
512    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
513    pub fn OH_Input_SetKeyPressed(keyState: *mut Input_KeyState, keyAction: i32);
514    /// Checks whether the key specific to a key status enumeration object is pressed.
515    ///
516    /// # Arguments
517    ///
518    /// * `keyState` - Key status enumeration object.
519    ///
520    /// # Returns
521    ///
522    /// * Key pressing status of the key status enumeration object.
523    ///
524    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
525    ///
526    /// Available since API-level: 12
527    #[cfg(feature = "api-12")]
528    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
529    pub fn OH_Input_GetKeyPressed(keyState: *const Input_KeyState) -> i32;
530    /// Sets the key switch of the key status enumeration object.
531    ///
532    /// # Arguments
533    ///
534    /// * `keyState` - Key status enumeration object.
535    ///
536    /// * `keySwitch` - Key switch of the key status enumeration object.
537    ///
538    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
539    ///
540    /// Available since API-level: 12
541    #[cfg(feature = "api-12")]
542    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
543    pub fn OH_Input_SetKeySwitch(keyState: *mut Input_KeyState, keySwitch: i32);
544    /// Obtains the key switch of the key status enumeration object.
545    ///
546    /// # Arguments
547    ///
548    /// * `keyState` - Key status enumeration object.
549    ///
550    /// # Returns
551    ///
552    /// * Key switch of the key status enumeration object.
553    ///
554    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
555    ///
556    /// Available since API-level: 12
557    #[cfg(feature = "api-12")]
558    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
559    pub fn OH_Input_GetKeySwitch(keyState: *const Input_KeyState) -> i32;
560    /// Inject system keys.
561    ///
562    /// # Arguments
563    ///
564    /// * `keyEvent` - - the key event to be injected.
565    ///
566    /// # Returns
567    ///
568    /// * OH_Input_InjectKeyEvent function result code.
569    /// [`INPUT_SUCCESS`] inject keyEvent success.
570    ///
571    /// [`INPUT_PERMISSION_DENIED`] Permission verification failed.
572    ///
573    /// [`INPUT_PARAMETER_ERROR`] keyCode is less 0, can not process.
574    ///
575    ///
576    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
577    ///
578    /// Available since API-level: 12
579    #[cfg(feature = "api-12")]
580    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
581    pub fn OH_Input_InjectKeyEvent(keyEvent: *const Input_KeyEvent) -> i32;
582    /// Creates a key event object.
583    ///
584    ///
585    /// # Returns
586    ///
587    /// * Returns an [`Input_KeyEvent`] pointer object if the operation is successful.
588    /// Otherwise, a null pointer is returned. The possible cause is memory allocation failure.
589    ///
590    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
591    ///
592    /// Available since API-level: 12
593    #[cfg(feature = "api-12")]
594    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
595    pub fn OH_Input_CreateKeyEvent() -> *mut Input_KeyEvent;
596    /// Destroys a key event object.
597    ///
598    /// # Arguments
599    ///
600    /// * `keyEvent` - Key event object.
601    ///
602    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
603    ///
604    /// Available since API-level: 12
605    #[cfg(feature = "api-12")]
606    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
607    pub fn OH_Input_DestroyKeyEvent(keyEvent: *mut *mut Input_KeyEvent);
608    /// Sets the key event type.
609    ///
610    /// # Arguments
611    ///
612    /// * `keyEvent` - Key event object.
613    ///
614    /// * `action` - Key event type.
615    ///
616    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
617    ///
618    /// Available since API-level: 12
619    #[cfg(feature = "api-12")]
620    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
621    pub fn OH_Input_SetKeyEventAction(keyEvent: *mut Input_KeyEvent, action: i32);
622    /// Obtains the key event type.
623    ///
624    /// # Arguments
625    ///
626    /// * `keyEvent` - Key event object.
627    ///
628    /// # Returns
629    ///
630    /// * Key event type.
631    ///
632    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
633    ///
634    /// Available since API-level: 12
635    #[cfg(feature = "api-12")]
636    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
637    pub fn OH_Input_GetKeyEventAction(keyEvent: *const Input_KeyEvent) -> i32;
638    /// Sets the key value for a key event.
639    ///
640    /// # Arguments
641    ///
642    /// * `keyEvent` - Key event object.
643    ///
644    /// * `keyCode` - keyCode Key code.
645    ///
646    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
647    ///
648    /// Available since API-level: 12
649    #[cfg(feature = "api-12")]
650    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
651    pub fn OH_Input_SetKeyEventKeyCode(keyEvent: *mut Input_KeyEvent, keyCode: i32);
652    /// Obtains the key value of a key event.
653    ///
654    /// # Arguments
655    ///
656    /// * `keyEvent` - Key event object.
657    ///
658    /// # Returns
659    ///
660    /// * Key code.
661    ///
662    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
663    ///
664    /// Available since API-level: 12
665    #[cfg(feature = "api-12")]
666    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
667    pub fn OH_Input_GetKeyEventKeyCode(keyEvent: *const Input_KeyEvent) -> i32;
668    /// Sets the time when a key event occurs.
669    ///
670    /// # Arguments
671    ///
672    /// * `keyEvent` - Key event object.
673    ///
674    /// * `actionTime` - Time when the key event occurs.
675    ///
676    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
677    ///
678    /// Available since API-level: 12
679    #[cfg(feature = "api-12")]
680    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
681    pub fn OH_Input_SetKeyEventActionTime(keyEvent: *mut Input_KeyEvent, actionTime: i64);
682    /// Obtains the time when a key event occurs.
683    ///
684    /// # Arguments
685    ///
686    /// * `keyEvent` - Key event object.
687    ///
688    /// # Returns
689    ///
690    /// * Returns the time when the key event occurs.
691    ///
692    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
693    ///
694    /// Available since API-level: 12
695    #[cfg(feature = "api-12")]
696    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
697    pub fn OH_Input_GetKeyEventActionTime(keyEvent: *const Input_KeyEvent) -> i64;
698    /// Inject mouse event.
699    ///
700    /// # Arguments
701    ///
702    /// * `mouseEvent` - - the mouse event to be injected.
703    ///
704    /// # Returns
705    ///
706    /// * OH_Input_InjectMouseEvent function result code.
707    /// [`INPUT_SUCCESS`] inject mouseEvent success.
708    ///
709    /// [`INPUT_PERMISSION_DENIED`] Permission verification failed.
710    ///
711    /// [`INPUT_PARAMETER_ERROR`] Parameter check failed.
712    ///
713    ///
714    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
715    ///
716    /// Available since API-level: 12
717    #[cfg(feature = "api-12")]
718    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
719    pub fn OH_Input_InjectMouseEvent(mouseEvent: *const Input_MouseEvent) -> i32;
720    /// Creates a mouse event object.
721    ///
722    ///
723    /// # Returns
724    ///
725    /// * Returns an [`Input_MouseEvent`] pointer object if the operation is successful.
726    /// Otherwise, a null pointer is returned. The possible cause is memory allocation failure.
727    ///
728    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
729    ///
730    /// Available since API-level: 12
731    #[cfg(feature = "api-12")]
732    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
733    pub fn OH_Input_CreateMouseEvent() -> *mut Input_MouseEvent;
734    /// Destroys a mouse event object.
735    ///
736    /// # Arguments
737    ///
738    /// * `mouseEvent` - Mouse event object.
739    ///
740    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
741    ///
742    /// Available since API-level: 12
743    #[cfg(feature = "api-12")]
744    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
745    pub fn OH_Input_DestroyMouseEvent(mouseEvent: *mut *mut Input_MouseEvent);
746    /// Sets the action for a mouse event.
747    ///
748    /// # Arguments
749    ///
750    /// * `mouseEvent` - Mouse event object.
751    ///
752    /// * `action` - Mouse action.
753    ///
754    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
755    ///
756    /// Available since API-level: 12
757    #[cfg(feature = "api-12")]
758    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
759    pub fn OH_Input_SetMouseEventAction(mouseEvent: *mut Input_MouseEvent, action: i32);
760    /// Obtains the action of a mouse event.
761    ///
762    /// # Arguments
763    ///
764    /// * `mouseEvent` - Mouse event object.
765    ///
766    /// # Returns
767    ///
768    /// * Mouse action.
769    ///
770    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
771    ///
772    /// Available since API-level: 12
773    #[cfg(feature = "api-12")]
774    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
775    pub fn OH_Input_GetMouseEventAction(mouseEvent: *const Input_MouseEvent) -> i32;
776    /// Sets the X coordinate for a mouse event.
777    ///
778    /// # Arguments
779    ///
780    /// * `mouseEvent` - Mouse event object.
781    ///
782    /// * `displayX` - X coordinate on the display.
783    ///
784    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
785    ///
786    /// Available since API-level: 12
787    #[cfg(feature = "api-12")]
788    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
789    pub fn OH_Input_SetMouseEventDisplayX(mouseEvent: *mut Input_MouseEvent, displayX: i32);
790    /// Obtains the X coordinate of a mouse event.
791    ///
792    /// # Arguments
793    ///
794    /// * `mouseEvent` - Mouse event object.
795    ///
796    /// # Returns
797    ///
798    /// * X coordinate on the display.
799    ///
800    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
801    ///
802    /// Available since API-level: 12
803    #[cfg(feature = "api-12")]
804    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
805    pub fn OH_Input_GetMouseEventDisplayX(mouseEvent: *const Input_MouseEvent) -> i32;
806    /// Sets the Y coordinate for a mouse event.
807    ///
808    /// # Arguments
809    ///
810    /// * `mouseEvent` - Mouse event object.
811    ///
812    /// * `displayY` - Y coordinate on the display.
813    ///
814    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
815    ///
816    /// Available since API-level: 12
817    #[cfg(feature = "api-12")]
818    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
819    pub fn OH_Input_SetMouseEventDisplayY(mouseEvent: *mut Input_MouseEvent, displayY: i32);
820    /// Obtains the Y coordinate of a mouse event.
821    ///
822    /// # Arguments
823    ///
824    /// * `mouseEvent` - Mouse event object.
825    ///
826    /// # Returns
827    ///
828    /// * Y coordinate on the display.
829    ///
830    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
831    ///
832    /// Available since API-level: 12
833    #[cfg(feature = "api-12")]
834    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
835    pub fn OH_Input_GetMouseEventDisplayY(mouseEvent: *const Input_MouseEvent) -> i32;
836    /// Sets the button for a mouse event.
837    ///
838    /// # Arguments
839    ///
840    /// * `mouseEvent` - Mouse event object.
841    ///
842    /// * `button` - Mouse button.
843    ///
844    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
845    ///
846    /// Available since API-level: 12
847    #[cfg(feature = "api-12")]
848    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
849    pub fn OH_Input_SetMouseEventButton(mouseEvent: *mut Input_MouseEvent, button: i32);
850    /// Obtains the button of a mouse event.
851    ///
852    /// # Arguments
853    ///
854    /// * `mouseEvent` - Mouse event object.
855    ///
856    /// # Returns
857    ///
858    /// * Mouse button.
859    ///
860    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
861    ///
862    /// Available since API-level: 12
863    #[cfg(feature = "api-12")]
864    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
865    pub fn OH_Input_GetMouseEventButton(mouseEvent: *const Input_MouseEvent) -> i32;
866    /// Sets the axis type for mouse event.
867    ///
868    /// # Arguments
869    ///
870    /// * `mouseEvent` - Mouse event object.
871    ///
872    /// * `axisType` - Axis type, for example, X axis or Y axis.
873    ///
874    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
875    ///
876    /// Available since API-level: 12
877    #[cfg(feature = "api-12")]
878    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
879    pub fn OH_Input_SetMouseEventAxisType(mouseEvent: *mut Input_MouseEvent, axisType: i32);
880    /// Obtains the axis type of a mouse event.
881    ///
882    /// # Arguments
883    ///
884    /// * `mouseEvent` - Mouse event object.
885    ///
886    /// # Returns
887    ///
888    /// * Axis type.
889    ///
890    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
891    ///
892    /// Available since API-level: 12
893    #[cfg(feature = "api-12")]
894    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
895    pub fn OH_Input_GetMouseEventAxisType(mouseEvent: *const Input_MouseEvent) -> i32;
896    /// Sets the axis value for a mouse axis event.
897    ///
898    /// # Arguments
899    ///
900    /// * `mouseEvent` - Mouse event object.
901    ///
902    /// * `axisValue` - Axis value. A positive value means scrolling forward,
903    /// and a negative number means scrolling backward.
904    ///
905    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
906    ///
907    /// Available since API-level: 12
908    #[cfg(feature = "api-12")]
909    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
910    pub fn OH_Input_SetMouseEventAxisValue(mouseEvent: *mut Input_MouseEvent, axisValue: f32);
911    /// Obtains the axis value of a mouse event.
912    ///
913    /// # Arguments
914    ///
915    /// * `mouseEvent` - Mouse event object.
916    ///
917    /// # Returns
918    ///
919    /// * Axis value.
920    ///
921    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
922    ///
923    /// Available since API-level: 12
924    #[cfg(feature = "api-12")]
925    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
926    pub fn OH_Input_GetMouseEventAxisValue(mouseEvent: *const Input_MouseEvent) -> f32;
927    /// Sets the time when a mouse event occurs.
928    ///
929    /// # Arguments
930    ///
931    /// * `mouseEvent` - Mouse event object.
932    ///
933    /// * `actionTime` - Time when the mouse event occurs.
934    ///
935    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
936    ///
937    /// Available since API-level: 12
938    #[cfg(feature = "api-12")]
939    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
940    pub fn OH_Input_SetMouseEventActionTime(mouseEvent: *mut Input_MouseEvent, actionTime: i64);
941    /// Obtains the time when a mouse event occurs.
942    ///
943    /// # Arguments
944    ///
945    /// * `mouseEvent` - Mouse event object.
946    ///
947    /// # Returns
948    ///
949    /// * Returns the time when the mouse event occurs.
950    ///
951    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
952    ///
953    /// Available since API-level: 12
954    #[cfg(feature = "api-12")]
955    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
956    pub fn OH_Input_GetMouseEventActionTime(mouseEvent: *const Input_MouseEvent) -> i64;
957    /// Inject touch event.
958    ///
959    /// # Arguments
960    ///
961    /// * `touchEvent` - - the touch event to be injected.
962    ///
963    /// # Returns
964    ///
965    /// * OH_Input_InjectTouchEvent function result code.
966    /// [`INPUT_SUCCESS`] inject touchEvent success.
967    ///
968    /// [`INPUT_PARAMETER_ERROR`] Parameter check failed.
969    ///
970    ///
971    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
972    ///
973    /// Available since API-level: 12
974    #[cfg(feature = "api-12")]
975    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
976    pub fn OH_Input_InjectTouchEvent(touchEvent: *const Input_TouchEvent) -> i32;
977    /// Creates a touch event object.
978    ///
979    ///
980    /// # Returns
981    ///
982    /// * Returns an [`Input_TouchEvent`] pointer object if the operation is successful.
983    /// Otherwise, a null pointer is returned. The possible cause is memory allocation failure.
984    ///
985    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
986    ///
987    /// Available since API-level: 12
988    #[cfg(feature = "api-12")]
989    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
990    pub fn OH_Input_CreateTouchEvent() -> *mut Input_TouchEvent;
991    /// Destroys a touch event object.
992    ///
993    /// # Arguments
994    ///
995    /// * `touchEvent` - Touch event object.
996    ///
997    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
998    ///
999    /// Available since API-level: 12
1000    #[cfg(feature = "api-12")]
1001    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1002    pub fn OH_Input_DestroyTouchEvent(touchEvent: *mut *mut Input_TouchEvent);
1003    /// Sets the action for a touch event.
1004    ///
1005    /// # Arguments
1006    ///
1007    /// * `touchEvent` - Touch event object.
1008    ///
1009    /// * `action` - Touch action.
1010    ///
1011    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1012    ///
1013    /// Available since API-level: 12
1014    #[cfg(feature = "api-12")]
1015    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1016    pub fn OH_Input_SetTouchEventAction(touchEvent: *mut Input_TouchEvent, action: i32);
1017    /// Obtains the action of a touch event.
1018    ///
1019    /// # Arguments
1020    ///
1021    /// * `touchEvent` - Touch event object.
1022    ///
1023    /// # Returns
1024    ///
1025    /// * Touch action.
1026    ///
1027    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1028    ///
1029    /// Available since API-level: 12
1030    #[cfg(feature = "api-12")]
1031    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1032    pub fn OH_Input_GetTouchEventAction(touchEvent: *const Input_TouchEvent) -> i32;
1033    /// Sets the finger ID for the touch event.
1034    ///
1035    /// # Arguments
1036    ///
1037    /// * `touchEvent` - Touch event object.
1038    ///
1039    /// * `id` - Finger ID.
1040    ///
1041    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1042    ///
1043    /// Available since API-level: 12
1044    #[cfg(feature = "api-12")]
1045    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1046    pub fn OH_Input_SetTouchEventFingerId(touchEvent: *mut Input_TouchEvent, id: i32);
1047    /// Obtains the finger ID of a touch event.
1048    ///
1049    /// # Arguments
1050    ///
1051    /// * `touchEvent` - Touch event object.
1052    ///
1053    /// # Returns
1054    ///
1055    /// * Finger ID.
1056    ///
1057    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1058    ///
1059    /// Available since API-level: 12
1060    #[cfg(feature = "api-12")]
1061    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1062    pub fn OH_Input_GetTouchEventFingerId(touchEvent: *const Input_TouchEvent) -> i32;
1063    /// Sets the X coordinate for a touch event.
1064    ///
1065    /// # Arguments
1066    ///
1067    /// * `touchEvent` - Touch event object.
1068    ///
1069    /// * `displayX` - X coordinate.
1070    ///
1071    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1072    ///
1073    /// Available since API-level: 12
1074    #[cfg(feature = "api-12")]
1075    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1076    pub fn OH_Input_SetTouchEventDisplayX(touchEvent: *mut Input_TouchEvent, displayX: i32);
1077    /// Obtains the X coordinate of a touch event.
1078    ///
1079    /// # Arguments
1080    ///
1081    /// * `touchEvent` - Touch event object.
1082    ///
1083    /// # Returns
1084    ///
1085    /// * X coordinate.
1086    ///
1087    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1088    ///
1089    /// Available since API-level: 12
1090    #[cfg(feature = "api-12")]
1091    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1092    pub fn OH_Input_GetTouchEventDisplayX(touchEvent: *const Input_TouchEvent) -> i32;
1093    /// Sets the Y coordinate for a touch event.
1094    ///
1095    /// # Arguments
1096    ///
1097    /// * `touchEvent` - Touch event object.
1098    ///
1099    /// * `displayY` - Y coordinate.
1100    ///
1101    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1102    ///
1103    /// Available since API-level: 12
1104    #[cfg(feature = "api-12")]
1105    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1106    pub fn OH_Input_SetTouchEventDisplayY(touchEvent: *mut Input_TouchEvent, displayY: i32);
1107    /// Obtains the Y coordinate of a touch event.
1108    ///
1109    /// # Arguments
1110    ///
1111    /// * `touchEvent` - Touch event object.
1112    ///
1113    /// # Returns
1114    ///
1115    /// * Y coordinate.
1116    ///
1117    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1118    ///
1119    /// Available since API-level: 12
1120    #[cfg(feature = "api-12")]
1121    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1122    pub fn OH_Input_GetTouchEventDisplayY(touchEvent: *const Input_TouchEvent) -> i32;
1123    /// Sets the time when a touch event occurs.
1124    ///
1125    /// # Arguments
1126    ///
1127    /// * `touchEvent` - Touch event object.
1128    ///
1129    /// * `actionTime` - Time when the touch event occurs.
1130    ///
1131    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1132    ///
1133    /// Available since API-level: 12
1134    #[cfg(feature = "api-12")]
1135    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1136    pub fn OH_Input_SetTouchEventActionTime(touchEvent: *mut Input_TouchEvent, actionTime: i64);
1137    /// Obtains the time when a touch event occurs.
1138    ///
1139    /// # Arguments
1140    ///
1141    /// * `touchEvent` - touch event object.
1142    ///
1143    /// # Returns
1144    ///
1145    /// * Returns the time when the touch event occurs.
1146    ///
1147    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1148    ///
1149    /// Available since API-level: 12
1150    #[cfg(feature = "api-12")]
1151    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1152    pub fn OH_Input_GetTouchEventActionTime(touchEvent: *const Input_TouchEvent) -> i64;
1153    /// Cancels event injection and revokes authorization.
1154    ///
1155    ///
1156    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1157    ///
1158    /// Available since API-level: 12
1159    #[cfg(feature = "api-12")]
1160    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1161    pub fn OH_Input_CancelInjection();
1162    /// Creates an axis event object.
1163    ///
1164    ///
1165    /// # Returns
1166    ///
1167    /// * If the operation is successful, a [`Input_AxisEvent`] object is returned.
1168    /// If the operation fails, null is returned.
1169    ///
1170    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1171    ///
1172    /// Available since API-level: 12
1173    #[cfg(feature = "api-12")]
1174    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1175    pub fn OH_Input_CreateAxisEvent() -> *mut Input_AxisEvent;
1176    /// Destroys an axis event object.
1177    ///
1178    /// # Arguments
1179    ///
1180    /// * `axisEvent` - Pointer to the axis event object.
1181    ///
1182    /// # Returns
1183    ///
1184    /// * OH_Input_DestroyAxisEvent function result code.
1185    /// [`INPUT_SUCCESS`] Destroys axisEvent success.
1186    ///
1187    /// [`INPUT_PARAMETER_ERROR`]The axisEvent is NULL or the *axisEvent is NULL.
1188    ///
1189    ///
1190    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1191    ///
1192    /// Available since API-level: 12
1193    #[cfg(feature = "api-12")]
1194    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1195    pub fn OH_Input_DestroyAxisEvent(axisEvent: *mut *mut Input_AxisEvent) -> Input_Result;
1196    /// Sets the axis event action.
1197    ///
1198    /// # Arguments
1199    ///
1200    /// * `axisEvent` - Axis event object. For details, see [`Input_AxisEvent`].
1201    ///
1202    /// * `action` - Axis event action. The values are defined in [`InputEvent_AxisAction`].
1203    ///
1204    /// # Returns
1205    ///
1206    /// * OH_Input_SetAxisEventAction function result code.
1207    /// [`INPUT_SUCCESS`] Sets the axis event action success.
1208    ///
1209    /// [`INPUT_PARAMETER_ERROR`] The axisEvent is NULL.
1210    ///
1211    ///
1212    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1213    ///
1214    /// Available since API-level: 12
1215    #[cfg(feature = "api-12")]
1216    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1217    pub fn OH_Input_SetAxisEventAction(
1218        axisEvent: *mut Input_AxisEvent,
1219        action: InputEvent_AxisAction,
1220    ) -> Input_Result;
1221    /// Obtains the axis event action.
1222    ///
1223    /// # Arguments
1224    ///
1225    /// * `axisEvent` - Axis event object. For details, see [`Input_AxisEvent`].
1226    ///
1227    /// * `action` - Axis event action. The values are defined in [`InputEvent_AxisAction`].
1228    ///
1229    /// # Returns
1230    ///
1231    /// * OH_Input_GetAxisEventAction function result code.
1232    /// [`INPUT_SUCCESS`] Obtains the axis event action success.
1233    ///
1234    /// [`INPUT_PARAMETER_ERROR`] The axisEvent is NULL or the action is NULL.
1235    ///
1236    ///
1237    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1238    ///
1239    /// Available since API-level: 12
1240    #[cfg(feature = "api-12")]
1241    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1242    pub fn OH_Input_GetAxisEventAction(
1243        axisEvent: *const Input_AxisEvent,
1244        action: *mut InputEvent_AxisAction,
1245    ) -> Input_Result;
1246    /// Sets the X coordinate of an axis event.
1247    ///
1248    /// # Arguments
1249    ///
1250    /// * `axisEvent` - Axis event object. For details, see [`Input_AxisEvent`].
1251    ///
1252    /// * `displayX` - X coordinate of the axis event.
1253    ///
1254    /// # Returns
1255    ///
1256    /// * OH_Input_SetAxisEventDisplayX function result code.
1257    /// [`INPUT_SUCCESS`] Sets the X coordinate of the axis event success.
1258    ///
1259    /// [`INPUT_PARAMETER_ERROR`] The axisEvent is NULL.
1260    ///
1261    ///
1262    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1263    ///
1264    /// Available since API-level: 12
1265    #[cfg(feature = "api-12")]
1266    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1267    pub fn OH_Input_SetAxisEventDisplayX(
1268        axisEvent: *mut Input_AxisEvent,
1269        displayX: f32,
1270    ) -> Input_Result;
1271    /// Obtains the X coordinate of an axis event.
1272    ///
1273    /// # Arguments
1274    ///
1275    /// * `axisEvent` - Axis event object. For details, see [`Input_AxisEvent`].
1276    ///
1277    /// * `displayX` - X coordinate of the axis event.
1278    ///
1279    /// # Returns
1280    ///
1281    /// * OH_Input_GetAxisEventDisplayX function result code.
1282    /// [`INPUT_SUCCESS`] Obtains the X coordinate of the axis event success.
1283    ///
1284    /// [`INPUT_PARAMETER_ERROR`] The axisEvent is NULL or the displayX is NULL.
1285    ///
1286    ///
1287    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1288    ///
1289    /// Available since API-level: 12
1290    #[cfg(feature = "api-12")]
1291    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1292    pub fn OH_Input_GetAxisEventDisplayX(
1293        axisEvent: *const Input_AxisEvent,
1294        displayX: *mut f32,
1295    ) -> Input_Result;
1296    /// Sets the Y coordinate of an axis event.
1297    ///
1298    /// # Arguments
1299    ///
1300    /// * `axisEvent` - Axis event object. For details, see [`Input_AxisEvent`].
1301    ///
1302    /// * `displayY` - Y coordinate of the axis event.
1303    ///
1304    /// # Returns
1305    ///
1306    /// * OH_Input_SetAxisEventDisplayY function result code.
1307    /// [`INPUT_SUCCESS`] Sets the Y coordinate of the axis event success.
1308    ///
1309    /// [`INPUT_PARAMETER_ERROR`] The axisEvent is NULL.
1310    ///
1311    ///
1312    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1313    ///
1314    /// Available since API-level: 12
1315    #[cfg(feature = "api-12")]
1316    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1317    pub fn OH_Input_SetAxisEventDisplayY(
1318        axisEvent: *mut Input_AxisEvent,
1319        displayY: f32,
1320    ) -> Input_Result;
1321    /// Obtains the Y coordinate of an axis event.
1322    ///
1323    /// # Arguments
1324    ///
1325    /// * `axisEvent` - Axis event object. For details, see [`Input_AxisEvent`].
1326    ///
1327    /// * `displayY` - Y coordinate of the axis event.
1328    ///
1329    /// # Returns
1330    ///
1331    /// * OH_Input_GetAxisEventDisplayY function result code.
1332    /// [`INPUT_SUCCESS`] Obtains the Y coordinate of the axis event success.
1333    ///
1334    /// [`INPUT_PARAMETER_ERROR`] The axisEvent is NULL or the displayY is NULL.
1335    ///
1336    ///
1337    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1338    ///
1339    /// Available since API-level: 12
1340    #[cfg(feature = "api-12")]
1341    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1342    pub fn OH_Input_GetAxisEventDisplayY(
1343        axisEvent: *const Input_AxisEvent,
1344        displayY: *mut f32,
1345    ) -> Input_Result;
1346    /// Sets the axis value of the axis type specified by the axis event.
1347    ///
1348    /// # Arguments
1349    ///
1350    /// * `axisEvent` - Axis event object. For details, see [`Input_AxisEvent`].
1351    ///
1352    /// * `axisType` - Axis type. The values are defined in [`InputEvent_AxisType`].
1353    ///
1354    /// * `axisValue` - Axis value.
1355    ///
1356    /// # Returns
1357    ///
1358    /// * OH_Input_SetAxisEventAxisValue function result code.
1359    /// [`INPUT_SUCCESS`] Sets the axis value of the axis event success.
1360    ///
1361    /// [`INPUT_PARAMETER_ERROR`] The axisEvent is NULL.
1362    ///
1363    ///
1364    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1365    ///
1366    /// Available since API-level: 12
1367    #[cfg(feature = "api-12")]
1368    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1369    pub fn OH_Input_SetAxisEventAxisValue(
1370        axisEvent: *mut Input_AxisEvent,
1371        axisType: InputEvent_AxisType,
1372        axisValue: f64,
1373    ) -> Input_Result;
1374    /// Obtains the axis value for the specified axis type of the axis event.
1375    ///
1376    /// # Arguments
1377    ///
1378    /// * `axisEvent` - Axis event object. For details, see [`Input_AxisEvent`].
1379    ///
1380    /// * `axisType` - Axis type. The values are defined in [`InputEvent_AxisType`].
1381    ///
1382    /// * `axisValue` - Axis value.
1383    ///
1384    /// # Returns
1385    ///
1386    /// * OH_Input_GetAxisEventAxisValue function result code.
1387    /// [`INPUT_SUCCESS`] Obtains the axis value of the axis event success.
1388    ///
1389    /// [`INPUT_PARAMETER_ERROR`] The axisEvent is NULL or the axisValue is NULL,
1390    /// or the axisType not found in the axisEvent.
1391    ///
1392    ///
1393    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1394    ///
1395    /// Available since API-level: 12
1396    #[cfg(feature = "api-12")]
1397    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1398    pub fn OH_Input_GetAxisEventAxisValue(
1399        axisEvent: *const Input_AxisEvent,
1400        axisType: InputEvent_AxisType,
1401        axisValue: *mut f64,
1402    ) -> Input_Result;
1403    /// Sets the time when an axis event occurs.
1404    ///
1405    /// # Arguments
1406    ///
1407    /// * `axisEvent` - Axis event object. For details, see [`Input_AxisEvent`].
1408    ///
1409    /// * `actionTime` - Time when an axis event occurs.
1410    ///
1411    /// # Returns
1412    ///
1413    /// * OH_Input_SetAxisEventActionTime function result code.
1414    /// [`INPUT_SUCCESS`] Sets the time when an axis event occurs success.
1415    ///
1416    /// [`INPUT_PARAMETER_ERROR`] The axisEvent is NULL.
1417    ///
1418    ///
1419    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1420    ///
1421    /// Available since API-level: 12
1422    #[cfg(feature = "api-12")]
1423    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1424    pub fn OH_Input_SetAxisEventActionTime(
1425        axisEvent: *mut Input_AxisEvent,
1426        actionTime: i64,
1427    ) -> Input_Result;
1428    /// Obtains the time when an axis event occurs.
1429    ///
1430    /// # Arguments
1431    ///
1432    /// * `axisEvent` - Axis event object. For details, see [`Input_AxisEvent`].
1433    ///
1434    /// * `actionTime` - Time when an axis event occurs.
1435    ///
1436    /// # Returns
1437    ///
1438    /// * OH_Input_GetAxisEventActionTime function result code.
1439    /// [`INPUT_SUCCESS`] Obtains the time when an axis event occurs success.
1440    ///
1441    /// [`INPUT_PARAMETER_ERROR`] The axisEvent is NULL or the actionTime is NULL.
1442    ///
1443    ///
1444    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1445    ///
1446    /// Available since API-level: 12
1447    #[cfg(feature = "api-12")]
1448    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1449    pub fn OH_Input_GetAxisEventActionTime(
1450        axisEvent: *const Input_AxisEvent,
1451        actionTime: *mut i64,
1452    ) -> Input_Result;
1453    /// Sets the axis event type.
1454    ///
1455    /// # Arguments
1456    ///
1457    /// * `axisEvent` - Axis event object. For details, see [`Input_AxisEvent`].
1458    ///
1459    /// * `axisEventType` - Axis event type. The values are defined in [`InputEvent_AxisEventType`].
1460    ///
1461    /// # Returns
1462    ///
1463    /// * OH_Input_SetAxisEventType function result code.
1464    /// [`INPUT_SUCCESS`] Sets the axis event type success.
1465    ///
1466    /// [`INPUT_PARAMETER_ERROR`] The axisEvent is NULL.
1467    ///
1468    ///
1469    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1470    ///
1471    /// Available since API-level: 12
1472    #[cfg(feature = "api-12")]
1473    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1474    pub fn OH_Input_SetAxisEventType(
1475        axisEvent: *mut Input_AxisEvent,
1476        axisEventType: InputEvent_AxisEventType,
1477    ) -> Input_Result;
1478    /// Obtains the axis event type.
1479    ///
1480    /// # Arguments
1481    ///
1482    /// * `axisEvent` - Axis event object.
1483    ///
1484    /// * `axisEventType` - Axis event type. The values are defined in [`InputEvent_AxisEventType`].
1485    ///
1486    /// # Returns
1487    ///
1488    /// * OH_Input_GetAxisEventType function result code.
1489    /// [`INPUT_SUCCESS`] Obtains the axis event type success.
1490    ///
1491    /// [`INPUT_PARAMETER_ERROR`] The axisEvent is NULL or the axisEventType is NULL.
1492    ///
1493    ///
1494    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1495    ///
1496    /// Available since API-level: 12
1497    #[cfg(feature = "api-12")]
1498    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1499    pub fn OH_Input_GetAxisEventType(
1500        axisEvent: *const Input_AxisEvent,
1501        axisEventType: *mut InputEvent_AxisEventType,
1502    ) -> Input_Result;
1503    /// Sets the axis event source type.
1504    ///
1505    /// # Arguments
1506    ///
1507    /// * `axisEvent` - Axis event object.
1508    ///
1509    /// * `sourceType` - Axis event source type. The values are defined in [`InputEvent_SourceType`].
1510    ///
1511    /// # Returns
1512    ///
1513    /// * OH_Input_SetAxisEventSourceType function result code.
1514    /// [`INPUT_SUCCESS`] Sets the axis event source type success.
1515    ///
1516    /// [`INPUT_PARAMETER_ERROR`] The axisEvent is NULL.
1517    ///
1518    ///
1519    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1520    ///
1521    /// Available since API-level: 12
1522    #[cfg(feature = "api-12")]
1523    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1524    pub fn OH_Input_SetAxisEventSourceType(
1525        axisEvent: *mut Input_AxisEvent,
1526        sourceType: InputEvent_SourceType,
1527    ) -> Input_Result;
1528    /// Obtains the axis event source type.
1529    ///
1530    /// # Arguments
1531    ///
1532    /// * `axisEvent` - Axis event object.
1533    ///
1534    /// * `sourceType` - Axis event source type. The values are defined in [`InputEvent_SourceType`].
1535    ///
1536    /// # Returns
1537    ///
1538    /// * OH_Input_GetAxisEventSourceType function result code.
1539    /// [`INPUT_SUCCESS`] Obtains the axis event source type success.
1540    ///
1541    /// [`INPUT_PARAMETER_ERROR`] The axisEvent is NULL or the sourceType is NULL.
1542    ///
1543    ///
1544    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1545    ///
1546    /// Available since API-level: 12
1547    #[cfg(feature = "api-12")]
1548    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1549    pub fn OH_Input_GetAxisEventSourceType(
1550        axisEvent: *const Input_AxisEvent,
1551        sourceType: *mut InputEvent_SourceType,
1552    ) -> Input_Result;
1553    /// Adds a listener of key events.
1554    ///
1555    /// ohos.permission.INPUT_MONITORING
1556    /// # Arguments
1557    ///
1558    /// * `callback` - - Callback used to receive key events.
1559    ///
1560    /// # Returns
1561    ///
1562    /// * OH_Input_AddKeyEventMonitor function result code.
1563    /// [`INPUT_SUCCESS`] Adds a listener of key events success.
1564    ///
1565    /// [`INPUT_PERMISSION_DENIED`] Permission verification failed.
1566    ///
1567    /// [`INPUT_PARAMETER_ERROR`] The callback is NULL.
1568    ///
1569    /// [`INPUT_SERVICE_EXCEPTION`] Failed to add the monitor because the service is exception.
1570    ///
1571    ///
1572    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1573    ///
1574    /// Available since API-level: 12
1575    #[cfg(feature = "api-12")]
1576    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1577    pub fn OH_Input_AddKeyEventMonitor(callback: Input_KeyEventCallback) -> Input_Result;
1578    /// Adds a listener for mouse events, including mouse click and movement events,
1579    /// but not scroll wheel events. Scroll wheel events are axis events.
1580    ///
1581    /// ohos.permission.INPUT_MONITORING
1582    /// # Arguments
1583    ///
1584    /// * `callback` - - Callback used to receive mouse events.
1585    ///
1586    /// # Returns
1587    ///
1588    /// * OH_Input_AddMouseEventMonitor function result code.
1589    /// [`INPUT_SUCCESS`] Adds a listener of mouse events success.
1590    ///
1591    /// [`INPUT_PERMISSION_DENIED`] Permission verification failed.
1592    ///
1593    /// [`INPUT_PARAMETER_ERROR`] The callback is NULL.
1594    ///
1595    /// [`INPUT_SERVICE_EXCEPTION`] Failed to add the monitor because the service is exception.
1596    ///
1597    ///
1598    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1599    ///
1600    /// Available since API-level: 12
1601    #[cfg(feature = "api-12")]
1602    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1603    pub fn OH_Input_AddMouseEventMonitor(callback: Input_MouseEventCallback) -> Input_Result;
1604    /// Add a listener for touch events.
1605    ///
1606    /// ohos.permission.INPUT_MONITORING
1607    /// # Arguments
1608    ///
1609    /// * `callback` - - Callback used to receive touch events.
1610    ///
1611    /// # Returns
1612    ///
1613    /// * OH_Input_AddTouchEventMonitor function result code.
1614    /// [`INPUT_SUCCESS`] Adds a listener of touch events success.
1615    ///
1616    /// [`INPUT_PERMISSION_DENIED`] Permission verification failed.
1617    ///
1618    /// [`INPUT_PARAMETER_ERROR`] The callback is NULL.
1619    ///
1620    /// [`INPUT_SERVICE_EXCEPTION`] Failed to add the monitor because the service is exception.
1621    ///
1622    ///
1623    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1624    ///
1625    /// Available since API-level: 12
1626    #[cfg(feature = "api-12")]
1627    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1628    pub fn OH_Input_AddTouchEventMonitor(callback: Input_TouchEventCallback) -> Input_Result;
1629    /// Adds a listener for all types of axis events.
1630    /// The axis event types are defined in [`InputEvent_AxisEventType`].
1631    ///
1632    /// ohos.permission.INPUT_MONITORING
1633    /// # Arguments
1634    ///
1635    /// * `callback` - - Callback used to receive axis events.
1636    ///
1637    /// # Returns
1638    ///
1639    /// * OH_Input_AddAxisEventMonitorForAll function result code.
1640    /// [`INPUT_SUCCESS`] Adds a listener for all types of axis events success.
1641    ///
1642    /// [`INPUT_PERMISSION_DENIED`] Permission verification failed.
1643    ///
1644    /// [`INPUT_PARAMETER_ERROR`] The callback is NULL.
1645    ///
1646    /// [`INPUT_SERVICE_EXCEPTION`] Failed to add the monitor because the service is exception.
1647    ///
1648    ///
1649    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1650    ///
1651    /// Available since API-level: 12
1652    #[cfg(feature = "api-12")]
1653    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1654    pub fn OH_Input_AddAxisEventMonitorForAll(callback: Input_AxisEventCallback) -> Input_Result;
1655    /// Adds a listener for the specified type of axis events.
1656    ///
1657    /// ohos.permission.INPUT_MONITORING
1658    /// # Arguments
1659    ///
1660    /// * `axisEventType` - - Axis event type. The values are defined in [`InputEvent_AxisEventType`].
1661    ///
1662    /// * `callback` - - Callback used to receive the specified type of axis events.
1663    ///
1664    /// # Returns
1665    ///
1666    /// * OH_Input_AddAxisEventMonitor function result code.
1667    /// [`INPUT_SUCCESS`] Adds a listener for the specified types of axis events success.
1668    ///
1669    /// [`INPUT_PERMISSION_DENIED`] Permission verification failed.
1670    ///
1671    /// [`INPUT_PARAMETER_ERROR`] The callback is NULL.
1672    ///
1673    /// [`INPUT_SERVICE_EXCEPTION`] Failed to add the monitor because the service is exception.
1674    ///
1675    ///
1676    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1677    ///
1678    /// Available since API-level: 12
1679    #[cfg(feature = "api-12")]
1680    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1681    pub fn OH_Input_AddAxisEventMonitor(
1682        axisEventType: InputEvent_AxisEventType,
1683        callback: Input_AxisEventCallback,
1684    ) -> Input_Result;
1685    /// Removes a key event listener.
1686    ///
1687    /// ohos.permission.INPUT_MONITORING
1688    /// # Arguments
1689    ///
1690    /// * `callback` - - Callback for the key event listener.
1691    ///
1692    /// # Returns
1693    ///
1694    /// * OH_Input_RemoveKeyEventMonitor function result code.
1695    /// [`INPUT_SUCCESS`] Removes a key event listener success.
1696    ///
1697    /// [`INPUT_PERMISSION_DENIED`] Permission verification failed.
1698    ///
1699    /// [`INPUT_PARAMETER_ERROR`] The callback is NULL or has not been added.
1700    ///
1701    /// [`INPUT_SERVICE_EXCEPTION`] Fail to remove the monitor because the service is exception.
1702    ///
1703    ///
1704    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1705    ///
1706    /// Available since API-level: 12
1707    #[cfg(feature = "api-12")]
1708    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1709    pub fn OH_Input_RemoveKeyEventMonitor(callback: Input_KeyEventCallback) -> Input_Result;
1710    /// Removes a mouse event listener.
1711    ///
1712    /// ohos.permission.INPUT_MONITORING
1713    /// # Arguments
1714    ///
1715    /// * `callback` - - Callback for the mouse event listener.
1716    ///
1717    /// # Returns
1718    ///
1719    /// * OH_Input_RemoveMouseEventMonitor function result code.
1720    /// [`INPUT_SUCCESS`] Removes a mouse event listener success.
1721    ///
1722    /// [`INPUT_PERMISSION_DENIED`] Permission verification failed.
1723    ///
1724    /// [`INPUT_PARAMETER_ERROR`] The callback is NULL or has not been added.
1725    ///
1726    /// [`INPUT_SERVICE_EXCEPTION`] Fail to remove the monitor because the service is exception.
1727    ///
1728    ///
1729    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1730    ///
1731    /// Available since API-level: 12
1732    #[cfg(feature = "api-12")]
1733    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1734    pub fn OH_Input_RemoveMouseEventMonitor(callback: Input_MouseEventCallback) -> Input_Result;
1735    /// Removes a touch event listener.
1736    ///
1737    /// ohos.permission.INPUT_MONITORING
1738    /// # Arguments
1739    ///
1740    /// * `callback` - - Callback for the touch event listener.
1741    ///
1742    /// # Returns
1743    ///
1744    /// * OH_Input_RemoveTouchEventMonitor function result code.
1745    /// [`INPUT_SUCCESS`] Removes a touch event listener success.
1746    ///
1747    /// [`INPUT_PERMISSION_DENIED`] Permission verification failed.
1748    ///
1749    /// [`INPUT_PARAMETER_ERROR`] The callback is NULL or has not been added.
1750    ///
1751    /// [`INPUT_SERVICE_EXCEPTION`] Fail to remove the monitor because the service is exception.
1752    ///
1753    ///
1754    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1755    ///
1756    /// Available since API-level: 12
1757    #[cfg(feature = "api-12")]
1758    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1759    pub fn OH_Input_RemoveTouchEventMonitor(callback: Input_TouchEventCallback) -> Input_Result;
1760    /// Removes the listener for all types of axis events.
1761    ///
1762    /// ohos.permission.INPUT_MONITORING
1763    /// # Arguments
1764    ///
1765    /// * `callback` - - Callback for the listener used to listen for all types of axis events.
1766    ///
1767    /// # Returns
1768    ///
1769    /// * OH_Input_RemoveAxisEventMonitorForAll function result code.
1770    /// [`INPUT_SUCCESS`] Removes the listener for all types of axis events success.
1771    ///
1772    /// [`INPUT_PERMISSION_DENIED`] Permission verification failed.
1773    ///
1774    /// [`INPUT_PARAMETER_ERROR`] The callback is NULL or has not been added.
1775    ///
1776    /// [`INPUT_SERVICE_EXCEPTION`] Fail to remove the monitor because the service is exception.
1777    ///
1778    ///
1779    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1780    ///
1781    /// Available since API-level: 12
1782    #[cfg(feature = "api-12")]
1783    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1784    pub fn OH_Input_RemoveAxisEventMonitorForAll(callback: Input_AxisEventCallback)
1785        -> Input_Result;
1786    /// Removes the listener for the specified type of axis events.
1787    ///
1788    /// ohos.permission.INPUT_MONITORING
1789    /// # Arguments
1790    ///
1791    /// * `axisEventType` - - Axis event type. The axis event type is defined in [`InputEvent_AxisEventType`].
1792    ///
1793    /// * `callback` - - Callback for the listener used to listen for the specified type of axis events.
1794    ///
1795    /// # Returns
1796    ///
1797    /// * OH_Input_RemoveAxisEventMonitor function result code.
1798    /// [`INPUT_SUCCESS`] Removes the listener for the specified type of axis events success.
1799    ///
1800    /// [`INPUT_PERMISSION_DENIED`] Permission verification failed.
1801    ///
1802    /// [`INPUT_PARAMETER_ERROR`] The callback is NULL or has not been added.
1803    ///
1804    /// [`INPUT_SERVICE_EXCEPTION`] Fail to remove the monitor because the service is exception.
1805    ///
1806    ///
1807    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1808    ///
1809    /// Available since API-level: 12
1810    #[cfg(feature = "api-12")]
1811    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1812    pub fn OH_Input_RemoveAxisEventMonitor(
1813        axisEventType: InputEvent_AxisEventType,
1814        callback: Input_AxisEventCallback,
1815    ) -> Input_Result;
1816    /// Adds a key event interceptor. If multiple interceptors are added, only the first one takes effect.
1817    ///
1818    /// ohos.permission.INTERCEPT_INPUT_EVENT
1819    /// # Arguments
1820    ///
1821    /// * `callback` - - Callback used to receive key events.
1822    ///
1823    /// * `option` - - Options for event interception. If **null** is passed, the default value is used.
1824    ///
1825    /// # Returns
1826    ///
1827    /// * OH_Input_AddKeyEventInterceptor function result code.
1828    /// [`INPUT_SUCCESS`] Adds a key event interceptor success.
1829    ///
1830    /// [`INPUT_PERMISSION_DENIED`] Permission verification failed.
1831    ///
1832    /// [`INPUT_PARAMETER_ERROR`] The callback is NULL.
1833    ///
1834    /// [`INPUT_REPEAT_INTERCEPTOR`] Interceptor repeatedly created for an application.
1835    ///
1836    /// [`INPUT_SERVICE_EXCEPTION`] Failed to add the interceptor because the service is exception.
1837    ///
1838    ///
1839    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1840    ///
1841    /// Available since API-level: 12
1842    #[cfg(feature = "api-12")]
1843    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1844    pub fn OH_Input_AddKeyEventInterceptor(
1845        callback: Input_KeyEventCallback,
1846        option: *mut Input_InterceptorOptions,
1847    ) -> Input_Result;
1848    /// Adds an interceptor for input events, including mouse, touch, and axis events.
1849    /// If multiple interceptors are added, only the first one takes effect.
1850    ///
1851    /// ohos.permission.INTERCEPT_INPUT_EVENT
1852    /// # Arguments
1853    ///
1854    /// * `callback` - - Pointer to the structure of the callback for the input event interceptor.
1855    /// For details, see [`Input_InterceptorEventCallback`].
1856    ///
1857    /// * `option` - - Options for event interception. If **null** is passed, the default value is used.
1858    ///
1859    /// # Returns
1860    ///
1861    /// * OH_Input_AddInputEventInterceptor function result code.
1862    /// [`INPUT_SUCCESS`] Adds an interceptor for input events success.
1863    ///
1864    /// [`INPUT_PERMISSION_DENIED`] Permission verification failed.
1865    ///
1866    /// [`INPUT_PARAMETER_ERROR`] The callback is NULL.
1867    ///
1868    /// [`INPUT_REPEAT_INTERCEPTOR`] Interceptor repeatedly created for an application.
1869    ///
1870    /// [`INPUT_SERVICE_EXCEPTION`] Failed to add the interceptor because the service is exception.
1871    ///
1872    ///
1873    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1874    ///
1875    /// Available since API-level: 12
1876    #[cfg(feature = "api-12")]
1877    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1878    pub fn OH_Input_AddInputEventInterceptor(
1879        callback: *mut Input_InterceptorEventCallback,
1880        option: *mut Input_InterceptorOptions,
1881    ) -> Input_Result;
1882    /// Removes a key event interceptor.
1883    ///
1884    /// ohos.permission.INTERCEPT_INPUT_EVENT
1885    ///
1886    /// # Returns
1887    ///
1888    /// * OH_Input_RemoveKeyEventInterceptor function result code.
1889    /// [`INPUT_SUCCESS`]Removes a key event interceptor success.
1890    ///
1891    /// [`INPUT_PERMISSION_DENIED`] Permission verification failed.
1892    ///
1893    /// [`INPUT_SERVICE_EXCEPTION`] Failed to remove the interceptor because the service is exception.
1894    ///
1895    ///
1896    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1897    ///
1898    /// Available since API-level: 12
1899    #[cfg(feature = "api-12")]
1900    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1901    pub fn OH_Input_RemoveKeyEventInterceptor() -> Input_Result;
1902    /// Removes an interceptor for input events, including mouse, touch, and axis events.
1903    ///
1904    /// ohos.permission.INTERCEPT_INPUT_EVENT
1905    ///
1906    /// # Returns
1907    ///
1908    /// * OH_Input_RemoveInputEventInterceptor function result code.
1909    /// [`INPUT_SUCCESS`] Removes an interceptor for input events success.
1910    ///
1911    /// [`INPUT_PERMISSION_DENIED`] Permission verification failed.
1912    ///
1913    /// [`INPUT_SERVICE_EXCEPTION`] Failed to remove the interceptor because the service is exception.
1914    ///
1915    ///
1916    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1917    ///
1918    /// Available since API-level: 12
1919    #[cfg(feature = "api-12")]
1920    #[cfg_attr(docsrs, doc(cfg(feature = "api-12")))]
1921    pub fn OH_Input_RemoveInputEventInterceptor() -> Input_Result;
1922    /// Obtains the interval since the last system input event.
1923    ///
1924    /// # Arguments
1925    ///
1926    /// * `timeInterval` - Interval, in microseconds.
1927    ///
1928    /// # Returns
1929    ///
1930    /// * OH_Input_GetIntervalSinceLastInput status code, specifically.
1931    /// [`INPUT_SUCCESS`] if the Operation is successful.
1932    ///
1933    /// [`INPUT_SERVICE_EXCEPTION`] Failed to get the interval because the service is exception.
1934    ///
1935    /// [`INPUT_PARAMETER_ERROR`] The timeInterval is NULL.
1936    ///
1937    ///
1938    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1939    ///
1940    /// Available since API-level: 14
1941    #[cfg(feature = "api-14")]
1942    #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
1943    pub fn OH_Input_GetIntervalSinceLastInput(timeInterval: *mut i64) -> Input_Result;
1944    /// Creates a hot key object.
1945    ///
1946    ///
1947    /// # Returns
1948    ///
1949    /// * Returns an [`Input_Hotkey`] pointer object if the operation is successful. Otherwise, a null pointer is
1950    /// returned. The possible cause is memory allocation failure.
1951    ///
1952    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1953    ///
1954    /// Available since API-level: 14
1955    #[cfg(feature = "api-14")]
1956    #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
1957    pub fn OH_Input_CreateHotkey() -> *mut Input_Hotkey;
1958    /// Destroys a hot key object.
1959    ///
1960    /// # Arguments
1961    ///
1962    /// * `hotkey` - Hot key object.
1963    ///
1964    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1965    ///
1966    /// Available since API-level: 14
1967    #[cfg(feature = "api-14")]
1968    #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
1969    pub fn OH_Input_DestroyHotkey(hotkey: *mut *mut Input_Hotkey);
1970    /// Sets a modifier key.
1971    ///
1972    /// # Arguments
1973    ///
1974    /// * `hotkey` - Hotkey key object.
1975    ///
1976    /// * `preKeys` - List of modifier keys.
1977    ///
1978    /// * `size` - Number of modifier keys. One or two modifier keys are supported.
1979    ///
1980    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
1981    ///
1982    /// Available since API-level: 14
1983    #[cfg(feature = "api-14")]
1984    #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
1985    pub fn OH_Input_SetPreKeys(hotkey: *mut Input_Hotkey, preKeys: *mut i32, size: i32);
1986    /// Obtains a modifier key.
1987    ///
1988    /// # Arguments
1989    ///
1990    /// * `hotkey` - Hotkey key object.
1991    ///
1992    /// * `preKeys` - List of modifier keys.
1993    ///
1994    /// * `preKeyCount` - Number of modifier keys.
1995    ///
1996    /// # Returns
1997    ///
1998    /// * OH_Input_GetPreKeys status code, specifically,
1999    /// [`INPUT_SUCCESS`] if the operation is successful;
2000    ///
2001    /// [`INPUT_PARAMETER_ERROR`] The hotkey is NULL or the pressedKeys is NULL or the pressedKeyCount
2002    /// is NULL;
2003    ///
2004    /// [`INPUT_DEVICE_NOT_SUPPORTED`] Capability not supported.
2005    ///
2006    ///
2007    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
2008    ///
2009    /// Available since API-level: 14
2010    #[cfg(feature = "api-14")]
2011    #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
2012    pub fn OH_Input_GetPreKeys(
2013        hotkey: *const Input_Hotkey,
2014        preKeys: *mut *mut i32,
2015        preKeyCount: *mut i32,
2016    ) -> Input_Result;
2017    /// Sets a modified key.
2018    ///
2019    /// # Arguments
2020    ///
2021    /// * `hotkey` - Hotkey key object.
2022    ///
2023    /// * `finalKey` - Modified key. Only one modified key is supported.
2024    ///
2025    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
2026    ///
2027    /// Available since API-level: 14
2028    #[cfg(feature = "api-14")]
2029    #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
2030    pub fn OH_Input_SetFinalKey(hotkey: *mut Input_Hotkey, finalKey: i32);
2031    /// Obtains a modified key.
2032    ///
2033    /// # Arguments
2034    ///
2035    /// * `hotkey` - Hotkey key object.
2036    ///
2037    /// * `finalKeyCode` - Returns the key value of the decorated key.
2038    ///
2039    /// # Returns
2040    ///
2041    /// * OH_Input_GetfinalKey status code, specifically,
2042    /// [`INPUT_SUCCESS`] if the operation is successful;
2043    ///
2044    /// [`INPUT_PARAMETER_ERROR`] The hotkey is NULL or the finalKeyCode is NULL;
2045    ///
2046    /// [`INPUT_DEVICE_NOT_SUPPORTED`] Capability not supported.
2047    ///
2048    ///
2049    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
2050    ///
2051    /// Available since API-level: 14
2052    #[cfg(feature = "api-14")]
2053    #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
2054    pub fn OH_Input_GetFinalKey(
2055        hotkey: *const Input_Hotkey,
2056        finalKeyCode: *mut i32,
2057    ) -> Input_Result;
2058    /// Creates an array of [`Input_Hotkey`] instances.
2059    ///
2060    /// # Arguments
2061    ///
2062    /// * `count` - Number of [`Input_Hotkey`] instances to be created. The count must be the same as the number of
2063    /// system shortcut keys.
2064    ///
2065    /// # Returns
2066    ///
2067    /// * Returns a pointer to an array of [`Input_Hotkey`] instances if the operation is successful. If the
2068    /// operation fails, a null pointer is returned. The possible cause is memory allocation failure or count is not equal
2069    /// to the number of system hotkeys.
2070    ///
2071    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
2072    ///
2073    /// Available since API-level: 14
2074    #[cfg(feature = "api-14")]
2075    #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
2076    pub fn OH_Input_CreateAllSystemHotkeys(count: i32) -> *mut *mut Input_Hotkey;
2077    /// Destroys an array of [`Input_Hotkey`] instances and reclaims memory.
2078    ///
2079    /// # Arguments
2080    ///
2081    /// * `hotkeys` - Pointer to an array of [`Input_Hotkey`] instances created by the
2082    /// [`OH_Input_CreateAllSystemHotkeys`] method.
2083    ///
2084    /// * `count` - Count of the array to be destroyed, which must be the same as the number of system shortcut keys.
2085    ///
2086    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
2087    ///
2088    /// Available since API-level: 14
2089    #[cfg(feature = "api-14")]
2090    #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
2091    pub fn OH_Input_DestroyAllSystemHotkeys(hotkeys: *mut *mut Input_Hotkey, count: i32);
2092    /// Obtains all hot keys supported by the system.
2093    ///
2094    /// # Arguments
2095    ///
2096    /// * `hotkey` - Array of [`Input_Hotkey`] instances.
2097    /// When calling this API for the first time, you can pass NULL to obtain the array length.
2098    ///
2099    /// * `count` - Number of hot keys supported by the system.
2100    ///
2101    /// # Returns
2102    ///
2103    /// * OH_Input_GetAllSystemHotkeys status code, specifically,
2104    /// [`INPUT_SUCCESS`] if the operation is successful;
2105    ///
2106    /// [`INPUT_PARAMETER_ERROR`] The hotkey or count is NULL, or the value of count does not match the number
2107    /// of system shortcut keys supported by the system;
2108    /// [`INPUT_DEVICE_NOT_SUPPORTED`] Capability not supported.
2109    ///
2110    ///
2111    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
2112    ///
2113    /// Available since API-level: 14
2114    #[cfg(feature = "api-14")]
2115    #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
2116    pub fn OH_Input_GetAllSystemHotkeys(
2117        hotkey: *mut *mut Input_Hotkey,
2118        count: *mut i32,
2119    ) -> Input_Result;
2120    /// Specifies whether to report repeated key events.
2121    ///
2122    /// # Arguments
2123    ///
2124    /// * `hotkey` - Shortcut key object.
2125    ///
2126    /// * `isRepeat` - Whether to report repeated key events.
2127    /// The value <b>true</b> means to report repeated key events, and the value <b>false</b> means the opposite.
2128    ///
2129    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
2130    ///
2131    /// Available since API-level: 14
2132    #[cfg(feature = "api-14")]
2133    #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
2134    pub fn OH_Input_SetRepeat(hotkey: *mut Input_Hotkey, isRepeat: bool);
2135    /// Checks whether to report repeated key events.
2136    ///
2137    /// # Arguments
2138    ///
2139    /// * `hotkey` - Shortcut key object.
2140    ///
2141    /// * `isRepeat` - Whether a key event is repeated.
2142    ///
2143    /// # Returns
2144    ///
2145    /// * OH_Input_GetIsRepeat status code, specifically,
2146    /// [`INPUT_SUCCESS`] if the operation is successful;
2147    ///
2148    /// [`INPUT_PARAMETER_ERROR`] otherwise;
2149    ///
2150    /// [`INPUT_DEVICE_NOT_SUPPORTED`] Capability not supported.
2151    ///
2152    ///
2153    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
2154    ///
2155    /// Available since API-level: 14
2156    #[cfg(feature = "api-14")]
2157    #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
2158    pub fn OH_Input_GetRepeat(hotkey: *const Input_Hotkey, isRepeat: *mut bool) -> Input_Result;
2159    /// Subscribes to shortcut key events.
2160    ///
2161    /// # Arguments
2162    ///
2163    /// * `hotkey` - Shortcut key object.
2164    ///
2165    /// * `callback` - Callback used to return shortcut key events.
2166    ///
2167    /// # Returns
2168    ///
2169    /// * OH_Input_AddHotkeyMonitor status code, specifically,
2170    /// [`INPUT_SUCCESS`] if the operation is successful;
2171    ///
2172    /// [`INPUT_PARAMETER_ERROR`] if hotkey or callback is NULL;
2173    ///
2174    /// [`INPUT_DEVICE_NOT_SUPPORTED`] Capability not supported;
2175    ///
2176    /// [`INPUT_OCCUPIED_BY_SYSTEM`] The hotkey has been used by the system. You can call the [`GetAllSystemHotkeys`] interface to query all system shortcut keys.
2177    ///
2178    /// [`INPUT_OCCUPIED_BY_OTHER`] The hotkey has been subscribed to by another.
2179    ///
2180    ///
2181    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
2182    ///
2183    /// Available since API-level: 14
2184    #[cfg(feature = "api-14")]
2185    #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
2186    pub fn OH_Input_AddHotkeyMonitor(
2187        hotkey: *const Input_Hotkey,
2188        callback: Input_HotkeyCallback,
2189    ) -> Input_Result;
2190    /// Unsubscribes from shortcut key events.
2191    ///
2192    /// # Arguments
2193    ///
2194    /// * `hotkey` - Shortcut key object.
2195    ///
2196    /// * `callback` - Callback used to return shortcut key events.
2197    ///
2198    /// # Returns
2199    ///
2200    /// * OH_Input_RemoveHotkeyMonitor status code, specifically,
2201    /// [`INPUT_SUCCESS`] if the operation is successful;
2202    ///
2203    /// [`INPUT_PARAMETER_ERROR`] if hotkey or callback is NULL;
2204    ///
2205    /// [`INPUT_DEVICE_NOT_SUPPORTED`] Capability not supported.
2206    ///
2207    ///
2208    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
2209    ///
2210    /// Available since API-level: 14
2211    #[cfg(feature = "api-14")]
2212    #[cfg_attr(docsrs, doc(cfg(feature = "api-14")))]
2213    pub fn OH_Input_RemoveHotkeyMonitor(
2214        hotkey: *const Input_Hotkey,
2215        callback: Input_HotkeyCallback,
2216    ) -> Input_Result;
2217    /// Obtains the IDs of all input devices.
2218    ///
2219    /// # Arguments
2220    ///
2221    /// * `deviceIds` - Array of input device IDs.
2222    ///
2223    /// * `inSize` - Size of the array of input device IDs.
2224    ///
2225    /// * `outSize` - Length of the list of input device IDs. The value cannot be greater than the value of inSize.
2226    ///
2227    /// # Returns
2228    ///
2229    /// * OH_Input_GetDeviceIds result code, specifically,
2230    /// [`INPUT_SUCCESS`] if the operation is successful;
2231    /// [`INPUT_PARAMETER_ERROR`] if deviceIds or outSize is a null pointer or inSize is less than 0.
2232    ///
2233    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
2234    ///
2235    /// Available since API-level: 13
2236    #[cfg(feature = "api-13")]
2237    #[cfg_attr(docsrs, doc(cfg(feature = "api-13")))]
2238    pub fn OH_Input_GetDeviceIds(
2239        deviceIds: *mut i32,
2240        inSize: i32,
2241        outSize: *mut i32,
2242    ) -> Input_Result;
2243    /// Obtains the information about an input device.
2244    ///
2245    /// # Arguments
2246    ///
2247    /// * `deviceId` - Device ID.
2248    ///
2249    /// * `deviceInfo` - Pointer to an [`Input_DeviceInfo`] object.
2250    ///
2251    /// # Returns
2252    ///
2253    /// * OH_Input_GetDevice result code, specifically,
2254    /// [`INPUT_SUCCESS`] if the operation is successful;
2255    /// [`INPUT_PARAMETER_ERROR`] if the deviceInfo is a null pointer or the deviceId is invalid.
2256    /// You can use the [`OH_Input_GetDeviceIds`] interface to query the device IDs supported by the system.
2257    ///
2258    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
2259    ///
2260    /// Available since API-level: 13
2261    #[cfg(feature = "api-13")]
2262    #[cfg_attr(docsrs, doc(cfg(feature = "api-13")))]
2263    pub fn OH_Input_GetDevice(
2264        deviceId: i32,
2265        deviceInfo: *mut *mut Input_DeviceInfo,
2266    ) -> Input_Result;
2267    /// Creates a deviceInfo object.
2268    ///
2269    ///
2270    /// # Returns
2271    ///
2272    /// * Pointer to an [`Input_DeviceInfo`] object if the operation is successful;
2273    /// a null pointer otherwise (possibly because of a memory allocation failure).
2274    ///
2275    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
2276    ///
2277    /// Available since API-level: 13
2278    #[cfg(feature = "api-13")]
2279    #[cfg_attr(docsrs, doc(cfg(feature = "api-13")))]
2280    pub fn OH_Input_CreateDeviceInfo() -> *mut Input_DeviceInfo;
2281    /// Destroys a deviceInfo object.
2282    ///
2283    /// # Arguments
2284    ///
2285    /// * `deviceInfo` - information object. For details, see [`Input_DeviceInfo`].
2286    ///
2287    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
2288    ///
2289    /// Available since API-level: 13
2290    #[cfg(feature = "api-13")]
2291    #[cfg_attr(docsrs, doc(cfg(feature = "api-13")))]
2292    pub fn OH_Input_DestroyDeviceInfo(deviceInfo: *mut *mut Input_DeviceInfo);
2293    /// Obtains the keyboard type of an input device.
2294    ///
2295    /// # Arguments
2296    ///
2297    /// * `deviceId` - Device ID.
2298    ///
2299    /// * `keyboardType` - Pointer to the keyboard type of the input device.
2300    ///
2301    /// # Returns
2302    ///
2303    /// * OH_Input_GetKeyboardType result code, specifically,
2304    /// [`INPUT_SUCCESS`] if the operation is successful;
2305    /// [`INPUT_PARAMETER_ERROR`] if the device ID is invalid or keyboardType is a null pointer.
2306    ///
2307    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
2308    ///
2309    /// Available since API-level: 13
2310    #[cfg(feature = "api-13")]
2311    #[cfg_attr(docsrs, doc(cfg(feature = "api-13")))]
2312    pub fn OH_Input_GetKeyboardType(deviceId: i32, keyboardType: *mut i32) -> Input_Result;
2313    /// Obtains the ID of an input device.
2314    ///
2315    /// # Arguments
2316    ///
2317    /// * `deviceInfo` - information object. For details, see [`Input_DeviceInfo`].
2318    ///
2319    /// * `id` - Pointer to the ID of the input device.
2320    ///
2321    /// # Returns
2322    ///
2323    /// * OH_Input_GetDeviceId result code, specifically,
2324    /// [`INPUT_SUCCESS`] if the operation is successful;
2325    /// [`INPUT_PARAMETER_ERROR`] if deviceInfo or id is a null pointer.
2326    ///
2327    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
2328    ///
2329    /// Available since API-level: 13
2330    #[cfg(feature = "api-13")]
2331    #[cfg_attr(docsrs, doc(cfg(feature = "api-13")))]
2332    pub fn OH_Input_GetDeviceId(deviceInfo: *mut Input_DeviceInfo, id: *mut i32) -> Input_Result;
2333    /// Obtains the name of an input device.
2334    ///
2335    /// # Arguments
2336    ///
2337    /// * `deviceInfo` - information object. For details, see [`Input_DeviceInfo`].
2338    ///
2339    /// * `name` - Pointer to the name of the input device.
2340    ///
2341    /// # Returns
2342    ///
2343    /// * OH_Input_GetDeviceName result code, specifically,
2344    /// [`INPUT_SUCCESS`] if the operation is successful;
2345    /// [`INPUT_PARAMETER_ERROR`] if deviceInfo or name is a null pointer.
2346    ///
2347    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
2348    ///
2349    /// Available since API-level: 13
2350    #[cfg(feature = "api-13")]
2351    #[cfg_attr(docsrs, doc(cfg(feature = "api-13")))]
2352    pub fn OH_Input_GetDeviceName(
2353        deviceInfo: *mut Input_DeviceInfo,
2354        name: *mut *mut ::core::ffi::c_char,
2355    ) -> Input_Result;
2356    /// Obtains the capabilities of an input device, for example, a touchscreen, touchpad, or keyboard.
2357    ///
2358    /// # Arguments
2359    ///
2360    /// * `deviceInfo` - information object. For details, see [`Input_DeviceInfo`].
2361    ///
2362    /// * `capabilities` - Pointer to the capabilities of the input device.
2363    ///
2364    /// # Returns
2365    ///
2366    /// * OH_Input_GetCapabilities result code, specifically,
2367    /// [`INPUT_SUCCESS`] if the operation is successful;
2368    /// [`INPUT_PARAMETER_ERROR`] if deviceInfo or capabilities is a null pointer.
2369    ///
2370    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
2371    ///
2372    /// Available since API-level: 13
2373    #[cfg(feature = "api-13")]
2374    #[cfg_attr(docsrs, doc(cfg(feature = "api-13")))]
2375    pub fn OH_Input_GetCapabilities(
2376        deviceInfo: *mut Input_DeviceInfo,
2377        capabilities: *mut i32,
2378    ) -> Input_Result;
2379    /// Obtains the version information of an input device.
2380    ///
2381    /// # Arguments
2382    ///
2383    /// * `deviceInfo` - information object. For details, see [`Input_DeviceInfo`].
2384    ///
2385    /// * `version` - Pointer to the version information of the input device.
2386    ///
2387    /// # Returns
2388    ///
2389    /// * OH_Input_GetDeviceVersion result code, specifically,
2390    /// [`INPUT_SUCCESS`] if the operation is successful;
2391    /// [`INPUT_PARAMETER_ERROR`] if deviceInfo or version is a null pointer.
2392    ///
2393    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
2394    ///
2395    /// Available since API-level: 13
2396    #[cfg(feature = "api-13")]
2397    #[cfg_attr(docsrs, doc(cfg(feature = "api-13")))]
2398    pub fn OH_Input_GetDeviceVersion(
2399        deviceInfo: *mut Input_DeviceInfo,
2400        version: *mut i32,
2401    ) -> Input_Result;
2402    /// Obtains the product information of an input device.
2403    ///
2404    /// # Arguments
2405    ///
2406    /// * `deviceInfo` - information object. For details, see [`Input_DeviceInfo`].
2407    ///
2408    /// * `product` - Pointer to the product information of the input device.
2409    ///
2410    /// # Returns
2411    ///
2412    /// * OH_Input_GetDeviceProduct result code, specifically,
2413    /// [`INPUT_SUCCESS`] if the operation is successful;
2414    /// [`INPUT_PARAMETER_ERROR`] if deviceInfo or product is a null pointer.
2415    ///
2416    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
2417    ///
2418    /// Available since API-level: 13
2419    #[cfg(feature = "api-13")]
2420    #[cfg_attr(docsrs, doc(cfg(feature = "api-13")))]
2421    pub fn OH_Input_GetDeviceProduct(
2422        deviceInfo: *mut Input_DeviceInfo,
2423        product: *mut i32,
2424    ) -> Input_Result;
2425    /// Obtains the vendor information of an input device.
2426    ///
2427    /// # Arguments
2428    ///
2429    /// * `deviceInfo` - information object. For details, see [`Input_DeviceInfo`].
2430    ///
2431    /// * `vendor` - Pointer to the vendor information of the input device.
2432    ///
2433    /// # Returns
2434    ///
2435    /// * OH_Input_GetDeviceVendor result code, specifically,
2436    /// [`INPUT_SUCCESS`] if the operation is successful;
2437    /// [`INPUT_PARAMETER_ERROR`] if deviceInfo or vendor is a null pointer.
2438    ///
2439    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
2440    ///
2441    /// Available since API-level: 13
2442    #[cfg(feature = "api-13")]
2443    #[cfg_attr(docsrs, doc(cfg(feature = "api-13")))]
2444    pub fn OH_Input_GetDeviceVendor(
2445        deviceInfo: *mut Input_DeviceInfo,
2446        vendor: *mut i32,
2447    ) -> Input_Result;
2448    /// Obtains the physical address of an input device.
2449    ///
2450    /// # Arguments
2451    ///
2452    /// * `deviceInfo` - information object. For details, see [`Input_DeviceInfo`].
2453    ///
2454    /// * `address` - Pointer to the physical address of the input device.
2455    ///
2456    /// # Returns
2457    ///
2458    /// * OH_Input_GetDeviceAddress result code, specifically,
2459    /// [`INPUT_SUCCESS`] if the operation is successful;
2460    /// [`INPUT_PARAMETER_ERROR`] if deviceInfo or address is a null pointer.
2461    ///
2462    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
2463    ///
2464    /// Available since API-level: 13
2465    #[cfg(feature = "api-13")]
2466    #[cfg_attr(docsrs, doc(cfg(feature = "api-13")))]
2467    pub fn OH_Input_GetDeviceAddress(
2468        deviceInfo: *mut Input_DeviceInfo,
2469        address: *mut *mut ::core::ffi::c_char,
2470    ) -> Input_Result;
2471    /// Registers a listener for device hot swap events.
2472    ///
2473    /// # Arguments
2474    ///
2475    /// * `listener` - Pointer to an [`Input_DeviceListener`] object.
2476    ///
2477    ///
2478    /// # Returns
2479    ///
2480    /// * OH_Input_RegisterDeviceListener status code, specifically,
2481    /// [`INPUT_SUCCESS`] if the operation is successful;
2482    ///
2483    /// [`INPUT_PARAMETER_ERROR`] if listener is NULL;
2484    ///
2485    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
2486    ///
2487    /// Available since API-level: 13
2488    #[cfg(feature = "api-13")]
2489    #[cfg_attr(docsrs, doc(cfg(feature = "api-13")))]
2490    pub fn OH_Input_RegisterDeviceListener(listener: *mut Input_DeviceListener) -> Input_Result;
2491    /// Unregisters the listener for device hot swap events.
2492    ///
2493    /// # Arguments
2494    ///
2495    /// * `listener` - Pointer to the listener for device hot swap events. For details, see [`Input_DeviceListener`].
2496    ///
2497    ///
2498    /// # Returns
2499    ///
2500    /// * OH_Input_UnregisterDeviceListener status code, specifically,
2501    /// [`INPUT_SUCCESS`] if the operation is successful;
2502    ///
2503    /// [`INPUT_PARAMETER_ERROR`] if listener is NULL or no listener is registered;
2504    /// [`INPUT_SERVICE_EXCEPTION`] if the service is abnormal.
2505    ///
2506    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
2507    ///
2508    /// Available since API-level: 13
2509    #[cfg(feature = "api-13")]
2510    #[cfg_attr(docsrs, doc(cfg(feature = "api-13")))]
2511    pub fn OH_Input_UnregisterDeviceListener(listener: *mut Input_DeviceListener) -> Input_Result;
2512    /// Unregisters the listener for all device hot swap events.
2513    ///
2514    ///
2515    /// # Returns
2516    ///
2517    /// * OH_Input_UnregisterDeviceListener status code, specifically,
2518    /// [`INPUT_SUCCESS`] if the operation is successful;
2519    ///
2520    /// [`INPUT_SERVICE_EXCEPTION`] if the service is abnormal.
2521    ///
2522    /// Required System Capabilities: SystemCapability.MultimodalInput.Input.Core
2523    ///
2524    /// Available since API-level: 13
2525    #[cfg(feature = "api-13")]
2526    #[cfg_attr(docsrs, doc(cfg(feature = "api-13")))]
2527    pub fn OH_Input_UnregisterDeviceListeners() -> Input_Result;
2528}