aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/htmlinputelement.rs
diff options
context:
space:
mode:
authorAnthony Ramine <n.oxyde@gmail.com>2019-01-09 14:11:13 +0100
committerAnthony Ramine <n.oxyde@gmail.com>2019-01-09 14:12:54 +0100
commit3ccda7f90cfb783d66c5bd793888a3138c1a5643 (patch)
tree5e02a039ded02b084b774df86f13c869cbbdd010 /components/script/dom/htmlinputelement.rs
parentddef6211b39d0b4927aff02646070f6ebc052eaa (diff)
downloadservo-3ccda7f90cfb783d66c5bd793888a3138c1a5643.tar.gz
servo-3ccda7f90cfb783d66c5bd793888a3138c1a5643.zip
Make a bunch of layout queries morally safer
Diffstat (limited to 'components/script/dom/htmlinputelement.rs')
-rwxr-xr-xcomponents/script/dom/htmlinputelement.rs6
1 files changed, 2 insertions, 4 deletions
diff --git a/components/script/dom/htmlinputelement.rs b/components/script/dom/htmlinputelement.rs
index 4541c38038e..c43ea02828b 100755
--- a/components/script/dom/htmlinputelement.rs
+++ b/components/script/dom/htmlinputelement.rs
@@ -1467,10 +1467,8 @@ impl VirtualMethods for HTMLInputElement {
// now.
if let Some(point_in_target) = mouse_event.point_in_target() {
let window = window_from_node(self);
- let TextIndexResponse(index) = window.text_index_query(
- self.upcast::<Node>().to_trusted_node_address(),
- point_in_target,
- );
+ let TextIndexResponse(index) =
+ window.text_index_query(self.upcast::<Node>(), point_in_target);
if let Some(i) = index {
self.textinput.borrow_mut().set_edit_point_index(i as usize);
// trigger redraw