Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Document#elementsFromPoint no viewport available test #10426

Merged
merged 1 commit into from Apr 15, 2016
Merged
Changes from all commits
Commits
File filter...
Filter file types
Jump to…
Jump to file
Failed to load files.

Always

Just for now

@@ -1551,8 +1551,6 @@ impl Document {
}

pub fn nodes_from_point(&self, page_point: &Point2D<f32>) -> Vec<UntrustedNodeAddress> {
assert!(self.GetDocumentElement().is_some());

self.window.layout().nodes_from_point(*page_point)
}
}
@@ -2718,6 +2716,10 @@ impl DocumentMethods for Document {
let window = window_from_node(self);
let viewport = window.window_size().unwrap().visible_viewport;

if self.browsing_context().is_none() {
return vec!();
}

// Step 2
if x < 0.0 || y < 0.0 || x > viewport.width.get() || y > viewport.height.get() {
return vec!();
@@ -12,6 +12,3 @@
[no hit target at x,y]
expected: FAIL

[No viewport available]
expected: FAIL

ProTip! Use n and p to navigate between commits in a pull request.
You can’t perform that action at this time.