Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(245)

Side by Side Diff: content/browser/frame_host/render_frame_host_impl.cc

Issue 669943002: Revert of Ensure that the browser’s copy of page id is in sync with the renderer’s. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « chrome/common/crash_keys.cc ('k') | content/browser/renderer_host/render_view_host_delegate.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/browser/frame_host/render_frame_host_impl.h" 5 #include "content/browser/frame_host/render_frame_host_impl.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/containers/hash_tables.h" 9 #include "base/containers/hash_tables.h"
10 #include "base/lazy_instance.h" 10 #include "base/lazy_instance.h"
(...skipping 1033 matching lines...) Expand 10 before | Expand all | Expand 10 after
1044 void RenderFrameHostImpl::OnDidAssignPageId(int32 page_id) { 1044 void RenderFrameHostImpl::OnDidAssignPageId(int32 page_id) {
1045 // Update the RVH's current page ID so that future IPCs from the renderer 1045 // Update the RVH's current page ID so that future IPCs from the renderer
1046 // correspond to the new page. 1046 // correspond to the new page.
1047 render_view_host_->page_id_ = page_id; 1047 render_view_host_->page_id_ = page_id;
1048 } 1048 }
1049 1049
1050 void RenderFrameHostImpl::OnUpdateTitle( 1050 void RenderFrameHostImpl::OnUpdateTitle(
1051 int32 page_id, 1051 int32 page_id,
1052 const base::string16& title, 1052 const base::string16& title,
1053 blink::WebTextDirection title_direction) { 1053 blink::WebTextDirection title_direction) {
1054 CHECK_EQ(render_view_host_->page_id_, page_id);
1055 // This message is only sent for top-level frames. TODO(avi): when frame tree 1054 // This message is only sent for top-level frames. TODO(avi): when frame tree
1056 // mirroring works correctly, add a check here to enforce it. 1055 // mirroring works correctly, add a check here to enforce it.
1057 if (title.length() > kMaxTitleChars) { 1056 if (title.length() > kMaxTitleChars) {
1058 NOTREACHED() << "Renderer sent too many characters in title."; 1057 NOTREACHED() << "Renderer sent too many characters in title.";
1059 return; 1058 return;
1060 } 1059 }
1061 1060
1062 delegate_->UpdateTitle(this, page_id, title, 1061 delegate_->UpdateTitle(this, page_id, title,
1063 WebTextDirectionToChromeTextDirection( 1062 WebTextDirectionToChromeTextDirection(
1064 title_direction)); 1063 title_direction));
(...skipping 498 matching lines...) Expand 10 before | Expand all | Expand 10 after
1563 // Clear any state if a pending navigation is canceled or preempted. 1562 // Clear any state if a pending navigation is canceled or preempted.
1564 if (suspended_nav_params_) 1563 if (suspended_nav_params_)
1565 suspended_nav_params_.reset(); 1564 suspended_nav_params_.reset();
1566 1565
1567 TRACE_EVENT_ASYNC_END0("navigation", 1566 TRACE_EVENT_ASYNC_END0("navigation",
1568 "RenderFrameHostImpl navigation suspended", this); 1567 "RenderFrameHostImpl navigation suspended", this);
1569 navigations_suspended_ = false; 1568 navigations_suspended_ = false;
1570 } 1569 }
1571 1570
1572 } // namespace content 1571 } // namespace content
OLDNEW
« no previous file with comments | « chrome/common/crash_keys.cc ('k') | content/browser/renderer_host/render_view_host_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698