aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/mediaquerylist.rs
Commit message (Collapse)AuthorAgeFilesLines
* Replace all uses of the `heapsize` crate with `malloc_size_of`.Nicholas Nethercote2017-10-181-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Servo currently uses `heapsize`, but Stylo/Gecko use `malloc_size_of`. `malloc_size_of` is better -- it handles various cases that `heapsize` does not -- so this patch changes Servo to use `malloc_size_of`. This patch makes the following changes to the `malloc_size_of` crate. - Adds `MallocSizeOf` trait implementations for numerous types, some built-in (e.g. `VecDeque`), some external and Servo-only (e.g. `string_cache`). - Makes `enclosing_size_of_op` optional, because vanilla jemalloc doesn't support that operation. - For `HashSet`/`HashMap`, falls back to a computed estimate when `enclosing_size_of_op` isn't available. - Adds an extern "C" `malloc_size_of` function that does the actual heap measurement; this is based on the same functions from the `heapsize` crate. This patch makes the following changes elsewhere. - Converts all the uses of `heapsize` to instead use `malloc_size_of`. - Disables the "heapsize"/"heap_size" feature for the external crates that provide it. - Removes the `HeapSizeOf` implementation from `hashglobe`. - Adds `ignore` annotations to a few `Rc`/`Arc`, because `malloc_size_of` doesn't derive those types, unlike `heapsize`.
* Fix commonmark Markdown warnings in docs, part 1Matt Brubeck2017-10-171-1/+1
| | | | | | | | Fixes warnings from rust-lang/rust#44229 when `--enable-commonmark` is passed to rustdoc. This is mostly a global find-and-replace for bare URIs on lines by themselves in doc comments.
* Remove use of unstable box syntax.Simon Sapin2017-10-161-1/+1
| | | | | | | | | | | | | | | | | | | | 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.
* Implement EventListenerOptions for EventTargetGuillaume Gomez2017-09-301-5/+12
| | | | For now, only "capture" is supported.
* Rename Root<T> to DomRoot<T>Anthony Ramine2017-09-261-2/+2
| | | | | | | 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.
* Rename DOMRefCell<T> to DomRefCell<T>Anthony Ramine2017-09-261-3/+3
| | | | | | | | 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.
* Rename JS<T> to Dom<T>Anthony Ramine2017-09-261-4/+4
|
* Rename dom::bindings::js to dom::bindings::rootAnthony Ramine2017-09-261-1/+1
|
* Use absolute paths in the event handlers macrosAnthony Ramine2017-09-011-1/+0
|
* style: Replicate the list of stylesheets on the layout thread.Emilio Cobos Álvarez2017-08-181-8/+3
| | | | | | This is a patch that unifies a bit how Gecko and Stylo stylesheets work, in order to be able to eventually move the stylesheets into the stylist, and be able to incrementally update the invalidation map.
* Rework MediaType to be an atom-based struct instead of an enum.Brad Werth2017-08-091-1/+1
| | | | MozReview-Commit-ID: 1Tfrs9PBkhA
* Fixed scaling artefacts in paint worklets caused by zoom and hidpi.Alan Jeffrey2017-07-201-1/+2
|
* Propagate quirks mode all the way to ParserContextAnthony Ramine2017-04-271-1/+1
| | | | The quirks mode is still not properly propagated in geckolib.
* Make #[dom_struct] a proc_macro attributeAnthony Ramine2017-02-241-0/+1
|
* Introduce CSSPixel as a replacement for ViewportPx and PagePx.Glenn Watson2017-02-241-8/+3
|
* Calling matchMedia during a MQL change event will not panicPrudhvi Rampey2017-02-181-6/+12
|
* Fix #14497: WeakMediaQueryListVec assumes its contents are still alivePavel Potocek2017-01-171-2/+2
|
* Spec conformancebd3392016-12-201-2/+11
| | | | Use MediaQueryListEvent instead of Event, in MediaQueryList.
* Mark JSTraceable and its method as unsafeAnthony Ramine2016-12-061-2/+3
|
* Rename media_queries::MediaQueryList to MediaListXidorn Quan2016-11-081-7/+4
|
* Prefer Servo-specific ToCss for all typesRavi Shankar2016-11-071-2/+1
|
* Remove unneeded #allow(unsafe_code)Stefan Schindler2016-11-051-2/+0
|
* Migrate `EventTarget` event firing functions to use `Atom`s.Corey Farwell2016-11-031-1/+1
| | | | This allows us to utilize more `atom` macros.
* Remove "fire a simple event" concept, refactor event firing API.Corey Farwell2016-11-031-1/+1
| | | | | "fire a simple event" concept was removed in https://github.com/whatwg/html/pull/1933.
* Implement matchMedia and MediaQueryListJack Moffitt2016-11-021-0/+156
Fixes #13376.