Skip to content

Fix Document#elementsFromPoint no viewport available test - #10426

Merged
bors-servo merged 1 commit into
servo:masterfrom
luthfianto:fix-elementsFromPoint-no-viewport-available-test
Apr 15, 2016
Merged

bors-servo merged 1 commit into
servo:masterfrom
luthfianto:fix-elementsFromPoint-no-viewport-available-test

Conversation

@luthfianto

Copy link
Copy Markdown
Contributor

Fixes #10093 and improves #10034.


This change is Reviewable

@highfive

highfive commented Apr 6, 2016

Copy link
Copy Markdown

Heads up! This PR modifies the following files:

  • @jgraham: tests/wpt/metadata/cssom-view/elementsFromPoint.html.ini
  • @KiChjang: components/script/dom/document.rs

@highfive highfive added the S-awaiting-review There is new code that needs to be reviewed. label Apr 6, 2016
Comment thread components/script/dom/document.rs Outdated
let window = window_from_node(self);
let viewport = window.window_size().unwrap().visible_viewport;

if !self.browsing_context().is_some() {

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this correct? If it's correct, should I merge this with if x < 0.0 || y < 0.0 || x > viewport.width.get() || y > viewport.height.get() {?

@nox

nox commented Apr 15, 2016

Copy link
Copy Markdown
Contributor

@rilut Just change that to if self.browsing_context().is_none() and I will r=me.

@nox nox added S-needs-code-changes Changes have not yet been made that were requested by a reviewer. and removed S-awaiting-review There is new code that needs to be reviewed. labels Apr 15, 2016
@highfive highfive added S-awaiting-review There is new code that needs to be reviewed. and removed S-needs-code-changes Changes have not yet been made that were requested by a reviewer. labels Apr 15, 2016
@emilio

emilio commented Apr 15, 2016

Copy link
Copy Markdown
Member

@bors-servo: r=nox

@bors-servo

Copy link
Copy Markdown
Contributor

📌 Commit be16099 has been approved by nox

@highfive highfive added S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. and removed S-awaiting-review There is new code that needs to be reviewed. labels Apr 15, 2016
Comment thread components/script/dom/document.rs Outdated
pub fn nodes_from_point(&self, page_point: &Point2D<f32>) -> Vec<UntrustedNodeAddress> {
assert!(self.GetDocumentElement().is_some());

pub fn nodes_from_point(&self, page_point: &Point2D<f32>) -> Vec<UntrustedNodeAddress> {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Indentation fail. Just press backspace once, so the pub fn lines up with the previous line's }

@emilio

emilio commented Apr 15, 2016

Copy link
Copy Markdown
Member

@bors-servo: r-

Please change the indentation :)

@emilio

emilio commented Apr 15, 2016

Copy link
Copy Markdown
Member

@bors-servo: delegate+

@bors-servo

Copy link
Copy Markdown
Contributor

✌️ @rilut can now approve this pull request

@highfive highfive added S-awaiting-review There is new code that needs to be reviewed. and removed S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. labels Apr 15, 2016
@luthfianto

Copy link
Copy Markdown
Contributor Author

@bors-servo: r=nox

@bors-servo

Copy link
Copy Markdown
Contributor

📌 Commit 5a3ce59 has been approved by nox

@highfive highfive added S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. and removed S-awaiting-review There is new code that needs to be reviewed. labels Apr 15, 2016
@bors-servo

Copy link
Copy Markdown
Contributor

⌛ Testing commit 5a3ce59 with merge 44d7657...

bors-servo pushed a commit that referenced this pull request Apr 15, 2016
…ble-test, r=nox

Fix Document#elementsFromPoint no viewport available test

Fixes #10093 and improves #10034.

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="35" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/10426)
<!-- Reviewable:end -->
@bors-servo

Copy link
Copy Markdown
Contributor

☀️ Test successful - android, arm32, arm64, linux-dev, linux-rel, mac-dev-unit, mac-rel-css, mac-rel-wpt

@bors-servo
bors-servo merged commit 5a3ce59 into servo:master Apr 15, 2016
@highfive highfive removed the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Apr 15, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants