Replace OpenURL usage in window.open() with LoadURLWithParams.

The current window.open() implementation on the browser side is using
OpenURL to navigate when the opener is suppressed (e.g. 'noopener') and
URL is specified. This results in the navigation being sent up to the
embedder and come back to content. Since the default parameters being
constructed should not cause the embedder to make any changes to the
navigation, it should be safe to skip the extra code and directly
navigate the new window.

This CL adds LoadURLParams storage to WebContentsImpl and implements
all navigations of window.open() that are started browser process side
to use NavigationController::LoadURLWithParams. It effectively
short-circuits the unnecessary trip to the embedder.

Bug: 882053
Change-Id: I09120397f3a6e7856e76ba0448d0bdff807f7628
Reviewed-on: https://chromium-review.googlesource.com/c/1286194
Commit-Queue: Nasko Oskov <nasko@chromium.org>
Reviewed-by: Alex Moshchuk <alexmos@chromium.org>
Cr-Commit-Position: refs/heads/master@{#601148}
2 files changed