| Index: content/browser/frame_host/navigation_handle_impl.cc
|
| diff --git a/content/browser/frame_host/navigation_handle_impl.cc b/content/browser/frame_host/navigation_handle_impl.cc
|
| index cd75c0ffbc6a252bda93a53090708c90d00ddfdd..f6bc72c0e283128e82a8f8b346490f67259b7987 100644
|
| --- a/content/browser/frame_host/navigation_handle_impl.cc
|
| +++ b/content/browser/frame_host/navigation_handle_impl.cc
|
| @@ -40,21 +40,20 @@ std::unique_ptr<NavigationHandleImpl> NavigationHandleImpl::Create(
|
| const GURL& url,
|
| FrameTreeNode* frame_tree_node,
|
| bool is_renderer_initiated,
|
| - bool is_synchronous,
|
| + bool is_same_page,
|
| bool is_srcdoc,
|
| const base::TimeTicks& navigation_start,
|
| int pending_nav_entry_id) {
|
| - return std::unique_ptr<NavigationHandleImpl>(
|
| - new NavigationHandleImpl(url, frame_tree_node, is_renderer_initiated,
|
| - is_synchronous, is_srcdoc, navigation_start,
|
| - pending_nav_entry_id));
|
| + return std::unique_ptr<NavigationHandleImpl>(new NavigationHandleImpl(
|
| + url, frame_tree_node, is_renderer_initiated, is_same_page, is_srcdoc,
|
| + navigation_start, pending_nav_entry_id));
|
| }
|
|
|
| NavigationHandleImpl::NavigationHandleImpl(
|
| const GURL& url,
|
| FrameTreeNode* frame_tree_node,
|
| bool is_renderer_initiated,
|
| - bool is_synchronous,
|
| + bool is_same_page,
|
| bool is_srcdoc,
|
| const base::TimeTicks& navigation_start,
|
| int pending_nav_entry_id)
|
| @@ -65,8 +64,7 @@ NavigationHandleImpl::NavigationHandleImpl(
|
| net_error_code_(net::OK),
|
| render_frame_host_(nullptr),
|
| is_renderer_initiated_(is_renderer_initiated),
|
| - is_same_page_(false),
|
| - is_synchronous_(is_synchronous),
|
| + is_same_page_(is_same_page),
|
| is_srcdoc_(is_srcdoc),
|
| was_redirected_(false),
|
| state_(INITIAL),
|
| @@ -129,10 +127,6 @@ bool NavigationHandleImpl::IsRendererInitiated() {
|
| return is_renderer_initiated_;
|
| }
|
|
|
| -bool NavigationHandleImpl::IsSynchronousNavigation() {
|
| - return is_synchronous_;
|
| -}
|
| -
|
| bool NavigationHandleImpl::IsSrcdoc() {
|
| return is_srcdoc_;
|
| }
|
| @@ -201,9 +195,6 @@ RenderFrameHostImpl* NavigationHandleImpl::GetRenderFrameHost() {
|
| }
|
|
|
| bool NavigationHandleImpl::IsSamePage() {
|
| - DCHECK(state_ == DID_COMMIT || state_ == DID_COMMIT_ERROR_PAGE)
|
| - << "This accessor should not be called before the navigation has "
|
| - "committed.";
|
| return is_same_page_;
|
| }
|
|
|
| @@ -454,13 +445,13 @@ void NavigationHandleImpl::DidCommitNavigation(
|
| RenderFrameHostImpl* render_frame_host) {
|
| DCHECK(!render_frame_host_ || render_frame_host_ == render_frame_host);
|
| DCHECK_EQ(frame_tree_node_, render_frame_host->frame_tree_node());
|
| + DCHECK_EQ(same_page, IsSamePage());
|
| CHECK_EQ(url_, params.url);
|
|
|
| method_ = params.method;
|
| has_user_gesture_ = (params.gesture == NavigationGestureUser);
|
| transition_ = params.transition;
|
| render_frame_host_ = render_frame_host;
|
| - is_same_page_ = same_page;
|
|
|
| // If an error page reloads, net_error_code might be 200 but we still want to
|
| // count it as an error page.
|
|
|