aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/worker.rs
Commit message (Collapse)AuthorAgeFilesLines
...
* Remove extraneous script_chan parameter from Trusted::newKeith Yeung2016-04-281-2/+2
|
* Modify Worker constructor to use the document's base URL.Bridget McErlean2016-04-251-1/+1
|
* Implement Worker#terminate() (fixes #4427).Joe Wilm2016-04-071-9/+69
| | | | | Adds support for terminating DOM workers. A closing flag was added to WorkerGlobalScope per the spec.
* refactors entities from script_thread into script_runtimeRahul Sharma2016-04-061-1/+2
|
* Add task_source directoryKeith Yeung2016-03-101-5/+5
| | | | Use DOMManipulationTaskSource whenever possible
* Issue #9561 continued - renamed *_thread_source to *_task_source in ↵Kamil Muszyński2016-02-171-3/+3
| | | | global.rs and related files
* Remove the global argument to EventTarget::{fire_event, fire_simple_event}.Ms2ger2016-02-081-2/+1
|
* Add global default method for Reflectable traitChad Kimes2016-01-111-5/+5
|
* Remove global field from WorkerChad Kimes2016-01-101-10/+7
|
* task -> threadrohan.prinja2016-01-101-6/+6
|
* Implement EventTarget::fire_simple_event and ↵Arthur Skobara2015-12-221-5/+1
| | | | EventTarget::fire_simple_event_params
* Use Url.join instead of UrlParser.base_url(...).parse (#9002)Mathieu Agopian2015-12-181-2/+1
|
* Remove from Trusted::new an unnecessary argumentArthur Skobara2015-12-121-2/+2
|
* Pass around event types as Atoms instead of StringsCorey Farwell2015-12-101-2/+2
| | | | | | `Event` internally stores the `type` as an `Atom`, and we're `String`s everywhere, which can cause unnecessary allocations to occur since they'll end up as `Atom`s anyways.
* Split fn script_chan into 5 different task channel fnKeith Yeung2015-12-061-3/+3
|
* Replaced DOMString constructor by conversion functions.Alan Jeffrey2015-11-121-3/+2
| | | | | | Replaced DOMString(...) by DOMString::from(...). Replaced ....0 by String::from(...). Removed any uses of .to_owner() in DOMString::from("...").
* Replaced DOMString by String in devtools.Alan Jeffrey2015-11-121-1/+1
|
* Make DOMString a newtype around String, rather than a typedef.Ms2ger2015-11-041-3/+3
| | | | | | | | | | This should make it somewhat easier to experiment with alternative representations in the future. To reduce churn, this commit leaves the String field public, though. Also, this will allow us to use the default String type to represent the IDL USVString type, which explicitly forbids unpaired surrogates, ans as such is a better match to the Rust String type.
* rearrange imports to be in alphabetical orderrohan.prinja2015-10-301-3/+2
|
* more refactoringrohan.prinja2015-10-301-1/+2
|
* move Castable into dom::bindings::inheritancerohan.prinja2015-10-301-1/+1
|
* Timers are scheduled by a dedicated per-constellation thread.benshu2015-10-211-0/+2
|
* Clean up the cast callsAnthony Ramine2015-10-211-7/+3
|
* Introduce trait CastableAnthony Ramine2015-10-211-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This trait is used to hold onto the downcast and upcast functions of all castable IDL interfaces. A castable IDL interface is one which either derives from or is derived by other interfaces. The deriving relation is represented by implementations of marker trait DerivedFrom<T: Castable> generated in InheritTypes. /^[ ]*use dom::bindings::codegen::InheritTypes::.*(Base|Cast|Derived)/ { /::[a-zA-Z]+(Base|Cast|Derived);/d s/([{ ])[a-zA-Z]+(Base|Cast|Derived), /\1/g s/([{ ])[a-zA-Z]+(Base|Cast|Derived), /\1/g s/, [a-zA-Z]+(Base|Cast|Derived)([},])/\2/g s/, [a-zA-Z]+(Base|Cast|Derived)([},])/\2/g /\{([a-zA-Z]+(Base|Cast|Derived))?\};$/d s/\{([a-zA-Z_]+)\};$/\1;/ } s/([a-zA-Z]+)Cast::from_ref\(\&?\**([a-zA-Z_]+)(\.r\(\))?\)/\2.upcast::<\1>()/g s/([a-zA-Z]+)Cast::from_ref\(\&?\**([a-zA-Z_]+)(\.[a-zA-Z_]+\(\))?\)/\2\3.upcast::<\1>()/g s/\(([a-zA-Z]+)Cast::from_ref\)/\(Castable::upcast::<\1>\)/g s/([a-zA-Z]+)Cast::from_root/Root::upcast::<\1>/g s/([a-zA-Z]+)Cast::from_layout_js\(\&([a-zA-Z_.]+)\)/\2.upcast::<\1>()/g s/([a-zA-Z]+)Cast::to_ref\(\&?\**([a-zA-Z_]+)(\.r\(\))?\)/\2.downcast::<\1>()/g s/([a-zA-Z]+)Cast::to_ref\(\&?\**([a-zA-Z_]+)(\.[a-zA-Z_]+\(\))?\)/\2\3.downcast::<\1>()/g s/\(([a-zA-Z]+)Cast::to_ref\)/\(Castable::downcast::<\1>\)/g s/([a-zA-Z]+)Cast::to_root/Root::downcast::<\1>/g s/([a-zA-Z]+)Cast::to_layout_js\(&?([a-zA-Z_.]+(\(\))?)\)/\2.downcast::<\1>()/g s/\.is_document\(\)/.is::<Document>()/g s/\.is_htmlanchorelement\(\)/.is::<HTMLAnchorElement>()/g s/\.is_htmlappletelement\(\)/.is::<HTMLAppletElement>()/g s/\.is_htmlareaelement\(\)/.is::<HTMLAreaElement>()/g s/\.is_htmlbodyelement\(\)/.is::<HTMLBodyElement>()/g s/\.is_htmlembedelement\(\)/.is::<HTMLEmbedElement>()/g s/\.is_htmlfieldsetelement\(\)/.is::<HTMLFieldSetElement>()/g s/\.is_htmlformelement\(\)/.is::<HTMLFormElement>()/g s/\.is_htmlframesetelement\(\)/.is::<HTMLFrameSetElement>()/g s/\.is_htmlhtmlelement\(\)/.is::<HTMLHtmlElement>()/g s/\.is_htmlimageelement\(\)/.is::<HTMLImageElement>()/g s/\.is_htmllegendelement\(\)/.is::<HTMLLegendElement>()/g s/\.is_htmloptgroupelement\(\)/.is::<HTMLOptGroupElement>()/g s/\.is_htmloptionelement\(\)/.is::<HTMLOptionElement>()/g s/\.is_htmlscriptelement\(\)/.is::<HTMLScriptElement>()/g s/\.is_htmltabledatacellelement\(\)/.is::<HTMLTableDataCellElement>()/g s/\.is_htmltableheadercellelement\(\)/.is::<HTMLTableHeaderCellElement>()/g s/\.is_htmltablerowelement\(\)/.is::<HTMLTableRowElement>()/g s/\.is_htmltablesectionelement\(\)/.is::<HTMLTableSectionElement>()/g s/\.is_htmltitleelement\(\)/.is::<HTMLTitleElement>()/g
* Explicitly place '/' before fragment for multipage spec linksCorey Farwell2015-10-101-1/+1
| | | | | This prevents us from 301 redirecting, which could cause the fragment to get lost
* Replace usage of old-style WHATWG spec linksCorey Farwell2015-10-101-1/+1
|
* Refactor Error enum usage to consistently be qualifiedAnthony Urena2015-10-061-3/+2
|
* sorted the extern crate, mod & use declarationsRavi Shankar2015-09-241-6/+6
|
* Fix reported test-tidy errors for unmerged import blocksBrandon Fairchild2015-09-191-7/+4
| | | | This merges import blocks that were reported by tidy as unmerged.
* Move EventTargetTypeId/NodeTypeId to DOMClassMichael Wu2015-09-121-2/+2
|
* Enforce linking to spec for method implementations via macrosCorey Farwell2015-08-311-0/+3
|
* Implemented onerror event handler for AbstractWorkererneyja2015-08-301-0/+1
|
* Time distribution across script event categories.benshu2015-08-281-6/+6
|
* Make the traits for the IDL interfaces take &selfAnthony Ramine2015-08-271-2/+2
|
* Remove helper traitsAnthony Ramine2015-08-271-3/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now that JSRef<T> is gone, there is no need to have helper traits. On components/script/*.rs: # Remove imports. /^ *use dom::[a-z]+::\{.*Helpers/ { s/\{(Raw[^L]|[^L][^a])[a-zA-Z]+Helpers, /\{/ s/, (Raw[^L]|[^L][^a])[a-zA-Z]+Helpers([,}])/\2/g s/\{([a-zA-Z]+)\}/\1/ /\{\}/d s/::self;$/;/ } /^ *use dom::[a-z]+::\{?(Raw[^L]|[^L][^a])[a-zA-Z]+Helpers\}?;$/d On components/script/dom/*.rs: # Ignore layout things. /^(pub )?(impl|trait).*Layout.* \{/,/^}$/ { P; D; } # Delete helpers traits. /^(pub )?trait ([^L][^ ]|L[^a])[^ ]+Helpers(<'a>)? \{$/,/^\}$/D # Patch private helpers. /^impl.*Private.*Helpers/,/^\}$/ { s/^impl<'a> Private([^L][^ ]|L[^a])[^ ]+Helpers(<'a>)? for &'a ([^ ]+) \{$/impl \3 {/ /^ *(unsafe )?fn .*\(self.*[<&]'a/ { s/&'a /\&/g s/<'a, /</g } /^ *(unsafe )?fn /s/\(self([,)])/\(\&self\1/ } # Patch public helpers. /^impl.*Helpers/,/^\}$/ { s/^impl(<'a>)? ([^L][^ ]|L[^a])[^ ]+Helpers(<'a>)? for (&'a )?([^ ]+) \{$/impl \5 {/ /^ *(unsafe )?fn .*\(self.*[<&]'a/ { s/&'a /\&/g s/<'a, /</g } /^ *(unsafe )?fn .*\(&?self[,)]/s/(unsafe )?fn/pub &/ /^ *pub (unsafe )?fn /s/\(self([,)])/\(\&self\1/ } The few error cases were then fixed by hand.
* make dom_struct derive HeapSizeOf,João Oliveira2015-08-271-1/+0
| | | | closes #7357
* Auto merge of #7238 - Wafflespeanut:workerglobal, r=Ms2gerbors-servo2015-08-201-2/+2
|\ | | | | | | | | | | | | | | | | | | Improved field names for devtools-related channels... (for #6924) - I took this because the confusion was actually caused by me while working on #6829 <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/7238) <!-- Reviewable:end -->
| * Improved field names for devtools-related channels; r=Ms2gerRavi Shankar2015-08-201-2/+2
| |
* | sort all usesJohann Tuffe2015-08-201-5/+5
|/
* Splitting ScriptMsg into various enums; r=jdmRavi Shankar2015-08-151-8/+11
|
* Measure heap memory usage for more types. Fixes #6951Bogdan Cuza2015-08-131-0/+2
|
* Pass WorkerGlobalScopeInit to DedicatedWorkerGlobalScope::run_worker_scope.Ms2ger2015-08-031-3/+11
|
* Take WorkerGlobalScope's worker_id out of its Option.Ms2ger2015-08-031-1/+1
| | | | | Unsurprisingly, every worker has an id, so there is no need to wrap it in an Option.
* Fixes issue #6866Harrison G2015-08-021-2/+2
|
* Persuading devtools to communicate with the workers; r=jdmRavi Shankar2015-08-011-14/+19
|
* Add spec linksBogdan Cuza2015-07-281-0/+1
|
* devtools: Convert the developer tools to run over IPC.Patrick Walton2015-07-271-5/+6
|
* script: Make most of 2D canvas and WebGL run over IPC.Patrick Walton2015-07-251-1/+2
| | | | | | To actually make the multiprocess communication work, we'll need to reroute the task creation to the pipeline or the compositor. But this works as a first step.
* Wire up the JS engine's memory reporting.Nicholas Nethercote2015-07-151-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | SpiderMonkey provides an extremely fine-grained breakdown of memory usage, but for Servo we aggregate the measurements into a small number of coarse buckets, which seems appropriate for the current level of detail provided by Servo's memory profiler. Sample output: ``` | 10.99 MiB -- pages | 7.75 MiB -- url(http://html5demos.com/worker) | 4.63 MiB -- js | 2.00 MiB -- gc-heap | 0.94 MiB -- decommitted | 0.92 MiB -- used | 0.09 MiB -- unused | 0.05 MiB -- admin | 1.44 MiB -- malloc-heap | 1.19 MiB -- non-heap | [...] | 3.24 MiB -- url(http://html5demos.com/js/worker-cruncher.js) | 3.24 MiB -- js | 1.17 MiB -- malloc-heap | 1.06 MiB -- non-heap | 1.00 MiB -- gc-heap | 0.69 MiB -- used | 0.19 MiB -- decommitted | 0.09 MiB -- unused | 0.03 MiB -- admin ``` Most of the changes are plumbing to get the script and worker tasks communicating with the memory profiler task.
* Upgrade to SM 39Michael Wu2015-06-191-22/+25
|