Chromium Code Reviews| Index: Source/core/frame/LocalFrame.cpp |
| diff --git a/Source/core/frame/LocalFrame.cpp b/Source/core/frame/LocalFrame.cpp |
| index c2c67c5d0a68af2a1f03461d05f35ea5b2f29b9f..838e923e56af641e065bdde37bd430ec3e228ca9 100644 |
| --- a/Source/core/frame/LocalFrame.cpp |
| +++ b/Source/core/frame/LocalFrame.cpp |
| @@ -251,6 +251,22 @@ void LocalFrame::navigate(Document& originDocument, const KURL& url, bool lockBa |
| } |
| } |
| +void LocalFrame::navigate(const FrameLoadRequest& request) |
| +{ |
| + // TODO(dcheng): Special case for window.open("about:blank") to ensure it loads synchronously into |
|
Nate Chapin
2015/06/08 16:56:22
I don't love the duplication here. Perhaps we shou
nasko
2015/06/08 17:27:04
Yeah, not a big fan either. I've modified it as su
|
| + // a new window. This is our historical behavior, and it's consistent with the creation of |
| + // a new iframe with src="about:blank". Perhaps we could get rid of this if we started reporting |
| + // the initial empty document's url as about:blank? See crbug.com/471239. |
| + // TODO(japhet): This special case is also necessary for behavior asserted by some extensions tests. |
| + // Using NavigationScheduler::scheduleNavigationChange causes the navigation to be flagged as a |
| + // client redirect, which is observable via the webNavigation extension api. |
| + if (isMainFrame() && !m_loader.stateMachine()->committedFirstRealDocumentLoad()) { |
| + m_loader.load(request); |
| + } else { |
| + m_navigationScheduler.scheduleLocationChange(request.originDocument(), request.resourceRequest().url(), request.lockBackForwardList()); |
| + } |
| +} |
| + |
| void LocalFrame::reload(ReloadPolicy reloadPolicy, ClientRedirectPolicy clientRedirectPolicy) |
| { |
| ASSERT(clientRedirectPolicy == NotClientRedirect || reloadPolicy == NormalReload); |