Commit graph

9908 commits

Author SHA1 Message Date
Keith Yeung
4dcf693a75 Use fetch infrastructure to load external scripts 2016-09-21 11:50:55 -07:00
Keith Yeung
d4816762fa Add fetch_async to PendingAsyncLoad, DocumentLoader and Document 2016-09-21 11:50:54 -07:00
Keith Yeung
2bb95989c5 Implement default values for RequestInit 2016-09-21 11:50:53 -07:00
Keith Yeung
5729a4a3d4 Fix incorrect indentation 2016-09-21 11:50:52 -07:00
Keith Yeung
4c616dad90 Add crossorigin attribute and implement step 14 of prepare a script
Add WPT test for HTMLScriptElement crossOrigin IDL attribute
2016-09-21 11:50:51 -07:00
Keith Yeung
f566a8d44f Update step annotations for prepare a script 2016-09-21 11:49:47 -07:00
Bobby Holley
63124bab66 Filter non-element / non-text nodes in LayoutIterator. 2016-09-21 11:43:52 -07:00
bors-servo
7b98c8a788 Auto merge of #13332 - servo:mozmap, r=jdm
Implement the MozMap type.

Fixes #13144.

<!-- 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/13332)
<!-- Reviewable:end -->
2016-09-21 10:09:58 -05:00
bors-servo
c0bcd6fa5e Auto merge of #13315 - Phrohdoh:textinput-minlength-13313, r=ConnorGBrewster
Implement minlength attribute for text inputs

<!-- Please describe your changes on the following line: -->
**This is not ready to be merged:
I need help writing tests as I am not familiar with the methods used in the `maxlength` tests (introduced in  tests/unit/script/textinput.rs).**

I also need to write the `minlength-manual` test.

Closes #13313
This depends on #13314 (and includes the commit from it so will need to be rebased once that patch lands).

I am just looking for a quick review to make sure I am on the right path.

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

<!-- Either: -->
- [X] There ~~are~~ *will be* tests for these changes

<!-- 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/13315)
<!-- Reviewable:end -->
2016-09-21 08:49:14 -05:00
Anthony Ramine
948d2792c6 Update Rust to 1.13.0-nightly (c772948b6 2016-09-20) 2016-09-21 15:40:06 +02:00
Anthony Ramine
fe4f3543c1 Silence a warning in ExtendableEvent::WaitUntil 2016-09-21 15:38:51 +02:00
Taryn Hill
2cb5adf6c6 Implement minlength for text inputs 2016-09-21 07:54:39 -05:00
Ms2ger
2d83e5a788 Implement the MozMap type.
Fixes #13144.
2016-09-21 14:03:34 +02:00
Ms2ger
9a9ca45084 Introduce wrapInNativeContainerType. 2016-09-21 14:03:33 +02:00
Ms2ger
9371889a03 Use innerContainerType in getConversionConfigForType. 2016-09-21 13:44:31 +02:00
Ms2ger
b2fc80a847 Rename innerSequenceType to innerContainerType. 2016-09-21 13:42:35 +02:00
Ms2ger
e942f50e1b Handle unsupported types better in getUnionTypeTemplateVars. 2016-09-21 13:17:05 +02:00
Ms2ger
d1d2074d43 Improve handling of ConversionResult::Failure in unions. 2016-09-21 13:17:04 +02:00
Ms2ger
6023560863 Improve jsid_to_str's name and documentation. 2016-09-21 13:17:03 +02:00
Tetsuharu OHZEKI
93866d42ed Update mozjs_sys to fix the build failure on macOS Sierra 2016-09-21 19:16:25 +09:00
Bobby Holley
4aa3e589c0 Introduce the LayoutIterator newtype and return it for all children() methods in style and layout. 2016-09-20 17:48:31 -07:00
bors-servo
7c0dfd07ad Auto merge of #13309 - anholt:webgl-fbo-prep, r=emilio
webgl: FBO support preparation

<!-- Please describe your changes on the following line: -->
Sending this PR now so that we can get the webrender patches merged.  This is prep for the webgl-fbo series, with one small fix for some conformance tests.

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

<!-- 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/13309)
<!-- Reviewable:end -->
2016-09-20 19:19:21 -05:00
Bobby Holley
e6bbff110a Split out is_element and is_text_node into a helper trait. 2016-09-20 17:16:27 -07:00
bors-servo
8a78e75d43 Auto merge of #12493 - TheKK:referrer_policy_dliver_via_rel, r=jdm
Implement referrer policy delivery via noreferrer link relation

According to https://w3c.github.io/webappsec-referrer-policy/#referrer-policy-delivery, there's `<a>`, `<link>` and `<area>` could apply this delivery method. This PR contains changes for `<a>` and `<link>` **but** not `<area>`, since HTMLAreaElement is barely implemented.

We should file another issue for it.

---
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #11862
- [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/12493)
<!-- Reviewable:end -->
2016-09-20 17:42:11 -05:00
Glenn Watson
6b1104e7f6 Update webrender to master, including shaders.
This updates webrender to include the webgl related changes
needed for this patch. There was an additional commit in
webrender before these landed, so also copy the shaders
for that change across. There is an interface change to
webrender push_image. For now, just pass zero, which is a
no-op to this function. A follow up commit will introduce
the servo specific changes to use this new interface.
2016-09-21 08:24:59 +10:00
Eric Anholt
87c9333abd webgl: Do validation that the framebuffer is complete for FBO operations.
Given that we can't make a complete FBO yet, just return false from
the status check.
2016-09-21 08:05:45 +10:00
Eric Anholt
b2c169274a webgl: Don't forget update WebGL's texture binding on unbind.
This doesn't appear to fix any testcases, but I noticed it when fixing
renderbuffers.
2016-09-21 08:05:45 +10:00
Eric Anholt
2d66840145 webgl: Don't forget to update the WebGL context's RB binding.
We need to track the RB in the DOM context for
getParameter(gl.RENDERBUFFER_BINDING), among others.
2016-09-21 08:05:45 +10:00
Eric Anholt
cc294fffcc webgl: Update the match for WebGLError's new InvalidFramebufferOperation. 2016-09-21 08:05:45 +10:00
Ying-Ruei Liang(KK)
55a2270e16 Bring referrer policy delivery to <a> and <link> via rel attribute 2016-09-20 21:17:37 +08:00
Ms2ger
61402b8ca7 Inline push_pending_frame into its callers.
The recently added replace argument makes it less readable, especially with
the second boolean argument I am adding in #11893.
2016-09-20 14:01:56 +02:00
Alexandrov Sergey
3488d15022 fix JS IndexedGetter and NamedSetter bindings generation 2016-09-20 14:50:21 +03:00
bors-servo
53938c439f Auto merge of #13329 - pcwalton:last-line-in-flow, r=notriddle
layout: Make `baseline_offset_of_last_line_box_in_flow()` only check blocks in flow.

Improves python.org.

Closes #12124.

r? @notriddle

<!-- 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/13329)
<!-- Reviewable:end -->
2016-09-19 22:45:55 -05:00
bors-servo
f313beee9b Auto merge of #13330 - glennw:update-wr-prim-cache, r=pcwalton
Update webrender (prim cache changes, blend/composite shaders).

<!-- 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/13330)
<!-- Reviewable:end -->
2016-09-19 21:47:40 -05:00
Glenn Watson
7c8664e6ec Update webrender (prim cache changes, blend/composite shaders). 2016-09-20 10:57:48 +10:00
bors-servo
993fbc4320 Auto merge of #13302 - pcwalton:negative-margin-speculation, r=notriddle
layout: Disable the speculation of block formatting contexts' inline sizes if the block formatting contexts have negative margins.

The heuristics that determine how and whether floats flow into the
margins are not valid in that case.

Closes #13299.

r? @notriddle

<!-- 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/13302)
<!-- Reviewable:end -->
2016-09-19 19:22:29 -05:00
Patrick Walton
c6b9b315aa layout: Make baseline_offset_of_last_line_box_in_flow() only check
blocks in flow.

Improves python.org.

Closes #12124.
2016-09-19 17:17:08 -07:00
Patrick Walton
b4aea115b8 layout: Disable the speculation of block formatting contexts' inline
sizes if the block formatting contexts have negative margins.

The heuristics that determine how and whether floats flow into the
margins are not valid in that case.

Closes #13299.
2016-09-19 16:27:55 -07:00
bors-servo
dc3e11f96e Auto merge of #13324 - anholt:webgl-default-texture, r=jdm
Update offscreen_gl_context dependency to get webgl fix.

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

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

<!-- 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/13324)
<!-- Reviewable:end -->
2016-09-19 16:41:49 -05:00
bors-servo
7d3c7beb21 Auto merge of #13322 - jdm:msvc-build-fix, r=KiChjang
Make dummy font implementation conform to API changes.

- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #13321
- [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/13322)
<!-- Reviewable:end -->
2016-09-19 15:37:16 -05:00
Connor Brewster
e9b2f1b916 Replace current session entry for reloads 2016-09-19 14:23:03 -05:00
Josh Matthews
d985741701 Make dummy font implementation conform to API changes. 2016-09-19 14:38:36 -04:00
Eric Anholt
0303767da8 Update offscreen_gl_context dependency to get webgl fix.
Fixes #11618 (intermittent failure in default_texture.html) by not
polluting our context's binding with the texture it created.
2016-09-19 18:48:31 +01:00
Ms2ger
630da77744 Update js. 2016-09-19 17:39:33 +02:00
bors-servo
a82d5106bd Auto merge of #12076 - jdm:font-load, r=pcwalton
Make font template data load fallible

Remove a TODO around dealing with a failed file operation.

Can we write an automated test for this? I don't really know what font template data is, but this failure seems to be fontconfig-specific...

---
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #12037
- [ ] There are tests for these changes OR
- [ ] These changes do not require tests because _____

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="35" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/12076)
<!-- Reviewable:end -->
2016-09-19 09:14:55 -05:00
Emilio Cobos Álvarez
e2db4fe466
constellation: Minor refactoring to aid legibility.
Two things changed, on one hand, avoid a dumb if chain that could be more
idiomatically written with a match expression, and also avoiding use map() to
change state.

In general I'm pretty surprised for our lack of error reporting in this
critical code, but that's not the purpose of this PR.
2016-09-19 14:25:29 +02:00
bors-servo
fe426f65b9 Auto merge of #13306 - Jenselme:13247-decode-utf8-with-utf8-lossy, r=Ms2ger
Decode UTF-8 with from_utf8_lossy in DedicatedWorkerGlobalScope

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

<!-- Either: -->
- [X] There are tests for these changes: `./mach test-wpt /workers/semantics/encodings/004.worker` passes

<!-- 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/13306)
<!-- Reviewable:end -->
2016-09-19 04:07:14 -05:00
Julien Enselme
9adda6e38d Decode UTF-8 with from_utf8_lossy in DedicatedWorkerGlobalScope 2016-09-19 10:29:05 +02:00
bors-servo
d76091ef0f Auto merge of #13314 - Phrohdoh:update-string_cache-to29patch, r=KiChjang
Update string_cache to 0.2.29

<!-- Please describe your changes on the following line: -->
Update string-cache from 0.2.28 to 0.2.29 which includes `minlength` for #13313.

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

<!-- Either: -->
- [X] These changes do not require tests because this is only adding a single string to string-cache (ref https://github.com/servo/string-cache/pull/172)

<!-- 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/13314)
<!-- Reviewable:end -->
2016-09-19 00:44:05 -05:00
bors-servo
5457b80233 Auto merge of #13307 - bubbles231:code_refactor, r=Manishearth
Code refactoring

<!-- Please describe your changes on the following line: -->
The code was refactored to follow Rust naming conventions better.

---
<!-- 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 help fix #12379.

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

<!-- 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/13307)
<!-- Reviewable:end -->
2016-09-18 22:57:59 -05:00