summaryrefslogtreecommitdiffstats
path: root/WebKit/chromium/src/ApplicationCacheHost.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'WebKit/chromium/src/ApplicationCacheHost.cpp')
-rw-r--r--WebKit/chromium/src/ApplicationCacheHost.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/WebKit/chromium/src/ApplicationCacheHost.cpp b/WebKit/chromium/src/ApplicationCacheHost.cpp
index dfd4754..3bfcfe2 100644
--- a/WebKit/chromium/src/ApplicationCacheHost.cpp
+++ b/WebKit/chromium/src/ApplicationCacheHost.cpp
@@ -202,6 +202,15 @@ void ApplicationCacheHost::setDOMApplicationCache(DOMApplicationCache* domApplic
void ApplicationCacheHost::notifyDOMApplicationCache(EventID id, int total, int done)
{
+#if ENABLE(INSPECTOR)
+ // If host's frame is main frame and inspector frontend is connected, update appcache status.
+ if (id != PROGRESS_EVENT && m_documentLoader->frame()) {
+ Page* page = m_documentLoader->frame()->page();
+ if (page && page->inspectorController()->applicationCacheAgent() && page->mainFrame() == m_documentLoader->frame())
+ page->inspectorController()->applicationCacheAgent()->updateApplicationCacheStatus(status());
+ }
+#endif
+
if (m_defersEvents) {
// Event dispatching is deferred until document.onload has fired.
m_deferredEvents.append(DeferredEvent(id, total, done));