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

Unified Diff: Source/core/loader/appcache/ApplicationCache.cpp

Issue 22802012: Rename DOMApplicationCache to ApplicationCache and expose it to JS (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Remove change to devtools and fix nits Created 7 years, 4 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
« no previous file with comments | « Source/core/loader/appcache/ApplicationCache.h ('k') | Source/core/loader/appcache/ApplicationCache.idl » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/loader/appcache/ApplicationCache.cpp
diff --git a/Source/core/loader/appcache/DOMApplicationCache.cpp b/Source/core/loader/appcache/ApplicationCache.cpp
similarity index 81%
rename from Source/core/loader/appcache/DOMApplicationCache.cpp
rename to Source/core/loader/appcache/ApplicationCache.cpp
index d3af99c2014981c59a34854e7c43121bcc22fdd0..786c8fdd3b9588a1b959716935536305538d06bc 100644
--- a/Source/core/loader/appcache/DOMApplicationCache.cpp
+++ b/Source/core/loader/appcache/ApplicationCache.cpp
@@ -24,7 +24,7 @@
*/
#include "config.h"
-#include "core/loader/appcache/DOMApplicationCache.h"
+#include "core/loader/appcache/ApplicationCache.h"
#include "bindings/v8/ExceptionMessages.h"
#include "bindings/v8/ExceptionState.h"
@@ -39,30 +39,30 @@
namespace WebCore {
-DOMApplicationCache::DOMApplicationCache(Frame* frame)
+ApplicationCache::ApplicationCache(Frame* frame)
: DOMWindowProperty(frame)
{
ScriptWrappable::init(this);
ApplicationCacheHost* cacheHost = applicationCacheHost();
if (cacheHost)
- cacheHost->setDOMApplicationCache(this);
+ cacheHost->setApplicationCache(this);
}
-void DOMApplicationCache::willDestroyGlobalObjectInFrame()
+void ApplicationCache::willDestroyGlobalObjectInFrame()
{
if (ApplicationCacheHost* cacheHost = applicationCacheHost())
- cacheHost->setDOMApplicationCache(0);
+ cacheHost->setApplicationCache(0);
DOMWindowProperty::willDestroyGlobalObjectInFrame();
}
-ApplicationCacheHost* DOMApplicationCache::applicationCacheHost() const
+ApplicationCacheHost* ApplicationCache::applicationCacheHost() const
{
if (!m_frame || !m_frame->loader()->documentLoader())
return 0;
return m_frame->loader()->documentLoader()->applicationCacheHost();
}
-unsigned short DOMApplicationCache::status() const
+unsigned short ApplicationCache::status() const
{
ApplicationCacheHost* cacheHost = applicationCacheHost();
if (!cacheHost)
@@ -70,40 +70,40 @@ unsigned short DOMApplicationCache::status() const
return cacheHost->status();
}
-void DOMApplicationCache::update(ExceptionState& es)
+void ApplicationCache::update(ExceptionState& es)
{
ApplicationCacheHost* cacheHost = applicationCacheHost();
if (!cacheHost || !cacheHost->update())
es.throwDOMException(InvalidStateError, ExceptionMessages::failedToExecute("update", "ApplicationCache", "there is no application cache to update."));
}
-void DOMApplicationCache::swapCache(ExceptionState& es)
+void ApplicationCache::swapCache(ExceptionState& es)
{
ApplicationCacheHost* cacheHost = applicationCacheHost();
if (!cacheHost || !cacheHost->swapCache())
es.throwDOMException(InvalidStateError, ExceptionMessages::failedToExecute("swapCache", "ApplicationCache", "there is no newer application cache to swap to."));
}
-void DOMApplicationCache::abort()
+void ApplicationCache::abort()
{
ApplicationCacheHost* cacheHost = applicationCacheHost();
if (cacheHost)
cacheHost->abort();
}
-const AtomicString& DOMApplicationCache::interfaceName() const
+const AtomicString& ApplicationCache::interfaceName() const
{
- return eventNames().interfaceForDOMApplicationCache;
+ return eventNames().interfaceForApplicationCache;
}
-ScriptExecutionContext* DOMApplicationCache::scriptExecutionContext() const
+ScriptExecutionContext* ApplicationCache::scriptExecutionContext() const
{
if (m_frame)
return m_frame->document();
return 0;
}
-const AtomicString& DOMApplicationCache::toEventType(ApplicationCacheHost::EventID id)
+const AtomicString& ApplicationCache::toEventType(ApplicationCacheHost::EventID id)
{
switch (id) {
case ApplicationCacheHost::CHECKING_EVENT:
@@ -127,12 +127,12 @@ const AtomicString& DOMApplicationCache::toEventType(ApplicationCacheHost::Event
return eventNames().errorEvent;
}
-EventTargetData* DOMApplicationCache::eventTargetData()
+EventTargetData* ApplicationCache::eventTargetData()
{
return &m_eventTargetData;
}
-EventTargetData* DOMApplicationCache::ensureEventTargetData()
+EventTargetData* ApplicationCache::ensureEventTargetData()
{
return &m_eventTargetData;
}
« no previous file with comments | « Source/core/loader/appcache/ApplicationCache.h ('k') | Source/core/loader/appcache/ApplicationCache.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698