aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/node.rs
Commit message (Collapse)AuthorAgeFilesLines
* Formatting.Josh Matthews2023-05-281-1/+5
|
* Support arbitrary protos when wrapping DOM objects with constructors.Josh Matthews2023-05-281-2/+11
|
* Throw HierarchyRequest error for Attr in pre-insert and replacechildcybai2023-04-211-5/+7
|
* Add support for <iframe> elements for Layout 2020Martin Robinson2023-04-041-8/+4
| | | | | | This change adds support for the <iframe> element to Layout 2020. In addition, certain aspects of the implementation are made the same between both layout systems.
* apply pylbrecht/servo/named.window.getter (closes #27952)Delan Azabani2023-03-231-29/+0
|
* Update nightly rustc.Josh Matthews2021-11-011-2/+2
|
* Replaced ref_slice::ref_slice with std::slice::from_refAdrian Willenbücher2021-06-101-5/+5
| | | | | | | ref_slice::ref_slice is deprecated in ref_slice-1.2.1, because it's redundant with std since rust 1.28. Signed-off-by: Adrian Willenbücher <willenbuecher@xq-tec.com>
* fmtteymour-aldridge2021-02-051-4/+2
|
* Remove unused arguments from methods.teymour-aldridge2021-02-051-2/+1
|
* Implement ParentNode#replaceChildrenVincent Ricard2020-09-251-0/+12
|
* Do not panic on navigating across documentsUtsav Oza2020-07-301-3/+3
|
* Cancel animations for nodes which are removed from the DOMMartin Robinson2020-06-171-0/+7
| | | | This includes nodes which are being reparented.
* Implement concept of dirty rootAnthony Ramine2020-05-191-12/+40
|
* Make Node::style_and_layout_data be a DomRefCell<T>Anthony Ramine2020-05-191-21/+25
| | | | That way we can use borrow_mut_for_layout and borrow_mut.
* Correctly paint the CSS canvas’ backgroundSimon Sapin2020-05-151-0/+6
| | | | | | | https://drafts.csswg.org/css-backgrounds/#special-backgrounds Fixes https://github.com/servo/servo/issues/25559 Closes https://github.com/servo/servo/pull/26121, as it is an alternative.
* Add a fast path in Element::SetInnerHTML when the value is small and trivial ↵Bastien Orivel2020-05-041-0/+14
| | | | | | | | | text Inspired from gecko which has a similar fast path. This makes innerHTML more than 10 times faster for this case. Fixes #25892
* Don't go through the layout thread to retrieve a node's primary styleAnthony Ramine2020-04-071-0/+19
|
* Replace OpaqueStyleAndLayoutData by StyleAndOpaqueLayoutDataAnthony Ramine2020-04-061-10/+10
|
* Rename a bunch of style/layout data itemsAnthony Ramine2020-04-061-6/+6
| | | | | | | | | | | | | GetLayoutData::get_style_and_layout_data becomes GetOpaqueStyleAndLayoutData::get_opaque_style_and_layout_data. GetRawData::get_raw_data becomes GetStyleAndLayoutData::get_style_and_layout_data. LayoutNode::init_style_and_layout_data becomes LayoutNode::init_opaque_style_and_layout_data. LayoutNode::take_style_and_layout_data becomes LayoutNode::take_opaque_style_and_layout_data.
* Make DOM own the style and layout data, in an UnsafeCellAnthony Ramine2020-04-041-52/+13
| | | | The previous Cell was a lie.
* Add some comments and remove obsolete allow attributesAnthony Ramine2020-04-011-3/+7
|
* Introduce more layout helpers to make selection_for_layout be safeAnthony Ramine2020-04-011-3/+2
|
* Introduce <LayoutDom<HTMLImageElement>>::current_requestAnthony Ramine2020-04-011-11/+7
| | | | | This safe helper contains the only source of unsafety from the actual image layout helpers methods, making them completely safe.
* Make LayoutNodeHelpers::composed_parent_node_ref be safeAnthony Ramine2020-04-011-5/+12
| | | | | | For clarity, I introduce <LayoutDom<Element>>::parent_node_ref to contain the remaining unsafety bits out of composed_parent_node_ref which is more complex than just a field access.
* Make a bunch of LayoutNodeHelpers be safeAnthony Ramine2020-03-311-24/+21
|
* Introduce LayoutDom::isAnthony Ramine2020-03-311-4/+3
| | | | Just like Castable::is.
* Make layout methods accessing rare data be safeAnthony Ramine2020-03-311-9/+11
| | | | | | They don't do anything fancy so there is no additional unsafety calling them compared to using LayoutDom in the first place, the usual story of all those changes.
* Don't generate rare_data_for_layout methods anymoreAnthony Ramine2020-03-311-2/+3
| | | | It is only used twice.
* Make LayoutNodeHelpers::text_content return a cowAnthony Ramine2020-03-311-6/+6
|
* Make LayoutCharacterDataHelpers::data_for_layout be safeAnthony Ramine2020-03-311-2/+1
|
* Make LayoutHTMLTextAreaElementHelpers::value_for_layout safeAnthony Ramine2020-03-311-1/+1
|
* Make LayoutHTMLInputElementHelpers::value_for_layout return a cowAnthony Ramine2020-03-311-1/+1
|
* Make LayoutNodeHelpers methods take selfAnthony Ramine2020-03-291-58/+58
|
* Give a lifetime parameter to LayoutDomAnthony Ramine2020-03-281-16/+16
|
* Add trait DomObjectWrap to provide WRAP functionYUAN LYU2020-03-201-10/+4
|
* Auto merge of #25499 - NeverHappened:implement-form-dirname, r=jdmbors-servo2020-02-241-0/+20
|\ | | | | | | | | | | | | | | | | | | | | | | Implement dirname support for form element Added support for dirname in input on form submit Added Dir getter / setter for HTMLElement NOT YET Added get directionality according to https://html.spec.whatwg.org/multipage/dom.html#the-directionality - [X] `./mach build -d` does not report any errors - [x] `./mach test-tidy` does not report any errors - [x] These changes fix #25379 (GitHub issue number if applicable)
| * Simplify code for directionalityDmitry Kolupaev2020-02-251-6/+4
| |
| * Remove recursiveness from directionality searchDmitry Kolupaev2020-02-251-9/+18
| |
| * Simplify node#parent_directionalityDmitry Kolupaev2020-02-251-8/+2
| |
| * Rearrange directionality algorithm functionsDmitry Kolupaev2020-02-251-0/+19
| |
* | Avoid accessing node global during Node's destructor.Josh Matthews2020-02-241-12/+22
|/
* Auto merge of #25548 - pshaughn:docnamedgetter, r=jdmbors-servo2020-02-131-0/+29
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add SupportedPropertyNames to Document (also fix iframe getting) Existing test of named-getting an iframe now succeeds. I added a new test for Object.getOwnPropertyNames(document) based on my understanding of the spec; that test could use a second opinion. UPDATE: This was trying to do too many things in one PR as originally submitted. It is now using #25572 as a base, and I suggest reviewing that PR before this one to avoid duplicating review effort. --- <!-- 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 #7273 for all implemented named getters, fix #25146, and fix the iframe case only of #25145. <!-- 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. -->
| * Doc named getter improvementsPatrick Shaughnessy2020-02-131-0/+29
| |
* | Event dispatch rewritten to resemble spec more often, activate on clicks betterPatrick Shaughnessy2020-02-121-0/+42
|/
* Remove outdated comment about #4105Patrick Shaughnessy2020-02-051-3/+2
|
* Add accountable-refcell as optional build time featureKunal Mohan2020-01-081-2/+2
|
* Auto merge of #25310 - pshaughn:attr_node, r=Manishearthbors-servo2020-01-071-56/+203
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Attr is a Node, with consequences for many Node methods <!-- Please describe your changes on the following line: --> Attr is now a Node, as current WHATWG specs require. I think I did some unidiomatic things to make compareDocumentPosition work and it could use a look by someone more familiar with how to write concise Rust code. I also think the new cases in compareDocumentPosition lack tests; it is possible to compare the position of two attributes, or of an attribute and an element, and I don't think any tests are exercising that functionality. --- <!-- 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 #25124 <!-- Either: --> - [ ] There are tests for these changes (existing cases of Node methods are well-tested, and there is a WPT test specifically for whether Attr is Node, but I'm not sure about new Node method cases) <!-- 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. -->
| * Attr is a Node, with consequences for many Node methodsPatrick Shaughnessy2019-12-231-56/+203
| |
* | Now passing output tests as well as anyonePatrick Shaughnessy2020-01-061-0/+15
|/
* adding .isConnected DOM attributePatrick Shaughnessy2019-12-111-0/+5
|