servo/components/script
bors-servo 2dfbbd0ca2
Auto merge of #23368 - gterzian:clean_up_navigation, r=asajeffrey
Clean-up navigation

<!-- Please describe your changes on the following line: -->

1. Navigation as a result of following a hyperlink should be done in a task: https://html.spec.whatwg.org/multipage/links.html#following-hyperlinks:dom-manipulation-task-source
2. The javascript url navigation should also be done in a task: https://html.spec.whatwg.org/multipage/browsing-the-web.html#navigating-across-documents:dom-manipulation-task-source
3. In `window.load_url`, it seems there is no need to send a message to the script-thread(the entirety of `load_url` should instead be done in a task when appropriate), so we can just do that last part "sync" by calling a method on the script, which will send a message to the constellation(for the parallel navigation steps), or queue task(for the JS navigation), as appropriate.
4. Separate the "normal" navigation flow from the handling of "navigate an iframe" message from constellation, since doing everything in one method as was previously done with `handle_navigate`, is confusing.

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: -->
- [ ] `./mach build -d` does not report any errors
- [ ] `./mach test-tidy` does not report any errors
- [ ] These changes fix #___ (GitHub issue number if applicable)

<!-- Either: -->
- [ ] There are tests for these changes OR
- [ ] These changes do not require tests because ___

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- 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/23368)
<!-- Reviewable:end -->
2019-07-18 14:22:03 -04:00
..
docs
dom Auto merge of #23368 - gterzian:clean_up_navigation, r=asajeffrey 2019-07-18 14:22:03 -04:00
task_source
body.rs Pass InCompartment by value 2019-04-25 11:37:35 +02:00
build.rs Remove restrictions on cross-compiling on Windows. 2019-05-24 22:32:34 -04:00
Cargo.toml Hook supportsSession() into new xr crate 2019-07-11 11:12:59 -07:00
clipboard_provider.rs Remove not needed DummyClipboardContext 2019-06-13 20:20:25 +02:00
CMakeLists.txt Remove restrictions on cross-compiling on Windows. 2019-05-24 22:32:34 -04:00
compartments.rs Create a helper API for entering a DOM object's compartment 2019-06-29 19:23:17 +02:00
devtools.rs Create a helper API for entering a DOM object's compartment 2019-06-29 19:23:17 +02:00
document_loader.rs Remove unused code from script* crates 2019-06-02 07:12:26 +02:00
fetch.rs Create a helper API for entering a DOM object's compartment 2019-06-29 19:23:17 +02:00
image_listener.rs Implement HTMLMediaElement poster attribute 2019-01-11 17:11:11 +01:00
layout_image.rs Implementing the builder pattern for RequestInit 2019-04-10 14:01:30 -03:00
lib.rs Remove uses of mem::uninitialized 2019-07-17 10:48:54 +02:00
mem.rs
microtask.rs Upgrade to Spidermonkey 67. 2019-06-26 18:10:46 -04:00
network_listener.rs Let resources timing entries be added to performance entry buffer. 2019-06-11 09:40:31 -07:00
script_runtime.rs Upgrade to Spidermonkey 67. 2019-06-26 18:10:46 -04:00
script_thread.rs Auto merge of #23368 - gterzian:clean_up_navigation, r=asajeffrey 2019-07-18 14:22:03 -04:00
serviceworker_manager.rs #8539 Config preferences backend restructure 2019-03-20 15:01:26 +00:00
serviceworkerjob.rs Update Worker webidl to support WorkerOptions 2019-05-11 12:14:25 +09:00
stylesheet_loader.rs Rename shadow_root_from_node to containing_shadow_root 2019-04-26 12:00:26 +02:00
stylesheet_set.rs Move StylesheetSetRef to script 2019-04-26 12:00:26 +02:00
task.rs Remove default-except-unstable 2019-07-01 15:43:24 +02:00
task_manager.rs
task_queue.rs in BC event-loop, only run tasks related to fully-active documents 2019-03-06 14:18:18 +08:00
test.rs
textinput.rs Add clipboard cut functionality 2019-07-10 18:44:43 +02:00
timers.rs #8539 Config preferences backend restructure 2019-03-20 15:01:26 +00:00
unpremultiplytable.rs
webdriver_handlers.rs Implement GetPageSource WebDriver command 2019-06-17 13:06:29 +03:00