Auto merge of #22395 - jdm:initial-iframe-size, r=Manishearth

Initialize iframe viewport immediately

This is probably a significant cause of unstable test results, and it finally bothered me enough to fix it. The solution isn't great for performance (a sync layout query every time a iframe is added to a document), but performance needs to follow correctness.

---
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes fix #14364 and fix #15689 and fix #15688.
- [x] There are tests for these changes

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/22395)
<!-- Reviewable:end -->
This commit is contained in:
bors-servo 2018-12-18 08:51:26 -05:00 committed by GitHub
commit c553c43ba1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
19 changed files with 210 additions and 154 deletions

View file

@ -4,18 +4,9 @@
[window.matchMedia exists]
expected: FAIL
[MediaQueryList.matches for "(max-width: 199px), all and (min-width: 200px)"]
expected: FAIL
[MediaQueryList.matches for "(min-aspect-ratio: 1/1)"]
expected: FAIL
[MediaQueryList.matches for "(width: 200px)"]
expected: FAIL
[MediaQueryList.matches for "(min-width: 150px)"]
expected: FAIL
[Resize iframe from 200x100 to 200x50, then to 100x50]
expected: NOTRUN

View file

@ -1,2 +1,8 @@
[getComputedStyle-detached-subtree.html]
expected: ERROR
[getComputedStyle returns no style for element in non-rendered iframe (display: none) from iframe's window]
expected: FAIL
[getComputedStyle returns no style for element in non-rendered iframe (display: none)]
expected: FAIL