Commit graph

196 commits

Author SHA1 Message Date
Joshua Holmer
83e66d6959 Move AnimationState to script_traits
Resolves #9223
2016-01-13 18:14:12 -05:00
apopiak
4b773cefe9 move MozBrowserEvent to script_traits (+ documentation) 2016-01-13 17:48:50 +01:00
Brandon Fairchild
d1186eda7a Move DocumentState to script_traits
Fixes #9224.
2016-01-12 13:30:33 -05:00
bors-servo
fed41a42da Auto merge of #9257 - fmmartins:refactor-scripttraits, r=jdm
Move IFrameLoadInfo and IFrameSandboxState to script_traits

Hi, this should fix #8841!
Any change that might be needed please tell me

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9257)
<!-- Reviewable:end -->
2016-01-12 01:44:27 +05:30
Fernando Martins
0ef003c20a moved IFrameLoadInfo and IFrameSandboxState to script_traits 2016-01-11 18:24:08 +00:00
John DeSilva
f32995543d Move Epoch to gfx_traits
Resolves #9222. Moved Epoch from components/msg/compositor_msg to
components/gfx_traits/lib. Updated use statements to reflect the move.
2016-01-10 17:36:52 -05:00
rohan.prinja
1f02c4ebbb task -> thread 2016-01-10 17:58:13 +09:00
Paul Rouget
268e285439 update pipeline url after redirections 2016-01-06 06:49:49 +01:00
Joe Kachmar
655268d111 Separate script and layout messages, issue #8843 2015-12-26 12:24:51 -05:00
bors-servo
95eabdb4db Auto merge of #9022 - mskrzypkows:PaintMsg_refactoring, r=jdm
Move PaintMsg enum to gfx_traits #8844

re-PR of https://github.com/servo/servo/pull/9007, because homu seems stuck

Fixes #8844.

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/9022)
<!-- Reviewable:end -->
2015-12-20 01:34:26 +05:30
Maciej Skrzypkowski
3f7f323556 Move PaintMsg enum to gfx_traits #8844 2015-12-18 08:33:32 +01:00
Paul Rouget
e7449d541f Freeze old pipeline in iframes 2015-12-18 08:26:57 +01:00
bors-servo
9570b51565 Auto merge of #8618 - paulrouget:reload, r=jdm
Browser API: implement iframe.reload()

fixes #8575

The implementation is naive, and doesn't support the `hardreload` parameter.
And for the test, I'm not sure how else I can test the reload.

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/8618)
<!-- Reviewable:end -->
2015-12-17 19:45:44 +05:30
Glenn Watson
b670430cb2 Add test to constellation to avoid writing reftest image if there are pending frames.
Also change when pipelines become active.

This makes the constellation activate a pipeline as the current frame
when it is ready to do initial reflow, rather than when it is ready
to paint.

This fixes a number of intermittent failures that could previously occur
if an iframe was not visible - which would mean it was never moved from
a pending frame in the constellation to an active frame.

(It happens that webrender exposes these intermittents as permanent failures).
2015-12-17 12:30:19 +10:00
bors-servo
4e73a30b00 Auto merge of #8898 - vwvww:compositor_msg_refactor, r=Ms2ger
Moved CompositorMsg enum into compositing crate.

moved CompositorMsg enum into compositing crate.
moved from components/msg/constellation_msg.rs
            to components/compositing/lib.rs
fixes #8832

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/8898)
<!-- Reviewable:end -->
2015-12-11 12:02:52 +05:30
Beomjin Kim
729812f383 Moved CompositorMsg enum into compositing crate.
moved from components/msg/constellation_msg.rs
      to components/compositing/lib.rs

dependencies on compositing crate added in ports/cef/Cargo.lock
2015-12-11 13:42:14 +09:00
Tetsuharu OHZEKI
e8c12c1c6d Fix warnings: Use Vec.extend_from_slice instead of Vec.push_all 2015-12-10 16:49:29 -05:00
Tomas Cernaj
5507be2653 Move ScriptMsg from msg crate into script_traits 2015-12-09 20:50:11 +01:00
Paul Rouget
2a86f9d165 Browser API: implement iframe.reload() 2015-12-08 04:40:16 +01:00
Ms2ger
208c05f944 Fix warnings. 2015-12-04 10:31:19 +01:00
Matt Brubeck
9551363bfb If a mouse event is targeting an iframe, forward it to the iframe's inner window
Fixes #8759.

This adds a slow path for cases where the compositor's layer-based hit testing
is incorrect.  To optimize for this case, we could instead replace the
layer hit testing with display-list hit testing done in the paint task.
2015-12-03 08:19:41 -08:00
Josh Matthews
c23cbd4163 Dispatch load events for cross origin iframes. Resolves #6672. 2015-11-30 17:37:16 -05:00
Ms2ger
9d73b869db Consume self in PrivilegedPipelineContent methods.
This leads to a little bit of copy/paste, but the resulting code should be
quite a bit more efficient.
2015-11-26 10:23:11 +01:00
bors-servo
5e7306bf19 Auto merge of #8598 - g-k:split-scriptmsg, r=KiChjang
Split paint task messages from ScriptMsg

Refs: https://github.com/servo/servo/issues/8592

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/8598)
<!-- Reviewable:end -->
2015-11-26 03:02:47 +05:30
Greg Guthe
7668fd0503 Split paint task messages from ScriptMsg
Refs: https://github.com/servo/servo/issues/8592
2015-11-25 14:35:52 -05:00
bors-servo
e3eee5a41b Auto merge of #8597 - r0e:testing, r=Manishearth
Fix for #8593 'loop..match' should be 'while let'

As per #8593.

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/8597)
<!-- Reviewable:end -->
2015-11-23 08:18:20 +05:30
Corey Farwell
f34da4120d Implement 'url!(..)' macro
https://github.com/servo/rust-url/issues/136

https://github.com/servo/rust-url/pull/137
2015-11-21 08:15:56 -05:00
r0e
99acd46c48 Fix for #8593 'loop..match' should be 'while let'
changed line 641 of constellation.rs to while let

added while let at line 1201 in constellation.rs

added while let to line 1199 in block.rs
2015-11-19 21:48:45 -08:00
Patrick Walton
1c130819ca compositing: Split Servo up into multiple sandboxed processes.
Multiprocess mode is enabled with the `-M` switch, and sandboxing is
enabled with the `-S` switch.
2015-11-19 16:38:04 -05:00
Keith Yeung
19294db6e5 Split ConstellationMsg into ScriptMsg and CompositorMsg 2015-11-16 23:10:53 -08:00
James Graham
09b9293b09 Implement support for WebDriver send keys command.
Supports sending keys to an element. The specification here is still
rather unfinished so the error handling and so on in this code will
need iteration as it becomes clearer what the expected behaviour is.
2015-11-16 22:48:26 +00:00
bors-servo
231bf425f2 Auto merge of #8478 - KiChjang:constellation-two-receivers, r=Ms2ger
Split chan and receiver_port into script and compositor flavors

Partial #8356. Currently this doesn't build because of a lint denying me to user unsafe code, which unfortunately the select! macro falls under. Not sure what to do there.

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/8478)
<!-- Reviewable:end -->
2015-11-13 14:35:08 +05:30
Keith Yeung
d04615f44b Split chan and receiver_port into script and compositor flavors 2015-11-13 01:01:57 -08:00
Patrick Walton
1dc0d61c3c script: Make timer events e10s-safe.
Closes #8235.
2015-11-12 14:30:25 -05:00
Ms2ger
ffffc5f065 Remove the unused PipelineExitType argument from Pipeline::exit. 2015-11-05 16:32:45 +01:00
Josh Matthews
19a1e57c90 Add debugging information when running tests that timeout on build machines. 2015-11-04 12:26:41 -05:00
Eli Friedman
4f866625cc Attempt to fix webfont-related intermittent test failures.
I'm not completely sure the race condition outlined in this patch is
actually the race condition causing failures... but it seems reasonable.
2015-10-30 12:50:05 -07:00
benshu
553a0dbefd Timers are scheduled by a dedicated per-constellation thread. 2015-10-21 16:40:49 +02:00
Glenn Watson
ed72e5766b Remove webdriver use of SubpageId 2015-10-15 07:11:31 +10:00
Glenn Watson
8d312b0f0c Convert RemoveIFrame message to use pipeline id. 2015-10-12 14:14:31 +10:00
Glenn Watson
736730f2e7 Remove unused subpage senders map. 2015-10-12 11:13:30 +10:00
Glenn Watson
da881947e5 Remove constellation round trip for subpage mapping in compositor.
This makes use of the new functionality that allows iframes to generate their own pipeline IDs in order to remove any knowledge of subpage ids from the compositor.

(This is the first of several commits removing subpage from parts of servo).
2015-10-07 12:24:15 +10:00
bors-servo
098bdb5f22 Auto merge of #7807 - glennw:pid, r=jdm
Make it possible for iframes to create their own pipeline ID.

This doesn't change any functionality, but it's the first step towards removing SubpageId.

Adding this change now will allow us to gradually change over code referencing subpage id rather than in one massive PR.

Introduces a namespace for pipeline ID generation - there is a namespace for the constellation thread, and one per script thread.

<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/7807)
<!-- Reviewable:end -->
2015-10-06 01:08:32 -06:00
Glenn Watson
5645dba1fa Make it possible for iframes to create their own pipeline ID.
This doesn't change any functionality, but it's the first step towards removing SubpageId.

Adding this change now will allow us to gradually change over code referencing subpage id rather than in one massive PR.

Introduces a namespace for pipeline ID generation - there is a namespace for the constellation thread, and one per script thread.
2015-10-06 17:06:53 +10:00
Matt Brubeck
a604b360da Start the constellation with the correct pixel ratio
This may mitigate race conditions like #7730.
2015-09-30 16:53:10 -07:00
Patrick Walton
c72d0c2ed0 layout: Make the compositor rather than layout determine the position of
each iframe.

The old code that attempted to do this during layout wasn't able to work
for multiple reasons: it couldn't know where the iframe was going to be
on the page (because of nested iframes), and at the time it was building
the display list for a fragment it couldn't know where that fragment was
going to be in page coordinates.

This patch rewrites that code so that both the sizes and positions of
iframes are determined by the compositor. Layout layerizes all iframes
and marks the iframe layers with the appropriate pipeline and subpage
IDs so that the compositor can place them correctly. This approach is
similar in spirit to Gecko's `RefLayer` infrastructure. The logic that
determines when it is time to take the screenshot for reftests has been
significantly revamped to deal with this change in delegation of
responsibility.

Additionally, this code removes the infrastructure that sends layout
data back to the layout task to be destroyed, since it is now all
thread-safe and can be destroyed on the script task.

The failing tests now fail because of a pre-existing bug related to
intrinsic heights and borders on inline replaced elements. They happened
to pass before because we never rendered the iframes at all, which meant
they never had a chance to draw the red border the tests expect to not
render!

Closes #7377.
2015-09-29 09:47:28 -07:00
Patrick Walton
9bb6acd690 layout: Load Web fonts asynchronously.
Improves page load times significantly.

Closes #7343.
2015-09-27 15:38:20 -07:00
James Graham
79e548905e Enable resetable and String prefs.
This allows both boolean and string-type preferences. It
also implements a system where prefs that are read from a
configuration file can be reset back to their initial value,
which is useful in a number of cases e.g. when running tests
to ensure that each test starts with the same values for
the prefs.
2015-09-25 00:58:48 +01:00
Ravi Shankar
889eec364b sorted the extern crate, mod & use declarations 2015-09-24 02:12:45 +05:30
Maciej Skrzypkowski
88815d21ba Add plugins for compositing and net crates #7699
Changed to_string calls to to_owned calls
where was a need.
2015-09-22 13:51:21 +02:00