Emilio Cobos Álvarez
31e8e418ea
Miscellaneous build / tidy fixes.
2021-02-26 17:53:55 +01:00
Anthony Ramine
fb1ff3f097
Remove an obsolete comment
2020-03-31 15:23:06 +02:00
Anthony Ramine
3e875ce3eb
Introduce AttrHelpersForLayout::namespace
2020-03-31 14:06:22 +02:00
Anthony Ramine
47c9f19121
Don't clone the result of AttrHelpersForLayout::local_name
...
There is no need to do that. Embrace returning borrows from the DOM, it good.
2020-03-31 14:02:14 +02:00
Anthony Ramine
4db84bede8
Rename AttrHelpersForLayout methods
2020-03-31 13:58:50 +02:00
Anthony Ramine
4c16729a01
Make AttrHelpersForLayout methods be safe
...
The unsafety isn't there, it's in the creation of the LayoutDom<T> values.
2020-03-31 13:54:52 +02:00
Anthony Ramine
02fb5a68e6
Remove a bunch of _forever suffixes in Attr methods
...
They don't return &'static references anymore.
2020-03-30 13:09:03 +02:00
Anthony Ramine
05c71dff88
Fix AttrHelpersForLayout
...
We should never be returning 'static stuff from attrs, that's a big lie.
2020-03-30 13:07:27 +02:00
Anthony Ramine
dba6a635e5
Give a lifetime parameter to LayoutDom
2020-03-28 15:37:57 +01:00
YUAN LYU
3ea6d87bcc
Add trait DomObjectWrap to provide WRAP function
2020-03-20 22:16:56 -04:00
Kunal Mohan
02c1612cb0
Add accountable-refcell as optional build time feature
2020-01-08 09:44:41 +05:30
Patrick Shaughnessy
67e9fc8c0a
Attr is a Node, with consequences for many Node methods
2019-12-23 19:10:16 -05:00
Simon Sapin
c38c964f1b
Upgrade to rustc 1.38.0-nightly (dddb7fca0 2019-07-30)
2019-07-31 13:34:01 +02:00
est31
8b6ed3d182
Remove unused code from script* crates
2019-06-02 07:12:26 +02:00
Anthony Ramine
5fe5e5d6de
Remove most RootedReference uses
...
We can replace all uses of RootedReference for Option<T> by Option::deref calls.
2019-03-10 17:51:35 +01:00
Jan Andre Ikenmeyer
a1a14459c1
Update MPL license to https (part 3)
2018-11-19 14:47:12 +01:00
Pyfisch
9e92eb205a
Reorder imports
2018-11-06 22:35:07 +01:00
Simon Sapin
76e59a46d3
Sort use
statements
2018-11-06 15:26:02 +01:00
Simon Sapin
45f7199eee
cargo fix --edition
2018-11-06 15:26:02 +01:00
chansuke
c37a345dc9
Format script component
2018-09-19 17:40:47 -04:00
Fabrice Desré
75434e6fce
MutationObserver api: Implement takeRecords() and characterData mutations
2018-05-02 09:58:37 -07:00
CYBAI
34babb6dcf
Use specific assertion for DOM attr
2018-01-26 01:18:54 +08:00
Simon Sapin
aa15dc269f
Remove use of unstable box syntax.
...
http://www.robohornet.org gives a score of 101.36 on master,
and 102.68 with this PR. The latter is slightly better,
but probably within noise level.
So it looks like this PR does not affect DOM performance.
This is expected since `Box::new` is defined as:
```rust
impl<T> Box<T> {
#[inline(always)]
pub fn new(x: T) -> Box<T> {
box x
}
}
```
With inlining, it should compile to the same as box syntax.
2017-10-16 17:16:20 +02:00
Anthony Ramine
f87c2a8d76
Rename Root<T> to DomRoot<T>
...
In a later PR, DomRoot<T> will become a type alias of Root<Dom<T>>,
where Root<T> will be able to handle all the things that need to be
rooted that have a stable traceable address that doesn't move for the
whole lifetime of the root. Stay tuned.
2017-09-26 09:49:10 +02:00
Anthony Ramine
577370746e
Rename DOMRefCell<T> to DomRefCell<T>
...
I don't want to do such a gratuitous rename, but with all the other types
now having "Dom" as part of their name, and especially with "DomOnceCell",
I feel like the other cell type that we already have should also follow
the convention. That argument loses weight though when we realise there
is still DOMString and other things.
2017-09-26 09:49:08 +02:00
Anthony Ramine
e2dac78d36
Rename LayoutJS<T> to LayoutDom<T>
2017-09-26 09:49:04 +02:00
Anthony Ramine
c52fd0a780
Rename MutNullableJS<T> to MutNullableDom<T>
2017-09-26 09:49:02 +02:00
Anthony Ramine
0e3c54c191
Rename dom::bindings::js to dom::bindings::root
2017-09-26 02:19:05 +02:00
Connor Brewster
e700006fb2
Handle exceptions during upgrades
2017-08-09 14:36:20 -06:00
Connor Brewster
4665991503
Support custom element callback reactions
2017-07-17 22:23:45 -06:00
Sumit
3ca89204ff
Mutation Observer API
2017-05-15 18:15:38 -04:00
Simon Sapin
6c518c89b9
Upgrade to html5ever 0.16
2017-05-02 19:24:28 +02:00
Anthony Ramine
31e9d81c0f
Make #[dom_struct] a proc_macro attribute
2017-02-24 01:50:51 +01:00
Emilio Cobos Álvarez
d37e6f8c66
script: Propagate the attribute into the document's element_attr_will_change method.
2017-01-30 19:24:42 +01:00
Anthony Ramine
1327ebd52f
Remove HeapGCValue
...
It could be used to have mutable JSVal fields without GC barriers.
With the removal of that trait, MutHeap and MutNullableHeap can respectively
be replaced by MutJS and MutNullableJS.
2016-12-12 10:47:54 -10:00
Anthony Ramine
fb206e2b10
Make Attr::prefix return an Option<&Prefix>
2016-12-01 11:55:13 +01:00
Simon Sapin
53b638c0e2
Update to string-cache 0.3
2016-11-03 16:23:05 +01:00
Anthony Ramine
0b3ab875f4
Remove intrinsic Root::r()
2016-10-11 19:44:32 +02:00
Anthony Ramine
fcb59d3057
Make reflect_dom_object take a &GlobalScope
2016-10-06 20:59:09 +02:00
Simon Sapin
fbde392c3d
Revert "Make DOMRefCell use style’s copy of RefCell"
...
This reverts commit ec723057b2
.
2016-10-04 18:35:01 +02:00
Simon Sapin
ec723057b2
Make DOMRefCell use style’s copy of RefCell
2016-08-31 02:34:04 +02:00
Ms2ger
684510bc94
Stop re-exporting AttrValue.
2016-06-07 13:15:23 +02:00
David Raifaizen
8b39260793
Removed mutation calls from sync_property_with_attrs_style method in order to avoid reparsing serialized output
2016-05-25 09:25:37 +02:00
Anthony Ramine
cdc7bca944
Move DOMString back to script
...
This entirely removes the 'non-geckolib' feature of the util crate.
2016-05-24 10:54:57 +02:00
David Zbarsky
8cbcdfb761
Implement nodeName on Attr
2016-04-03 10:27:41 -07:00
Mathieu Hordesseaux
322b120f8a
Implement SetNamedItem, SetNamedItemNS, SetAttributeNode and SetAttributeNodeNS
2016-01-28 12:35:44 +01:00
Johannes Linke
6b215f38ee
Fix a bunch of clippy lints
2016-01-02 23:27:15 +01:00
Alan Jeffrey
3dec6edd10
Update string_cache to 0.2.
...
Updated string_cache, html5ever, xml5ever and selectors in Cargo.toml files and Cargo.lock.
Removed references to string_cache_plugin.
Import atom! and ns! from string_cache.
Replaced ns!("") by ns!().
Replaced ns!(XML) and co by ns!(xml) and co.
Replaced atom!(foo) by atom!("foo").
Replaced Atom::from_slice by Atom::from.
Replaced atom.as_slice() by &*atom.
2015-11-25 10:13:21 -06:00
Ms2ger
0c61be7a57
Rustfmt some of script.
2015-11-18 11:14:05 +01:00
Alan Jeffrey
84bde75b42
Replaced DOMString constructor by conversion functions.
...
Replaced DOMString(...) by DOMString::from(...).
Replaced ....0 by String::from(...).
Removed any uses of .to_owner() in DOMString::from("...").
2015-11-12 17:52:59 -06:00