mirror of
https://github.com/crossterm-rs/crossterm.git
synced 2025-09-28 13:31:23 +00:00
add cfg
This commit is contained in:
parent
2165c388df
commit
4fb0ec5726
@ -1,7 +1,7 @@
|
|||||||
use std::io;
|
use std::io;
|
||||||
|
|
||||||
use crate::event::{
|
use crate::event::{
|
||||||
Event, KeyCode, KeyEvent, KeyEventKind, KeyEventState, KeyModifiers, KeyboardEnhancementFlags,
|
Event, KeyCode, KeyEvent, KeyEventKind::Release,, KeyEventState, KeyModifiers, KeyboardEnhancementFlags,
|
||||||
MediaKeyCode, ModifierKeyCode, MouseButton, MouseEvent, MouseEventKind,
|
MediaKeyCode, ModifierKeyCode, MouseButton, MouseEvent, MouseEventKind,
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -1365,6 +1365,7 @@ mod tests {
|
|||||||
KeyEventKind::Press,
|
KeyEventKind::Press,
|
||||||
)))),
|
)))),
|
||||||
);
|
);
|
||||||
|
#[cfg(feature = "event-kind")]
|
||||||
assert_eq!(
|
assert_eq!(
|
||||||
parse_csi_u_encoded_key_code(b"\x1B[57449;3:3u").unwrap(),
|
parse_csi_u_encoded_key_code(b"\x1B[57449;3:3u").unwrap(),
|
||||||
Some(InternalEvent::Event(Event::Key(KeyEvent::new_with_kind(
|
Some(InternalEvent::Event(Event::Key(KeyEvent::new_with_kind(
|
||||||
|
Loading…
x
Reference in New Issue
Block a user