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

Unified Diff: Source/platform/network/ResourceRequest.cpp

Issue 339593005: Set the target type when creating the request for main resource (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 6 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: Source/platform/network/ResourceRequest.cpp
diff --git a/Source/platform/network/ResourceRequest.cpp b/Source/platform/network/ResourceRequest.cpp
index 02a0ec18bb5f63008d7a88322ea6dfa093c5e1a0..db0d026a28fb3c5abc0a96eb7efbe88fd40b4053 100644
--- a/Source/platform/network/ResourceRequest.cpp
+++ b/Source/platform/network/ResourceRequest.cpp
@@ -82,6 +82,12 @@ PassOwnPtr<CrossThreadResourceRequestData> ResourceRequest::copyData() const
return data.release();
}
+void ResourceRequest::initializeForMainResource(bool isMainFrame)
ppi 2014/06/19 18:25:42 This can be called at any point, while ::initializ
+{
+ m_targetType = isMainFrame ? TargetIsMainFrame : TargetIsSubframe;
+ m_priority = ResourceLoadPriorityVeryHigh;
+}
+
bool ResourceRequest::isEmpty() const
{
return m_url.isEmpty();

Powered by Google App Engine
This is Rietveld 408576698