Commit graph

8612 commits

Author SHA1 Message Date
Kunal Mohan
37d606621d address review comments 2020-07-17 02:23:39 +05:30
Kunal Mohan
d1c13e8df7 Use existing BindGroupLayout if an equivalent BGL already exists 2020-07-16 23:21:09 +05:30
Kunal Mohan
0dc1514d57 Implement Async Error reporting for WebGPU and update wgpu-core 2020-07-16 23:21:09 +05:30
bors-servo
ef4f5e5264
Auto merge of #27265 - jdm:hubs-stubs2, r=ferjm
Add stubs for HTMLCanvasElement.captureStream and WebRTC transceiver APIs

These stubs are hidden by default and only exist to allow getting past the relevant code that invokes them on hubs.mozilla.org.
2020-07-15 03:33:20 -04:00
bors-servo
1e182cd185
Auto merge of #27266 - jdm:hubs-stubs3, r=Manishearth
Hide Window extension methods by default and add helper Window.js_backtrace method

Fixes #26858.
2020-07-14 22:40:20 -04:00
Josh Matthews
4dd7387799 dom: Add Window.js_backtrace debugging extension method. 2020-07-14 22:39:59 -04:00
Josh Matthews
e6cdfddea6 dom: Hide debugging extension methods behind a pref. 2020-07-14 22:39:59 -04:00
bors-servo
12d4c0d5eb
Auto merge of #27264 - jdm:hubs-stubs, r=Manishearth
Implement Navigator.languages

Fixes #27210.
2020-07-14 15:10:56 -04:00
bors-servo
c8d0548824
Auto merge of #27255 - avr1254:master, r=jdm
Implemented HTMLFormElement.relList

<!-- Please describe your changes on the following line: -->
Updated the tests to reflect addition of rel and relList for HTMLFormElement, as well as porting those code snippets from HTMLAnchorElement.

---
<!-- 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 #27252  (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. -->
2020-07-14 12:49:13 -04:00
Josh Matthews
84efd56e57 dom: Add WebRTC transceiver stubs. 2020-07-14 12:48:45 -04:00
Josh Matthews
1ae117f67b dom: Add stub implementation for HTMLCanvasElement.captureStream. 2020-07-14 12:48:45 -04:00
Arjun Ramachandrula
00f69dd50f Ported Rel, SetRel, and RelList from HTMLAnchorElement into HTMLForElement
Updated tests to reflect rel and relList in HTMLFormElement

Added AttrValue as style

Added attr

Updated outstanding test cases

Fixed formatting. Hopefully this time works

Implemented HTMLFormElement.relList
2020-07-14 12:37:57 -04:00
Josh Matthews
2acd295ea6 dom: Implement Navigator.languages. 2020-07-14 11:50:59 -04:00
Paul Rouget
6252d36a14 Unfocus input when virtual keyboard is dismissed 2020-07-13 14:04:06 +02:00
bors-servo
242e7e2630
Auto merge of #27232 - asajeffrey:webxr-depth-stencil, r=Manishearth
Support depth and stencil in webxr

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

Creates a `DEPTH_STENCIL` attachment if one is provided by the webxr device.

---
<!-- 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 we don't reftest webxr

<!-- 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. -->
2020-07-10 19:36:45 -04:00
Alan Jeffrey
a9bb3f7181 Support depth and stencil in webxr 2020-07-10 18:35:09 -05:00
bors-servo
a77a1f7bf4
Auto merge of #27235 - asajeffrey:webxr-sessionavailable, r=jdm
Add a sessionavailable event that allows content to enter an XR session without a user gesture

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

This allows servo to implement immersive web apps. https://immersive-web.github.io/webxr/#application-launch

---
<!-- 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 I'm not sure we should have a WPT for something this non-standard.

<!-- 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. -->
2020-07-10 18:14:10 -04:00
Alan Jeffrey
63663fada9 Add a sessionavailable event that allows content to enter an XR session without a user gesture 2020-07-10 14:09:18 -05:00
bors-servo
fb243a32f0
Auto merge of #27152 - ferjm:mediadevices.enumeratedevices, r=Manishearth
Mediadevices.enumeratedevices

- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #26877
2020-07-10 08:42:27 -04:00
Fernando Jiménez Moreno
c0fb6c8d23 Implement MediaDevices.enumerateDevices() 2020-07-10 13:18:26 +02:00
Josh Matthews
63528f6fdf dom: Generate iterator symbol for interfaces with indexed getters. 2020-07-09 23:22:48 -04:00
Josh Matthews
aa80f91399 dom: Use pref macro for IDL conditional guards. 2020-07-09 23:22:48 -04:00
Alan Jeffrey
a2142d7dbd Add support for webxr cubemap and spherical 360 rendering 2020-07-09 14:02:23 -05:00
bors-servo
cbbbe16936
Auto merge of #27088 - jdm:group, r=ferjm
Implement Console grouping APIs.

These are used by Hubs and other sites we want to run.

---
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes fix #9274
- [x] These changes do not require tests because we can't test stdout content or devtools messages.
2020-07-07 01:24:03 -04:00
Josh Matthews
2d7effddef Implement Console grouping APIs. 2020-07-06 19:36:26 -04:00
bors-servo
ec9308199e
Auto merge of #27180 - kunalmohan:segfault, r=kvark
Remove segfaults in WebGPU threads

<!-- Please describe your changes on the following line: -->
I have also increased the number of staging buffers for presentation.
Segfault occurred at 2 places-
1. RenderPipeline descriptor.
2. BufferMapAsync callback.

r?@kvark

---
<!-- 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
- [ ] 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. -->
2020-07-06 17:45:09 -04:00
Kunal Mohan
9e7e9433e4 Remove segfaults in WebGPU threads 2020-07-07 01:55:03 +05:30
bors-servo
22a7522a04
Auto merge of #27168 - jdm:gl-fake-context-lost, r=Manishearth
Add stub isContextLost API.

We don't support losing contexts yet, so it's not lying to say that the context is never lost.

---
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes fix #27116
- [x] There are tests for these changes
2020-07-06 14:56:50 -04:00
bors-servo
1cd78e78f6
Auto merge of #26998 - gterzian:improve_task_cancelling, r=jdm
Use a stronger atomic guarantee when cancelling tasks

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

In the context of https://github.com/servo/servo/issues/22507

Note that the "other side" of these operations is at 0b61cfc3ae/components/script/task.rs (L102)

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: -->
- [ ] `./mach build -d` does not report any errors
- [ ] `./mach test-tidy` does not report any errors
- [ ] These changes fix #___ (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. -->
2020-07-06 11:11:25 -04:00
bors-servo
d93e67a0bf
Auto merge of #27174 - muodov:form-invalid-event-removal, r=gterzian
Do not fire `invalid` event on form elements

This is a follow-up to my [previous PR](https://github.com/servo/servo/pull/27100) suggested by @gterzian.

`invalid` event on the `<form>` element has been [recently removed](https://github.com/whatwg/html/issues/4626) from the spec.

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

<!-- Either: -->
- [x] [WPT test](https://github.com/servo/servo/blob/master/tests/wpt/web-platform-tests/html/semantics/forms/form-submission-0/historical.window.js) marked as passing
2020-07-05 00:34:12 -04:00
bors-servo
f2e6f34a2b
Auto merge of #27173 - kunalmohan:gpu-queue-write, r=kvark
Implement GPUQueue write methods and update wgpu-core

<!-- Please describe your changes on the following line: -->
Implements `GPUQueue.writeBuffer` and `GPUQueue.writeTexture`.

r?@kvark

---
<!-- 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
- [ ] 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. -->
2020-07-04 21:32:43 -04:00
Maxim Tsoy
7fd903c214 Remove invalid event on a form element 2020-07-05 00:12:08 +02:00
Kunal Mohan
fae66089fa Implement GPUQueue.writeBuffer and GPUQueue.writeTexture 2020-07-04 21:49:32 +05:30
Kunal Mohan
8ef7f24541 Update wgpu-core and wgpu-types 2020-07-04 13:59:30 +05:30
bors-servo
8916a42180
Auto merge of #27163 - alarsyo:23053-layout-queries-disconnected-frames-panic, r=jdm
Return Option for Window's layout channel

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

`Window::layout_chan()` now returns an `Option<Sender<Msg>>`, returning `None` if the window is dead.

FIX #26969
FIX #26429
FIX #21208
FIX #19092
FIX #22559
FIX #22584
FIX #22652

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

<!-- 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. -->

This is my first contribution, I'm trying to figure things out!

This fix passes the test case shown in #23053, however I don't know what the behavior should be in `Document` and `ScriptThread` if `Window::is_alive()` is false : simply ignore it, don't do anything ? Or is this something that should not happen now that we return false in `Window::force_reflow()` ?

I'm not sure about the directory where the test case should go, any advice?
2020-07-04 01:30:27 -04:00
Josh Matthews
795560ad52 webgl: Add stub isContextLost API. 2020-07-03 14:47:06 -04:00
bors-servo
7fafd91593
Auto merge of #27154 - kunalmohan:async-presentation, r=kvark
WebGPU update presentation data asynchronously

<!-- Please describe your changes on the following line: -->
This PR aims to make updating Webrender presentation data non-blocking.
A callback is passed to the `buffer_map_async()` fn wherein the data is read and a message sent to the server itself to write the data into the shared `PresentationData` struct object.

r?@kvark

---
<!-- 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
- [ ] 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. -->
2020-07-03 14:01:55 -04:00
Antoine Martin
36fbbea2b5 Return Option for Window's layout channel 2020-07-03 20:00:26 +02:00
bors-servo
8800452e34
Auto merge of #27104 - utsavoza:ugo/issue-27030/28-06-2020, r=gterzian
Update referrer computation

The PR updates the request's referrer computation in consideration with the recent changes in [w3c/webappsec-referrer-policy#135](https://github.com/w3c/webappsec-referrer-policy/pull/135).

---
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes fix #27030 and fix #14505
- [x] There are tests for these changes
2020-07-03 11:39:07 -04:00
Kunal Mohan
b672b78e19 WebGPU update presentation data asynchronously 2020-07-03 15:42:08 +05:30
bors-servo
4504eebdc3
Auto merge of #27143 - Manishearth:streamnodes, r=ferjm
Implement MediaStreamAudioDestinationNode, MediaStreamAudioSourceNode, MediaStreamTrackAudioSourceNode

Progress in https://github.com/servo/servo/issues/26097

This is a draft since we need the data channels stuff to land first

(also I need to make sure we're passing WPT)
2020-07-03 01:48:52 -04:00
bors-servo
ee56d5d212
Auto merge of #27149 - paulrouget:key_events2, r=jdm
UWP: support virtual keyboard

Fix #26898 and fix #26680.

@jdm: can you test on the device?
2020-07-03 00:25:05 -04:00
Manish Goregaokar
718304709e Add AudioContext constructors for media stream nodes 2020-07-02 13:26:55 -07:00
Manish Goregaokar
0b998a1d1c Unpref MediaStream and MediaStreamTrack 2020-07-02 13:26:55 -07:00
Manish Goregaokar
6143173858 Add MediaStreamTrackAudioSourceNode 2020-07-02 13:26:55 -07:00
Manish Goregaokar
bc2267fb77 Add MediaStreamAudioSourceNode 2020-07-02 13:26:55 -07:00
Manish Goregaokar
2a838d935b Add MedaStreamAudioDestinationNode::stream 2020-07-02 13:26:55 -07:00
Manish Goregaokar
bf9614edf7 Add MediaStream::new_single() 2020-07-02 13:26:55 -07:00
Manish Goregaokar
6a001e7523 Add MediaStreamAudioDestinationNode 2020-07-02 13:26:55 -07:00
bors-servo
3bc4a935f8
Auto merge of #27100 - muodov:master, r=gterzian
Implement HTMLFormElement.requestSubmit()

<!-- Please describe your changes on the following line: -->
This PR contains an implementation of [HTMLFormElement.requestSubmit()](https://html.spec.whatwg.org/multipage/forms.html#dom-form-requestsubmit)

This is literally my first hundred lines of Rust code, so if I crossed a few sacred lines here and there, please go easy on me :)

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

<!-- Either: -->
- [x] [WPT tests](https://github.com/servo/servo/blob/master/tests/wpt/web-platform-tests/html/semantics/forms/the-form-element/form-requestsubmit.html) for these changes
There are two tests that still fail because we don't support `:invalid` CSS selector (see #10781). I verified that they pass if you change them to not use `:invalid`. Should be unlocked by #26729.

<!-- 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. -->
2020-07-02 09:54:47 -04:00