diff options
author | Richard Dushime <45734838+richarddushime@users.noreply.github.com> | 2024-03-19 19:05:56 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-03-19 16:05:56 +0000 |
commit | 01ca220f83f549d03da566f4becdf826819747ae (patch) | |
tree | 43e7fb2dda3e536ce7e0d0427739a2fd70b78deb /components/script/dom/textcontrol.rs | |
parent | 676f655647fe261c9a9f005122cbbca0263a2625 (diff) | |
download | servo-01ca220f83f549d03da566f4becdf826819747ae.tar.gz servo-01ca220f83f549d03da566f4becdf826819747ae.zip |
clippy: Fix many warnings in `components/script` (#31717)
* Fix Several clippy warnings
* Fix Build errors
* Fix Unused import
* Fix requested changes
* Fix rustfmt
* Minor fixes
---------
Co-authored-by: Martin Robinson <mrobinson@igalia.com>
Diffstat (limited to 'components/script/dom/textcontrol.rs')
-rw-r--r-- | components/script/dom/textcontrol.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/components/script/dom/textcontrol.rs b/components/script/dom/textcontrol.rs index aae103ce728..e4f8546a721 100644 --- a/components/script/dom/textcontrol.rs +++ b/components/script/dom/textcontrol.rs @@ -126,7 +126,7 @@ impl<'a, E: TextControlElement> TextControlSelection<'a, E> { self.set_range( Some(self.start()), Some(self.end()), - direction.map(|d| SelectionDirection::from(d)), + direction.map(SelectionDirection::from), None, ); Ok(()) @@ -305,7 +305,7 @@ impl<'a, E: TextControlElement> TextControlSelection<'a, E> { .task_manager() .user_interaction_task_source() .queue_event( - &self.element.upcast::<EventTarget>(), + self.element.upcast::<EventTarget>(), atom!("select"), EventBubbles::Bubbles, EventCancelable::NotCancelable, |