Commit graph

8362 commits

Author SHA1 Message Date
Fernando Jiménez Moreno
df81debffc Set connected flag not only on elements 2019-04-26 10:17:45 +02:00
Fernando Jiménez Moreno
4740ce53a0 Make note_dirty_descendants jump around shadow roots 2019-04-26 10:17:45 +02:00
Fernando Jiménez Moreno
ea69bbc75b Node retargeting algorithm 2019-04-26 10:17:45 +02:00
Fernando Jiménez Moreno
441357b74e Add is_connected flag to node and use it to replace most uses of is_in_doc 2019-04-26 10:17:45 +02:00
Fernando Jiménez Moreno
640fc04743 Implement shadow-including root, set node as in doc when connected. Makes JS work in shadow trees 2019-04-26 10:17:45 +02:00
Fernando Jiménez Moreno
48975840dd Unify DocumentOrShadowRoot implementation 2019-04-26 10:17:45 +02:00
Fernando Jiménez Moreno
ffdc9d255f Expose Element.AttachShadow under dom.shadowdom.enabled pref 2019-04-26 10:17:44 +02:00
Fernando Jiménez Moreno
091fcbecd1 Node shadow root owner 2019-04-26 10:17:44 +02:00
Fernando Jiménez Moreno
9022bd3d11 IS_IN_SHADOW_TREE flag 2019-04-26 10:17:44 +02:00
Fernando Jiménez Moreno
569b4fce10 Element attachShadow implementation 2019-04-26 10:17:44 +02:00
Fernando Jiménez Moreno
4304ee28dc Partial ShadowRoot implementation of DocumentOrShadowRoot 2019-04-26 10:17:44 +02:00
Fernando Jiménez Moreno
18ae0fcbd6 ShadowRoot interface 2019-04-26 10:17:44 +02:00
Fernando Jiménez Moreno
cbcf21c248 DocumentOrShadowRoot mixin 2019-04-26 10:17:44 +02:00
bors-servo
56c2e85cab
Auto merge of #23270 - Manishearth:audioparam-validation, r=ferjm
Add input validation for AudioParam methods

Waiting on a build to make WPT updates

Spec requires us to validate inputs, we aren't doing this here.

We don't need to check for things being finite since we already get the arguments as `Finite` values

<!-- 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/23270)
<!-- Reviewable:end -->
2019-04-26 03:32:48 -04:00
bors-servo
b73956cc37
Auto merge of #23090 - miller-time:nav-fetch-referrer, r=gterzian
Add referrer to navigation fetch request

<!-- Please describe your changes on the following line: -->
Implement step 13 of [following hyperlinks](https://html.spec.whatwg.org/#following-hyperlinks-2) and step 14.3 of [window open](https://html.spec.whatwg.org/#window-open-steps), as well as other referrer- and fetch-related updates.

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: -->
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes fix #22890 (GitHub issue number if applicable)

<!-- Either: -->
- [ ] There are tests for these changes OR
- [ ] These changes do not require tests because ___

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- 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/23090)
<!-- Reviewable:end -->
2019-04-25 20:21:23 -04:00
Manish Goregaokar
8a8a9f7135 Add input validation for AudioParam methods 2019-04-25 16:00:11 -07:00
Josh Matthews
c038ba4c7c Force the use of clang-cl.exe for Windows builds. 2019-04-25 10:55:16 -04:00
Aron Zwaan
e2e6e2ac94 Pass InCompartment by value 2019-04-25 11:37:35 +02:00
Aron Zwaan
1b6949d4cf Add proof parameter to Promise::new_in_current_compartment 2019-04-24 19:46:10 +02:00
Aron Zwaan
7b293ee8cb Add proof that code is executed in compartment 2019-04-24 12:44:33 +02:00
bors-servo
03b005c7b2
Auto merge of #23178 - tdelacour:ISSUE-21263, r=jdm
Add PerformanceResourceTiming: ResponseEnd

<!-- Please describe your changes on the following line: -->
1. Added `ResponseEnd` to `ResourceAttribute` enum in `net_traits` and added it to the `set_attribute` function on `ResourceFetchTiming`
2. Added `response_end` field to `performanceresourcetiming.rs`
3. In `http_loader.rs`, set ResponseEnd after response body read is complete, or before return due to network error.

I could use a little guidance on testing. After building and running `wpt` tests, I noticed that some tests now "Pass" when they were expected to "Fail". As per the wiki instructions, I've removed those expectations from the `metadata`.

I noticed that there are a handful of other "failing" test expectations associated with `responseEnd`, but those still do not pass. I looked through some similar PRs (`connectEnd`, `redirectStart`, etc) and saw that they also still have a few failing test expectations here and there. Does that mean this is OK for now? How can I better understand which tests we expect to resolve for a given issue? Thanks!

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: -->
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #21263 (GitHub issue number if applicable)

<!-- Either: -->
- [X] There are tests for these changes OR
- [ ] These changes do not require tests because ___

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- 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/23178)
<!-- Reviewable:end -->
2019-04-23 16:49:12 -04:00
bors-servo
4c8d29f5a7
Auto merge of #23200 - krk:webidl-lint, r=jdm
Webidl lint

Parse webidl files and lint for inheritance correctness.

---

<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: -->
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #20461

<!-- 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/23200)
<!-- Reviewable:end -->
2019-04-23 15:24:33 -04:00
Thomas Delacour
fdbec9835c ISSUE-21263: implemented attribute setting in http loader 2019-04-23 12:33:28 -04:00
Fernando Jiménez Moreno
74a48937f1 Remove use of auto media backend. And update servo-media 2019-04-23 16:24:33 +02:00
bors-servo
4e12deb7b6
Auto merge of #23115 - pylbrecht:measure.blocked.layout.queries, r=jdm
measure blocked layout queries

<!-- Please describe your changes on the following line: -->

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: -->
- [X] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes fix #19797

<!-- Either: -->
- [ ] There are tests for these changes

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- 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/23115)
<!-- Reviewable:end -->
2019-04-22 10:52:49 -04:00
krk
fea2ad0fab Inherit TestBinding from TestBindingProxy. 2019-04-20 22:39:39 +02:00
krk
e9560617b6 Move WindowProxy declaration to the new WindowProxy.webidl file. 2019-04-20 22:39:39 +02:00
krk
dfca8ec913 Can collect webidl paths. 2019-04-20 22:39:22 +02:00
Russell Cousineau
2440e0f98a set referrer in window.load_url
- this conforms to follow-hyperlinks spec step 13
- this conforms to window-open spec step 14.3
- replace uses of `referrer_url` with `referrer`
- in Request class, change "no-referrer" to ""
- set websocket fetch referrer to "no-referrer"
2019-04-19 16:50:38 -07:00
bors-servo
53b752bab7
Auto merge of #23006 - aditj:aditj-patch-7, r=jdm
Added WebDriver DeleteCookies Function

<!-- Please describe your changes on the following line: -->
This change adds DeleteCookies function of the webdriver crate to the servo webdriver server.
See [spec](https://w3c.github.io/webdriver/#delete-all-cookies)

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: -->
- [x] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix part of #8623 (GitHub issue number if applicable)

<!-- Either: -->
- [X] There are tests for these changes OR
- [ ] These changes do not require tests because ___

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- 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/23006)
<!-- Reviewable:end -->
2019-04-19 09:48:30 -04:00
aditj
64961cc9c1 Add webdriver deletecookies function 2019-04-19 13:15:50 +05:30
bors-servo
b20333a324
Auto merge of #23215 - ferjm:decoder.channels, r=jdm
Keep a map between channel position and channel index for decoded audio

- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] There are WPTs for these changes.

This should help fixing #22842 (along with https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/issues/183). I couldn't reproduce it locally, so I cannot tell for sure.

<!-- 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/23215)
<!-- Reviewable:end -->
2019-04-18 16:10:39 -04:00
Ian Moody
8d7fe68ac3 Remove :-servo-case-sensitive-type-attr()
No longer needed now that the case-sensitive flag for attributes selectors is
supported.
Update user-agent CSS sheet to use the standard flag.

Fixes #23227
2019-04-18 13:46:59 +01:00
pylbrecht
4fd9fea7a6 fixup! Measure layout queries blocked by ongoing layout 2019-04-17 17:23:17 +02:00
Fernando Jiménez Moreno
292d1705a3 Keep a map between channel position and channel index for decoded audio 2019-04-17 12:38:21 +02:00
bors-servo
5efd57b7bd
Auto merge of #23216 - ferjm:replay, r=ceyusa
Allow replaying media

- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [ ] 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/23216)
<!-- Reviewable:end -->
2019-04-17 06:18:14 -04:00
Fernando Jiménez Moreno
501e6c1aed Allow replaying media 2019-04-17 12:11:14 +02:00
bors-servo
a14b952fa3
Auto merge of #23187 - krk:nopanic-unminifyjs, r=jdm
Do not unwrap empty unminified_js_dir in HTMLScriptElement.unminify_js.

Calling unwrap caused a panic when a directory could not be created.

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: -->
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #23031

<!-- 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/23187)
<!-- Reviewable:end -->
2019-04-16 11:18:09 -04:00
Josh Matthews
73cb8b9ea6
Clarify warning. 2019-04-16 11:17:53 -04:00
bors-servo
456ea6a388
Auto merge of #23153 - 5h1rU:xmlserializer-serializetostring-panics, r=jdm
Make serializeToString serialize document nodes correctly

<!-- Please describe your changes on the following line: -->
This is the fix for ScriptThread panic when `new XMLSerializer().serializeToString(document);` is called.

r?@jdm

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: -->
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes fix #23130

<!-- Either: -->
- [x] There are tests for these changes OR
- [ ] These changes do not require tests because ___

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- 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/23153)
<!-- Reviewable:end -->
2019-04-15 23:30:56 -04:00
Felipe Janer
1ffe8f059a Add new XMLSerializer().serializeToString functionality 2019-04-15 21:12:47 -05:00
bors-servo
0ba7da4431
Auto merge of #23169 - Manishearth:more-pose, r=jdm
Some more pose fixes

Based on https://github.com/servo/servo/pull/23164

This:

 - Adds support for position-disabled
 - Adds approximate support for floor-level
 - Makes transform.inverse.inverse return the original transform
(https://github.com/immersive-web/webxr/issues/576)

To support floor-level *properly* we have to decompose the `sitting_to_standing_transform` matrix. I'll have to add decomposition to euclid to do this, sadly.

It may be possible to reuse the decomposition code in servo's style crate, but there's a chance that that's written with column vector style, given that it reflects the CSS transforms spec, which is also written in column vector style. Ugh.

r? @asajeffrey

<!-- 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/23169)
<!-- Reviewable:end -->
2019-04-15 18:46:12 -04:00
Josh Matthews
eebd831ea5 Move media backend initialization to process startup. 2019-04-15 16:46:25 -04:00
bors-servo
17204544d9
Auto merge of #23157 - ferjm:gum.playback, r=Manishearth
MediaStream playback through audio and video elements

- [X] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [ ] 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/23157)
<!-- Reviewable:end -->
2019-04-13 20:28:17 -04:00
Philipp Albrecht
858011c513 Measure layout queries blocked by ongoing layout 2019-04-13 07:42:07 +02:00
bors-servo
9832feddf3
Auto merge of #23192 - jackxbritton:issue-23134, r=jdm
Implement DocumentFragment XML serialization.

When serializing a DocumentFragment node, we should follow [this guy](https://w3c.github.io/DOM-Parsing/#dfn-xml-serializing-a-documentfragment-node) and serialize the node's immediate children. This commit makes that change.

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: -->
- [X] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [X] These changes fix #23134 (GitHub issue number if applicable)

<!-- Either: -->
- [x] There are tests for these changes OR
- [ ] These changes do not require tests because ___ well, they probably do, but I don't know how to do that and could use some help.

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- 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/23192)
<!-- Reviewable:end -->
2019-04-12 14:37:45 -04:00
Anthony Ramine
44163148c2 Make use of RefCell::try_borrow_unguarded 2019-04-12 19:02:07 +02:00
Jack Britton
1dd1cb4f4f Implement DocumentFragment XML serialization. 2019-04-12 12:49:18 -04:00
Emilio Cobos Álvarez
49842f5031 style: Fix servo build, and appease tidy / fmt. 2019-04-12 12:20:15 +02:00
bors-servo
db9300d3e6
Auto merge of #23183 - krk:fix-23144, r=asajeffrey
Replace panic with warn in DocumentLoader.finish_load.

Fix panic on broken script URL with an onerror handler that rewrites the document.

<!-- Please describe your changes on the following line: -->

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: -->
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #23144

<!-- 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/23183)
<!-- Reviewable:end -->
2019-04-11 14:33:44 -04:00