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

Side by Side Diff: content/browser/web_contents/web_contents_impl.cc

Issue 433733002: Revert 284592 "Cache the current WebPreferences on RenderViewHos..." (Closed) Base URL: svn://svn.chromium.org/chrome/branches/2107/src/
Patch Set: Created 6 years, 4 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/web_contents/web_contents_impl.h" 5 #include "content/browser/web_contents/web_contents_impl.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/debug/trace_event.h" 10 #include "base/debug/trace_event.h"
(...skipping 3819 matching lines...) Expand 10 before | Expand all | Expand 10 after
3830 bool WebContentsImpl::AddMessageToConsole(int32 level, 3830 bool WebContentsImpl::AddMessageToConsole(int32 level,
3831 const base::string16& message, 3831 const base::string16& message,
3832 int32 line_no, 3832 int32 line_no,
3833 const base::string16& source_id) { 3833 const base::string16& source_id) {
3834 if (!delegate_) 3834 if (!delegate_)
3835 return false; 3835 return false;
3836 return delegate_->AddMessageToConsole(this, level, message, line_no, 3836 return delegate_->AddMessageToConsole(this, level, message, line_no,
3837 source_id); 3837 source_id);
3838 } 3838 }
3839 3839
3840 WebPreferences WebContentsImpl::ComputeWebkitPrefs() { 3840 WebPreferences WebContentsImpl::GetWebkitPrefs() {
3841 // We want to base the page config off of the actual URL, rather than the 3841 // We want to base the page config off of the actual URL, rather than the
3842 // virtual URL. 3842 // virtual URL.
3843 // TODO(nasko): Investigate how to remove the GetActiveEntry usage here, 3843 // TODO(nasko): Investigate how to remove the GetActiveEntry usage here,
3844 // as it is deprecated and can be out of sync with GetRenderViewHost(). 3844 // as it is deprecated and can be out of sync with GetRenderViewHost().
3845 GURL url = controller_.GetActiveEntry() 3845 GURL url = controller_.GetActiveEntry()
3846 ? controller_.GetActiveEntry()->GetURL() : GURL::EmptyGURL(); 3846 ? controller_.GetActiveEntry()->GetURL() : GURL::EmptyGURL();
3847 3847
3848 return GetRenderManager()->current_host()->ComputeWebkitPrefs(url); 3848 return GetRenderManager()->current_host()->GetWebkitPrefs(url);
3849 } 3849 }
3850 3850
3851 int WebContentsImpl::CreateSwappedOutRenderView( 3851 int WebContentsImpl::CreateSwappedOutRenderView(
3852 SiteInstance* instance) { 3852 SiteInstance* instance) {
3853 return GetRenderManager()->CreateRenderFrame(instance, MSG_ROUTING_NONE, 3853 return GetRenderManager()->CreateRenderFrame(instance, MSG_ROUTING_NONE,
3854 true, true); 3854 true, true);
3855 } 3855 }
3856 3856
3857 void WebContentsImpl::OnUserGesture() { 3857 void WebContentsImpl::OnUserGesture() {
3858 // Notify observers. 3858 // Notify observers.
(...skipping 377 matching lines...) Expand 10 before | Expand all | Expand 10 after
4236 if (new_size != old_size) 4236 if (new_size != old_size)
4237 delegate_->UpdatePreferredSize(this, new_size); 4237 delegate_->UpdatePreferredSize(this, new_size);
4238 } 4238 }
4239 4239
4240 void WebContentsImpl::ResumeResponseDeferredAtStart() { 4240 void WebContentsImpl::ResumeResponseDeferredAtStart() {
4241 FrameTreeNode* node = frame_tree_.root(); 4241 FrameTreeNode* node = frame_tree_.root();
4242 node->render_manager()->ResumeResponseDeferredAtStart(); 4242 node->render_manager()->ResumeResponseDeferredAtStart();
4243 } 4243 }
4244 4244
4245 } // namespace content 4245 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/web_contents/web_contents_impl.h ('k') | content/public/browser/render_view_host.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698