From 33ca29f3954960800da2f5e35068b31fe6c1c586 Mon Sep 17 00:00:00 2001 From: FabianLars Date: Sat, 22 Feb 2020 22:17:51 +0100 Subject: ctrl + a selection for text input --- native/src/widget/text_input.rs | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'native/src') diff --git a/native/src/widget/text_input.rs b/native/src/widget/text_input.rs index bfe5244f..4aed2767 100644 --- a/native/src/widget/text_input.rs +++ b/native/src/widget/text_input.rs @@ -439,6 +439,16 @@ where self.state.is_pasting = None; } } + keyboard::KeyCode::A => { + if platform::is_copy_paste_modifier_pressed(modifiers) { + self.state.cursor_position = { + Cursor::Selection { + start: 0, + end: self.value.len(), + } + } + } + } _ => {} }, Event::Keyboard(keyboard::Event::Input { -- cgit