[−][src]Function winconsole::input::write
pub fn write(
event: impl Into<InputEvent>,
button_status: impl Into<Option<[bool; 5]>>
) -> WinResult<()>
Adds an input event directly to the input buffer.
Arguments
event
- The InputEvent to add.button_status
- The current status of mouse buttons 1 through 5. If None, the current button states are used.
Examples
let mut event = FocusEvent::new(); event.focused = true; input::write(event, None).unwrap();
Errors
InvalidHandleError
: Returned if an invalid handle to the console input is retrieved or used.IoError
: Returned if an OS error occurs.