Commit graph

7566 commits

Author SHA1 Message Date
Simon Sapin
1d38bc0419 Fix some new warnings 2019-06-22 14:59:09 +02:00
bors-servo
9213331910
Auto merge of #23546 - asajeffrey:magicleap-webvr-second-cut, r=Manishearth
Add Servo3D immersive demo for magicleap

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

An immersive mode demo for magicleap.

---
<!-- 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 (apart from dupes, sigh)
- [X] These changes fix #22402 (GitHub issue number if applicable)
- [X] These changes do not require tests because it's a new platform

<!-- 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/23546)
<!-- Reviewable:end -->
2019-06-13 18:49:16 -04:00
Alan Jeffrey
0b48ff496f Add Servo3D immersive demo for magicleap 2019-06-13 15:04:05 -05:00
bors-servo
988f9847a0
Auto merge of #23560 - jdm:rand-upgrades, r=asajeffrey
Upgrade various old versions of rand

Old versions of rand rely on Windows APIs that are forbidden in UWP applications. These changes upgrade various dependencies that transitively depend on them.

---
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] There are tests for these changes
- [x] Fixes #22767.

<!-- 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/23560)
<!-- Reviewable:end -->
2019-06-13 15:46:29 -04:00
Josh Matthews
b1510d9ad5 Upgrade headers, headers-core, and hyper_serde. 2019-06-13 11:08:16 -04:00
bors-servo
a74f38f843
Auto merge of #23551 - asajeffrey:script-navigatorid, r=jdm
Added missing NavigatorId attributes

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

Add the missing attributes from https://html.spec.whatwg.org/multipage/system-state.html#navigatorid

---
<!-- 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 do not require tests because there are already tests for Navigator

<!-- 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/23551)
<!-- Reviewable:end -->
2019-06-12 16:59:31 -04:00
Manish Goregaokar
7d029d5a36 Use correct length in FakeXRDeviceController.setViews() 2019-06-11 10:10:41 -07:00
Manish Goregaokar
2af8e0ef9f Add stub makeXRCompatible() 2019-06-11 10:10:41 -07:00
Alan Jeffrey
4cfd62ac79 Added missing NavigatorId attributes 2019-06-11 11:46:28 -05:00
Manish Goregaokar
52b0d37bb7 Update originOffset semantics 2019-06-10 16:06:31 -07:00
Manish Goregaokar
26e0aaca6c Update reference spaces to new model 2019-06-10 15:50:44 -07:00
bors-servo
4c776f33d4
Auto merge of #23529 - gatoWololo:omar_split_mutation_observer, r=ferjm
Split getter for mutation_observers() into two methods.

Please let me know if these API changes look good:

registered_mutation_observers() returns immutable references and does
not init mutation observers.

registered_mutation_observers_mut() lazily initializes raredata if it
does not exist.

Updated code that uses this methods to call appropriate method when
mutation is not necessary.

<!-- 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 #23286

<!-- Either: -->
- [X] These changes do not require tests because: this is a small change to the API, and existing tests for Partial ShadowDOM support cover this API use/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/23529)
<!-- Reviewable:end -->
2019-06-10 10:08:40 -04:00
Robert Snakard
35bca991ad Implement WheelEvent Interface
Note: The WheelEvent interface supports rotation in all 3 spatial
dimensions. This implementation only supports two due to limitations
in the Glutin compositor.

The wheelevent interface is a dom interface that triggers for any
attached device that can rotate in one or more spatial dimensions.
Traditionally this is the mouse wheel though other devices could be
used as well. E.g. the trackball on a trackball mouse.
2019-06-09 13:25:01 -04:00
gatowololo
15c06b1b26 Use TypeError instead of InvalidState for exception.
Addresses Issue #23202
2019-06-07 09:01:53 -07:00
gatowololo
3df8d6891e Split getter for mutation_observers() into two methods.
registered_mutation_observers() returns immutable references and does
not init mutation observers.

registered_mutation_observers_mut() lazily initializes raredata if it
does not exist.

Updated code that uses this methods to call appropriate method when
mutation is not necessary.
2019-06-06 11:30:37 -07:00
Víctor Manuel Jáquez Leal
985efb4b8d Use media element task source to receive the player's events
This is crumb left behind when changing the usage of dom task source
to the proper media element task source.
2019-06-06 17:03:59 +02:00
bors-servo
fe8aad7227
Auto merge of #23503 - emilio:gecko-sync, r=emilio
style: sync changes from mozilla-central

See each individual commit for details. This also cherry-picks #23463 with a few fixes that were needed in Gecko-only code.

<!-- 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/23503)
<!-- Reviewable:end -->
2019-06-04 08:30:39 -04:00
bors-servo
faf3a183f3
Auto merge of #23499 - est31:unused_code_removal_3, r=jdm
Remove unused code (3/N)

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

Third PR in a series of PRs to remove unused/dead code from servo, powered by an (upcoming) tool of mine. Please take a look and tell me if you want to keep something.

* First PR: #23477
* Second PR: #23498

---
<!-- 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
- [ ] These changes fix #___ (GitHub issue number if applicable)

<!-- Either: -->
- [ ] There are tests for these changes OR
- [x] These changes do not require tests because they only remove dead code

<!-- 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/23499)
<!-- Reviewable:end -->
2019-06-04 02:27:29 -04:00
Evgeniy Reizner
6f1df517e0 style: Do not use borrowed types in the selectors::Element trait.
Closes #22972
Closes #23463
2019-06-04 01:04:03 -04:00
Emilio Cobos Álvarez
2e5078e9c5 layout: Fix servo build. 2019-06-04 01:04:02 -04:00
bors-servo
7f7eead3d8
Auto merge of #23372 - sreeise:xhr_resource_url, r=jdm
Change XHRContext and resource timing information to use request URL

<!-- Please describe your changes on the following line: -->
Change resource timing information to return the URL used to create the XHR and store the URL in XHRContext.

---
<!-- 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 #23329 (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/23372)
<!-- Reviewable:end -->
2019-06-02 22:48:25 -04:00
bors-servo
03f223663f
Auto merge of #23459 - Eijebong:compartments, r=jdm
Add an inCompartments config option for bindings

Fixes #23257

<!-- 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/23459)
<!-- Reviewable:end -->
2019-06-02 14:41:20 -04:00
est31
8b6ed3d182 Remove unused code from script* crates 2019-06-02 07:12:26 +02:00
csmoe
05bef140bf Implement worker origin member of WorkerLocation 2019-06-02 10:20:03 +08:00
bors-servo
7c8a4ecead
Auto merge of #23485 - Manishearth:xrtest, r=asajeffrey
Basic XR Testing support

This adds support for the XRTest and FakeXRDeviceController APIs from https://github.com/immersive-web/webxr-test-api, and plugs them into the `mock` backend of rust-webvr.

Tested with [a modified webxr test page](https://github.com/immersive-web/webxr-test-api)

r? @jdm @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/23485)
<!-- Reviewable:end -->
2019-05-30 22:04:22 -04:00
Manish Goregaokar
c2d4900c16 Add 'spec' links 2019-05-30 19:04:08 -07:00
Manish Goregaokar
d044a792f1 Normalize rotations 2019-05-30 19:04:08 -07:00
Manish Goregaokar
97df39fce1 Add FakeXRDeviceController.setViewerOrigin() 2019-05-30 19:04:08 -07:00
Manish Goregaokar
4b930b9e30 Add FakeXRDeviceController.setViews() 2019-05-30 19:04:08 -07:00
Manish Goregaokar
e95b24bfa6 Add XRTest.simulateDeviceConnection() 2019-05-30 19:04:08 -07:00
Manish Goregaokar
c689866d35 Add XR.test() 2019-05-30 13:29:05 -07:00
Manish Goregaokar
9a31f6fe7a Add blank FakeXRDeviceController interface 2019-05-30 12:53:47 -07:00
Manish Goregaokar
1c07b0f416 Add blank XRTest interface 2019-05-30 12:53:47 -07:00
bors-servo
69eacfa8c8
Auto merge of #23472 - ffwff:master, r=cybai
Add value sanitization for input[type=email]

<!-- Please describe your changes on the following line: -->
Add value sanitization for input[type=email] as per the [HTML specification](https://html.spec.whatwg.org/multipage/input.html#e-mail-state-(type=email)).

---
<!-- 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 #21810 (GitHub issue number if applicable)

<!-- Either: -->
- [x] 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/23472)
<!-- Reviewable:end -->
2019-05-30 09:04:50 -04:00
Víctor Manuel Jáquez Leal
02dfee7b47 Pass frame renderer to player only if video element
Otherwise it will only render audio but no video frames.
2019-05-30 09:51:49 +02:00
bors-servo
0a9a222356
Auto merge of #23476 - ferjm:multi.streams, r=ceyusa
Allow simultaneous playback of audio and video for getUserMedia

- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors

<!-- 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/23476)
<!-- Reviewable:end -->
2019-05-29 21:28:18 -04:00
ffwff
3508140929 Add value sanitization algorithm for input[type="email"]
Handle "Multiple" attribute for email value sanitization

Fix code formatting

Tests for email value sanitization should pass

Make failing wpt tests pass

Change new_value => sanitized
2019-05-29 23:07:17 +07:00
Fernando Jiménez Moreno
dfbf7e37ab Allow simultaneous playback of audio and video for getUserMedia 2019-05-29 16:17:36 +02:00
Emilio Cobos Álvarez
66056bd4d5 script: Fix Servo build. 2019-05-29 16:14:36 +02:00
bors-servo
8dc7a25893
Auto merge of #23381 - maharsh312:master, r=jdm
Canvas Components for OffscreenCanvas

<!-- 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
- [ ] These changes fix #___ (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/23381)
<!-- Reviewable:end -->
2019-05-28 23:13:23 -04:00
Alex Johnson
1c35c44c35 Fixes #23408
Switched from using thread for websocket requests to ipc_channel::router::ROUTER

Signed-off-by: Alex Johnson <hello@alex-johnson.net>
2019-05-26 09:46:48 -07:00
Bastien Orivel
b7e10a8224 Make tidy happy 2019-05-25 23:23:42 +02:00
Bastien Orivel
292d468cd1 Use the newly added inCompartments option everywhere it can be 2019-05-25 17:28:07 +02:00
Bastien Orivel
0b29caa554 Add support for attributes to the inCompartments binding parameter 2019-05-25 14:43:44 +02:00
Bastien Orivel
7dbff6efb7 Add an inCompartments config for bindings 2019-05-24 23:02:38 +02:00
sreeise
e1692789f8 Change XHRContext and resource timing information to use request URL instead of XHR's global URL r?@jdm 2019-05-24 15:11:09 -04:00
bors-servo
f24f517965
Auto merge of #23272 - tdelacour:ISSUE-20455, r=SimonSapin
ISSUE-20455: introduce stronger types for textinput indexing

<!-- Please describe your changes on the following line: -->
Added two new types:
- ByteOffset
- UTF16CodeUnitOffset

I've replaced any instance of `usize` that would be better represented by one or the other of these. I also updated any downstream code, including the unit tests for `textinput.rs`. Along the way, I tried to add or edit comments to better reflect my understanding of this file - happy to revisit if I have misrepresented anything.

I did not end up finding any places where types were very obviously being mixed, as the issue description suggested I should do... LMK if I should re-audit the file for that (might need a bit of guidance)!

---
<!-- 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 #20455 (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/23272)
<!-- Reviewable:end -->
2019-05-23 12:01:29 -04:00
Maharsh
85c20db495 Extract canvas operations for reuse by OffscreenCanvas. 2019-05-22 10:24:54 -04:00
bors-servo
377ade0aed
Auto merge of #23188 - jackxbritton:issue-22287, r=KiChjang,ferjm
Implement HTMLMediaElement.crossorigin attribute logic.

<!-- 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 #22287
- [X] 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/23188)
<!-- Reviewable:end -->
2019-05-22 07:52:26 -04:00
Jack Britton
ade697b782 Implement HTMLMediaElement.crossorigin attribute logic. 2019-05-22 12:23:51 +02:00