Simon Sapin
2012be4a8b
cargo fix --edition-idioms
2018-11-08 09:28:00 +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
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
0e3c54c191
Rename dom::bindings::js to dom::bindings::root
2017-09-26 02:19:05 +02:00
Anthony Ramine
6c9fb5ae7a
Introduce TaskOnce
...
Having both TaskBox and TaskOnce allows us to remove the superfluous inner boxing
from CancellableTask<T>.
2017-09-20 10:37:09 +02:00
Anthony Ramine
915a4f8385
Use task! for the details notification steps
2017-09-18 02:47:23 +02:00
Anthony Ramine
46628fba05
Move Task to its own module
2017-09-18 02:47:04 +02:00
Anthony Ramine
56117d3185
Rename Runnable to Task
...
The changes are:
* `*Runnable` -> `*Task`;
* `RunnableMsg` -> `Task`;
* `RunnableWrapper` -> `TaskCanceller`;
* `MainThreadRunnable` -> `MainThreadTask`;
* `wrap_runnable` -> `wrap_task`;
* `get_runnable_wrapper` -> `task_canceller`;
* `handler` -> `run`;
* `main_thread_handler` -> `run_with_script_thread`.
2017-09-16 15:43:26 +02:00
toidiu
99e4504f85
move name implementation as default implementation to the trait and remove overrides.
2017-09-03 16:30:48 -04:00
Christian Poveda
62821a6915
Solving merge conficts related to the html5ever_atoms -> html5ever change
2017-05-03 12:57:49 -05:00
Christian Poveda
875e422fe6
Changed all prefixes from DOMString to the atomic Prefix from html5ever
2017-05-03 10:17:42 -05: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
Corey Farwell
f447040ea9
Migrate EventTarget
event firing functions to use Atom
s.
...
This allows us to utilize more `atom` macros.
2016-11-03 17:04:30 -04:00
Corey Farwell
c3b279a4c3
Remove "fire a simple event" concept, refactor event firing API.
...
"fire a simple event" concept was removed in
https://github.com/whatwg/html/pull/1933 .
2016-11-03 15:01:07 -04:00
Simon Sapin
53b638c0e2
Update to string-cache 0.3
2016-11-03 16:23:05 +01:00
Anthony Ramine
44ca9f3d71
Make TaskSource::queue take a &GlobalScope
2016-10-06 21:35:52 +02:00
Arthur Marble
883902bd97
Most of the code refactoring needed to be done is done with this commit.
2016-09-18 03:41:16 -05:00
Josh Matthews
2aef518ce6
Make task queue API usable from non-main threads.
2016-07-14 13:27:41 -04:00
Kuba Birecki
85f4da18a6
Inline DOM element creation into box expressions in components/script/dom/
2016-07-14 08:44:22 +02:00
Connor Brewster
ad30275d04
Move boxing to runnable initialization
2016-07-13 11:10:23 -06:00
Connor Brewster
5f7324a9a5
Make all task source runnables cancellable
...
Implement all Runnable methods on CancellableRunnable to redirect to their inner runnable
2016-07-13 09:59:51 -06:00
Connor Brewster
afc0ccb48d
Add event runnables
...
Make tasks a wrapper over runnables
2016-07-11 22:21:45 -06:00
Changwan Hong
de8be94691
Add name method for Runnable trait into DetailsNotificationRunnable
2016-07-08 19:31:47 +09:00
Connor Brewster
d6f4dc06df
Combined DOMManipulationTask runnable variants into a single variant
2016-07-06 10:46:56 -06:00
Keith Yeung
05fc799f92
Clean up DOMManipulationTaskSource
2016-06-02 15:27:08 -04: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
Keith Yeung
ce302c78c1
Rename ToggleEventRunnable to DetailsNotificationRunnable
2016-05-04 21:01:26 -04:00
Keith Yeung
33acb1937c
Remove extraneous script_chan parameter from Trusted::new
2016-04-28 10:52:44 +02:00
Rahul Sharma
2caa9a2a76
refactors entities from script_thread into script_runtime
2016-04-06 12:46:49 +05:30
Keith Yeung
3f2cbf0025
Add task_source directory
...
Use DOMManipulationTaskSource whenever possible
2016-03-10 01:05:53 -05:00
Kamil Muszyński
076cc409e6
Issue #9561 Renamed *_thread_source to *_task_source and ThreadSource to TaskSource
2016-02-14 15:29:44 +01:00
Ms2ger
5317af1e19
Remove the global argument to EventTarget::{fire_event, fire_simple_event}.
2016-02-08 19:21:56 +01:00
Lanza
cfc3500dbf
Implement HTMLDetailsElement. Fixes #9216
2016-01-20 16:15:37 +01:00