Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upSeparate script and layout messages, issue #8843 #8958
Conversation
highfive
commented
Dec 13, 2015
|
Thanks for the pull request, and welcome! The Servo team is excited to review your changes, and you should hear from @larsbergstrom (or someone else) soon. |
highfive
commented
Dec 13, 2015
|
|
|
r? @KiChjang |
| @@ -306,6 +307,13 @@ impl JSTraceable for ConstellationChan<ScriptMsg> { | |||
| } | |||
| } | |||
|
|
|||
| impl JSTraceable for ConstellationChan<LayoutMsg> { | |||
This comment has been minimized.
This comment has been minimized.
Manishearth
Dec 16, 2015
Member
I think we should just use no_jsmanaged_fields! on ConstellationChan<T>?
| @@ -22,6 +22,9 @@ path = "../net_traits" | |||
| [dependencies.profile_traits] | |||
| path = "../profile_traits" | |||
|
|
|||
| [dependencies.style_traits] | |||
| path = "../style_traits" | |||
This comment has been minimized.
This comment has been minimized.
| @@ -27,6 +27,9 @@ path = "../net_traits" | |||
| [dependencies.profile_traits] | |||
| path = "../profile_traits" | |||
|
|
|||
| [dependencies.layout_traits] | |||
| path = "../layout_traits" | |||
This comment has been minimized.
This comment has been minimized.
|
@bors-servo delegate=KiChjang Looks good to me (modulo nits) at a glance; Keith can do a more thorough review |
|
|
|
-S-awaiting-review -S-needs-rebase +S-needs-code-changes Great job so far! I've left comments in places where care must be taken when dealing with passing messages to the constellation. The most important idea here is to recognize that the script objects should only send Secondly, both script and layout objects should never need to know what kind of messages (i.e. Reviewed 11 of 19 files at r1, 8 of 8 files at r2. components/compositing/constellation.rs, line 102 [r2] (raw file): components/compositing/pipeline.rs, line 85 [r2] (raw file): components/script/dom/document.rs, line 1163 [r2] (raw file): components/script/dom/window.rs, line 199 [r2] (raw file): components/script/layout_interface.rs, line 21 [r2] (raw file): components/script/lib.rs, line 51 [r2] (raw file): components/script_traits/lib.rs, line 262 [r2] (raw file): Comments from the review on Reviewable.io |
|
|
|
-S-awaiting-review -S-needs-rebase +S-needs-code-changes Reviewed 13 of 16 files at r3. components/layout/layout_task.rs, line 692 [r3] (raw file): components/script/layout_interface.rs, line 259 [r3] (raw file): components/script/script_task.rs, line 1203 [r3] (raw file): Comments from the review on Reviewable.io |
|
-S-awaiting-review @bors-servo r+ Thanks for doing this! Reviewed 5 of 11 files at r4. Comments from the review on Reviewable.io |
|
|
Separate script and layout messages, issue #8843 Separated layout-specific messages to the constellation out from the `ScriptMsg` enum into a `LayoutMsg` enum within `script_traits/script_msg.rs`, addresses [#8843](#8843). I initially tried to move `LayoutMsg` into `layout_traits/lib.rs`, but this introduced a cyclic dependency: `layout_traits` depends on `script_traits` for the `LayoutTaskFactory` implementation, and `script_traits/script_task.rs` now depends on `LayoutMsg` for new layout channels in `InitialScriptState` and `ScriptTask`. <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/8958) <!-- Reviewable:end -->
|
|
jkachmar commentedDec 13, 2015
Separated layout-specific messages to the constellation out from the
ScriptMsgenum into aLayoutMsgenum withinscript_traits/script_msg.rs, addresses #8843.I initially tried to move
LayoutMsgintolayout_traits/lib.rs, but this introduced a cyclic dependency:layout_traitsdepends onscript_traitsfor theLayoutTaskFactoryimplementation, andscript_traits/script_task.rsnow depends onLayoutMsgfor new layout channels inInitialScriptStateandScriptTask.