mirror of
https://github.com/servo/servo.git
synced 2025-07-23 07:13:52 +01:00
Trigger reflow on document.elementsFromPoint
This commit is contained in:
parent
d0856fd4cd
commit
7426d902a3
10 changed files with 86 additions and 33 deletions
|
@ -1877,7 +1877,13 @@ impl Document {
|
|||
Point2D::new(client_point.x + self.window.PageXOffset() as f32,
|
||||
client_point.y + self.window.PageYOffset() as f32);
|
||||
|
||||
self.window.layout().nodes_from_point(page_point, *client_point)
|
||||
if !self.window.reflow(ReflowGoal::ForScriptQuery,
|
||||
ReflowQueryType::NodesFromPoint(page_point, *client_point),
|
||||
ReflowReason::Query) {
|
||||
return vec!();
|
||||
};
|
||||
|
||||
self.window.layout().nodes_from_point()
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue