Auto merge of #21543 - ceyusa:wip-player, r=<try>

Add <audio> and <video> player backends

These patches enables audio and video playing inside Servo.

It is bit hackish way to enable it, thus the purpose of this pull request is for an early request for comments.

It is tested with the current servo-media GStreamer backend in Linux.

~~The produced layout is not correct, since the elements after the video seems to be stacked behind, and the same with the scrolling bars.~~

~~There is no JavaScript interface yet~~, neither controls.

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

<!-- 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/21543)
<!-- Reviewable:end -->
This commit is contained in:
bors-servo 2018-10-09 04:15:18 -04:00 committed by GitHub
commit 3b153af49c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
29 changed files with 504 additions and 169 deletions

View file

@ -53,15 +53,9 @@
[opacity:0 child rendered ("<div>123<span style='opacity:0'>abc")]
expected: FAIL
[<audio> contents ignored ("<audio style='display:block'>abc")]
expected: FAIL
[<audio> contents ignored ("<audio style='display:block'><source id='target' class='poke' style='display:block'>")]
expected: FAIL
[<video> contents ignored ("<video>abc")]
expected: FAIL
[<video> contents ignored ("<video style='display:block'><source id='target' class='poke' style='display:block'>")]
expected: FAIL
@ -104,12 +98,6 @@
[<select size='2'> contents of options preserved ("<div><select size='2'><option>abc</option><option>def")]
expected: FAIL
[<audio> contents ignored ("<div><audio>abc")]
expected: FAIL
[<video> contents ignored ("<div><video>abc")]
expected: FAIL
[Blank lines between <p>s separated by non-empty block ("<div><p>abc</p><div>123</div><p>def")]
expected: FAIL
@ -260,3 +248,12 @@
[Whitespace around inline-block should not be collapsed ("<div>abc <span style='display:inline-block'></span> def")]
expected: FAIL
[text-transform handles Turkish casing ("<div><div lang='tr' style='text-transform:uppercase'>i ı")]
expected: FAIL
[<video> contents ok for element not being rendered ("<video style='display:block'><source id='target' class='poke' style='display:block'>")]
expected: FAIL
[<audio> contents ok for element not being rendered ("<audio style='display:block'><source id='target' class='poke' style='display:block'>")]
expected: FAIL

View file

@ -6786,12 +6786,6 @@
[HTMLVideoElement interface: attribute height]
expected: FAIL
[HTMLVideoElement interface: attribute videoWidth]
expected: FAIL
[HTMLVideoElement interface: attribute videoHeight]
expected: FAIL
[HTMLVideoElement interface: attribute poster]
expected: FAIL
@ -6804,12 +6798,6 @@
[HTMLVideoElement interface: document.createElement("video") must inherit property "height" with the proper type]
expected: FAIL
[HTMLVideoElement interface: document.createElement("video") must inherit property "videoWidth" with the proper type]
expected: FAIL
[HTMLVideoElement interface: document.createElement("video") must inherit property "videoHeight" with the proper type]
expected: FAIL
[HTMLVideoElement interface: document.createElement("video") must inherit property "poster" with the proper type]
expected: FAIL
@ -6837,9 +6825,6 @@
[HTMLMediaElement interface: calling fastSeek(double) on document.createElement("video") with too few arguments must throw TypeError]
expected: FAIL
[HTMLMediaElement interface: document.createElement("video") must inherit property "duration" with the proper type]
expected: FAIL
[HTMLMediaElement interface: document.createElement("video") must inherit property "getStartDate()" with the proper type]
expected: FAIL
@ -6909,9 +6894,6 @@
[HTMLMediaElement interface: calling fastSeek(double) on document.createElement("audio") with too few arguments must throw TypeError]
expected: FAIL
[HTMLMediaElement interface: document.createElement("audio") must inherit property "duration" with the proper type]
expected: FAIL
[HTMLMediaElement interface: document.createElement("audio") must inherit property "getStartDate()" with the proper type]
expected: FAIL
@ -7197,9 +7179,6 @@
[HTMLMediaElement interface: operation fastSeek(double)]
expected: FAIL
[HTMLMediaElement interface: attribute duration]
expected: FAIL
[HTMLMediaElement interface: operation getStartDate()]
expected: FAIL

View file

@ -1,5 +1,7 @@
[event_timeupdate_noautoplay.html]
type: testharness
disabled:
if os == "mac": https://github.com/servo/saltfs/pull/898
expected: TIMEOUT
[calling play() on a sufficiently long audio should trigger timeupdate event]
expected: NOTRUN

View file

@ -0,0 +1,4 @@
[load-events-networkState.html]
[NETWORK_NO_SOURCE]
expected: FAIL

View file

@ -0,0 +1,4 @@
[resource-selection-invoke-insert-into-iframe.html]
[NOT invoking resource selection by inserting into other document with src set]
expected: FAIL

View file

@ -0,0 +1,4 @@
[resource-selection-invoke-pause-networkState.html]
[NOT invoking resource selection with pause() when networkState is not NETWORK_EMPTY]
expected: FAIL

View file

@ -0,0 +1,4 @@
[resource-selection-invoke-remove-from-document-networkState.html]
[NOT invoking resource selection with implicit pause() when networkState is not NETWORK_EMPTY]
expected: FAIL