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

Unified Diff: Source/core/html/parser/HTMLResourcePreloader.cpp

Issue 457413002: Defer late and async scripts (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Lower priorities for late/async scripts 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/html/parser/HTMLResourcePreloader.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/html/parser/HTMLResourcePreloader.cpp
diff --git a/Source/core/html/parser/HTMLResourcePreloader.cpp b/Source/core/html/parser/HTMLResourcePreloader.cpp
index 3f1ee72eab01460a69638136a0c6c97b2c5eaa87..6cdc6da411ee29b8ff5f06d20950bb7017a0615f 100644
--- a/Source/core/html/parser/HTMLResourcePreloader.cpp
+++ b/Source/core/html/parser/HTMLResourcePreloader.cpp
@@ -88,6 +88,8 @@ void HTMLResourcePreloader::takeAndPreload(PreloadRequestStream& r)
void HTMLResourcePreloader::preload(PassOwnPtr<PreloadRequest> preload)
{
FetchRequest request = preload->resourceRequest(m_document);
+ request.setIsBeforeBody(preload->isBeforeBody());
+ request.setExecAsync(preload->execAsync());
blink::Platform::current()->histogramCustomCounts("WebCore.PreloadDelayMs", static_cast<int>(1000 * (monotonicallyIncreasingTime() - preload->discoveryTime())), 0, 2000, 20);
m_document->fetcher()->preload(preload->resourceType(), request, preload->charset());
}
« no previous file with comments | « Source/core/html/parser/HTMLResourcePreloader.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698