diff options
author | Ms2ger <ms2ger@gmail.com> | 2015-04-25 17:05:08 +0200 |
---|---|---|
committer | Ms2ger <ms2ger@gmail.com> | 2015-04-26 10:52:55 +0200 |
commit | a862479ca801c92bbb744eb769e59d177435fb63 (patch) | |
tree | d2cb8c7a55dac2e68ab02c48bd07ea0165ff74b6 /components/script/textinput.rs | |
parent | ef536372cdf26e5fd2ac7728e76482dc5d702cd0 (diff) | |
download | servo-a862479ca801c92bbb744eb769e59d177435fb63.tar.gz servo-a862479ca801c92bbb744eb769e59d177435fb63.zip |
Remove as_slice() calls from script.
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 }, |