Simplify frame target calculation in navigation |
|
Issue descriptionToday, FrameLoader::LoadInternal is (mostly) responsible for finding the target of a navigation. However, this gets fairly complicated as forms have their own target calculation: https://cs.chromium.org/chromium/src/third_party/blink/renderer/core/html/forms/html_form_element.cc?rcl=a8bfa46d7cc22ea442dea915392cfd424765a9b6&l=462 And LoadInternal() goes to some length to make sure it coordinates properly with form submission: https://cs.chromium.org/chromium/src/third_party/blink/renderer/core/loader/frame_loader.cc?rcl=a8bfa46d7cc22ea442dea915392cfd424765a9b6&l=884 FrameLoader::LoadInternal's responsibilities should be simplified: it should be in charge of driving navigations, and code that needs to call it needs to ensure that the navigation is already targeted at the correct frame. This becomes important when trying to schedule navigations for hyperlinks (https://html.spec.whatwg.org/multipage/links.html#following-hyperlinks-2): the target needs to be resolved first (potentially creating a new window) before the navigation itself can be scheduled on the targeted browsing context. |
|
►
Sign in to add a comment |
|