pub fn handle_key(
key: KeyCode,
editing_text: bool,
has_pending_confirmation: bool,
) -> ActionExpand description
Map a key code to an action.
§Arguments
key- The key code from a keyboard eventediting_text- Whether the user is currently editing text inputhas_pending_confirmation- Whether there is a pending confirmation dialog
§Returns
The corresponding action for the key, or Action::None if the key
is not mapped to any action.