diff options
Diffstat (limited to 'components/script/textinput.rs')
-rw-r--r-- | components/script/textinput.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/components/script/textinput.rs b/components/script/textinput.rs index 33c8ce90665..6b2053af3be 100644 --- a/components/script/textinput.rs +++ b/components/script/textinput.rs @@ -291,7 +291,7 @@ impl TextInput { } return Selection::NotSelected } - match event.Key().as_slice() { + match &*event.Key() { "a" if is_control_key(event) => { self.select_all(); KeyReaction::Nothing @@ -304,7 +304,7 @@ impl TextInput { contents = Some(rx.recv().unwrap()); } if let Some(contents) = contents { - self.insert_string(contents.as_slice()); + self.insert_string(&contents); } KeyReaction::DispatchInput }, |