aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/bindings
Commit message (Collapse)AuthorAgeFilesLines
* Implement the Request API for the Fetch API.Jeena Lee2016-08-121-0/+2
| | | | | | | | | | | | | | | This commit adds new files related to implementing the [Request API](https://fetch.spec.whatwg.org/#request-class). This commit also changes the expected web platform tests results. It also modifies the following files: components/net_traits/request.rs HeapSizeOf is implemented in net_traits/request so that dom::request can be used as a wrapper around net_traits::request::Request. components/script/dom/headers.rs Several methods are added to Headers so that request can access and modify some of the headers fields.
* bindings generator: support default ByteString values in dictionaryMalisa Smith2016-08-102-3/+27
|
* Add cancellability to file manager load and related refactoringZhen Zhang2016-08-021-6/+0
|
* Auto merge of #12186 - GuillaumeGomez:video-metadata, ↵bors-servo2016-07-291-0/+3
|\ | | | | | | | | | | | | | | | | | | r=larsbergstrom,jdm,KiChjang Implement video-metadata check <!-- 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/12186) <!-- Reviewable:end -->
| * Implement video-metadata checkggomez2016-07-251-0/+3
| |
* | Remove an unused argument to ErrorInfo::from_dom_exception.Ms2ger2016-07-291-2/+2
| |
* | Update SpiderMonkey to m-c bcf4ff0c3eef.Ms2ger2016-07-284-110/+196
|/ | | | | | This currently breaks Servo on Android, because there are a number of interdependent changes that cannot easily land serially in a way that keeps it working throughout. We expect to fix this in the near future.
* Auto merge of #12546 - malisas:malisa-bytestring-unions, r=KiChjangbors-servo2016-07-211-1/+4
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Union types now allow ByteString <!-- Please describe your changes on the following line: --> This PR addresses issue #12527 to allow ByteStrings in union types. --- <!-- 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 #12527 (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/12546) <!-- Reviewable:end -->
| * Union types now allow ByteStringMalisa Smith2016-07-211-1/+4
| |
* | Auto merge of #12469 - emilio:stylo, r=bholleybors-servo2016-07-211-2/+1
|\ \ | |/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | style: Rewrite the restyle hints code to allow different kinds of element snapshots. <!-- 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] 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. --> This is a rewrite for how style interfaces with its consumers in order to allow different representations for an element snapshot. This also changes the requirements of an element snapshot, requiring them to only implement MatchAttr, instead of MatchAttrGeneric. This is important for stylo since implementing MatchAttrGeneric is way more difficult for us given the atom limitations. This also allows for more performant implementations in the Gecko side of things. I don't want to get this merged just yet, mainly because the stylo part is not implemented, but I'd like early feedback from @bholley and/or @heycam: How do you see this approach? I don't think we'll have much problem to implement MatchAttr for our element snapshots, but... worth checking. r? @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/12469) <!-- Reviewable:end -->
| * style: Rewrite the restyle hints code to allow different kinds of element ↵Emilio Cobos Álvarez2016-07-211-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | snapshots, and use it for Gecko. This is a rewrite for how style interfaces with its consumers in order to allow different representations for an element snapshot. This also changes the requirements of an element snapshot, requiring them to only implement MatchAttr, instead of MatchAttrGeneric. This is important for stylo since implementing MatchAttrGeneric is way more difficult for us given the atom limitations. This also allows for more performant implementations in the Gecko side of things.
* | Auto merge of #12541 - jdm:seqseq, r=noxbors-servo2016-07-211-4/+8
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Support sequences of sequences in generated bindings. This fixes a blocker for #11897. `unroll` recursively gets the inner type of any sequence type encountered, so it's inappropriate for codegen that only wants the immediate inner type. However, if a type identifies as a sequence and is nullable, we need to reach through the nullable wrapper first. Gecko does very similar things. --- - [X] `./mach build -d` does not report any errors - [X] `./mach test-tidy` does not report any errors - [X] These changes fix #12528 (github issue number if applicable). - [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/12541) <!-- Reviewable:end -->
| * | Support sequences of sequences in generated bindings.Josh Matthews2016-07-211-4/+8
| | | | | | | | | | | | unroll recursively gets the inner type of any sequence type encountered, so it's inappropriate for codegen that only wants the immediate inner type. However, if a type identifies as a sequence and is nullable, we need to reach through the nullable wrapper first. Gecko does very similar things.
* | | Removed panic channel, replaced by integrated logging and issue reporting.Alan Jeffrey2016-07-201-9/+1
| | |
* | | Auto merge of #12467 - jeenalee:jeena-headersAPI, r=jdmbors-servo2016-07-201-1/+1
|\ \ \ | |_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add the append method for the Headers API <!-- Please describe your changes on the following line: --> This commit adds the append method for the Headers API. @malisas and I are both contributors. There are a few TODOs related: - The script needs to parse the header value for certain header names to decide the header group it belongs - There are possible spec bugs that could change what a valid header value looks like (related: [issue page](https://github.com/whatwg/fetch/issues/332)) There are WPT tests already written for the Headers API, but they will fail as the Headers API is not fully implemented. --- <!-- 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 tests for the Headers API already exists, but this commit does not implement the interface fully. The tests will fail. <!-- 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/12467) <!-- Reviewable:end -->
| * | Add the append method for the Headers API for the Fetch APIJeena Lee2016-07-191-1/+1
| | | | | | | | | | | | This commit will add the append method and associated helper functions, and introduce any necessary changes for it.
* | | Expand the documentation for DOMString.Ms2ger2016-07-191-0/+35
| | | | | | | | | | | | | | | There was some confusion on IRC about its purpose; hopefully this will clarify the situation.
* | | Integrate service worker manager threadRahul Sharma2016-07-161-9/+1
|/ /
* | Auto merge of #12451 - jdm:generate-dom-apis, r=Ms2gerbors-servo2016-07-157-11/+100
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Generate a list of supported DOM APIs from parsed WebIDLs. Supplement the existing list of supported CSS properties with an equivalent list of DOM APIs. --- <!-- 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 automatic generated documentation <!-- 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/12451) <!-- Reviewable:end -->
| * | Generate a list of supported DOM APIs from parsed WebIDLs.Josh Matthews2016-07-157-11/+100
| |/
* | Implement file reading task sourceKeith Yeung2016-07-141-2/+3
| | | | | | | | And remove superfluous FileReaderEvent enum
* | Allow wrapping worker runnables in cancellable runnables.Josh Matthews2016-07-141-1/+10
|/
* Auto merge of #12418 - emilio:webidl-update, r=Ms2gerbors-servo2016-07-137-303/+1179
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | WebIDL update <!-- Please describe your changes on the following line: --> ~~This should help #11203~~ (no, it doesn't, but still worth it). r? @jdm --- <!-- 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/12418) <!-- Reviewable:end -->
| * webidl: Apply and update debug.patch, remove abstract.patch which was ↵Emilio Cobos Álvarez2016-07-123-23/+12
| | | | | | | | already upstream.
| * webidl: Update parserEmilio Cobos Álvarez2016-07-124-280/+1167
| | | | | | | | Some patches failed to apply. I'll apply manually after this.
| * webidl: Update the update script now mxr is gone.Emilio Cobos Álvarez2016-07-121-1/+1
| |
* | Auto merge of #12406 - izgzhen:refactor-file, r=Manishearthbors-servo2016-07-121-0/+2
|\ \ | |/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Refactor FileAPI implementation Most are simple refactoring, cleanups and improvements, but still involving two slightly notable changes: + In `filemanager`, now we read the file content based on requested `RelativePos` by `seek` and `read_exact` (rather than `read_to_end` then do slicing). This strategy might be again adjusted in future performance tuning but certainly better than nothing. + Also, I cached more file meta-info in both sides and left a block of comment on `filemanager`'s file reading mentioning the snapshot-state problem (not solved now though). r? @Manishearth <!-- 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 <!-- 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/12406) <!-- Reviewable:end -->
| * Refactor FileAPI implementationZhen Zhang2016-07-131-0/+2
| |
* | Auto merge of #12395 - jdm:nowrap, r=Ms2gerbors-servo2016-07-122-12/+17
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Avoid calling JS_WrapValue for same-compartment DOM reflectors This change shaves off 15-20ns per iteration of the node.firstChild getter test in tests/html/bindings_perf.html. Based on [similar Gecko code](http://searchfox.org/mozilla-central/rev/f43c9e0ffa92e72dbdbcbf57eecf04a43d46da63/dom/bindings/BindingUtils.h#781). --- - [X] `./mach build -d` does not report any errors - [X] `./mach test-tidy` does not report any errors - [X] These changes fix (partially) #12358 <!-- 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/12395) <!-- Reviewable:end -->
| * | Remove unused imports from codegen.Josh Matthews2016-07-121-7/+6
| | |
| * | Avoid unnecessary JS_WrapValue calls for DOM reflectors.Josh Matthews2016-07-121-5/+11
| |/
* | Implement the [Exposed] extended attribute on interfaces.Ms2ger2016-07-124-16/+54
| | | | | | | | Fixes #2823.
* | Make sure that Descriptor.isGlobal() returns a bool.Ms2ger2016-07-121-2/+2
| |
* | Simplify CGConstructorEnabled.Ms2ger2016-07-121-16/+4
| |
* | Make DefineDOMInterface and ConstructorEnabled unsafe functions.Ms2ger2016-07-121-4/+6
| |
* | Add support for unsafe Rust-ABI functions to CGAbstractMethod.Ms2ger2016-07-121-3/+6
| |
* | Generate 'pub' before 'unsafe extern', if both are used.Ms2ger2016-07-121-3/+3
| |
* | Correct indentation in the DOMClass function.Ms2ger2016-07-121-9/+9
| |
* | Allow [Pref] annotations on worker-exposed interfaces.Ms2ger2016-07-123-12/+29
|/ | | | Servo does not have the same main-thread limitation as Gecko here.
* Auto merge of #12272 - Ms2ger:report, r=jdmbors-servo2016-07-061-10/+4
|\ | | | | | | | | | | | | | | Reuse report_pending_exception in CallSetup. <!-- 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/12272) <!-- Reviewable:end -->
| * Reuse report_pending_exception in CallSetup.Ms2ger2016-07-051-10/+4
| |
* | Auto merge of #12261 - szeged:gattcharacteristicfunctions, r=jdmbors-servo2016-07-061-0/+3
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Missing steps of Characteristic's readValue, writeValue functions <!-- Please describe your changes on the following line: --> Add a check for the read property of the characteristic as described in https://webbluetoothcg.github.io/web-bluetooth/#dom-bluetoothremotegattcharacteristic-readvalue (Step 4.1) Add two missing steps to characteristic's WriteValue function. https://webbluetoothcg.github.io/web-bluetooth/#dom-bluetoothremotegattcharacteristic-writevalue (Step 4 and 5) --- <!-- 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, there are no Web Bluetooth test API implementation yet. <!-- 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="35" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/12261) <!-- Reviewable:end -->
| * | Missing steps of Characteristic's readValue, writeValue functionszakorgy2016-07-061-0/+3
| | |
* | | Make textinput handle actual key values. Don't restrict character values to ↵Josh Matthews2016-07-061-1/+1
| | | | | | | | | | | | a single byte.
* | | Associate logical and physical keypresses together to support non-QWERTY ↵Josh Matthews2016-07-051-1/+10
| |/ |/| | | | | keyboards.
* | Move WindowSizeData to script_traits.Ms2ger2016-07-051-2/+2
| |
* | Auto merge of #11872 - eddyb:back-to-roots, r=Ms2gerbors-servo2016-07-047-202/+201
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Replace return_address usage for rooting with stack guards and convenience macros. The existing `Rooted` and `RootedVec` users were migrated the the following two macros: ```rust let x = Rooted::new(cx, value); // Was changed to: rooted!(in(cx) let x = value); // Which expands to: let mut __root = Rooted::new_unrooted(value); let x = RootedGuard::new(cx, &mut __root); ``` ```rust let mut v = RootedVec::new(); v.extend(iterator); // Was changed to: rooted_vec!(let v <- iterator); // Which expands to: let mut __root = RootableVec::new(); let v = RootedVec::new(&mut __root, iterator); ``` The `rooted!` macro depends on servo/rust-mozjs#272. These APIs based on two types, a container to be rooted and a rooting guard, allow implementing both `Rooted`-style rooting and `Traceable`-based rooting in stable Rust, without abusing `return_address`. Such macros may have been tried before, but in 1.9 their hygiene is broken, they work only since 1.10. Sadly, `Rooted` is a FFI type and completely exposed, so I cannot prevent anyone from creating their own, although all fields but the value get overwritten by `RootedGuard::new` anyway. `RootableVec` OTOH is *guaranteed* to be empty when not rooted, which makes it harmless AFAICT. By fixing rust-lang/rust#34227, this PR enables Servo to build with `-Zorbit`. --- - [x] `./mach build -d` does not report any errors - [x] `./mach test-tidy` does not report any errors - [x] These changes fix rust-lang/rust#34227 - [x] These changes do not require tests because they are not functional changes <!-- 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/11872) <!-- Reviewable:end -->
| * | Use a stack guard and a macro for RootedVec instead of return_address.Eduard Burtescu2016-07-042-46/+42
| | |
| * | Switch to using the new rooted!/RootedGuard API for rooting.Eduard Burtescu2016-07-047-156/+159
| |/
* | Integration and improvements of File API backendsZhen Zhang2016-07-041-1/+2
| | | | | | | | | | | | 1. More complete origin check in FileManagerThreadMsg 2. Add reference counting logic to file manage store and script API 3. Integrate the support of slicing