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

Side by Side Diff: third_party/WebKit/Source/core/loader/FrameLoader.cpp

Issue 2165653004: Don't wait for AppCache for link rel preloads (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Don't wait for appcache for link rel preloads 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserv ed. 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserv ed.
3 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) 3 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies)
4 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/) 4 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/)
5 * Copyright (C) 2008 Alp Toker <alp@atoker.com> 5 * Copyright (C) 2008 Alp Toker <alp@atoker.com>
6 * Copyright (C) Research In Motion Limited 2009. All rights reserved. 6 * Copyright (C) Research In Motion Limited 2009. All rights reserved.
7 * Copyright (C) 2011 Kris Jordan <krisjordan@gmail.com> 7 * Copyright (C) 2011 Kris Jordan <krisjordan@gmail.com>
8 * Copyright (C) 2011 Google Inc. All rights reserved. 8 * Copyright (C) 2011 Google Inc. All rights reserved.
9 * 9 *
10 * Redistribution and use in source and binary forms, with or without 10 * Redistribution and use in source and binary forms, with or without
(...skipping 427 matching lines...) Expand 10 before | Expand all | Expand 10 after
438 // When the embedder gets notified (above) that the new navigation has 438 // When the embedder gets notified (above) that the new navigation has
439 // committed, the embedder will drop the old Content Security Policy and 439 // committed, the embedder will drop the old Content Security Policy and
440 // therefore now is a good time to report to the embedder the Content 440 // therefore now is a good time to report to the embedder the Content
441 // Security Policies that have accumulated so far for the new navigation. 441 // Security Policies that have accumulated so far for the new navigation.
442 m_frame->securityContext()->contentSecurityPolicy()->reportAccumulatedHeader s(client()); 442 m_frame->securityContext()->contentSecurityPolicy()->reportAccumulatedHeader s(client());
443 443
444 // didObserveLoadingBehavior() must be called after dispatchDidCommitLoad() is called for the metrics tracking logic to handle it properly. 444 // didObserveLoadingBehavior() must be called after dispatchDidCommitLoad() is called for the metrics tracking logic to handle it properly.
445 if (client()->isControlledByServiceWorker(*m_documentLoader)) 445 if (client()->isControlledByServiceWorker(*m_documentLoader))
446 client()->didObserveLoadingBehavior(WebLoadingBehaviorServiceWorkerContr olled); 446 client()->didObserveLoadingBehavior(WebLoadingBehaviorServiceWorkerContr olled);
447 447
448 // Links with media values need more information (like viewport
449 // information). This happens after the first chunk is parsed in
450 // HTMLDocumentParser.
451 m_documentLoader->dispatchLinkHeaderPreloads(nullptr, LinkLoader::OnlyLoadNo nMedia);
452
448 TRACE_EVENT1("devtools.timeline", "CommitLoad", "data", InspectorCommitLoadE vent::data(m_frame)); 453 TRACE_EVENT1("devtools.timeline", "CommitLoad", "data", InspectorCommitLoadE vent::data(m_frame));
449 InspectorInstrumentation::didCommitLoad(m_frame, m_documentLoader.get()); 454 InspectorInstrumentation::didCommitLoad(m_frame, m_documentLoader.get());
450 m_frame->page()->didCommitLoad(m_frame); 455 m_frame->page()->didCommitLoad(m_frame);
451 dispatchDidClearDocumentOfWindowObject(); 456 dispatchDidClearDocumentOfWindowObject();
452 457
453 takeObjectSnapshot(); 458 takeObjectSnapshot();
454 } 459 }
455 460
456 void FrameLoader::didInstallNewDocument(bool dispatchWindowObjectAvailable) 461 void FrameLoader::didInstallNewDocument(bool dispatchWindowObjectAvailable)
457 { 462 {
(...skipping 1158 matching lines...) Expand 10 before | Expand all | Expand 10 after
1616 tracedValue->setString("documentLoaderURL", m_documentLoader ? m_documentLoa der->url() : String()); 1621 tracedValue->setString("documentLoaderURL", m_documentLoader ? m_documentLoa der->url() : String());
1617 return tracedValue; 1622 return tracedValue;
1618 } 1623 }
1619 1624
1620 inline void FrameLoader::takeObjectSnapshot() const 1625 inline void FrameLoader::takeObjectSnapshot() const
1621 { 1626 {
1622 TRACE_EVENT_OBJECT_SNAPSHOT_WITH_ID("loading", "FrameLoader", this, toTraced Value()); 1627 TRACE_EVENT_OBJECT_SNAPSHOT_WITH_ID("loading", "FrameLoader", this, toTraced Value());
1623 } 1628 }
1624 1629
1625 } // namespace blink 1630 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698