| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 52 #include "core/loader/DocumentLoader.h" | 52 #include "core/loader/DocumentLoader.h" |
| 53 #include "core/loader/FrameLoader.h" | 53 #include "core/loader/FrameLoader.h" |
| 54 #include "core/loader/FrameLoaderClient.h" | 54 #include "core/loader/FrameLoaderClient.h" |
| 55 #include "core/loader/MixedContentChecker.h" | 55 #include "core/loader/MixedContentChecker.h" |
| 56 #include "core/loader/NetworkHintsInterface.h" | 56 #include "core/loader/NetworkHintsInterface.h" |
| 57 #include "core/loader/PingLoader.h" | 57 #include "core/loader/PingLoader.h" |
| 58 #include "core/loader/ProgressTracker.h" | 58 #include "core/loader/ProgressTracker.h" |
| 59 #include "core/loader/appcache/ApplicationCacheHost.h" | 59 #include "core/loader/appcache/ApplicationCacheHost.h" |
| 60 #include "core/page/NetworkStateNotifier.h" | 60 #include "core/page/NetworkStateNotifier.h" |
| 61 #include "core/page/Page.h" | 61 #include "core/page/Page.h" |
| 62 #include "core/paint/FirstMeaningfulPaintDetector.h" |
| 62 #include "core/svg/graphics/SVGImageChromeClient.h" | 63 #include "core/svg/graphics/SVGImageChromeClient.h" |
| 63 #include "core/timing/DOMWindowPerformance.h" | 64 #include "core/timing/DOMWindowPerformance.h" |
| 64 #include "core/timing/Performance.h" | 65 #include "core/timing/Performance.h" |
| 65 #include "platform/TracedValue.h" | 66 #include "platform/TracedValue.h" |
| 66 #include "platform/mhtml/MHTMLArchive.h" | 67 #include "platform/mhtml/MHTMLArchive.h" |
| 67 #include "platform/network/NetworkUtils.h" | 68 #include "platform/network/NetworkUtils.h" |
| 68 #include "platform/network/ResourceLoadPriority.h" | 69 #include "platform/network/ResourceLoadPriority.h" |
| 69 #include "platform/network/ResourceTimingInfo.h" | 70 #include "platform/network/ResourceTimingInfo.h" |
| 70 #include "platform/weborigin/SchemeRegistry.h" | 71 #include "platform/weborigin/SchemeRegistry.h" |
| 71 #include "platform/weborigin/SecurityPolicy.h" | 72 #include "platform/weborigin/SecurityPolicy.h" |
| (...skipping 356 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 428 if (type == Resource::MainResource) | 429 if (type == Resource::MainResource) |
| 429 m_documentLoader->applicationCacheHost()->willStartLoadingMainResource(r
equest); | 430 m_documentLoader->applicationCacheHost()->willStartLoadingMainResource(r
equest); |
| 430 else | 431 else |
| 431 m_documentLoader->applicationCacheHost()->willStartLoadingResource(reque
st); | 432 m_documentLoader->applicationCacheHost()->willStartLoadingResource(reque
st); |
| 432 } | 433 } |
| 433 | 434 |
| 434 void FrameFetchContext::didLoadResource(Resource* resource) | 435 void FrameFetchContext::didLoadResource(Resource* resource) |
| 435 { | 436 { |
| 436 if (resource->isLoadEventBlockingResourceType()) | 437 if (resource->isLoadEventBlockingResourceType()) |
| 437 frame()->loader().checkCompleted(); | 438 frame()->loader().checkCompleted(); |
| 439 if (m_document) |
| 440 FirstMeaningfulPaintDetector::from(*m_document).checkNetworkStable(); |
| 438 } | 441 } |
| 439 | 442 |
| 440 void FrameFetchContext::addResourceTiming(const ResourceTimingInfo& info) | 443 void FrameFetchContext::addResourceTiming(const ResourceTimingInfo& info) |
| 441 { | 444 { |
| 442 Document* initiatorDocument = m_document && info.isMainResource() ? m_docume
nt->parentDocument() : m_document.get(); | 445 Document* initiatorDocument = m_document && info.isMainResource() ? m_docume
nt->parentDocument() : m_document.get(); |
| 443 if (!initiatorDocument || !initiatorDocument->domWindow()) | 446 if (!initiatorDocument || !initiatorDocument->domWindow()) |
| 444 return; | 447 return; |
| 445 DOMWindowPerformance::performance(*initiatorDocument->domWindow())->addResou
rceTiming(info); | 448 DOMWindowPerformance::performance(*initiatorDocument->domWindow())->addResou
rceTiming(info); |
| 446 } | 449 } |
| 447 | 450 |
| (...skipping 385 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 833 } | 836 } |
| 834 | 837 |
| 835 DEFINE_TRACE(FrameFetchContext) | 838 DEFINE_TRACE(FrameFetchContext) |
| 836 { | 839 { |
| 837 visitor->trace(m_document); | 840 visitor->trace(m_document); |
| 838 visitor->trace(m_documentLoader); | 841 visitor->trace(m_documentLoader); |
| 839 FetchContext::trace(visitor); | 842 FetchContext::trace(visitor); |
| 840 } | 843 } |
| 841 | 844 |
| 842 } // namespace blink | 845 } // namespace blink |
| OLD | NEW |