| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2009, 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2009, 2012 Google Inc. All rights reserved. |
| 3 * Copyright (C) 2011 Apple Inc. All rights reserved. | 3 * Copyright (C) 2011 Apple Inc. All rights reserved. |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions are | 6 * modification, are permitted provided that the following conditions are |
| 7 * met: | 7 * met: |
| 8 * | 8 * |
| 9 * * Redistributions of source code must retain the above copyright | 9 * * Redistributions of source code must retain the above copyright |
| 10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 62 #include "modules/serviceworkers/NavigatorServiceWorker.h" | 62 #include "modules/serviceworkers/NavigatorServiceWorker.h" |
| 63 #include "modules/serviceworkers/ServiceWorkerLinkResource.h" | 63 #include "modules/serviceworkers/ServiceWorkerLinkResource.h" |
| 64 #include "modules/storage/DOMWindowStorageController.h" | 64 #include "modules/storage/DOMWindowStorageController.h" |
| 65 #include "modules/vr/NavigatorVR.h" | 65 #include "modules/vr/NavigatorVR.h" |
| 66 #include "platform/Histogram.h" | 66 #include "platform/Histogram.h" |
| 67 #include "platform/MIMETypeRegistry.h" | 67 #include "platform/MIMETypeRegistry.h" |
| 68 #include "platform/RuntimeEnabledFeatures.h" | 68 #include "platform/RuntimeEnabledFeatures.h" |
| 69 #include "platform/UserGestureIndicator.h" | 69 #include "platform/UserGestureIndicator.h" |
| 70 #include "platform/exported/WrappedResourceRequest.h" | 70 #include "platform/exported/WrappedResourceRequest.h" |
| 71 #include "platform/exported/WrappedResourceResponse.h" | 71 #include "platform/exported/WrappedResourceResponse.h" |
| 72 #include "platform/fonts/GlyphPageTreeNode.h" | |
| 73 #include "platform/network/HTTPParsers.h" | 72 #include "platform/network/HTTPParsers.h" |
| 74 #include "platform/plugins/PluginData.h" | 73 #include "platform/plugins/PluginData.h" |
| 75 #include "public/platform/Platform.h" | 74 #include "public/platform/Platform.h" |
| 76 #include "public/platform/WebApplicationCacheHost.h" | 75 #include "public/platform/WebApplicationCacheHost.h" |
| 77 #include "public/platform/WebMediaPlayerSource.h" | 76 #include "public/platform/WebMediaPlayerSource.h" |
| 78 #include "public/platform/WebMimeRegistry.h" | 77 #include "public/platform/WebMimeRegistry.h" |
| 79 #include "public/platform/WebRTCPeerConnectionHandler.h" | 78 #include "public/platform/WebRTCPeerConnectionHandler.h" |
| 80 #include "public/platform/WebSecurityOrigin.h" | 79 #include "public/platform/WebSecurityOrigin.h" |
| 81 #include "public/platform/WebURL.h" | 80 #include "public/platform/WebURL.h" |
| 82 #include "public/platform/WebURLError.h" | 81 #include "public/platform/WebURLError.h" |
| (...skipping 364 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 447 static_cast<WebIconURL::Type>(type)); | 446 static_cast<WebIconURL::Type>(type)); |
| 448 } | 447 } |
| 449 | 448 |
| 450 void FrameLoaderClientImpl::dispatchDidCommitLoad( | 449 void FrameLoaderClientImpl::dispatchDidCommitLoad( |
| 451 HistoryItem* item, | 450 HistoryItem* item, |
| 452 HistoryCommitType commitType) { | 451 HistoryCommitType commitType) { |
| 453 if (!m_webFrame->parent()) { | 452 if (!m_webFrame->parent()) { |
| 454 m_webFrame->viewImpl()->didCommitLoad(commitType == StandardCommit, false); | 453 m_webFrame->viewImpl()->didCommitLoad(commitType == StandardCommit, false); |
| 455 } | 454 } |
| 456 | 455 |
| 457 // Save some histogram data so we can compute the average memory used per | |
| 458 // page load of the glyphs. | |
| 459 // TODO(esprehn): Is this ancient uma actually useful? | |
| 460 DEFINE_STATIC_LOCAL(CustomCountHistogram, gyphsPagesPerLoadHistogram, | |
| 461 ("Memory.GlyphPagesPerLoad", 1, 10000, 50)); | |
| 462 gyphsPagesPerLoadHistogram.count(GlyphPageTreeNode::treeGlyphPageCount()); | |
| 463 | |
| 464 if (m_webFrame->client()) | 456 if (m_webFrame->client()) |
| 465 m_webFrame->client()->didCommitProvisionalLoad( | 457 m_webFrame->client()->didCommitProvisionalLoad( |
| 466 m_webFrame, WebHistoryItem(item), | 458 m_webFrame, WebHistoryItem(item), |
| 467 static_cast<WebHistoryCommitType>(commitType)); | 459 static_cast<WebHistoryCommitType>(commitType)); |
| 468 if (WebDevToolsAgentImpl* devTools = devToolsAgent()) | 460 if (WebDevToolsAgentImpl* devTools = devToolsAgent()) |
| 469 devTools->didCommitLoadForLocalFrame(m_webFrame->frame()); | 461 devTools->didCommitLoadForLocalFrame(m_webFrame->frame()); |
| 470 } | 462 } |
| 471 | 463 |
| 472 void FrameLoaderClientImpl::dispatchDidFailProvisionalLoad( | 464 void FrameLoaderClientImpl::dispatchDidFailProvisionalLoad( |
| 473 const ResourceError& error, | 465 const ResourceError& error, |
| (...skipping 517 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 991 WebDevToolsAgentImpl* FrameLoaderClientImpl::devToolsAgent() { | 983 WebDevToolsAgentImpl* FrameLoaderClientImpl::devToolsAgent() { |
| 992 return WebLocalFrameImpl::fromFrame(m_webFrame->frame()->localFrameRoot()) | 984 return WebLocalFrameImpl::fromFrame(m_webFrame->frame()->localFrameRoot()) |
| 993 ->devToolsAgentImpl(); | 985 ->devToolsAgentImpl(); |
| 994 } | 986 } |
| 995 | 987 |
| 996 KURL FrameLoaderClientImpl::overrideFlashEmbedWithHTML(const KURL& url) { | 988 KURL FrameLoaderClientImpl::overrideFlashEmbedWithHTML(const KURL& url) { |
| 997 return m_webFrame->client()->overrideFlashEmbedWithHTML(WebURL(url)); | 989 return m_webFrame->client()->overrideFlashEmbedWithHTML(WebURL(url)); |
| 998 } | 990 } |
| 999 | 991 |
| 1000 } // namespace blink | 992 } // namespace blink |
| OLD | NEW |