diff options
Diffstat (limited to 'chrome/browser')
-rw-r--r-- | chrome/browser/render_view_host.cc | 8 | ||||
-rw-r--r-- | chrome/browser/render_view_host.h | 2 | ||||
-rw-r--r-- | chrome/browser/render_view_host_delegate.h | 2 | ||||
-rw-r--r-- | chrome/browser/web_contents.cc | 23 | ||||
-rw-r--r-- | chrome/browser/web_contents.h | 2 |
5 files changed, 4 insertions, 33 deletions
diff --git a/chrome/browser/render_view_host.cc b/chrome/browser/render_view_host.cc index 38bbe9e..77512b6 100644 --- a/chrome/browser/render_view_host.cc +++ b/chrome/browser/render_view_host.cc @@ -832,14 +832,8 @@ void RenderViewHost::OnMsgNavigate(const IPC::Message& msg) { } void RenderViewHost::OnMsgUpdateState(int32 page_id, - const GURL& url, - const std::wstring& title, const std::string& state) { - GURL validated_url(url); - FilterURL(RendererSecurityPolicy::GetInstance(), - process()->host_id(), &validated_url); - - delegate_->UpdateState(this, page_id, validated_url, title, state); + delegate_->UpdateState(this, page_id, state); } void RenderViewHost::OnMsgUpdateTitle(int32 page_id, diff --git a/chrome/browser/render_view_host.h b/chrome/browser/render_view_host.h index b7d1ae2..5ccd88f 100644 --- a/chrome/browser/render_view_host.h +++ b/chrome/browser/render_view_host.h @@ -420,8 +420,6 @@ class RenderViewHost : public RenderWidgetHost { void OnMsgRendererGone(); void OnMsgNavigate(const IPC::Message& msg); void OnMsgUpdateState(int32 page_id, - const GURL& url, - const std::wstring& title, const std::string& state); void OnMsgUpdateTitle(int32 page_id, const std::wstring& title); void OnMsgUpdateEncoding(const std::wstring& encoding); diff --git a/chrome/browser/render_view_host_delegate.h b/chrome/browser/render_view_host_delegate.h index 63e2eaa..f0c4b0e 100644 --- a/chrome/browser/render_view_host_delegate.h +++ b/chrome/browser/render_view_host_delegate.h @@ -160,8 +160,6 @@ class RenderViewHostDelegate { // The state for the page changed and should be updated. virtual void UpdateState(RenderViewHost* render_view_host, int32 page_id, - const GURL& url, - const std::wstring& title, const std::string& state) { } // The page's title was changed and should be updated. diff --git a/chrome/browser/web_contents.cc b/chrome/browser/web_contents.cc index 4afc290..1191d5d 100644 --- a/chrome/browser/web_contents.cc +++ b/chrome/browser/web_contents.cc @@ -745,8 +745,6 @@ void WebContents::DidNavigate(RenderViewHost* rvh, void WebContents::UpdateState(RenderViewHost* rvh, int32 page_id, - const GURL& url, - const std::wstring& title, const std::string& state) { if (rvh != render_view_host() || render_manager_.showing_interstitial_page()) { @@ -774,27 +772,12 @@ void WebContents::UpdateState(RenderViewHost* rvh, if (entry_index < 0) return; NavigationEntry* entry = controller()->GetEntryAtIndex(entry_index); - unsigned changed_flags = 0; - - // Update the URL. - if (url != entry->url()) { - changed_flags |= INVALIDATE_URL; - if (entry == controller()->GetActiveEntry()) - fav_icon_helper_.FetchFavIcon(url); - entry->set_url(url); - } - - // Save the new title if it changed. - if (UpdateTitleForEntry(entry, title)) - changed_flags |= INVALIDATE_TITLE; - // Update the state (forms, etc.). - if (state != entry->content_state()) - entry->set_content_state(state); + if (state == entry->content_state()) + return; // Nothing to update. + entry->set_content_state(state); // Notify everybody of the changes (only when the current page changed). - if (changed_flags && entry == controller()->GetActiveEntry()) - NotifyNavigationStateChanged(changed_flags); controller()->NotifyEntryChanged(entry, entry_index); } diff --git a/chrome/browser/web_contents.h b/chrome/browser/web_contents.h index efe7a10..f7ed61e 100644 --- a/chrome/browser/web_contents.h +++ b/chrome/browser/web_contents.h @@ -231,8 +231,6 @@ class WebContents : public TabContents, const ViewHostMsg_FrameNavigate_Params& params); virtual void UpdateState(RenderViewHost* render_view_host, int32 page_id, - const GURL& url, - const std::wstring& title, const std::string& state); virtual void UpdateTitle(RenderViewHost* render_view_host, int32 page_id, |