summaryrefslogtreecommitdiffstats
path: root/native
diff options
context:
space:
mode:
authorLibravatar Héctor Ramón <hector0193@gmail.com>2021-08-12 12:58:08 +0700
committerLibravatar GitHub <noreply@github.com>2021-08-12 12:58:08 +0700
commita7c40665fea1762aef87a82541cebf7a0b859220 (patch)
treecdfd7645da0b31e39ffa5a88e6f3b5888dc1e614 /native
parent86f5e56c55a3a1aab64efa6f03f52ac80c3b44eb (diff)
parent498188e735c4e9f2158adeeeee9a9e8bf082576b (diff)
downloadiced-a7c40665fea1762aef87a82541cebf7a0b859220.tar.gz
iced-a7c40665fea1762aef87a82541cebf7a0b859220.tar.bz2
iced-a7c40665fea1762aef87a82541cebf7a0b859220.zip
Merge pull request #652 from twitchyliquid64/text_input_fix
text_input: Do not capture Tab/Up/Down keys
Diffstat (limited to 'native')
-rw-r--r--native/src/widget/text_input.rs10
1 files changed, 10 insertions, 0 deletions
diff --git a/native/src/widget/text_input.rs b/native/src/widget/text_input.rs
index cec1e485..bb64d5b7 100644
--- a/native/src/widget/text_input.rs
+++ b/native/src/widget/text_input.rs
@@ -582,6 +582,11 @@ where
self.state.keyboard_modifiers =
keyboard::Modifiers::default();
}
+ keyboard::KeyCode::Tab
+ | keyboard::KeyCode::Up
+ | keyboard::KeyCode::Down => {
+ return event::Status::Ignored;
+ }
_ => {}
}
@@ -594,6 +599,11 @@ where
keyboard::KeyCode::V => {
self.state.is_pasting = None;
}
+ keyboard::KeyCode::Tab
+ | keyboard::KeyCode::Up
+ | keyboard::KeyCode::Down => {
+ return event::Status::Ignored;
+ }
_ => {}
}