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

Unified Diff: third_party/WebKit/Source/core/page/Page.cpp

Issue 2174263002: Defer loads in new pages/frames if ScopedPageLoadDeferral is active (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Make the unfortunate hack slightly less ugly. Created 4 years, 5 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/page/Page.cpp
diff --git a/third_party/WebKit/Source/core/page/Page.cpp b/third_party/WebKit/Source/core/page/Page.cpp
index f82f7cea97ff15d102c421be69abde8152c55461..4d02c07212e8cb7ff3584b6864bc7a263eb9aaff 100644
--- a/third_party/WebKit/Source/core/page/Page.cpp
+++ b/third_party/WebKit/Source/core/page/Page.cpp
@@ -46,6 +46,7 @@
#include "core/page/DragController.h"
#include "core/page/FocusController.h"
#include "core/page/PointerLockController.h"
+#include "core/page/ScopedPageLoadDeferrer.h"
#include "core/page/ValidationMessageClient.h"
#include "core/page/scrolling/ScrollingCoordinator.h"
#include "core/paint/PaintLayer.h"
@@ -104,6 +105,8 @@ Page* Page::createOrdinary(PageClients& pageClients)
{
Page* page = create(pageClients);
ordinaryPages().add(page);
+ if (ScopedPageLoadDeferrer::isActive())
+ page->setDefersLoading(true);
return page;
}
« no previous file with comments | « third_party/WebKit/Source/core/loader/FrameLoader.cpp ('k') | third_party/WebKit/Source/core/page/ScopedPageLoadDeferrer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698