Updated string_cache to 0.2, and updated the dependencies that depend on string_cache.
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::from_slice by Atom::from.
Replaced atom.as_slice() by &*atom.
r? @SimonSapin
Source-Repo: https://github.com/servo/servo
Source-Revision: 188fa9378c103093f1f8dac24bff0d9d237fd2bc
This patch makes DOMString an opaque wrapper round String (currently it's a transparent wrapper).
The changes are:
* Replacing DOMString(foo) by DOMString::from(foo).
* Replacing foo.0 by String::from(foo).
* Adding functions clear, push_str and extend for in-place mutation of DOMStrings.
* Replacing DOMString by String in other threads (devtools, storage and filereader).
* Making DOMString implement !Send.
* Removing the pub attribute from the contents of DOMString.
This enables experimenting with other string representations in the DOM.
Source-Repo: https://github.com/servo/servo
Source-Revision: 62acdd303b78951885c2c90747b31f318907d6c9
This change should prevent page scrolling when up/down buttons are pressed within text inputs and textboxes which should resolve issue #8379.
Source-Repo: https://github.com/servo/servo
Source-Revision: f1565bdd82bdf9a7fc383d20fdb53d07adec55c1
This resolves#8107
Previously the index of the insetion point for a password input was
calculated using the scrambled string based on the edit point in the
raw string. That could lead to a wrong position of the caret. This
commit changes this behavior to calculate the insertion point using
the raw string.
Source-Repo: https://github.com/servo/servo
Source-Revision: e91169c0e2cfe37b1a2d0feb3aab50b72c816ffc
Removes all those messy FooCast structures in InheritTypes.rs.
Source-Repo: https://github.com/servo/servo
Source-Revision: 674589c370d978f543e71f995d58c5b28e6e9842
We can only borrow `JS<T>` from rooted things, so it's safe to deref it.
The only types that provide mutable `JS<T>` things are `MutHeap<JS<T>>` and
`MutNullableHeap<JS<T>>`, which don't actually expose that they contain
`JS<T>` values.
Source-Repo: https://github.com/servo/servo
Source-Revision: 1a376aa75d5de8781b17a673850860f8afd2c28f
Just getting my feet wet with Rust here. Please feel free to nit the hell out of it stylistically and idiomatically. :-)
Source-Repo: https://github.com/servo/servo
Source-Revision: ff2151b8bbc62fa29c90a429b7a4f12520420b6e
`JS<T>` belongs on the heap, and only on the heap. This is a collection of fixes so that code uses either `Root<T>` or `&T` to pass around garbage-collected pointers.
Ideally, we could completely ban constructing a `JS<T>` outside of constructor functions, but we aren't quite there yet.
Source-Repo: https://github.com/servo/servo
Source-Revision: 7c7dbde0f4372037aac3635b8d81531ca9cdced3
This frees us forever from caring about maintaining these enums. The last commit removes their use from the initialisation of interface objects derived from Node.
Source-Repo: https://github.com/servo/servo
Source-Revision: 32daa17d5cbcad02db0713e21e52410cdc60480e
Factor out FormDatum collection for `<input>`
Improve early return logic for getting the FormDatum from an `<input>`
Condense element type patterns
Proposed to close#7851
Source-Repo: https://github.com/servo/servo
Source-Revision: 94dc98717b79c12cdac6b1eba72227199850ac31
get_size method appeared to be never used so I removed it.
Source-Repo: https://github.com/servo/servo
Source-Revision: 9a12c2c06199bc0a11982949b0cb43ee8500c001
The trait is now implemented for HTMLFooElement instead of
&HTMLFooElement and does no longer require an impl body.
Suggested by @Manishearth
Source-Repo: https://github.com/servo/servo
Source-Revision: 94e85a5226fe5b18bde40a2d5f6727b717bd148f
Radio button groups with missing or empty names are always the only element of their respective radio button group.
Source-Repo: https://github.com/servo/servo
Source-Revision: 37ce248f316ba3cb5a2cfb0b4bb95918c1c45828
This is a direct extract from my abandoned PR for a lint (#7546), along with some rather clumsy modifications (only on `components/script/dom/mod.rs` and `components/style/lib.rs`), because I had to sort some of the files again to make peace with tidy, which hasn't been educated about sorting yet!
Source-Repo: https://github.com/servo/servo
Source-Revision: a7208869f2903e36f9b2f540b55b50283d7df466
Known issues:
* The caret doesn't show up if there's no text present, because we don't create text runs in that case. This should be a followup.
* Text runs don't support decomposing ligatures into their constituent subglyphs for advance computation, so the caret won't appear inside a ligature. This is a text run bug.
r? @mbrubeck
Source-Repo: https://github.com/servo/servo
Source-Revision: 6cd098da302db85975d0967ddee836f04eae3bd5
Elided almost all the lifetimes and removed needless returns. Mostly done by sed + manual fixes.
r? @nox
Source-Repo: https://github.com/servo/servo
Source-Revision: c2c2646d37614ece5869af861993c3d619f6e003
Now that `JSRef<T>` is gone, there is no need to have helper traits.
Source-Repo: https://github.com/servo/servo
Source-Revision: 909429702972d53bf02dfe9a4aa93ea0cb588cf4
Also adds HeapSizeOf implementations/derive for some types. I've used "Cannot calculate Heap size" as a reason everywhere, because my imagination is rather limited. If you'd like me to change this message for specific types, please write something like this: "Trusted - Cannot calculate Heap size for Trusted" so that it would be easier for me to replace them through a script :)
Source-Repo: https://github.com/servo/servo
Source-Revision: a03616f379c255cc6c9b6e1d04dd7d98bd9926ce