Source/WebCore: Use a platform strategy for local storage
[WebKit-https.git] / Source / WebKit / qt / WebCoreSupport / PlatformStrategiesQt.cpp
index 07e8460..70c8532 100644 (file)
@@ -65,6 +65,11 @@ CookiesStrategy* PlatformStrategiesQt::createCookiesStrategy()
     return this;
 }
 
+DatabaseStrategy* PlatformStrategiesQt::createDatabaseStrategy()
+{
+    return this;
+}
+
 LoaderStrategy* PlatformStrategiesQt::createLoaderStrategy()
 {
     return this;
@@ -85,58 +90,44 @@ SharedWorkerStrategy* PlatformStrategiesQt::createSharedWorkerStrategy()
     return this;
 }
 
-VisitedLinkStrategy* PlatformStrategiesQt::createVisitedLinkStrategy()
+StorageStrategy* PlatformStrategiesQt::createStorageStrategy()
 {
     return this;
 }
 
-void PlatformStrategiesQt::notifyCookiesChanged()
-{
-}
-
-String PlatformStrategiesQt::cookiesForDOM(NetworkingContext* context, const KURL& firstParty, const KURL& url)
-{
-    return WebCore::cookiesForDOM(context, firstParty, url);
-}
-
-void PlatformStrategiesQt::setCookiesFromDOM(NetworkingContext* context, const KURL& firstParty, const KURL& url, const String& cookieString)
-{
-    WebCore::setCookiesFromDOM(context, firstParty, url, cookieString);
-}
-
-bool PlatformStrategiesQt::cookiesEnabled(NetworkingContext* context, const KURL& firstParty, const KURL& url)
+VisitedLinkStrategy* PlatformStrategiesQt::createVisitedLinkStrategy()
 {
-    return WebCore::cookiesEnabled(context, firstParty, url);
+    return this;
 }
 
-String PlatformStrategiesQt::cookieRequestHeaderFieldValue(NetworkingContext* context, const KURL& firstParty, const KURL& url)
+String PlatformStrategiesQt::cookiesForDOM(const NetworkStorageSession& session, const KURL& firstParty, const KURL& url)
 {
-    return WebCore::cookieRequestHeaderFieldValue(context, firstParty, url);
+    return WebCore::cookiesForDOM(session, firstParty, url);
 }
 
-bool PlatformStrategiesQt::getRawCookies(NetworkingContext* context, const KURL& firstParty, const KURL& url, Vector<Cookie>& rawCookies)
+void PlatformStrategiesQt::setCookiesFromDOM(const NetworkStorageSession& session, const KURL& firstParty, const KURL& url, const String& cookieString)
 {
-    return WebCore::getRawCookies(context, firstParty, url, rawCookies);
+    WebCore::setCookiesFromDOM(session, firstParty, url, cookieString);
 }
 
-void PlatformStrategiesQt::deleteCookie(NetworkingContext* context, const KURL& url, const String& cookieName)
+bool PlatformStrategiesQt::cookiesEnabled(const NetworkStorageSession& session, const KURL& firstParty, const KURL& url)
 {
-    WebCore::deleteCookie(context, url, cookieName);
+    return WebCore::cookiesEnabled(session, firstParty, url);
 }
 
-void PlatformStrategiesQt::getHostnamesWithCookies(NetworkingContext* context, HashSet<String>& hostnames)
+String PlatformStrategiesQt::cookieRequestHeaderFieldValue(const NetworkStorageSession& session, const KURL& firstParty, const KURL& url)
 {
-    WebCore::getHostnamesWithCookies(context, hostnames);
+    return WebCore::cookieRequestHeaderFieldValue(session, firstParty, url);
 }
 
-void PlatformStrategiesQt::deleteCookiesForHostname(NetworkingContext* context, const String& hostname)
+bool PlatformStrategiesQt::getRawCookies(const NetworkStorageSession& session, const KURL& firstParty, const KURL& url, Vector<Cookie>& rawCookies)
 {
-    WebCore::deleteCookiesForHostname(context, hostname);
+    return WebCore::getRawCookies(session, firstParty, url, rawCookies);
 }
 
-void PlatformStrategiesQt::deleteAllCookies(NetworkingContext* context)
+void PlatformStrategiesQt::deleteCookie(const NetworkStorageSession& session, const KURL& url, const String& cookieName)
 {
-    WebCore::deleteAllCookies(context);
+    WebCore::deleteCookie(session, url, cookieName);
 }
 
 void PlatformStrategiesQt::refreshPlugins()