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

Unified Diff: third_party/WebKit/Source/core/loader/FrameFetchContext.cpp

Issue 2837763003: Reland "Move most of FrameLoader::CheckCompleted() to Document" (Closed)
Patch Set: Fix comment typos Created 3 years, 8 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/loader/FrameFetchContext.cpp
diff --git a/third_party/WebKit/Source/core/loader/FrameFetchContext.cpp b/third_party/WebKit/Source/core/loader/FrameFetchContext.cpp
index d0011ef61e5c6130560ce20b823ca28e77e11caa..513288579dbf9325567bb90516b4e59c98567b3e 100644
--- a/third_party/WebKit/Source/core/loader/FrameFetchContext.cpp
+++ b/third_party/WebKit/Source/core/loader/FrameFetchContext.cpp
@@ -613,10 +613,11 @@ void FrameFetchContext::RecordLoadingActivity(
}
void FrameFetchContext::DidLoadResource(Resource* resource) {
+ if (!GetDocument())
+ return;
+ FirstMeaningfulPaintDetector::From(*GetDocument()).CheckNetworkStable();
if (resource->IsLoadEventBlockingResourceType())
- GetFrame()->Loader().CheckCompleted();
- if (GetDocument())
- FirstMeaningfulPaintDetector::From(*GetDocument()).CheckNetworkStable();
+ GetDocument()->CheckCompleted();
}
void FrameFetchContext::AddResourceTiming(const ResourceTimingInfo& info) {

Powered by Google App Engine
This is Rietveld 408576698