Commit graph

21881 commits

Author SHA1 Message Date
Keith Yeung
c198bfa388 Add GenerationId to EventSource 2016-11-11 14:50:48 -08:00
Keith Yeung
2924726b0a Implement reestablishing the connection for EventSource
And remove unneeded fields in EventSourceContext
2016-11-11 14:50:47 -08:00
Keith Yeung
9afc17cd3a Remove preferences in EventSource.webidl 2016-11-11 14:50:45 -08:00
Keith Yeung
388c3bff7b Parse metadata in EventSource 2016-11-11 14:50:44 -08:00
Keith Yeung
72cb856e31 Properly implement TaskSource for NetworkingTaskSource 2016-11-11 14:50:42 -08:00
Keith Yeung
d99d26cf1f Implement the constructor for EventSource 2016-11-11 14:50:37 -08:00
bors-servo
3b2e3dcfb9 Auto merge of #14175 - bholley:separate_cascade, r=emilio
Separate selector matching from property cascading

This builds on @emilio's rule tree work. The goal is to raise the boundary between rule node computation and property cascading higher up the callstack, so that the new traversal architecture can decide to do one but not the other.

<!-- 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/14175)
<!-- Reviewable:end -->
2016-11-11 16:35:34 -06:00
Bobby Holley
5741b8150a Separate rule node computation from cascade. 2016-11-11 14:04:17 -08:00
bors-servo
4b9693cf81 Auto merge of #14120 - Manishearth:logical, r=emilio
Support logical properties in style

Adds support for the logical block-end/inline-start/etc properties. These properties (like `border-block-end-color`) map to "physical" properties (e.g. `border-top-color`) depending on the writing mode.

Todo:

 - [x] Handle shorthands
 - [x] Make geckolib setters work
 - [x] Handle padding/offset logical properties
 - [x] Perhaps handle `-block-size`, `-inline-size` type logical properties?
 - [x] Tests?

This will overall add 16 new longhands and 4 new shorthands, taking a big bite out of the [remaining properties work](https://manishearth.github.io/css-properties-list/?stylo=hide&servo=hide&firefox=only&chrome=show&mdn=false&alexa=false)

f? @emilio @SimonSapin

<!-- 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/14120)
<!-- Reviewable:end -->
2016-11-11 15:41:08 -06:00
Vladimir Vukicevic
3cbf7aa5eb Update dwrote-rs to pick up non-en-us language fix 2016-11-11 15:36:34 -05:00
Manish Goregaokar
5fad7b0ff6 Add support for inline-size, block-size, and max-*-size/min-*-size 2016-11-11 11:56:27 -08:00
Manish Goregaokar
f974719d9f Add logical padding, margin longhands and border shorthands 2016-11-11 11:55:59 -08:00
Manish Goregaokar
e34eb13d65 Support logical properties 2016-11-11 11:55:57 -08:00
bors-servo
d49840eeec Auto merge of #14167 - emilio:rule-tree-list, r=Manishearth
style: Don't assume siblings are alive in the rule tree when removing ourselves from the child list.

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

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

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

We can't assume all our siblings are alive because they may very well be in the
free list too.

This tempts to happen when the rule nodes are destroyed as part of the last GC,
the one that runs in the root destructor.

Also, properly put the next sibling back into the list when the rules are GCd.

<!-- 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/14167)
<!-- Reviewable:end -->
2016-11-11 13:33:06 -06:00
Ravi Shankar
34955e0bf8 Add tests for the new LintRunner 2016-11-11 19:54:34 +05:30
Ravi Shankar
8385c9ae79 Isolate the WPT lint and make use of the LintRunner 2016-11-11 19:54:32 +05:30
Ravi Shankar
b5cff9db8f Add a generic LintRunner object for running custom lints 2016-11-11 19:54:21 +05:30
bors-servo
75d35241db Auto merge of #14168 - Manishearth:tmp-transform, r=heycam
stylo: support transform

r=heycam from https://bugzilla.mozilla.org/show_bug.cgi?id=1314200

<!-- 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/14168)
<!-- Reviewable:end -->
2016-11-10 18:38:48 -06:00
Manish Goregaokar
bb5f351f4a stylo: support transform 2016-11-10 16:38:15 -08:00
bors-servo
796fae4bbe Auto merge of #14153 - vvuk:win32-dwrite, r=glennw
Add support for DirectWrite font rendering on Windows

<!-- Please describe your changes on the following line: -->
This PR adds support for DirectWrite text rendering using a thin wrapper for dwrite, as well as similar functionality added to WebRender.  In doing so it removes the FreeType dep from the Windows build.

There is still work to be done here, but this is a good starting point for future cleanup and fixes.

---
<!-- 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
- [ ] `./mach test-tidy` does not report any errors
- [X] These changes fix #13371 (github issue number if applicable).

<!-- Either: -->
- [ ] There are tests for these changes OR
- [X] These changes do not require tests because they are already tested by other tests

<!-- 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/14153)
<!-- Reviewable:end -->
2016-11-10 16:55:17 -06:00
Vladimir Vukicevic
473df194fc tidy and warning fixes 2016-11-10 16:07:40 -05:00
bors-servo
e3f07dfa16 Auto merge of #14156 - frewsxcv:cors-capitalization, r=KiChjang
Update CORS naming from 'CORS' to 'Cors'.

As per:

https://aturon.github.io/style/naming/README.html#general-conventions-[rfc-#430]

Acronyms should be considered one word and not all caps.

<!-- 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/14156)
<!-- Reviewable:end -->
2016-11-10 14:43:36 -06:00
Glenn Watson
8a5baee83b Update WR to get ipc-channel revert. 2016-11-11 06:27:22 +10:00
Glenn Watson
8aff2dd298 Remove unused old blur shader. 2016-11-11 06:02:33 +10:00
Glenn Watson
9991e0674b Update shaders for sampler names, copy new text-shadow shaders. 2016-11-11 06:02:03 +10:00
Vladimir Vukicevic
db357b0334 DirectWrite font backend for Windows 2016-11-10 14:58:51 -05:00
bors-servo
990884be20 Auto merge of #14164 - nox:write, r=Ms2ger
Update html5ever to 0.10.1

<!-- 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/14164)
<!-- Reviewable:end -->
2016-11-10 13:51:37 -06:00
bors-servo
86a5682247 Auto merge of #14142 - mbrubeck:bug-1292275, r=heycam
Bug 1292275 - Stylo: Fix crash after failed stylesheet load.

This is the Servo part of [bug 1292275](https://bugzilla.mozilla.org/show_bug.cgi?id=1292275), already reviewed there by @heycam.

<!-- 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/14142)
<!-- Reviewable:end -->
2016-11-10 12:56:48 -06:00
bors-servo
d16f312464 Auto merge of #14136 - stshine:orthogonal-symmetry, r=SimonSapin
style: Add a "start_end()" method to LogicalMargin

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

Add a `LogicalMargin::start_end()` method that receives a `Direction' parameter. This is useful for some layout that is symmetric in inline and block directions, like flexbox.

Part of #14123.

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

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

r? @SimonSapin

<!-- 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/14136)
<!-- Reviewable:end -->
2016-11-10 11:53:05 -06:00
Emilio Cobos Álvarez
65f239c9e1
style: Don't assume siblings are alive in the rule tree when removing ourselves from the child list.
We can't assume all our siblings are alive because they may very well be in the
free list too.

This tempts to happen when the rule nodes are destroyed as part of the last GC,
the one that runs in the root destructor.

Also, properly put the next sibling back into the list when the rules are GCd.
2016-11-10 17:56:54 +01:00
bors-servo
d8a0a00032 Auto merge of #14127 - servo:response-new-url, r=nox
Make Response::url private.

<!-- 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/14127)
<!-- Reviewable:end -->
2016-11-10 09:19:52 -06:00
bors-servo
164e956944 Auto merge of #13791 - emilio:lazy-url, r=SimonSapin
Centralize construction of specified url() values in style.

This reduces a decent amount of overhead in #13778.

r? @SimonSapin

---

<!-- 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] There are tests for these changes OR

<!-- 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/13791)

<!-- Reviewable:end -->
2016-11-10 08:28:39 -06:00
Anthony Ramine
330263bf2c Update html5ever to 0.10.1 2016-11-10 14:58:10 +01:00
Ravi Shankar
f214765b61 Move file list iterator to a new module 2016-11-10 18:56:51 +05:30
Ms2ger
15b55c3231 Make Response::url private. 2016-11-10 13:18:43 +01:00
Ms2ger
c1e1695f66 Pass the URL to Response::new(). 2016-11-10 13:17:02 +01:00
Emilio Cobos Álvarez
5f2e7af864
style: Centralize specified url value handling, and refcount urls. 2016-11-10 13:15:21 +01:00
Ms2ger
65602de403 Add a successful test for a redirect loop. 2016-11-10 13:13:31 +01:00
Ms2ger
581c6dfe1b Rewrite test_load_errors_when_there_a_redirect_loop. 2016-11-10 12:57:19 +01:00
Pu Xingyu
eb22d33d4e style: Add a "start_end()" method to LogicalMargin
Add a `LogicalMargin::start_end()` method that receives a `Direction'
parameter. This is useful for some layout that is symmetric in inline
and block directions, like flexbox.
2016-11-10 19:17:29 +08:00
Ms2ger
bced313c47 Rewrite test_load_sets_default_accept_encoding_to_gzip_and_deflate. 2016-11-10 11:34:48 +01:00
Ms2ger
195774436b Rewrite test_load_uses_explicit_accept_encoding_from_load_data_headers. 2016-11-10 11:32:31 +01:00
Ms2ger
e12a6d7f4e Rewrite test_load_sets_default_accept_to_html_xhtml_xml_and_then_anything_else. 2016-11-10 11:26:54 +01:00
Ms2ger
6319d7cb99 Rewrite test_load_uses_explicit_accept_from_headers_in_load_data. 2016-11-10 11:22:23 +01:00
Ms2ger
5a02586341 Rewrite test_load_sets_content_length_to_length_of_request_body. 2016-11-10 11:18:22 +01:00
Ms2ger
c229a0116e Rewrite test_when_cookie_received_marked_secure_is_ignored_for_http. 2016-11-10 11:06:23 +01:00
Ms2ger
982c59662c Rewrite test_cookie_set_with_httponly_should_not_be_available_using_getcookiesforurl. 2016-11-10 11:06:22 +01:00
Ms2ger
52258e2282 Rewrite test_load_sends_cookie_if_nonhttp. 2016-11-10 11:01:08 +01:00
Ms2ger
f1f090ca81 Rewrite test_load_sets_requests_cookies_header_for_url_by_getting_cookies_from_the_resource_manager. 2016-11-10 11:01:07 +01:00
Ms2ger
5bf90c563c Rewrite test_load_sets_cookies_in_the_resource_manager_when_it_get_set_cookie_header_in_response. 2016-11-10 11:01:05 +01:00