aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom
Commit message (Collapse)AuthorAgeFilesLines
...
* | | | | Bug 1325878: Pass the MediaList down to Servo, making <style media> work. ↵Emilio Cobos Álvarez2017-04-124-13/+13
| |_|/ / |/| | | | | | | | | | | | | | | | | | | | | | | r=xidorn MozReview-Commit-ID: BUCSQJs2CNI Signed-off-by: Emilio Cobos Álvarez <emilio@crisal.io>
* | | | Auto merge of #16063 - methyl:image-usemap-panics, r=noxbors-servo2017-04-121-0/+5
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Avoid panics for empty or multibyte image usemap <!-- Please describe your changes on the following line: --> Some check were added to make sure we can call `split_at` with no risk of panics (when value is empty or the first char is multibyte). --- <!-- 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 #15883 (github issue number if applicable). - [x] There are 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/16063) <!-- Reviewable:end -->
| * | | | Avoid panics for empty or multibyte image usemapLucjan Suski2017-03-211-0/+5
| | | | |
* | | | | Pass ParserContext down to lengthsJ. Ryan Stinnett2017-04-125-16/+44
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | To make it possible to check the rule type when parsing lengths, we need to pass the `ParserContext` down through many layers to the place where length units are parsed. This change leaves it unused, so it's only to prepare for the next change. MozReview-Commit-ID: 70YwtcCxnWw
* | | | | Pull rule_type into ParserContextJ. Ryan Stinnett2017-04-123-5/+9
| |/ / / |/| | | | | | | | | | | | | | | | | | | | | | | Absorb `rule_type` into the `ParserContext` so that it's easier to pass down to deeper levels of the parser. MozReview-Commit-ID: DjBNytLxGKX
* | | | Auto merge of #16229 - tomhoule:fix-lengths, r=emiliobors-servo2017-04-121-2/+2
|\ \ \ \ | |_|/ / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | style: Do not immediately convert absolute specified lengths <!-- Please describe your changes on the following line: --> This PR aims to solve issue #15729. I tried to follow the recommendations there as much as possible. This is my first attempt at contributing to Servo, so this will probably need a lot of input, although I'm eager to make it as polished as possible. - The base inaccuracy issue seems solved, as can be easily verified with the `console.log` based example in the issue. - Very basic unit tests were added. I have doubts mainly about the right way to represent these new enum variants for the various length units: 1. With new enum variants in `NoCalcLength` *and* newtypes (current solution) 2. With a `NoCalcLength::Absolute` variant that contains a new `AbsoluteLength` enum, but without newtypes 3. Same as solution 2 but with newtypes - I mostly cared about unit tests until now but will investigate other types of tests - Tests to check the clamping - Write a proper commit message Thanks for your time and feedback :) --- <!-- 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 #15729. <!-- 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/16229) <!-- Reviewable:end -->
| * | | Style: Do not immediately convert absolute specified lengthsTom Houlé2017-04-121-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The NoCalcLength::Absolute variant has been rewritten to accommodate other units than Au with the new AbsoluteLength enum. This avoids loss of precision for some operations. The conversion from floating point absolute lengths to integer application unit values adopts the same clamping limits as Gecko.
* | | | Auto merge of #16325 - KiChjang:fix-formdata-wpt, r=cbrewsterbors-servo2017-04-103-6/+10
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix formdata-blob.htm The other failure is a legitimate WPT bug, will fix upstream. <!-- 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/16325) <!-- Reviewable:end -->
| * | | | Follow the spec in giving blobs a 'blob' name attributeKeith Yeung2017-04-091-3/+7
| | | | |
| * | | | Provide MIME type data for File in formdata::get_fileKeith Yeung2017-04-093-3/+3
| |/ / /
* | | | Auto merge of #16315 - jryans:at-page-stylo, r=xidornbors-servo2017-04-091-0/+1
|\ \ \ \ | |/ / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Stylo: @page support Reviewed by upsuper in https://bugzilla.mozilla.org/show_bug.cgi?id=1345206. - [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/16315) <!-- Reviewable:end -->
| * | | Servo parsing / serialization for @pageJ. Ryan Stinnett2017-04-091-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Adds basic parsing and serialization for @page rules in Servo. It is handled in the same manner as a regular style rule. MozReview-Commit-ID: JRr3DDGcUIl
* | | | script: Map HTMLCanvasElement width and height attributes.Emilio Cobos Álvarez2017-04-093-3/+46
| | | |
* | | | script: Remove now-unused function.Emilio Cobos Álvarez2017-04-091-4/+0
| | | | | | | | | | | | | | | | | | | | MozReview-Commit-ID: Cnw5dlczJxv Signed-off-by: Emilio Cobos Álvarez <emilio@crisal.io>
* | | | style: Stop special-casing a few attributes for style sharing, and use a ↵Emilio Cobos Álvarez2017-04-091-9/+0
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | visitor to track dependencies. Also, simplify all the pre-snapshot attribute hacks in the script and style code. MozReview-Commit-ID: 6c9ipeb7Tnr Signed-off-by: Emilio Cobos Álvarez <emilio@crisal.io>
* | | Kill Request::omit_origin_headerAnthony Ramine2017-04-071-4/+1
| | |
* | | Auto merge of #15904 - sendilkumarn:image-area, r=jdmbors-servo2017-04-052-10/+15
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | making image element areas good at finding areas <!-- 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 #15884 <!-- 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/15904) <!-- Reviewable:end -->
| * | | making image element areas good at finding areasSendilKumar N2017-04-042-10/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | linting errors replaced with map fixes comments moving to document added test cases linting and updating manifest changing test cases linting fixes manifest update linting fixes splitting the test cases into two
* | | | Auto merge of #16268 - jdm:tmp, r=jdmbors-servo2017-04-055-0/+127
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Basic MutationObserver interface stubs Rebase and squash of https://github.com/servo/servo/pull/16190. <!-- 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/16268) <!-- Reviewable:end -->
| * | | | Implement basic interface for MutationObserver and MutationRecord.Sumit2017-04-055-0/+127
| |/ / /
* / / / Add way to get c_void ptr or c_char from callermckaymatt2017-04-045-10/+32
|/ / /
* | | Revert to per-process shared lock for author-origin stylesheetsSimon Sapin2017-04-031-1/+15
| | | | | | | | | | | | | | | Fixes https://github.com/servo/servo/issues/16097 Reopens https://github.com/servo/servo/issues/16027
* | | Auto merge of #16214 - nox:net, r=emiliobors-servo2017-04-031-44/+36
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | Improve the net crate <!-- 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/16214) <!-- Reviewable:end -->
| * | | Remove all internal mutability from RequestAnthony Ramine2017-04-031-44/+36
| | | |
* | | | Use a UrlExtraData type alias to unify url handling logic.Xidorn Quan2017-04-035-16/+7
| | | |
* | | | Pass CSS loader to Servo for insertRule.Xidorn Quan2017-04-031-1/+4
| | | |
* | | | Make the parser accept @font-face rules without font-family or src.Simon Sapin2017-04-011-9/+6
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix #16165. Also, it turns out that the CSSFontFaceRule IDL specified in the css-fonts spec is not web-compatible. Instead browsers implement a .style attribute like in CSSStyleRule: https://github.com/w3c/csswg-drafts/issues/825 This in turn requires preserving data about which descriptors were set or not (distinguishing unset from set to a value that happens to be the initial value), so this commit also makes every field `Option<_>`.
* | | Auto merge of #15868 - servo:hyper, r=jdmbors-servo2017-03-311-7/+8
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | Update Hyper and OpenSSL <!-- 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/15868) <!-- Reviewable:end -->
| * | | Update Hyper and OpenSSLddh2017-03-311-7/+8
| | | |
* | | | Auto merge of #16170 - TheKK:implement_html_anchor_element_rel, r=jdmbors-servo2017-03-302-8/+14
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Implement HTMLAnchorElement.rel getter and setter This PR makes code below possible: ```javascript a = document.createElement("a"); a.rel = "foo"; console.log(a.rel); // print out "foo" ``` --- - [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 <!-- 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/16170) <!-- Reviewable:end -->
| * | | | Implement HTMLAnchorElement.rel getter and setterYing-Ruei Liang(KK)2017-03-302-8/+14
| |/ / / | | | | | | | | | | | | Signed-off-by: Ying-Ruei Liang(KK) <thumbd03803@gmail.com>
* / / / Terminate timer scheduler thread during shutdownFernando Jiménez Moreno2017-03-302-6/+6
|/ / /
* | | Rename font_face::FontFaceRule to FontFaceData.Xidorn Quan2017-03-302-4/+3
| | |
* | | Replace ParsedDeclaration::expand with non-generic methodSimon Sapin2017-03-291-4/+1
| | | | | | | | | | | | | | | | | | ... to reduce its code size impact. https://bugzilla.mozilla.org/show_bug.cgi?id=1351737
* | | Move image cache implementation to the net crateFernando Jiménez Moreno2017-03-271-3/+3
| | |
* | | Make image cache per-document rather than globalFernando Jiménez Moreno2017-03-276-28/+29
| | |
* | | style: Align border-spacing with other engines.Emilio Cobos Álvarez2017-03-271-2/+2
| | |
* | | Auto merge of #16137 - nox:die-rustc-serialize-die, r=emiliobors-servo2017-03-263-16/+7
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | Replace use of rustc_serialize::base64 by base64 <!-- 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/16137) <!-- Reviewable:end -->
| * | | Replace use of rustc_serialize::base64 by base64Anthony Ramine2017-03-263-16/+7
| | | |
* | | | Auto merge of #16139 - servo:rustup, r=emiliobors-servo2017-03-261-2/+2
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Update rustc to 1.17.0-nightly (7dd4e2db7 2017-03-26) <!-- 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/16139) <!-- Reviewable:end -->
| * | | | Update rustc to 1.17.0-nightly (7dd4e2db7 2017-03-26)Anthony Ramine2017-03-261-2/+2
| |/ / /
* / / / Remove some useless Option<T> wrappers from ServoUrl methodsAnthony Ramine2017-03-263-43/+23
|/ / /
* | | Only pass the protocol in use in to establish a WS connectionAnthony Ramine2017-03-241-7/+5
| | |
* | | Properly follow the spec in WebSocket::ConstructorAnthony Ramine2017-03-241-124/+34
| | |
* | | Make ServoUrl::as_url return a &UrlAnthony Ramine2017-03-234-15/+15
| | |
* | | Avoid a useless clone in WebSocket::ConstructorAnthony Ramine2017-03-231-5/+5
| | |
* | | Don't resolve URLs at parse time for Stylo.Bobby Holley2017-03-221-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It's a bit unfortunate the use separate implementations of SpecifiedUrl for Servo and Gecko, but they're different enough at this point that I don't think it really makes sense to try to share everything. Splitting them out has some nice simplifications as well. I recognize that there's still some potential correctness issues for Servo using the resolved URI in various places where the original URI may be the right thing, but I've got too much on my plate to look into that for now. MozReview-Commit-ID: BeDu93TQ4Ow
* | | Auto merge of #16083 - MortimerGoro:display_raf_check, r=emiliobors-servo2017-03-221-2/+11
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix WebVR data race condition when calling GetFrameData outside of VRDisplay.requestAnimationFrame callback <!-- Please describe your changes on the following line: --> Fix WebVR data race condition when calling GetFrameData outside of VRDisplay.requestAnimationFrame callback. Fixes a possible deadlock during the interval when the requestAnimationFrame is moved from window to VRDisplay. --- <!-- 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/16083) <!-- Reviewable:end -->
| * | | Only sync WebVR framedata with compositor when GetFrameData function is ↵Imanol Fernandez2017-03-221-2/+11
| |/ / | | | | | | | | | called inside a VRDisplay.requestAnimationFrame callback.
* | | Bug 1345950: stylo: Fix slow selector flags. r=bholleyEmilio Cobos Álvarez2017-03-221-4/+7
| | | | | | | | | | | | | | | MozReview-Commit-ID: QwuSxulNG0 Signed-off-by: Emilio Cobos Álvarez <emilio@crisal.io>