Commit graph

73 commits

Author SHA1 Message Date
Ms2ger
971a4c58bb Pass Option<JSVal> for optional JSVals. 2014-03-07 12:40:25 +01:00
Ms2ger
6291aac170 Pass &JS<Window> to some constructors. 2014-03-04 14:10:33 +01:00
Ms2ger
b6138580d3 Stop passing the scope argument to global object bindings' Wrap functions. 2014-03-04 13:24:16 +01:00
Josh Matthews
fa542e5de7 De-@mut the script crate. 2014-02-28 13:42:03 -05:00
lpy
8fc5ba5dc6 Add url getter to Page and fix users of Page url with it.(fixes #1762) 2014-02-28 14:13:08 +08:00
Josh Matthews
625325434b Implement JSManaged for DOM objects. 2014-02-24 15:16:42 -05:00
Ms2ger
59184bf6e1 Move DOMString into servo_util. 2014-02-14 12:48:51 +01:00
Austin King
b1b481f3f3 Adding most commonly used parts of window.console. Fixes Issue#506. r=Ms2ger 2014-02-11 09:55:29 -08:00
zmike
193b6d2635 add names for all servo spawned tasks
* add servo_util::task::{spawn_named,spawn_with_named} functions

* add name param for spawn_listener and spawn_conversation functions

this should resolve #1169
2014-01-13 13:12:48 -05:00
Jack Moffitt
a7ef1cd35e Upgrade to latest Rust. 2014-01-12 19:45:45 -07:00
Patrick Walton
be69a503fe script: Eliminate the phantom type in favor of just whitelisting methods
that layout can safely call.

This is simpler. Currently, the set of methods is not safe, but I plan
to lock it down more soon.
2013-12-17 18:07:12 -08:00
Keegan McAllister
0238410b47 Allow setting id, class, style without a full reflow
Instead we do selector matching again, then diff the style structs to set the
"restyle damage" bits which are used to prune reflow traversals.

Also don't force a reflow when timers finish, because individual DOM methods
should already take care of that.
2013-12-12 14:43:26 -08:00
Keegan McAllister
39fc9eb868 Get rid of reflow_all
This refactoring should not alter behavior.
2013-12-12 14:43:26 -08:00
Keegan McAllister
5157eac238 Warning police
And fix some formatting.
2013-11-25 13:29:34 -08:00
Tom Schuster
f9433e357c trace window.location and window.navigator 2013-11-24 23:11:11 +01:00
Tom Schuster
ccc7fa7be0 basic location 2013-11-24 22:40:24 +01:00
bors-servo
426d18ffb1 auto merge of #1219 : ksh8281/servo/impl_window_self, r=jdm
in order to Implement window.self
#868
2013-11-17 19:19:24 -08:00
Tetsuharu OHZEKI
f5ef4365f4 Stop passing DOMStrings via borrowed pointer. (#1201) 2013-11-14 20:35:36 +09:00
sh8281.kim
853bcba0d1 fix indent & name 2013-11-14 13:44:02 +09:00
Ms2ger
08afc6d19d Don't pass nullable strings to native DOM methods that want non-nullable strings. Fixes #1207. 2013-11-12 13:57:18 +01:00
Ms2ger
803cd4b7cf Make DOMString represent a non-nullable string. 2013-11-12 13:32:53 +01:00
sh8281.kim
8db917849a impl window self 2013-11-12 17:57:33 +09:00
Ms2ger
80a6103f7d Remove Reflectable::GetParentObject. 2013-11-06 21:56:47 +01:00
Ms2ger
53731b62ae Remove Reflectable::wrap_object_shared. 2013-11-06 16:40:16 +01:00
Ms2ger
4910a23803 Simplify Window wrapping. 2013-11-06 16:01:56 +01:00
Josh Matthews
88f5c2b133 Add basic event dispatch with bubbling, capturing, and propagation interruption. 2013-11-05 12:58:28 -05:00
Josh Matthews
7ecf5abbbd Generate code for handling callbacks. Implement add/removeEventListener and hacky dispatchEvent proof-of-concept. 2013-11-05 12:58:28 -05:00
Keegan McAllister
b451ff3e15 Other language changes 2013-10-31 14:58:55 -06:00
Keegan McAllister
e2b7885b73 fmt! -> format! 2013-10-31 14:58:55 -06:00
Jack Moffitt
94202661c0 Update to latest Rust. 2013-10-21 17:38:34 -06:00
bors-servo
4d8f7fd056 auto merge of #1099 : Ms2ger/servo/abstract-borrowed-pointers, r=jdm 2013-10-21 09:37:03 -07:00
Ms2ger
b90766404c Replace Document::{with_base, with_mut_base} by Document::{document, mut_document}. 2013-10-21 17:57:44 +02:00
Josh Matthews
fda77aa36b Eagerly reflect the navigator object. Fixes #1042. 2013-10-21 12:11:14 +02:00
Ms2ger
321e0373fa Merge BindingObject and Reflectable. 2013-10-18 17:02:16 +02:00
Ms2ger
25cae74093 Remove unused aTriedToWrap argument. 2013-10-17 16:43:28 +02:00
Ms2ger
da2cf6cbd7 Implement Window::get_cx() to reduce code repetition. 2013-10-13 12:06:32 +02:00
Bobby Holley
c4bbc4cd37 Introduce mutable/immutable variants of reflector() with named lifetimes, and kill unsafe casts. 2013-10-10 13:11:24 +02:00
Bobby Holley
5ed8b9e83f Rename |wrapper| to |reflector_| in Reflectable implementations for DOM objects. 2013-10-09 12:21:38 +02:00
Bobby Holley
92e91c58da Rename the |wrapper| field in Reflector. 2013-10-09 12:18:17 +02:00
Bobby Holley
549ac6a29b Rename some local variables and shorten some lines.
This was done manually, and might benefit from a more careful review.
2013-10-09 12:15:56 +02:00
Bobby Holley
62ddac8b6f Rename get_wrappercache() to reflector(). v1
I also updated some variable names in the codegen.
2013-10-09 12:11:25 +02:00
Bobby Holley
2cbe2d7ce9 Rename WrapperCache to Reflector.
I think the abstraction from the raw JSObject is still probably worthwhile for
now.
2013-10-09 12:07:41 +02:00
Bobby Holley
0a0599ad9b Rename CacheableWrapper to Reflectable. 2013-10-09 12:03:18 +02:00
Tim Kuehn
103cd6255d split script_task::ExitMsg into WindowExitMsg and PipelineExitMsg 2013-09-24 00:15:35 -04:00
Tim Kuehn
99f125bb64 script task only exits when the root pipeline exits 2013-09-24 00:03:52 -04:00
Tim Kuehn
c804db0f93 deactive profiler when not in use; use newtype structs for task chans 2013-09-20 17:25:08 -04:00
bors-servo
7ffcc29d54 auto merge of #955 : kmcallister/servo/bindings, r=metajack 2013-09-18 19:39:47 -07:00
James Graham
29a75daa66 Add support for clearTimeout. 2013-09-19 00:02:41 +01:00
Keegan McAllister
68ddc6b4ab Make DOMString an alias for Option<~str>
Fixes #898.
2013-09-18 14:46:42 -07:00
Josh Matthews
d465abdb1c Make all DOM manipulation wait until it's safe to do so (ie. all reflows for the page have completed). Fix a race where a newly-initiated reflow would be considered complete when receiving the completion notice for the previous reflow. 2013-09-16 23:41:34 -04:00