Anthony Ramine
44ca9f3d71
Make TaskSource::queue take a &GlobalScope
2016-10-06 21:35:52 +02:00
Anthony Ramine
19108aa330
Pass a &GlobalScope to WebIDL static methods and constructors
2016-10-06 21:35:49 +02:00
Anthony Ramine
766010379e
Introduce GlobalScope::as_window
2016-10-06 21:35:45 +02:00
bors-servo
19a5a30113
Auto merge of #13387 - emilio:debug-assertions, r=aneeshusa,jdm,pcwalton
...
Honor SERVO_ENABLE_DEBUG_ASSERTIONS on the build machines.
<!-- Please describe your changes on the following line: -->
As part of #13127 .
cc @aneeshusa
---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->
<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg " height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/13387 )
<!-- Reviewable:end -->
2016-10-04 14:01:49 -05:00
Simon Sapin
aeb3efda1f
Make script build without impl<T: HeapSizeOf> HeapSizeOf for Arc<T>
.
...
The removal of this impl is not included in this commit.
CC https://github.com/servo/heapsize/issues/37#issuecomment-249861171
2016-10-04 13:45:58 +02:00
Emilio Cobos Álvarez
fdd8471310
script: Prevent an integer overflow that was hitting us on htmlimageelement.rs
2016-10-02 18:02:17 +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
Paul Rouget
a48cf1d215
Trigger image.onerror
2016-08-23 07:51:47 +02: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
Gabriel Poesia
502497fb1f
Implement Runnable::name() for ImageResponseHandlerRunnable
2016-07-10 15:20:41 -03:00
Connor Brewster
d6f4dc06df
Combined DOMManipulationTask runnable variants into a single variant
2016-07-06 10:46:56 -06:00
Manish Goregaokar
fe5ff70284
Don't crash when <img> fails to parse its src
2016-07-05 21:52:18 +05:30
Ms2ger
684510bc94
Stop re-exporting AttrValue.
2016-06-07 13:15:23 +02:00
Ms2ger
06a1d04ca6
Move LengthOrPercentageOrAuto to style::attr.
2016-06-06 08:54:34 +02: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
Per Lundberg
2f7ed1d73e
Removed unused imports
...
This fixes #11185 .
2016-05-15 22:24:26 +03:00
Keith Yeung
33acb1937c
Remove extraneous script_chan parameter from Trusted::new
2016-04-28 10:52:44 +02:00
Simon Sapin
7932ab6ac2
Upgrade to rust-url 1.0 and hyper 0.9
2016-04-23 20:27:58 +02:00
Arnaud Marant
77f52d2eab
Issue #10574 Use the document base url in img
...
add a test with base path set to the resources path and an img with a cat and the reference directly to the image
2016-04-15 21:37:25 +02:00
akhan7
90359b1cba
Implement image request concept for HTMLImageElement. Implement HTMLImageElement.currentSrc.
2016-04-12 14:11:31 -04:00
Rahul Sharma
2caa9a2a76
refactors entities from script_thread into script_runtime
2016-04-06 12:46:49 +05:30
Adrian Utrilla
bc1b8ef4c6
Inlined content_changed
2016-04-04 11:33:37 +02:00
Corey Farwell
bf4db405e4
Remove get_*
on getters as per RFC 0344.
...
https://github.com/rust-lang/rfcs/blob/master/text/0344-conventions-galore.md#gettersetter-apis
https://github.com/servo/servo/issues/6224
2016-03-31 21:12:38 -04:00
Eli Friedman
7b671d13a0
Use presentation hints correctly for the dimensions of <img>
.
...
Mostly straightforward; includes some extra fixes to make `<canvas>`
work the same way as `<img>` for reflow.
2016-02-25 14:04:06 -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
jmr0
167ffa7a95
adding image metadata notification capabilities to image cache
2016-01-29 20:54:49 -05:00
rohan.prinja
1f02c4ebbb
task -> thread
2016-01-10 17:58:13 +09:00
Arthur Skobara
d38771e270
Implement EventTarget::fire_simple_event and EventTarget::fire_simple_event_params
2015-12-22 13:47:57 +06:00
Mathieu Agopian
11234f5370
Use Url.join instead of UrlParser.base_url(...).parse ( #9002 )
2015-12-18 17:02:41 +01:00
Arthur Skobara
8acb21a594
Remove from Trusted::new an unnecessary argument
2015-12-12 22:31:19 +06:00
Corey Farwell
4accaf50b2
Pass around event types as Atoms instead of Strings
...
`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.
2015-12-10 23:47:25 -05:00
Keith Yeung
8d90034d29
Split fn script_chan into 5 different task channel fn
2015-12-06 12:12:14 -08:00
Josh Matthews
5857b41a61
Make IPC image cache listener silently drop failures instead of catastrophically panicking. Resolves #8817 .
2015-12-04 00:05:18 -05:00
Eli Friedman
e42dcb3712
Remove unnecessary conversion to/from DOMString for localName.
2015-12-02 13:42:45 -08:00
Eli Friedman
c02c0576c8
Compute attribute name atoms at compile-time.
2015-11-27 15:42:34 -08:00
Alan Jeffrey
3dec6edd10
Update string_cache to 0.2.
...
Updated string_cache, html5ever, xml5ever and selectors in Cargo.toml files and Cargo.lock.
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!(foo) by atom!("foo").
Replaced Atom::from_slice by Atom::from.
Replaced atom.as_slice() by &*atom.
2015-11-25 10:13:21 -06:00
Alan Jeffrey
84bde75b42
Replaced DOMString constructor by conversion functions.
...
Replaced DOMString(...) by DOMString::from(...).
Replaced ....0 by String::from(...).
Removed any uses of .to_owner() in DOMString::from("...").
2015-11-12 17:52:59 -06:00
Josh Matthews
989e80036e
Implement cancellable runnables.
...
Additionally, make image load events cancellable. Resolves #7731 .
2015-11-06 10:41:38 -05:00
Ms2ger
6b75078503
Make DOMString a newtype around String, rather than a typedef.
...
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.
2015-11-04 12:09:11 +01:00
David Zbarsky
722aa86c89
Get rid of a bunch of explicit derefs
2015-11-03 19:51:46 -08:00
rohan.prinja
6e774ea6eb
merge from master
2015-11-03 19:01:23 +09:00
Eli Friedman
cf8f2b1874
Use attribute getter/setter macros for misc DOM attributes.
...
This fixes a few minor bugs.
Also adds some better testing for "unsigned long" attributes.
2015-11-01 12:47:28 -08:00
rohan.prinja
51df8e310b
rearrange imports to be in alphabetical order
2015-10-30 20:28:59 +09:00
rohan.prinja
bb2536cd01
move Castable into dom::bindings::inheritance
2015-10-30 20:24:42 +09:00
Anthony Ramine
68014af78e
Clean up the cast calls
2015-10-21 11:40:34 +02:00