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

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

Issue 1131373003: [Session restore] Add MRU logic to loading of background pages. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 7 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
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/lazy_instance.h" 10 #include "base/lazy_instance.h"
(...skipping 1039 matching lines...) Expand 10 before | Expand all | Expand 10 after
1050 } 1050 }
1051 1051
1052 if (delegate_) 1052 if (delegate_)
1053 delegate_->NavigationStateChanged(this, changed_flags); 1053 delegate_->NavigationStateChanged(this, changed_flags);
1054 } 1054 }
1055 1055
1056 base::TimeTicks WebContentsImpl::GetLastActiveTime() const { 1056 base::TimeTicks WebContentsImpl::GetLastActiveTime() const {
1057 return last_active_time_; 1057 return last_active_time_;
1058 } 1058 }
1059 1059
1060 void WebContentsImpl::SetLastActiveTime(base::TimeTicks time) {
1061 last_active_time_ = time;
1062 }
1063
1060 void WebContentsImpl::WasShown() { 1064 void WebContentsImpl::WasShown() {
1061 controller_.SetActive(true); 1065 controller_.SetActive(true);
1062 1066
1063 for (RenderWidgetHostView* view : GetRenderWidgetHostViewsInTree()) { 1067 for (RenderWidgetHostView* view : GetRenderWidgetHostViewsInTree()) {
1064 if (view) { 1068 if (view) {
1065 view->Show(); 1069 view->Show();
1066 #if defined(OS_MACOSX) 1070 #if defined(OS_MACOSX)
1067 view->SetActive(true); 1071 view->SetActive(true);
1068 #endif 1072 #endif
1069 } 1073 }
(...skipping 3359 matching lines...) Expand 10 before | Expand all | Expand 10 after
4429 node->render_manager()->ResumeResponseDeferredAtStart(); 4433 node->render_manager()->ResumeResponseDeferredAtStart();
4430 } 4434 }
4431 4435
4432 void WebContentsImpl::SetForceDisableOverscrollContent(bool force_disable) { 4436 void WebContentsImpl::SetForceDisableOverscrollContent(bool force_disable) {
4433 force_disable_overscroll_content_ = force_disable; 4437 force_disable_overscroll_content_ = force_disable;
4434 if (view_) 4438 if (view_)
4435 view_->SetOverscrollControllerEnabled(CanOverscrollContent()); 4439 view_->SetOverscrollControllerEnabled(CanOverscrollContent());
4436 } 4440 }
4437 4441
4438 } // namespace content 4442 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698