Rename a bunch of API classes and move them to Shared/API
authorandersca@apple.com <andersca@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 22 Dec 2014 19:27:07 +0000 (19:27 +0000)
committerandersca@apple.com <andersca@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 22 Dec 2014 19:27:07 +0000 (19:27 +0000)
https://bugs.webkit.org/show_bug.cgi?id=139866

Reviewed by Sam Weinig.

* Shared/API/APISecurityOrigin.h: Renamed from Source/WebKit2/Shared/WebSecurityOrigin.h.
(API::SecurityOrigin::createFromString):
(API::SecurityOrigin::create):
(API::SecurityOrigin::securityOrigin):
(API::SecurityOrigin::SecurityOrigin):
* Shared/API/APISerializedScriptValue.h: Renamed from Source/WebKit2/Shared/WebSerializedScriptValue.h.
(API::SerializedScriptValue::create):
(API::SerializedScriptValue::adopt):
(API::SerializedScriptValue::deserialize):
(API::SerializedScriptValue::dataReference):
(API::SerializedScriptValue::internalRepresentation):
(API::SerializedScriptValue::SerializedScriptValue):
* Shared/API/APIUserContentURLPattern.h: Renamed from Source/WebKit2/Shared/WebUserContentURLPattern.h.
(API::UserContentURLPattern::create):
(API::UserContentURLPattern::host):
(API::UserContentURLPattern::scheme):
(API::UserContentURLPattern::isValid):
(API::UserContentURLPattern::matchesURL):
(API::UserContentURLPattern::matchesSubdomains):
(API::UserContentURLPattern::patternString):
(API::UserContentURLPattern::UserContentURLPattern):
* Shared/API/c/WKSecurityOrigin.cpp:
(WKSecurityOriginGetTypeID):
(WKSecurityOriginCreateFromString):
(WKSecurityOriginCreateFromDatabaseIdentifier):
(WKSecurityOriginCreate):
* Shared/API/c/WKSerializedScriptValue.cpp:
(WKSerializedScriptValueGetTypeID):
(WKSerializedScriptValueCreate):
(WKSerializedScriptValueCreateWithInternalRepresentation):
* Shared/API/c/WKSharedAPICast.h:
(WebKit::toCopiedAPI):
* Shared/API/c/WKUserContentURLPattern.cpp:
(WKUserContentURLPatternGetTypeID):
(WKUserContentURLPatternCreate):
* Shared/SecurityOriginData.cpp:
(WebKit::performAPICallbackWithSecurityOriginDataVector):
* Shared/UserData.cpp:
(WebKit::UserData::encode):
(WebKit::UserData::decode):
* Shared/UserMessageCoders.h:
(WebKit::UserMessageEncoder::baseEncode):
(WebKit::UserMessageDecoder::baseDecode):
* UIProcess/API/APIUIClient.h:
(API::UIClient::exceededDatabaseQuota):
(API::UIClient::decidePolicyForGeolocationPermissionRequest):
(API::UIClient::decidePolicyForUserMediaPermissionRequest):
(API::UIClient::decidePolicyForNotificationPermissionRequest):
* UIProcess/API/C/WKNotification.cpp:
* UIProcess/API/C/WKPage.cpp:
(WKPageSetPageUIClient):
* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView evaluateJavaScript:completionHandler:]):
* UIProcess/Cocoa/UIDelegate.h:
* UIProcess/Cocoa/UIDelegate.mm:
(WebKit::UIDelegate::UIClient::exceededDatabaseQuota):
* UIProcess/GenericCallback.h:
* UIProcess/Notifications/WebNotification.cpp:
(WebKit::WebNotification::WebNotification):
* UIProcess/Notifications/WebNotification.h:
(WebKit::WebNotification::origin):
* UIProcess/Notifications/WebNotificationManagerProxy.cpp:
(WebKit::WebNotificationManagerProxy::providerDidUpdateNotificationPolicy):
(WebKit::WebNotificationManagerProxy::providerDidRemoveNotificationPolicies):
* UIProcess/Notifications/WebNotificationManagerProxy.h:
* UIProcess/Notifications/WebNotificationProvider.cpp:
* UIProcess/Notifications/WebNotificationProvider.h:
* UIProcess/PageClient.h:
(WebKit::PageClient::decidePolicyForGeolocationPermissionRequest):
* UIProcess/WebApplicationCacheManagerProxy.cpp:
(WebKit::WebApplicationCacheManagerProxy::deleteEntriesForOrigin):
* UIProcess/WebApplicationCacheManagerProxy.h:
* UIProcess/WebCookieManagerProxy.cpp:
* UIProcess/WebDatabaseManagerProxy.cpp:
(WebKit::WebDatabaseManagerProxy::didGetDatabasesByOrigin):
(WebKit::WebDatabaseManagerProxy::didGetDatabaseOrigins):
(WebKit::WebDatabaseManagerProxy::deleteDatabaseWithNameForOrigin):
(WebKit::WebDatabaseManagerProxy::deleteDatabasesForOrigin):
(WebKit::WebDatabaseManagerProxy::setQuotaForOrigin):
(WebKit::WebDatabaseManagerProxy::didModifyOrigin):
(WebKit::WebDatabaseManagerProxy::didModifyDatabase):
* UIProcess/WebDatabaseManagerProxy.h:
* UIProcess/WebDatabaseManagerProxyClient.cpp:
(WebKit::WebDatabaseManagerProxyClient::didModifyOrigin):
(WebKit::WebDatabaseManagerProxyClient::didModifyDatabase):
* UIProcess/WebDatabaseManagerProxyClient.h:
* UIProcess/WebKeyValueStorageManager.cpp:
(WebKit::WebKeyValueStorageManager::getKeyValueStorageOrigins):
(WebKit::WebKeyValueStorageManager::getStorageDetailsByOrigin):
(WebKit::WebKeyValueStorageManager::deleteEntriesForOrigin):
* UIProcess/WebKeyValueStorageManager.h:
* UIProcess/WebMediaCacheManagerProxy.cpp:
* UIProcess/WebOriginDataManagerProxy.cpp:
(WebKit::WebOriginDataManagerProxy::didGetOrigins):
(WebKit::WebOriginDataManagerProxy::deleteEntriesForOrigin):
* UIProcess/WebOriginDataManagerProxy.h:
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::runJavaScriptInMainFrame):
(WebKit::WebPageProxy::scriptValueCallback):
(WebKit::WebPageProxy::exceededDatabaseQuota):
(WebKit::WebPageProxy::requestGeolocationPermissionForFrame):
(WebKit::WebPageProxy::requestUserMediaPermissionForFrame):
(WebKit::WebPageProxy::requestNotificationPermission):
* UIProcess/WebPageProxy.h:
* UIProcess/WebResourceCacheManagerProxy.cpp:
(WebKit::WebResourceCacheManagerProxy::clearCacheForOrigin):
* UIProcess/WebResourceCacheManagerProxy.h:
* UIProcess/ios/PageClientImplIOS.h:
* UIProcess/ios/PageClientImplIOS.mm:
(WebKit::PageClientImpl::decidePolicyForGeolocationPermissionRequest):
* UIProcess/ios/WKContentView.h:
* WebKit2.xcodeproj/project.pbxproj:
* WebProcess/InjectedBundle/API/APIInjectedBundlePageUIClient.h:
(API::InjectedBundle::PageUIClient::didReachApplicationCacheOriginQuota):
(API::InjectedBundle::PageUIClient::didExceedDatabaseQuota):
* WebProcess/InjectedBundle/API/c/WKBundleFrame.cpp:
* WebProcess/InjectedBundle/InjectedBundlePageUIClient.cpp:
(WebKit::InjectedBundlePageUIClient::didReachApplicationCacheOriginQuota):
(WebKit::InjectedBundlePageUIClient::didExceedDatabaseQuota):
* WebProcess/InjectedBundle/InjectedBundlePageUIClient.h:
* WebProcess/WebCoreSupport/WebChromeClient.cpp:
(WebKit::WebChromeClient::exceededDatabaseQuota):
(WebKit::WebChromeClient::reachedApplicationCacheOriginQuota):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@177639 268f45cc-cd09-0410-ab3c-d52691b4dbfc

50 files changed:
Source/WebKit2/ChangeLog
Source/WebKit2/Shared/API/APISecurityOrigin.h [moved from Source/WebKit2/Shared/WebSecurityOrigin.h with 76% similarity]
Source/WebKit2/Shared/API/APISerializedScriptValue.h [moved from Source/WebKit2/Shared/WebSerializedScriptValue.h with 71% similarity]
Source/WebKit2/Shared/API/APIUserContentURLPattern.h [moved from Source/WebKit2/Shared/WebUserContentURLPattern.h with 70% similarity]
Source/WebKit2/Shared/API/c/WKSecurityOrigin.cpp
Source/WebKit2/Shared/API/c/WKSerializedScriptValue.cpp
Source/WebKit2/Shared/API/c/WKSharedAPICast.h
Source/WebKit2/Shared/API/c/WKUserContentURLPattern.cpp
Source/WebKit2/Shared/SecurityOriginData.cpp
Source/WebKit2/Shared/UserData.cpp
Source/WebKit2/Shared/UserMessageCoders.h
Source/WebKit2/UIProcess/API/APIUIClient.h
Source/WebKit2/UIProcess/API/C/WKNotification.cpp
Source/WebKit2/UIProcess/API/C/WKPage.cpp
Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm
Source/WebKit2/UIProcess/Cocoa/UIDelegate.h
Source/WebKit2/UIProcess/Cocoa/UIDelegate.mm
Source/WebKit2/UIProcess/GenericCallback.h
Source/WebKit2/UIProcess/Notifications/WebNotification.cpp
Source/WebKit2/UIProcess/Notifications/WebNotification.h
Source/WebKit2/UIProcess/Notifications/WebNotificationManagerProxy.cpp
Source/WebKit2/UIProcess/Notifications/WebNotificationManagerProxy.h
Source/WebKit2/UIProcess/Notifications/WebNotificationProvider.cpp
Source/WebKit2/UIProcess/Notifications/WebNotificationProvider.h
Source/WebKit2/UIProcess/PageClient.h
Source/WebKit2/UIProcess/WebApplicationCacheManagerProxy.cpp
Source/WebKit2/UIProcess/WebApplicationCacheManagerProxy.h
Source/WebKit2/UIProcess/WebCookieManagerProxy.cpp
Source/WebKit2/UIProcess/WebDatabaseManagerProxy.cpp
Source/WebKit2/UIProcess/WebDatabaseManagerProxy.h
Source/WebKit2/UIProcess/WebDatabaseManagerProxyClient.cpp
Source/WebKit2/UIProcess/WebDatabaseManagerProxyClient.h
Source/WebKit2/UIProcess/WebKeyValueStorageManager.cpp
Source/WebKit2/UIProcess/WebKeyValueStorageManager.h
Source/WebKit2/UIProcess/WebMediaCacheManagerProxy.cpp
Source/WebKit2/UIProcess/WebOriginDataManagerProxy.cpp
Source/WebKit2/UIProcess/WebOriginDataManagerProxy.h
Source/WebKit2/UIProcess/WebPageProxy.cpp
Source/WebKit2/UIProcess/WebPageProxy.h
Source/WebKit2/UIProcess/WebResourceCacheManagerProxy.cpp
Source/WebKit2/UIProcess/WebResourceCacheManagerProxy.h
Source/WebKit2/UIProcess/ios/PageClientImplIOS.h
Source/WebKit2/UIProcess/ios/PageClientImplIOS.mm
Source/WebKit2/UIProcess/ios/WKContentView.h
Source/WebKit2/WebKit2.xcodeproj/project.pbxproj
Source/WebKit2/WebProcess/InjectedBundle/API/APIInjectedBundlePageUIClient.h
Source/WebKit2/WebProcess/InjectedBundle/API/c/WKBundleFrame.cpp
Source/WebKit2/WebProcess/InjectedBundle/InjectedBundlePageUIClient.cpp
Source/WebKit2/WebProcess/InjectedBundle/InjectedBundlePageUIClient.h
Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.cpp

index b53c208..2894c57 100644 (file)
@@ -1,3 +1,134 @@
+2014-12-22  Anders Carlsson  <andersca@apple.com>
+
+        Rename a bunch of API classes and move them to Shared/API
+        https://bugs.webkit.org/show_bug.cgi?id=139866
+
+        Reviewed by Sam Weinig.
+
+        * Shared/API/APISecurityOrigin.h: Renamed from Source/WebKit2/Shared/WebSecurityOrigin.h.
+        (API::SecurityOrigin::createFromString):
+        (API::SecurityOrigin::create):
+        (API::SecurityOrigin::securityOrigin):
+        (API::SecurityOrigin::SecurityOrigin):
+        * Shared/API/APISerializedScriptValue.h: Renamed from Source/WebKit2/Shared/WebSerializedScriptValue.h.
+        (API::SerializedScriptValue::create):
+        (API::SerializedScriptValue::adopt):
+        (API::SerializedScriptValue::deserialize):
+        (API::SerializedScriptValue::dataReference):
+        (API::SerializedScriptValue::internalRepresentation):
+        (API::SerializedScriptValue::SerializedScriptValue):
+        * Shared/API/APIUserContentURLPattern.h: Renamed from Source/WebKit2/Shared/WebUserContentURLPattern.h.
+        (API::UserContentURLPattern::create):
+        (API::UserContentURLPattern::host):
+        (API::UserContentURLPattern::scheme):
+        (API::UserContentURLPattern::isValid):
+        (API::UserContentURLPattern::matchesURL):
+        (API::UserContentURLPattern::matchesSubdomains):
+        (API::UserContentURLPattern::patternString):
+        (API::UserContentURLPattern::UserContentURLPattern):
+        * Shared/API/c/WKSecurityOrigin.cpp:
+        (WKSecurityOriginGetTypeID):
+        (WKSecurityOriginCreateFromString):
+        (WKSecurityOriginCreateFromDatabaseIdentifier):
+        (WKSecurityOriginCreate):
+        * Shared/API/c/WKSerializedScriptValue.cpp:
+        (WKSerializedScriptValueGetTypeID):
+        (WKSerializedScriptValueCreate):
+        (WKSerializedScriptValueCreateWithInternalRepresentation):
+        * Shared/API/c/WKSharedAPICast.h:
+        (WebKit::toCopiedAPI):
+        * Shared/API/c/WKUserContentURLPattern.cpp:
+        (WKUserContentURLPatternGetTypeID):
+        (WKUserContentURLPatternCreate):
+        * Shared/SecurityOriginData.cpp:
+        (WebKit::performAPICallbackWithSecurityOriginDataVector):
+        * Shared/UserData.cpp:
+        (WebKit::UserData::encode):
+        (WebKit::UserData::decode):
+        * Shared/UserMessageCoders.h:
+        (WebKit::UserMessageEncoder::baseEncode):
+        (WebKit::UserMessageDecoder::baseDecode):
+        * UIProcess/API/APIUIClient.h:
+        (API::UIClient::exceededDatabaseQuota):
+        (API::UIClient::decidePolicyForGeolocationPermissionRequest):
+        (API::UIClient::decidePolicyForUserMediaPermissionRequest):
+        (API::UIClient::decidePolicyForNotificationPermissionRequest):
+        * UIProcess/API/C/WKNotification.cpp:
+        * UIProcess/API/C/WKPage.cpp:
+        (WKPageSetPageUIClient):
+        * UIProcess/API/Cocoa/WKWebView.mm:
+        (-[WKWebView evaluateJavaScript:completionHandler:]):
+        * UIProcess/Cocoa/UIDelegate.h:
+        * UIProcess/Cocoa/UIDelegate.mm:
+        (WebKit::UIDelegate::UIClient::exceededDatabaseQuota):
+        * UIProcess/GenericCallback.h:
+        * UIProcess/Notifications/WebNotification.cpp:
+        (WebKit::WebNotification::WebNotification):
+        * UIProcess/Notifications/WebNotification.h:
+        (WebKit::WebNotification::origin):
+        * UIProcess/Notifications/WebNotificationManagerProxy.cpp:
+        (WebKit::WebNotificationManagerProxy::providerDidUpdateNotificationPolicy):
+        (WebKit::WebNotificationManagerProxy::providerDidRemoveNotificationPolicies):
+        * UIProcess/Notifications/WebNotificationManagerProxy.h:
+        * UIProcess/Notifications/WebNotificationProvider.cpp:
+        * UIProcess/Notifications/WebNotificationProvider.h:
+        * UIProcess/PageClient.h:
+        (WebKit::PageClient::decidePolicyForGeolocationPermissionRequest):
+        * UIProcess/WebApplicationCacheManagerProxy.cpp:
+        (WebKit::WebApplicationCacheManagerProxy::deleteEntriesForOrigin):
+        * UIProcess/WebApplicationCacheManagerProxy.h:
+        * UIProcess/WebCookieManagerProxy.cpp:
+        * UIProcess/WebDatabaseManagerProxy.cpp:
+        (WebKit::WebDatabaseManagerProxy::didGetDatabasesByOrigin):
+        (WebKit::WebDatabaseManagerProxy::didGetDatabaseOrigins):
+        (WebKit::WebDatabaseManagerProxy::deleteDatabaseWithNameForOrigin):
+        (WebKit::WebDatabaseManagerProxy::deleteDatabasesForOrigin):
+        (WebKit::WebDatabaseManagerProxy::setQuotaForOrigin):
+        (WebKit::WebDatabaseManagerProxy::didModifyOrigin):
+        (WebKit::WebDatabaseManagerProxy::didModifyDatabase):
+        * UIProcess/WebDatabaseManagerProxy.h:
+        * UIProcess/WebDatabaseManagerProxyClient.cpp:
+        (WebKit::WebDatabaseManagerProxyClient::didModifyOrigin):
+        (WebKit::WebDatabaseManagerProxyClient::didModifyDatabase):
+        * UIProcess/WebDatabaseManagerProxyClient.h:
+        * UIProcess/WebKeyValueStorageManager.cpp:
+        (WebKit::WebKeyValueStorageManager::getKeyValueStorageOrigins):
+        (WebKit::WebKeyValueStorageManager::getStorageDetailsByOrigin):
+        (WebKit::WebKeyValueStorageManager::deleteEntriesForOrigin):
+        * UIProcess/WebKeyValueStorageManager.h:
+        * UIProcess/WebMediaCacheManagerProxy.cpp:
+        * UIProcess/WebOriginDataManagerProxy.cpp:
+        (WebKit::WebOriginDataManagerProxy::didGetOrigins):
+        (WebKit::WebOriginDataManagerProxy::deleteEntriesForOrigin):
+        * UIProcess/WebOriginDataManagerProxy.h:
+        * UIProcess/WebPageProxy.cpp:
+        (WebKit::WebPageProxy::runJavaScriptInMainFrame):
+        (WebKit::WebPageProxy::scriptValueCallback):
+        (WebKit::WebPageProxy::exceededDatabaseQuota):
+        (WebKit::WebPageProxy::requestGeolocationPermissionForFrame):
+        (WebKit::WebPageProxy::requestUserMediaPermissionForFrame):
+        (WebKit::WebPageProxy::requestNotificationPermission):
+        * UIProcess/WebPageProxy.h:
+        * UIProcess/WebResourceCacheManagerProxy.cpp:
+        (WebKit::WebResourceCacheManagerProxy::clearCacheForOrigin):
+        * UIProcess/WebResourceCacheManagerProxy.h:
+        * UIProcess/ios/PageClientImplIOS.h:
+        * UIProcess/ios/PageClientImplIOS.mm:
+        (WebKit::PageClientImpl::decidePolicyForGeolocationPermissionRequest):
+        * UIProcess/ios/WKContentView.h:
+        * WebKit2.xcodeproj/project.pbxproj:
+        * WebProcess/InjectedBundle/API/APIInjectedBundlePageUIClient.h:
+        (API::InjectedBundle::PageUIClient::didReachApplicationCacheOriginQuota):
+        (API::InjectedBundle::PageUIClient::didExceedDatabaseQuota):
+        * WebProcess/InjectedBundle/API/c/WKBundleFrame.cpp:
+        * WebProcess/InjectedBundle/InjectedBundlePageUIClient.cpp:
+        (WebKit::InjectedBundlePageUIClient::didReachApplicationCacheOriginQuota):
+        (WebKit::InjectedBundlePageUIClient::didExceedDatabaseQuota):
+        * WebProcess/InjectedBundle/InjectedBundlePageUIClient.h:
+        * WebProcess/WebCoreSupport/WebChromeClient.cpp:
+        (WebKit::WebChromeClient::exceededDatabaseQuota):
+        (WebKit::WebChromeClient::reachedApplicationCacheOriginQuota):
+
 2014-12-21  Sam Weinig  <sam@webkit.org>
 
         Allow the WebContext's history client to coexist with WKWebView's history delegate
similarity index 76%
rename from Source/WebKit2/Shared/WebSecurityOrigin.h
rename to Source/WebKit2/Shared/API/APISecurityOrigin.h
index 54b7083..c758025 100644 (file)
  * THE POSSIBILITY OF SUCH DAMAGE.
  */
 
-#ifndef WebSecurityOrigin_h
-#define WebSecurityOrigin_h
+#ifndef APISecurityOrigin_h
+#define APISecurityOrigin_h
 
 #include "APIObject.h"
 #include <WebCore/SecurityOrigin.h>
 #include <wtf/PassRefPtr.h>
 
-namespace WebKit {
+namespace API {
 
-class WebSecurityOrigin : public API::ObjectImpl<API::Object::Type::SecurityOrigin> {
+class SecurityOrigin : public API::ObjectImpl<API::Object::Type::SecurityOrigin> {
 public:
-    static PassRefPtr<WebSecurityOrigin> createFromString(const String& string)
+    static PassRefPtr<SecurityOrigin> createFromString(const WTF::String& string)
     {
         return create(WebCore::SecurityOrigin::createFromString(string));
     }
 
-    static PassRefPtr<WebSecurityOrigin> create(const String& protocol, const String& host, int port)
+    static PassRefPtr<SecurityOrigin> create(const WTF::String& protocol, const WTF::String& host, int port)
     {
         return create(WebCore::SecurityOrigin::create(protocol, host, port));
     }
 
-    static PassRefPtr<WebSecurityOrigin> create(PassRefPtr<WebCore::SecurityOrigin> securityOrigin)
+    static PassRefPtr<SecurityOrigin> create(PassRefPtr<WebCore::SecurityOrigin> securityOrigin)
     {
         if (!securityOrigin)
             return 0;
-        return adoptRef(new WebSecurityOrigin(securityOrigin));
+        return adoptRef(new SecurityOrigin(securityOrigin));
     }
 
     WebCore::SecurityOrigin& securityOrigin() const { return *m_securityOrigin; }
 
 private:
-    WebSecurityOrigin(PassRefPtr<WebCore::SecurityOrigin> securityOrigin)
+    SecurityOrigin(PassRefPtr<WebCore::SecurityOrigin> securityOrigin)
         : m_securityOrigin(securityOrigin)
     {
     }
@@ -62,6 +62,6 @@ private:
     RefPtr<WebCore::SecurityOrigin> m_securityOrigin;
 };
 
-} // namespace WebKit
+}
 
 #endif
@@ -23,8 +23,8 @@
  * THE POSSIBILITY OF SUCH DAMAGE.
  */
 
-#ifndef WebSerializedScriptValue_h
-#define WebSerializedScriptValue_h
+#ifndef APISerializedScriptValue_h
+#define APISerializedScriptValue_h
 
 #include "APIObject.h"
 
 #include <WebCore/SerializedScriptValue.h>
 #include <wtf/RefPtr.h>
 
-namespace WebKit {
+namespace API {
 
-class WebSerializedScriptValue : public API::ObjectImpl<API::Object::Type::SerializedScriptValue> {
+class SerializedScriptValue : public API::ObjectImpl<API::Object::Type::SerializedScriptValue> {
 public:
-    static PassRefPtr<WebSerializedScriptValue> create(PassRefPtr<WebCore::SerializedScriptValue> serializedValue)
+    static PassRefPtr<SerializedScriptValue> create(PassRefPtr<WebCore::SerializedScriptValue> serializedValue)
     {
-        return adoptRef(new WebSerializedScriptValue(serializedValue));
+        return adoptRef(new SerializedScriptValue(serializedValue));
     }
     
-    static PassRefPtr<WebSerializedScriptValue> create(JSContextRef context, JSValueRef value, JSValueRef* exception)
+    static PassRefPtr<SerializedScriptValue> create(JSContextRef context, JSValueRef value, JSValueRef* exception)
     {
         RefPtr<WebCore::SerializedScriptValue> serializedValue = WebCore::SerializedScriptValue::create(context, value, exception);
         if (!serializedValue)
             return 0;
-        return adoptRef(new WebSerializedScriptValue(serializedValue.get()));
+        return adoptRef(new SerializedScriptValue(serializedValue.get()));
     }
     
-    static PassRefPtr<WebSerializedScriptValue> adopt(Vector<uint8_t>& buffer)
+    static PassRefPtr<SerializedScriptValue> adopt(Vector<uint8_t>& buffer)
     {
-        return adoptRef(new WebSerializedScriptValue(WebCore::SerializedScriptValue::adopt(buffer)));
+        return adoptRef(new SerializedScriptValue(WebCore::SerializedScriptValue::adopt(buffer)));
     }
     
     JSValueRef deserialize(JSContextRef context, JSValueRef* exception)
@@ -64,7 +64,7 @@ public:
     void* internalRepresentation() { return m_serializedScriptValue.get(); }
 
 private:
-    explicit WebSerializedScriptValue(PassRefPtr<WebCore::SerializedScriptValue> serializedScriptValue)
+    explicit SerializedScriptValue(PassRefPtr<WebCore::SerializedScriptValue> serializedScriptValue)
         : m_serializedScriptValue(serializedScriptValue)
     {
     }
@@ -74,4 +74,4 @@ private:
     
 }
 
-#endif // WebSerializedScriptValue_h
+#endif
@@ -23,8 +23,8 @@
  * THE POSSIBILITY OF SUCH DAMAGE.
  */
 
-#ifndef WebUserContentURLPattern_h
-#define WebUserContentURLPattern_h
+#ifndef APIUserContentURLPattern_h
+#define APIUserContentURLPattern_h
 
 #include "APIObject.h"
 
 #include <WebCore/UserContentURLPattern.h>
 #include <wtf/RefPtr.h>
 
-namespace WebKit {
+namespace API {
 
-class WebUserContentURLPattern : public API::ObjectImpl<API::Object::Type::UserContentURLPattern> {
+class UserContentURLPattern : public API::ObjectImpl<API::Object::Type::UserContentURLPattern> {
 public:
-    static PassRefPtr<WebUserContentURLPattern> create(const String& pattern)
+    static PassRefPtr<UserContentURLPattern> create(const WTF::String& pattern)
     {
-        return adoptRef(new WebUserContentURLPattern(pattern));
+        return adoptRef(new UserContentURLPattern(pattern));
     }
 
-    const String& host() const { return m_pattern.host(); }
-    const String& scheme() const { return m_pattern.scheme(); }
+    const WTF::String& host() const { return m_pattern.host(); }
+    const WTF::String& scheme() const { return m_pattern.scheme(); }
     bool isValid() const { return m_pattern.isValid(); };
-    bool matchesURL(const String& url) const { return m_pattern.matches(WebCore::URL(WebCore::ParsedURLString, url)); }
+    bool matchesURL(const WTF::String& url) const { return m_pattern.matches(WebCore::URL(WebCore::ParsedURLString, url)); }
     bool matchesSubdomains() const { return m_pattern.matchSubdomains(); }
 
-    const String& patternString() const { return m_patternString; }
+    const WTF::String& patternString() const { return m_patternString; }
 
 private:
-    explicit WebUserContentURLPattern(const String& pattern)
+    explicit UserContentURLPattern(const WTF::String& pattern)
         : m_pattern(WebCore::UserContentURLPattern(pattern))
         , m_patternString(pattern)
     {
     }
 
     WebCore::UserContentURLPattern m_pattern;
-    String m_patternString;
+    WTF::String m_patternString;
 };
 
 }
 
-#endif // WebUserContentURLPattern_h
+#endif
index fce590f..6ffaf07 100644 (file)
 #include "config.h"
 #include "WKSecurityOrigin.h"
 
+#include "APISecurityOrigin.h"
 #include "WKAPICast.h"
-#include "WebSecurityOrigin.h"
 
 using namespace WebKit;
 
 WKTypeID WKSecurityOriginGetTypeID()
 {
-    return toAPI(WebSecurityOrigin::APIType);
+    return toAPI(API::SecurityOrigin::APIType);
 }
 
 WKSecurityOriginRef WKSecurityOriginCreateFromString(WKStringRef string)
 {
-    return toAPI(WebSecurityOrigin::create(WebCore::SecurityOrigin::createFromString(toImpl(string)->string())).leakRef());
+    return toAPI(API::SecurityOrigin::create(WebCore::SecurityOrigin::createFromString(toImpl(string)->string())).leakRef());
 }
 
 WKSecurityOriginRef WKSecurityOriginCreateFromDatabaseIdentifier(WKStringRef identifier)
 {
-    return toAPI(WebSecurityOrigin::create(WebCore::SecurityOrigin::createFromDatabaseIdentifier((toImpl(identifier)->string()))).leakRef());
+    return toAPI(API::SecurityOrigin::create(WebCore::SecurityOrigin::createFromDatabaseIdentifier((toImpl(identifier)->string()))).leakRef());
 }
 
 WKSecurityOriginRef WKSecurityOriginCreate(WKStringRef protocol, WKStringRef host, int port)
 {
-    RefPtr<WebSecurityOrigin> securityOrigin = WebSecurityOrigin::create(toImpl(protocol)->string(), toImpl(host)->string(), port);
+    RefPtr<API::SecurityOrigin> securityOrigin = API::SecurityOrigin::create(toImpl(protocol)->string(), toImpl(host)->string(), port);
     return toAPI(securityOrigin.release().leakRef());
 }
 
index f45c388..ec2ad96 100644 (file)
 #include "WKSerializedScriptValue.h"
 #include "WKSerializedScriptValuePrivate.h"
 
+#include "APISerializedScriptValue.h"
 #include "WKAPICast.h"
-#include "WebSerializedScriptValue.h"
 
 using namespace WebKit;
 
 WKTypeID WKSerializedScriptValueGetTypeID()
 {
-    return toAPI(WebSerializedScriptValue::APIType);
+    return toAPI(API::SerializedScriptValue::APIType);
 }
 
 WKSerializedScriptValueRef WKSerializedScriptValueCreate(JSContextRef context, JSValueRef value, JSValueRef* exception)
 {
-    RefPtr<WebSerializedScriptValue> serializedValue = WebSerializedScriptValue::create(context, value, exception);
+    RefPtr<API::SerializedScriptValue> serializedValue = API::SerializedScriptValue::create(context, value, exception);
     return toAPI(serializedValue.release().leakRef());
 }
 
 WKSerializedScriptValueRef WKSerializedScriptValueCreateWithInternalRepresentation(void* internalRepresentation)
 {
-    RefPtr<WebSerializedScriptValue> serializedValue = WebSerializedScriptValue::create(static_cast<WebCore::SerializedScriptValue*>(internalRepresentation));
+    RefPtr<API::SerializedScriptValue> serializedValue = API::SerializedScriptValue::create(static_cast<WebCore::SerializedScriptValue*>(internalRepresentation));
     return toAPI(serializedValue.release().leakRef());
 }
 
index 5a665a3..657853c 100644 (file)
@@ -28,6 +28,7 @@
 
 #include "APIError.h"
 #include "APINumber.h"
+#include "APISecurityOrigin.h"
 #include "APISession.h"
 #include "APIString.h"
 #include "APIURL.h"
@@ -48,7 +49,6 @@
 #include "WKUserScriptInjectionTime.h"
 #include "WebEvent.h"
 #include "WebFindOptions.h"
-#include "WebSecurityOrigin.h"
 #include <WebCore/ContextMenuItem.h>
 #include <WebCore/FloatRect.h>
 #include <WebCore/FrameLoaderTypes.h>
@@ -64,7 +64,10 @@ class Array;
 class Data;
 class Point;
 class Rect;
+class SecurityOrigin;
+class SerializedScriptValue;
 class Size;
+class UserContentURLPattern;
 class WebArchive;
 class WebArchiveResource;
 }
@@ -79,9 +82,6 @@ class WebConnection;
 class WebContextMenuItem;
 class WebGraphicsContext;
 class WebImage;
-class WebSecurityOrigin;
-class WebSerializedScriptValue;
-class WebUserContentURLPattern;
 
 template<typename APIType> struct APITypeInfo { };
 template<typename ImplType> struct ImplTypeInfo { };
@@ -104,8 +104,8 @@ WK_ADD_API_MAPPING(WKImageRef, WebImage)
 WK_ADD_API_MAPPING(WKMutableDictionaryRef, MutableDictionary)
 WK_ADD_API_MAPPING(WKPointRef, API::Point)
 WK_ADD_API_MAPPING(WKRectRef, API::Rect)
-WK_ADD_API_MAPPING(WKSecurityOriginRef, WebSecurityOrigin)
-WK_ADD_API_MAPPING(WKSerializedScriptValueRef, WebSerializedScriptValue)
+WK_ADD_API_MAPPING(WKSecurityOriginRef, API::SecurityOrigin)
+WK_ADD_API_MAPPING(WKSerializedScriptValueRef, API::SerializedScriptValue)
 WK_ADD_API_MAPPING(WKSizeRef, API::Size)
 WK_ADD_API_MAPPING(WKStringRef, API::String)
 WK_ADD_API_MAPPING(WKTypeRef, API::Object)
@@ -113,7 +113,7 @@ WK_ADD_API_MAPPING(WKUInt64Ref, API::UInt64)
 WK_ADD_API_MAPPING(WKURLRef, API::URL)
 WK_ADD_API_MAPPING(WKURLRequestRef, API::URLRequest)
 WK_ADD_API_MAPPING(WKURLResponseRef, API::URLResponse)
-WK_ADD_API_MAPPING(WKUserContentURLPatternRef, WebUserContentURLPattern)
+WK_ADD_API_MAPPING(WKUserContentURLPatternRef, API::UserContentURLPattern)
 WK_ADD_API_MAPPING(WKSessionRef, API::Session)
 
 template<> struct APITypeInfo<WKMutableArrayRef> { typedef API::Array* ImplType; };
@@ -219,7 +219,7 @@ inline WKSecurityOriginRef toCopiedAPI(WebCore::SecurityOrigin* origin)
 {
     if (!origin)
         return 0;
-    return toAPI(WebSecurityOrigin::create(origin).leakRef());
+    return toAPI(API::SecurityOrigin::create(origin).leakRef());
 }
 
 /* Geometry conversions */
index f6a204a..9f9b836 100644 (file)
 #include "config.h"
 #include "WKUserContentURLPattern.h"
 
+#include "APIUserContentURLPattern.h"
 #include "WKAPICast.h"
 #include "WKString.h"
-#include "WebUserContentURLPattern.h"
 
 using namespace WebKit;
 
 WKTypeID WKUserContentURLPatternGetTypeID()
 {
-    return toAPI(WebUserContentURLPattern::APIType);
+    return toAPI(API::UserContentURLPattern::APIType);
 }
 
 WKUserContentURLPatternRef WKUserContentURLPatternCreate(WKStringRef patternRef)
 {
-    RefPtr<WebUserContentURLPattern> userContentURLPattern = WebUserContentURLPattern::create(toImpl(patternRef)->string());
+    RefPtr<API::UserContentURLPattern> userContentURLPattern = API::UserContentURLPattern::create(toImpl(patternRef)->string());
     return toAPI(userContentURLPattern.release().leakRef());
 }
 
index 27322a8..28a7949 100644 (file)
@@ -28,7 +28,7 @@
 
 #include "APIArray.h"
 #include "WebCoreArgumentCoders.h"
-#include "WebSecurityOrigin.h"
+#include "APISecurityOrigin.h"
 #include <wtf/text/CString.h>
 
 using namespace WebCore;
@@ -92,7 +92,7 @@ void performAPICallbackWithSecurityOriginDataVector(const Vector<SecurityOriginD
     securityOrigins.reserveInitialCapacity(originDatas.size());
 
     for (const auto& originData : originDatas) {
-        RefPtr<API::Object> origin = WebSecurityOrigin::create(originData.protocol, originData.host, originData.port);
+        RefPtr<API::Object> origin = API::SecurityOrigin::create(originData.protocol, originData.host, originData.port);
         if (!origin)
             continue;
         securityOrigins.uncheckedAppend(WTF::move(origin));
index 0ae56e1..fec1fd7 100644 (file)
@@ -32,6 +32,7 @@
 #include "APIFrameHandle.h"
 #include "APIGeometry.h"
 #include "APINumber.h"
+#include "APISerializedScriptValue.h"
 #include "APIString.h"
 #include "APIURL.h"
 #include "APIURLRequest.h"
@@ -39,7 +40,6 @@
 #include "ArgumentCoders.h"
 #include "ArgumentEncoder.h"
 #include "MutableDictionary.h"
-#include "WebSerializedScriptValue.h"
 
 namespace WebKit {
 
@@ -161,7 +161,7 @@ void UserData::encode(IPC::ArgumentEncoder& encoder, const API::Object& object)
         break;
 
     case API::Object::Type::SerializedScriptValue: {
-        auto& serializedScriptValue = static_cast<const WebSerializedScriptValue&>(object);
+        auto& serializedScriptValue = static_cast<const API::SerializedScriptValue&>(object);
         encoder << serializedScriptValue.dataReference();
         break;
     }
@@ -295,7 +295,7 @@ bool UserData::decode(IPC::ArgumentDecoder& decoder, RefPtr<API::Object>& result
             return false;
 
         auto vector = dataReference.vector();
-        result = WebSerializedScriptValue::adopt(vector);
+        result = API::SerializedScriptValue::adopt(vector);
         break;
     }
 
index 2451ee1..c43ea6d 100644 (file)
 #include "APIError.h"
 #include "APIGeometry.h"
 #include "APINumber.h"
+#include "APISerializedScriptValue.h"
 #include "APIString.h"
 #include "APIURL.h"
 #include "APIURLRequest.h"
 #include "APIURLResponse.h"
+#include "APIUserContentURLPattern.h"
 #include "ArgumentDecoder.h"
 #include "ArgumentEncoder.h"
 #include "DataReference.h"
@@ -45,8 +47,6 @@
 #include "WebImage.h"
 #include "WebRenderLayer.h"
 #include "WebRenderObject.h"
-#include "WebSerializedScriptValue.h"
-#include "WebUserContentURLPattern.h"
 
 namespace WebKit {
 
@@ -108,7 +108,7 @@ public:
             return true;
         }
         case API::Object::Type::SerializedScriptValue: {
-            WebSerializedScriptValue* scriptValue = static_cast<WebSerializedScriptValue*>(m_root);
+            API::SerializedScriptValue* scriptValue = static_cast<API::SerializedScriptValue*>(m_root);
             encoder << scriptValue->dataReference();
             return true;
         }
@@ -191,7 +191,7 @@ public:
             return true;
         }
         case API::Object::Type::UserContentURLPattern: {
-            WebUserContentURLPattern* urlPattern = static_cast<WebUserContentURLPattern*>(m_root);
+            API::UserContentURLPattern* urlPattern = static_cast<API::UserContentURLPattern*>(m_root);
             encoder << urlPattern->patternString();
             return true;
         }
@@ -327,7 +327,7 @@ public:
                 return false;
             
             Vector<uint8_t> vector = dataReference.vector();
-            coder.m_root = WebSerializedScriptValue::adopt(vector);
+            coder.m_root = API::SerializedScriptValue::adopt(vector);
             break;
         }
         case API::Object::Type::Double: {
@@ -497,7 +497,7 @@ public:
             String string;
             if (!decoder.decode(string))
                 return false;
-            coder.m_root = WebUserContentURLPattern::create(string);
+            coder.m_root = API::UserContentURLPattern::create(string);
             break;
         }
         case API::Object::Type::Image: {
index c84d67a..2a0f912 100644 (file)
@@ -56,7 +56,6 @@ class WebFrameProxy;
 class WebOpenPanelParameters;
 class WebOpenPanelResultListenerProxy;
 class WebPageProxy;
-class WebSecurityOrigin;
 struct NavigationActionData;
 }
 
@@ -64,6 +63,7 @@ namespace API {
 
 class Data;
 class Object;
+class SecurityOrigin;
 
 class UIClient {
 public:
@@ -114,7 +114,7 @@ public:
     virtual void didDraw(WebKit::WebPageProxy*) { }
     virtual void pageDidScroll(WebKit::WebPageProxy*) { }
 
-    virtual void exceededDatabaseQuota(WebKit::WebPageProxy*, WebKit::WebFrameProxy*, WebKit::WebSecurityOrigin*, const WTF::String&, const WTF::String&, unsigned long long currentQuota, unsigned long long, unsigned long long, unsigned long long, std::function<void (unsigned long long)> completionHandler)
+    virtual void exceededDatabaseQuota(WebKit::WebPageProxy*, WebKit::WebFrameProxy*, SecurityOrigin*, const WTF::String&, const WTF::String&, unsigned long long currentQuota, unsigned long long, unsigned long long, unsigned long long, std::function<void (unsigned long long)> completionHandler)
     {
         completionHandler(currentQuota);
     }
@@ -125,9 +125,9 @@ public:
     }
 
     virtual bool runOpenPanel(WebKit::WebPageProxy*, WebKit::WebFrameProxy*, WebKit::WebOpenPanelParameters*, WebKit::WebOpenPanelResultListenerProxy*) { return false; }
-    virtual bool decidePolicyForGeolocationPermissionRequest(WebKit::WebPageProxy*, WebKit::WebFrameProxy*, WebKit::WebSecurityOrigin*, WebKit::GeolocationPermissionRequestProxy*) { return false; }
-    virtual bool decidePolicyForUserMediaPermissionRequest(WebKit::WebPageProxy&, WebKit::WebFrameProxy&, WebKit::WebSecurityOrigin&, WebKit::UserMediaPermissionRequestProxy&) { return false; }
-    virtual bool decidePolicyForNotificationPermissionRequest(WebKit::WebPageProxy*, WebKit::WebSecurityOrigin*, WebKit::NotificationPermissionRequest*) { return false; }
+    virtual bool decidePolicyForGeolocationPermissionRequest(WebKit::WebPageProxy*, WebKit::WebFrameProxy*, SecurityOrigin*, WebKit::GeolocationPermissionRequestProxy*) { return false; }
+    virtual bool decidePolicyForUserMediaPermissionRequest(WebKit::WebPageProxy&, WebKit::WebFrameProxy&, SecurityOrigin&, WebKit::UserMediaPermissionRequestProxy&) { return false; }
+    virtual bool decidePolicyForNotificationPermissionRequest(WebKit::WebPageProxy*, SecurityOrigin*, WebKit::NotificationPermissionRequest*) { return false; }
 
     // Printing.
     virtual float headerHeight(WebKit::WebPageProxy*, WebKit::WebFrameProxy*) { return 0; }
index 78b09e0..3d18057 100644 (file)
@@ -26,9 +26,9 @@
 #include "config.h"
 #include "WKNotification.h"
 
+#include "APISecurityOrigin.h"
 #include "WKAPICast.h"
 #include "WebNotification.h"
-#include "WebSecurityOrigin.h"
 
 using namespace WebKit;
 
index f8110d3..38f0ac7 100644 (file)
@@ -1477,7 +1477,7 @@ void WKPageSetPageUIClient(WKPageRef pageRef, const WKPageUIClientBase* wkClient
             m_client.pageDidScroll(toAPI(page), m_client.base.clientInfo);
         }
 
-        virtual void exceededDatabaseQuota(WebPageProxy* page, WebFrameProxy* frame, WebSecurityOrigin* origin, const String& databaseName, const String& databaseDisplayName, unsigned long long currentQuota, unsigned long long currentOriginUsage, unsigned long long currentDatabaseUsage, unsigned long long expectedUsage, std::function<void (unsigned long long)> completionHandler) override
+        virtual void exceededDatabaseQuota(WebPageProxy* page, WebFrameProxy* frame, API::SecurityOrigin* origin, const String& databaseName, const String& databaseDisplayName, unsigned long long currentQuota, unsigned long long currentOriginUsage, unsigned long long currentDatabaseUsage, unsigned long long expectedUsage, std::function<void (unsigned long long)> completionHandler) override
         {
             if (!m_client.exceededDatabaseQuota) {
                 completionHandler(currentQuota);
@@ -1496,7 +1496,7 @@ void WKPageSetPageUIClient(WKPageRef pageRef, const WKPageUIClientBase* wkClient
             return true;
         }
 
-        virtual bool decidePolicyForGeolocationPermissionRequest(WebPageProxy* page, WebFrameProxy* frame, WebSecurityOrigin* origin, GeolocationPermissionRequestProxy* permissionRequest) override
+        virtual bool decidePolicyForGeolocationPermissionRequest(WebPageProxy* page, WebFrameProxy* frame, API::SecurityOrigin* origin, GeolocationPermissionRequestProxy* permissionRequest) override
         {
             if (!m_client.decidePolicyForGeolocationPermissionRequest)
                 return false;
@@ -1505,7 +1505,7 @@ void WKPageSetPageUIClient(WKPageRef pageRef, const WKPageUIClientBase* wkClient
             return true;
         }
 
-        virtual bool decidePolicyForUserMediaPermissionRequest(WebPageProxy& page, WebFrameProxy& frame, WebSecurityOrigin& origin, UserMediaPermissionRequestProxy& permissionRequest) override
+        virtual bool decidePolicyForUserMediaPermissionRequest(WebPageProxy& page, WebFrameProxy& frame, API::SecurityOrigin& origin, UserMediaPermissionRequestProxy& permissionRequest) override
         {
             if (!m_client.decidePolicyForUserMediaPermissionRequest)
                 return false;
@@ -1514,7 +1514,7 @@ void WKPageSetPageUIClient(WKPageRef pageRef, const WKPageUIClientBase* wkClient
             return true;
         }
 
-        virtual bool decidePolicyForNotificationPermissionRequest(WebPageProxy* page, WebSecurityOrigin* origin, NotificationPermissionRequest* permissionRequest) override
+        virtual bool decidePolicyForNotificationPermissionRequest(WebPageProxy* page, API::SecurityOrigin* origin, NotificationPermissionRequest* permissionRequest) override
         {
             if (!m_client.decidePolicyForNotificationPermissionRequest)
                 return false;
index cb17d95..f729b53 100644 (file)
@@ -29,6 +29,7 @@
 #if WK_API_ENABLED
 
 #import "APIFormClient.h"
+#import "APISerializedScriptValue.h"
 #import "CompletionHandlerCallChecker.h"
 #import "FindClient.h"
 #import "LegacySessionStateCoding.h"
@@ -65,7 +66,6 @@
 #import "WebPageProxy.h"
 #import "WebPreferencesKeys.h"
 #import "WebProcessProxy.h"
-#import "WebSerializedScriptValue.h"
 #import "_WKFindDelegate.h"
 #import "_WKFormDelegate.h"
 #import "_WKRemoteObjectRegistryInternal.h"
@@ -583,7 +583,7 @@ static WKErrorCode callbackErrorCode(WebKit::CallbackBase::Error error)
 {
     auto handler = adoptNS([completionHandler copy]);
 
-    _page->runJavaScriptInMainFrame(javaScriptString, [handler](WebKit::WebSerializedScriptValue* serializedScriptValue, WebKit::ScriptValueCallback::Error errorCode) {
+    _page->runJavaScriptInMainFrame(javaScriptString, [handler](API::SerializedScriptValue* serializedScriptValue, WebKit::ScriptValueCallback::Error errorCode) {
         if (!handler)
             return;
 
index 0916625..637baf0 100644 (file)
@@ -66,7 +66,7 @@ private:
         virtual void runJavaScriptAlert(WebKit::WebPageProxy*, const WTF::String&, WebKit::WebFrameProxy*, std::function<void ()> completionHandler) override;
         virtual void runJavaScriptConfirm(WebKit::WebPageProxy*, const WTF::String&, WebKit::WebFrameProxy*, std::function<void (bool)> completionHandler) override;
         virtual void runJavaScriptPrompt(WebKit::WebPageProxy*, const WTF::String&, const WTF::String&, WebKit::WebFrameProxy*, std::function<void (const WTF::String&)> completionHandler) override;
-        virtual void exceededDatabaseQuota(WebPageProxy*, WebFrameProxy*, WebSecurityOrigin*, const WTF::String& databaseName, const WTF::String& displayName, unsigned long long currentQuota, unsigned long long currentOriginUsage, unsigned long long currentUsage, unsigned long long expectedUsage, std::function<void (unsigned long long)>) override;
+        virtual void exceededDatabaseQuota(WebPageProxy*, WebFrameProxy*, API::SecurityOrigin*, const WTF::String& databaseName, const WTF::String& displayName, unsigned long long currentQuota, unsigned long long currentOriginUsage, unsigned long long currentUsage, unsigned long long expectedUsage, std::function<void (unsigned long long)>) override;
         virtual void reachedApplicationCacheOriginQuota(WebPageProxy*, const WebCore::SecurityOrigin&, uint64_t currentQuota, uint64_t totalBytesNeeded, std::function<void (unsigned long long)> completionHandler) override;
         virtual void printFrame(WebKit::WebPageProxy*, WebKit::WebFrameProxy*) override;
     #if PLATFORM(IOS)
index af7a198..88bfea7 100644 (file)
@@ -178,7 +178,7 @@ void UIDelegate::UIClient::runJavaScriptPrompt(WebKit::WebPageProxy*, const WTF:
     }];
 }
 
-void UIDelegate::UIClient::exceededDatabaseQuota(WebPageProxy*, WebFrameProxy*, WebSecurityOrigin* securityOrigin, const WTF::String& databaseName, const WTF::String& displayName, unsigned long long currentQuota, unsigned long long currentOriginUsage, unsigned long long currentUsage, unsigned long long expectedUsage, std::function<void (unsigned long long)> completionHandler)
+void UIDelegate::UIClient::exceededDatabaseQuota(WebPageProxy*, WebFrameProxy*, API::SecurityOrigin* securityOrigin, const WTF::String& databaseName, const WTF::String& displayName, unsigned long long currentQuota, unsigned long long currentOriginUsage, unsigned long long currentUsage, unsigned long long expectedUsage, std::function<void (unsigned long long)> completionHandler)
 {
     if (!m_uiDelegate.m_delegateMethods.webViewDecideDatabaseQuotaForSecurityOriginCurrentQuotaCurrentOriginUsageCurrentDatabaseUsageExpectedUsageDecisionHandler) {
         completionHandler(currentQuota);
index 847a068..fefccc3 100644 (file)
 #define GenericCallback_h
 
 #include "APIError.h"
+#include "APISerializedScriptValue.h"
 #include "ProcessThrottler.h"
 #include "ShareableBitmap.h"
 #include "WKAPICast.h"
-#include "WebSerializedScriptValue.h"
 #include <functional>
 #include <wtf/HashMap.h>
 #include <wtf/PassRefPtr.h>
index 3705fb0..3d7bc00 100644 (file)
@@ -40,7 +40,7 @@ WebNotification::WebNotification(const String& title, const String& body, const
     , m_tag(tag)
     , m_lang(lang)
     , m_dir(dir)
-    , m_origin(WebSecurityOrigin::createFromString(originString))
+    , m_origin(API::SecurityOrigin::createFromString(originString))
     , m_notificationID(notificationID)
 {
 }
index 3682b4f..ea981d2 100644 (file)
@@ -27,7 +27,7 @@
 #define WebNotification_h
 
 #include "APIObject.h"
-#include "WebSecurityOrigin.h"
+#include "APISecurityOrigin.h"
 #include <wtf/PassRefPtr.h>
 #include <wtf/RefPtr.h>
 #include <wtf/text/WTFString.h>
@@ -54,7 +54,7 @@ public:
     const String& tag() const { return m_tag; }
     const String& lang() const { return m_lang; }
     const String& dir() const { return m_dir; }
-    WebSecurityOrigin* origin() const { return m_origin.get(); }
+    API::SecurityOrigin* origin() const { return m_origin.get(); }
     
     uint64_t notificationID() const { return m_notificationID; }
 
@@ -67,7 +67,7 @@ private:
     String m_tag;
     String m_lang;
     String m_dir;
-    RefPtr<WebSecurityOrigin> m_origin;
+    RefPtr<API::SecurityOrigin> m_origin;
     uint64_t m_notificationID;
 };
 
index 0034265..d8071a9 100644 (file)
 #include "WebNotificationManagerProxy.h"
 
 #include "APIArray.h"
+#include "APISecurityOrigin.h"
 #include "ImmutableDictionary.h"
 #include "WebContext.h"
 #include "WebNotification.h"
 #include "WebNotificationManagerMessages.h"
 #include "WebPageProxy.h"
 #include "WebProcessProxy.h"
-#include "WebSecurityOrigin.h"
 
-using namespace std;
-using namespace WTF;
 using namespace WebCore;
 
 namespace WebKit {
@@ -232,7 +230,7 @@ void WebNotificationManagerProxy::providerDidCloseNotifications(API::Array* glob
         it->key->process().send(Messages::WebNotificationManager::DidCloseNotifications(it->value), 0);
 }
 
-void WebNotificationManagerProxy::providerDidUpdateNotificationPolicy(const WebSecurityOrigin* origin, bool allowed)
+void WebNotificationManagerProxy::providerDidUpdateNotificationPolicy(const API::SecurityOrigin* origin, bool allowed)
 {
     if (!context())
         return;
@@ -253,7 +251,7 @@ void WebNotificationManagerProxy::providerDidRemoveNotificationPolicies(API::Arr
     originStrings.reserveInitialCapacity(size);
     
     for (size_t i = 0; i < size; ++i)
-        originStrings.append(origins->at<WebSecurityOrigin>(i)->securityOrigin().toString());
+        originStrings.append(origins->at<API::SecurityOrigin>(i)->securityOrigin().toString());
     
     context()->sendToAllProcesses(Messages::WebNotificationManager::DidRemoveNotificationDecisions(originStrings));
 }
index a835b37..d793388 100644 (file)
 
 namespace API {
 class Array;
+class SecurityOrigin;
 }
 
 namespace WebKit {
 
 class WebContext;
 class WebPageProxy;
-class WebSecurityOrigin;
 
 class WebNotificationManagerProxy : public API::ObjectImpl<API::Object::Type::NotificationManager>, public WebContextSupplement {
 public:
@@ -64,7 +64,7 @@ public:
     void providerDidShowNotification(uint64_t notificationID);
     void providerDidClickNotification(uint64_t notificationID);
     void providerDidCloseNotifications(API::Array* notificationIDs);
-    void providerDidUpdateNotificationPolicy(const WebSecurityOrigin*, bool allowed);
+    void providerDidUpdateNotificationPolicy(const API::SecurityOrigin*, bool allowed);
     void providerDidRemoveNotificationPolicies(API::Array* origins);
 
     using API::Object::ref;
index 41d8d5b..59c4c1c 100644 (file)
 
 #include "APIArray.h"
 #include "APINumber.h"
+#include "APISecurityOrigin.h"
 #include "ImmutableDictionary.h"
 #include "WKAPICast.h"
 #include "WebNotification.h"
 #include "WebNotificationManagerProxy.h"
 #include "WebPageProxy.h"
-#include "WebSecurityOrigin.h"
 
 namespace WebKit {
 
index b48d433..5ce8d51 100644 (file)
@@ -43,7 +43,6 @@ class ImmutableDictionary;
 class WebNotification;
 class WebNotificationManagerProxy;
 class WebPageProxy;
-class WebSecurityOrigin;
     
 class WebNotificationProvider : public API::Client<WKNotificationProviderBase> {
 public:
index f3c5376..67cb27e 100644 (file)
@@ -131,7 +131,7 @@ public:
 
     virtual void toolTipChanged(const String&, const String&) = 0;
 
-    virtual bool decidePolicyForGeolocationPermissionRequest(WebFrameProxy&, WebSecurityOrigin&, GeolocationPermissionRequestProxy&)
+    virtual bool decidePolicyForGeolocationPermissionRequest(WebFrameProxy&, API::SecurityOrigin&, GeolocationPermissionRequestProxy&)
     {
         return false;
     }
index ba7ba95..6229d63 100644 (file)
 #include "config.h"
 #include "WebApplicationCacheManagerProxy.h"
 
+#include "APISecurityOrigin.h"
 #include "SecurityOriginData.h"
 #include "WebApplicationCacheManagerMessages.h"
 #include "WebApplicationCacheManagerProxyMessages.h"
 #include "WebContext.h"
-#include "WebSecurityOrigin.h"
 
 namespace WebKit {
 
@@ -102,7 +102,7 @@ void WebApplicationCacheManagerProxy::didGetApplicationCacheOrigins(const Vector
     performAPICallbackWithSecurityOriginDataVector(originDatas, callback.get());
 }
 
-void WebApplicationCacheManagerProxy::deleteEntriesForOrigin(WebSecurityOrigin* origin)
+void WebApplicationCacheManagerProxy::deleteEntriesForOrigin(API::SecurityOrigin* origin)
 {
     if (!context())
         return;
index 581aed1..e1f6466 100644 (file)
 #include <wtf/Vector.h>
 
 namespace IPC {
-    class Connection;
+class Connection;
 }
 
 namespace WebKit {
 
-class WebSecurityOrigin;
 struct SecurityOriginData;
 
 typedef GenericCallback<API::Array*> ArrayCallback;
@@ -53,7 +52,7 @@ public:
     virtual ~WebApplicationCacheManagerProxy();
 
     void getApplicationCacheOrigins(std::function<void (API::Array*, CallbackBase::Error)>);
-    void deleteEntriesForOrigin(WebSecurityOrigin*);
+    void deleteEntriesForOrigin(API::SecurityOrigin*);
     void deleteAllEntries();
 
     using API::Object::ref;
index 7c819ea..36318ba 100644 (file)
 #include "WebCookieManagerProxy.h"
 
 #include "APIArray.h"
+#include "APISecurityOrigin.h"
 #include "SecurityOriginData.h"
 #include "WebContext.h"
 #include "WebCookieManagerMessages.h"
 #include "WebCookieManagerProxyMessages.h"
-#include "WebSecurityOrigin.h"
 
 namespace WebKit {
 
index 5953a23..19ff33b 100644 (file)
 #if ENABLE(SQL_DATABASE)
 
 #include "APIArray.h"
+#include "APISecurityOrigin.h"
 #include "ImmutableDictionary.h"
 #include "WebContext.h"
 #include "WebDatabaseManagerMessages.h"
 #include "WebDatabaseManagerProxyMessages.h"
-#include "WebSecurityOrigin.h"
 #include <wtf/NeverDestroyed.h>
 
 using namespace WebCore;
@@ -173,7 +173,7 @@ void WebDatabaseManagerProxy::didGetDatabasesByOrigin(const Vector<OriginAndData
     result.reserveInitialCapacity(originAndDatabasesVector.size());
 
     for (const auto& originAndDatabases : originAndDatabasesVector) {
-        RefPtr<API::Object> origin = WebSecurityOrigin::create(SecurityOrigin::createFromDatabaseIdentifier(originAndDatabases.originIdentifier));
+        RefPtr<API::Object> origin = API::SecurityOrigin::create(SecurityOrigin::createFromDatabaseIdentifier(originAndDatabases.originIdentifier));
 
         Vector<RefPtr<API::Object>> databases;
         databases.reserveInitialCapacity(originAndDatabases.databases.size());
@@ -226,17 +226,17 @@ void WebDatabaseManagerProxy::didGetDatabaseOrigins(const Vector<String>& origin
     securityOrigins.reserveInitialCapacity(originIdentifiers.size());
 
     for (const auto& originIdentifier : originIdentifiers)
-        securityOrigins.uncheckedAppend(WebSecurityOrigin::create(SecurityOrigin::createFromDatabaseIdentifier(originIdentifier)));
+        securityOrigins.uncheckedAppend(API::SecurityOrigin::create(SecurityOrigin::createFromDatabaseIdentifier(originIdentifier)));
 
     callback->performCallbackWithReturnValue(API::Array::create(WTF::move(securityOrigins)).get());
 }
 
-void WebDatabaseManagerProxy::deleteDatabaseWithNameForOrigin(const String& databaseIdentifier, WebSecurityOrigin* origin)
+void WebDatabaseManagerProxy::deleteDatabaseWithNameForOrigin(const String& databaseIdentifier, API::SecurityOrigin* origin)
 {
     context()->sendToOneProcess(Messages::WebDatabaseManager::DeleteDatabaseWithNameForOrigin(databaseIdentifier, origin->securityOrigin().databaseIdentifier()));
 }
 
-void WebDatabaseManagerProxy::deleteDatabasesForOrigin(WebSecurityOrigin* origin)
+void WebDatabaseManagerProxy::deleteDatabasesForOrigin(API::SecurityOrigin* origin)
 {
     context()->sendToOneProcess(Messages::WebDatabaseManager::DeleteDatabasesForOrigin(origin->securityOrigin().databaseIdentifier()));
 }
@@ -246,20 +246,20 @@ void WebDatabaseManagerProxy::deleteAllDatabases()
     context()->sendToOneProcess(Messages::WebDatabaseManager::DeleteAllDatabases());
 }
 
-void WebDatabaseManagerProxy::setQuotaForOrigin(WebSecurityOrigin* origin, uint64_t quota)
+void WebDatabaseManagerProxy::setQuotaForOrigin(API::SecurityOrigin* origin, uint64_t quota)
 {
     context()->sendToOneProcess(Messages::WebDatabaseManager::SetQuotaForOrigin(origin->securityOrigin().databaseIdentifier(), quota));
 }
 
 void WebDatabaseManagerProxy::didModifyOrigin(const String& originIdentifier)
 {
-    RefPtr<WebSecurityOrigin> origin = WebSecurityOrigin::create(SecurityOrigin::createFromDatabaseIdentifier(originIdentifier));
+    RefPtr<API::SecurityOrigin> origin = API::SecurityOrigin::create(SecurityOrigin::createFromDatabaseIdentifier(originIdentifier));
     m_client.didModifyOrigin(this, origin.get());
 }
 
 void WebDatabaseManagerProxy::didModifyDatabase(const String& originIdentifier, const String& databaseIdentifier)
 {
-    RefPtr<WebSecurityOrigin> origin = WebSecurityOrigin::create(SecurityOrigin::createFromDatabaseIdentifier(originIdentifier));
+    RefPtr<API::SecurityOrigin> origin = API::SecurityOrigin::create(SecurityOrigin::createFromDatabaseIdentifier(originIdentifier));
     m_client.didModifyDatabase(this, origin.get(), databaseIdentifier);
 }
 
index df46b0b..fb2b09c 100644 (file)
@@ -42,7 +42,6 @@ namespace WebKit {
 
 class WebContext;
 class WebProcessProxy;
-class WebSecurityOrigin;
 
 typedef GenericCallback<API::Array*> ArrayCallback;
 
@@ -57,10 +56,10 @@ public:
 
     void getDatabasesByOrigin(std::function<void (API::Array*, CallbackBase::Error)>);
     void getDatabaseOrigins(std::function<void (API::Array*, CallbackBase::Error)>);
-    void deleteDatabaseWithNameForOrigin(const String& databaseIdentifier, WebSecurityOrigin*);
-    void deleteDatabasesForOrigin(WebSecurityOrigin*);
+    void deleteDatabaseWithNameForOrigin(const String& databaseIdentifier, API::SecurityOrigin*);
+    void deleteDatabasesForOrigin(API::SecurityOrigin*);
     void deleteAllDatabases();
-    void setQuotaForOrigin(WebSecurityOrigin*, uint64_t quota);
+    void setQuotaForOrigin(API::SecurityOrigin*, uint64_t quota);
     
     static String originKey();
     static String originQuotaKey();
index 2aa7652..ea0de39 100644 (file)
@@ -31,7 +31,7 @@
 
 namespace WebKit {
 
-void WebDatabaseManagerProxyClient::didModifyOrigin(WebDatabaseManagerProxy* databaseManager, WebSecurityOrigin* origin)
+void WebDatabaseManagerProxyClient::didModifyOrigin(WebDatabaseManagerProxy* databaseManager, API::SecurityOrigin* origin)
 {
     if (!m_client.didModifyOrigin)
         return;
@@ -39,7 +39,7 @@ void WebDatabaseManagerProxyClient::didModifyOrigin(WebDatabaseManagerProxy* dat
     m_client.didModifyOrigin(toAPI(databaseManager), toAPI(origin), m_client.base.clientInfo);
 }
 
-void WebDatabaseManagerProxyClient::didModifyDatabase(WebDatabaseManagerProxy* databaseManager, WebSecurityOrigin* origin, const String& databaseIdentifier)
+void WebDatabaseManagerProxyClient::didModifyDatabase(WebDatabaseManagerProxy* databaseManager, API::SecurityOrigin* origin, const String& databaseIdentifier)
 {
     if (!m_client.didModifyDatabase)
         return;
index 0e5091a..2dbe3bb 100644 (file)
@@ -34,17 +34,18 @@ namespace API {
 template<> struct ClientTraits<WKDatabaseManagerClientBase> {
     typedef std::tuple<WKDatabaseManagerClientV0> Versions;
 };
+
+class SecurityOrigin;
 }
 
 namespace WebKit {
 
 class WebDatabaseManagerProxy;
-class WebSecurityOrigin;
 
 class WebDatabaseManagerProxyClient : public API::Client<WKDatabaseManagerClientBase> {
 public:
-    void didModifyOrigin(WebDatabaseManagerProxy*, WebSecurityOrigin*);
-    void didModifyDatabase(WebDatabaseManagerProxy*, WebSecurityOrigin*, const String& databaseIdentifier);
+    void didModifyOrigin(WebDatabaseManagerProxy*, API::SecurityOrigin*);
+    void didModifyDatabase(WebDatabaseManagerProxy*, API::SecurityOrigin*, const String& databaseIdentifier);
 };
 
 } // namespace WebKit
index 59d7bb6..42b40e4 100644 (file)
 #include "WebKeyValueStorageManager.h"
 
 #include "APIArray.h"
+#include "APISecurityOrigin.h"
 #include "LocalStorageDetails.h"
 #include "SecurityOriginData.h"
 #include "WebContext.h"
-#include "WebSecurityOrigin.h"
 #include <wtf/NeverDestroyed.h>
 
 using namespace WebCore;
@@ -92,7 +92,7 @@ void WebKeyValueStorageManager::getKeyValueStorageOrigins(std::function<void (AP
         Vector<RefPtr<API::Object>> webSecurityOrigins;
         webSecurityOrigins.reserveInitialCapacity(securityOrigins.size());
         for (auto& origin : securityOrigins)
-            webSecurityOrigins.uncheckedAppend(WebSecurityOrigin::create(WTF::move(origin)));
+            webSecurityOrigins.uncheckedAppend(API::SecurityOrigin::create(WTF::move(origin)));
 
         callbackFunction(API::Array::create(WTF::move(webSecurityOrigins)).get(), CallbackBase::Error::None);
     });
@@ -108,7 +108,7 @@ void WebKeyValueStorageManager::getStorageDetailsByOrigin(std::function<void (AP
         for (const LocalStorageDetails& originDetails : storageDetails) {
             HashMap<String, RefPtr<API::Object>> detailsMap;
 
-            RefPtr<API::Object> origin = WebSecurityOrigin::create(SecurityOrigin::createFromDatabaseIdentifier(originDetails.originIdentifier));
+            RefPtr<API::Object> origin = API::SecurityOrigin::create(SecurityOrigin::createFromDatabaseIdentifier(originDetails.originIdentifier));
 
             detailsMap.set(WebKeyValueStorageManager::originKey(), origin);
             if (originDetails.creationTime)
@@ -123,7 +123,7 @@ void WebKeyValueStorageManager::getStorageDetailsByOrigin(std::function<void (AP
     });
 }
 
-void WebKeyValueStorageManager::deleteEntriesForOrigin(WebSecurityOrigin* origin)
+void WebKeyValueStorageManager::deleteEntriesForOrigin(API::SecurityOrigin* origin)
 {
     context()->storageManager().deleteEntriesForOrigin(origin->securityOrigin());
 }
index 98e9a54..67a8a74 100644 (file)
@@ -47,7 +47,7 @@ public:
 
     void getKeyValueStorageOrigins(std::function<void (API::Array*, CallbackBase::Error)>);
     void getStorageDetailsByOrigin(std::function<void (API::Array*, CallbackBase::Error)>);
-    void deleteEntriesForOrigin(WebSecurityOrigin*);
+    void deleteEntriesForOrigin(API::SecurityOrigin*);
     void deleteAllEntries();
 
     using API::Object::ref;
index d52cb7c..b3416d0 100644 (file)
 #include "WebMediaCacheManagerProxy.h"
 
 #include "APIArray.h"
+#include "APISecurityOrigin.h"
 #include "WebContext.h"
 #include "WebMediaCacheManagerMessages.h"
 #include "WebMediaCacheManagerProxyMessages.h"
-#include "WebSecurityOrigin.h"
 
 namespace WebKit {
 
index 6cb48c7..1d09f1a 100644 (file)
 #include "config.h"
 #include "WebOriginDataManagerProxy.h"
 
+#include "APISecurityOrigin.h"
 #include "SecurityOriginData.h"
 #include "WebContext.h"
 #include "WebOriginDataManagerMessages.h"
 #include "WebOriginDataManagerProxyMessages.h"
-#include "WebSecurityOrigin.h"
-#include <WebCore/SecurityOrigin.h>
 #include <wtf/NeverDestroyed.h>
 
 using namespace WebCore;
@@ -201,12 +200,12 @@ void WebOriginDataManagerProxy::didGetOrigins(IPC::Connection* connection, const
     securityOrigins.reserveInitialCapacity(originIdentifiers.size());
 
     for (const auto& originIdentifier : originIdentifiers)
-        securityOrigins.uncheckedAppend(WebSecurityOrigin::create(originIdentifier.securityOrigin()));
+        securityOrigins.uncheckedAppend(API::SecurityOrigin::create(originIdentifier.securityOrigin()));
 
     callback->performCallbackWithReturnValue(API::Array::create(WTF::move(securityOrigins)).get());
 }
 
-void WebOriginDataManagerProxy::deleteEntriesForOrigin(WKOriginDataTypes types, WebSecurityOrigin* origin, std::function<void (CallbackBase::Error)> callbackFunction)
+void WebOriginDataManagerProxy::deleteEntriesForOrigin(WKOriginDataTypes types, API::SecurityOrigin* origin, std::function<void (CallbackBase::Error)> callbackFunction)
 {
     SecurityOriginData securityOriginData;
     securityOriginData.protocol = origin->securityOrigin().protocol();
index 5c22753..3262abe 100644 (file)
@@ -41,7 +41,6 @@ class Connection;
 
 namespace WebKit {
 
-class WebSecurityOrigin;
 struct SecurityOriginData;
 
 typedef GenericCallback<API::Array*> ArrayCallback;
@@ -54,7 +53,7 @@ public:
     virtual ~WebOriginDataManagerProxy();
 
     void getOrigins(WKOriginDataTypes, std::function<void (API::Array*, CallbackBase::Error)>);
-    void deleteEntriesForOrigin(WKOriginDataTypes, WebSecurityOrigin*, std::function<void (CallbackBase::Error)>);
+    void deleteEntriesForOrigin(WKOriginDataTypes, API::SecurityOrigin*, std::function<void (CallbackBase::Error)>);
     void deleteEntriesModifiedBetweenDates(WKOriginDataTypes, double startDate, double endDate, std::function<void (CallbackBase::Error)>);
     void deleteAllEntries(WKOriginDataTypes, std::function<void (CallbackBase::Error)>);
 
index 1c24594..6d8bb10 100644 (file)
@@ -33,6 +33,7 @@
 #include "APILegacyContextHistoryClient.h"
 #include "APILoaderClient.h"
 #include "APIPolicyClient.h"
+#include "APISecurityOrigin.h"
 #include "APIUIClient.h"
 #include "APIURLRequest.h"
 #include "AuthenticationChallengeProxy.h"
@@ -87,7 +88,6 @@
 #include "WebProcessMessages.h"
 #include "WebProcessProxy.h"
 #include "WebProtectionSpace.h"
-#include "WebSecurityOrigin.h"
 #include "WebUserContentControllerProxy.h"
 #include "WebsiteDataStore.h"
 #include <WebCore/DragController.h>
@@ -2346,7 +2346,7 @@ void WebPageProxy::countStringMatches(const String& string, FindOptions options,
     m_process->send(Messages::WebPage::CountStringMatches(string, options, maxMatchCount), m_pageID);
 }
 
-void WebPageProxy::runJavaScriptInMainFrame(const String& script, std::function<void (WebSerializedScriptValue*, CallbackBase::Error)> callbackFunction)
+void WebPageProxy::runJavaScriptInMainFrame(const String& script, std::function<void (API::SerializedScriptValue*, CallbackBase::Error)> callbackFunction)
 {
     if (!isValid()) {
         callbackFunction(nullptr, CallbackBase::Error::Unknown);
@@ -4387,7 +4387,7 @@ void WebPageProxy::scriptValueCallback(const IPC::DataReference& dataReference,
     data.reserveInitialCapacity(dataReference.size());
     data.append(dataReference.data(), dataReference.size());
 
-    callback->performCallbackWithReturnValue(data.size() ? WebSerializedScriptValue::adopt(data).get() : 0);
+    callback->performCallbackWithReturnValue(data.size() ? API::SerializedScriptValue::adopt(data).get() : 0);
 }
 
 void WebPageProxy::computedPagesCallback(const Vector<IntRect>& pageRects, double totalScaleFactorForPrinting, uint64_t callbackID)
@@ -4791,7 +4791,7 @@ void WebPageProxy::exceededDatabaseQuota(uint64_t frameID, const String& originI
         WebFrameProxy* frame = m_process->webFrame(record->frameID);
         MESSAGE_CHECK(frame);
 
-        RefPtr<WebSecurityOrigin> origin = WebSecurityOrigin::create(SecurityOrigin::createFromDatabaseIdentifier(record->originIdentifier));
+        RefPtr<API::SecurityOrigin> origin = API::SecurityOrigin::create(SecurityOrigin::createFromDatabaseIdentifier(record->originIdentifier));
         auto currentReply = record->reply;
         m_uiClient->exceededDatabaseQuota(this, frame, origin.get(),
             record->databaseName, record->displayName, record->currentQuota,
@@ -4816,7 +4816,7 @@ void WebPageProxy::requestGeolocationPermissionForFrame(uint64_t geolocationID,
     MESSAGE_CHECK(frame);
 
     // FIXME: Geolocation should probably be using toString() as its string representation instead of databaseIdentifier().
-    RefPtr<WebSecurityOrigin> origin = WebSecurityOrigin::create(SecurityOrigin::createFromDatabaseIdentifier(originIdentifier));
+    RefPtr<API::SecurityOrigin> origin = API::SecurityOrigin::create(SecurityOrigin::createFromDatabaseIdentifier(originIdentifier));
     RefPtr<GeolocationPermissionRequestProxy> request = m_geolocationPermissionRequestManager.createRequest(geolocationID);
 
     if (m_uiClient->decidePolicyForGeolocationPermissionRequest(this, frame, origin.get(), request.get()))
@@ -4833,7 +4833,7 @@ void WebPageProxy::requestUserMediaPermissionForFrame(uint64_t userMediaID, uint
     WebFrameProxy* frame = m_process->webFrame(frameID);
     MESSAGE_CHECK(frame);
 
-    RefPtr<WebSecurityOrigin> origin = WebSecurityOrigin::create(SecurityOrigin::createFromDatabaseIdentifier(originIdentifier));
+    RefPtr<API::SecurityOrigin> origin = API::SecurityOrigin::create(SecurityOrigin::createFromDatabaseIdentifier(originIdentifier));
     RefPtr<UserMediaPermissionRequestProxy> request = m_userMediaPermissionRequestManager.createRequest(userMediaID, audio, video);
 
     if (!m_uiClient->decidePolicyForUserMediaPermissionRequest(*this, *frame, *origin.get(), *request.get()))
@@ -4845,7 +4845,7 @@ void WebPageProxy::requestNotificationPermission(uint64_t requestID, const Strin
     if (!isRequestIDValid(requestID))
         return;
 
-    RefPtr<WebSecurityOrigin> origin = WebSecurityOrigin::createFromString(originString);
+    RefPtr<API::SecurityOrigin> origin = API::SecurityOrigin::createFromString(originString);
     RefPtr<NotificationPermissionRequest> request = m_notificationPermissionRequestManager.createRequest(requestID);
     
     if (!m_uiClient->decidePolicyForNotificationPermissionRequest(this, origin.get(), request.get()))
index deb7e3b..0378c82 100644 (file)
@@ -194,7 +194,7 @@ class QuickLookDocumentData;
 typedef GenericCallback<uint64_t> UnsignedCallback;
 typedef GenericCallback<EditingRange> EditingRangeCallback;
 typedef GenericCallback<const String&> StringCallback;
-typedef GenericCallback<WebSerializedScriptValue*> ScriptValueCallback;
+typedef GenericCallback<API::SerializedScriptValue*> ScriptValueCallback;
 
 #if PLATFORM(GTK)
 typedef GenericCallback<API::Error*> PrintFinishedCallback;
@@ -696,7 +696,7 @@ public:
     void getSelectionAsWebArchiveData(std::function<void (API::Data*, CallbackBase::Error)>);
     void getSourceForFrame(WebFrameProxy*, std::function<void (const String&, CallbackBase::Error)>);
     void getWebArchiveOfFrame(WebFrameProxy*, std::function<void (API::Data*, CallbackBase::Error)>);
-    void runJavaScriptInMainFrame(const String&, std::function<void (WebSerializedScriptValue*, CallbackBase::Error)> callbackFunction);
+    void runJavaScriptInMainFrame(const String&, std::function<void (API::SerializedScriptValue*, CallbackBase::Error)> callbackFunction);
     void forceRepaint(PassRefPtr<VoidCallback>);
 
     float headerHeight(WebFrameProxy*);
index d01e653..559fd89 100644 (file)
 #include "config.h"
 #include "WebResourceCacheManagerProxy.h"
 
+#include "APISecurityOrigin.h"
 #include "ImmutableDictionary.h"
 #include "SecurityOriginData.h"
 #include "WebContext.h"
 #include "WebResourceCacheManagerMessages.h"
 #include "WebResourceCacheManagerProxyMessages.h"
-#include "WebSecurityOrigin.h"
 
 #if ENABLE(NETWORK_PROCESS)
 #include "NetworkProcessMessages.h"
@@ -104,7 +104,7 @@ void WebResourceCacheManagerProxy::didGetCacheOrigins(const Vector<SecurityOrigi
     performAPICallbackWithSecurityOriginDataVector(origins, callback.get());
 }
 
-void WebResourceCacheManagerProxy::clearCacheForOrigin(WebSecurityOrigin* origin, ResourceCachesToClear cachesToClear)
+void WebResourceCacheManagerProxy::clearCacheForOrigin(API::SecurityOrigin* origin, ResourceCachesToClear cachesToClear)
 {
     SecurityOriginData securityOrigin;
     securityOrigin.protocol = origin->securityOrigin().protocol();
index 673bba4..a9e4549 100644 (file)
@@ -40,7 +40,6 @@ namespace WebKit {
 struct SecurityOriginData;
 class WebContext;
 class WebProcessProxy;
-class WebSecurityOrigin;
 
 typedef GenericCallback<API::Array*> ArrayCallback;
 
@@ -52,7 +51,7 @@ public:
     virtual ~WebResourceCacheManagerProxy();
 
     void getCacheOrigins(std::function<void (API::Array*, CallbackBase::Error)>);
-    void clearCacheForOrigin(WebSecurityOrigin*, ResourceCachesToClear);
+    void clearCacheForOrigin(API::SecurityOrigin*, ResourceCachesToClear);
     void clearCacheForAllOrigins(ResourceCachesToClear);
 
     using API::Object::ref;
index 6385b7b..235f22a 100644 (file)
@@ -67,7 +67,7 @@ private:
     virtual void pageClosed() override;
     virtual void preferencesDidChange() override;
     virtual void toolTipChanged(const String&, const String&) override;
-    virtual bool decidePolicyForGeolocationPermissionRequest(WebFrameProxy&, WebSecurityOrigin&, GeolocationPermissionRequestProxy&) override;
+    virtual bool decidePolicyForGeolocationPermissionRequest(WebFrameProxy&, API::SecurityOrigin&, GeolocationPermissionRequestProxy&) override;
     virtual void didCommitLoadForMainFrame(const String& mimeType, bool useCustomContentProvider) override;
     virtual void handleDownloadRequest(DownloadProxy*) override;
     virtual void setCursor(const WebCore::Cursor&) override;
index 1553cf7..91b3e41 100644 (file)
@@ -237,7 +237,7 @@ void PageClientImpl::toolTipChanged(const String&, const String&)
     notImplemented();
 }
 
-bool PageClientImpl::decidePolicyForGeolocationPermissionRequest(WebFrameProxy& frame, WebSecurityOrigin& origin, GeolocationPermissionRequestProxy& request)
+bool PageClientImpl::decidePolicyForGeolocationPermissionRequest(WebFrameProxy& frame, API::SecurityOrigin& origin, GeolocationPermissionRequestProxy& request)
 {
     [[wrapper(m_webView->_page->process().context()) _geolocationProvider] decidePolicyForGeolocationRequestFromOrigin:origin.securityOrigin() frame:frame request:request view:m_webView];
     return true;
index 63b4a20..c6ca0e1 100644 (file)
@@ -44,7 +44,6 @@ class RemoteLayerTreeTransaction;
 class WebContext;
 class WebFrameProxy;
 class WebPageProxy;
-class WebSecurityOrigin;
 struct WebPageConfiguration;
 }
 
index bdc722e..706ff37 100644 (file)
                ED82A7F2128C6FAF004477B3 /* WKBundlePageOverlay.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A22F0FF1289FCD90085E74F /* WKBundlePageOverlay.h */; settings = {ATTRIBUTES = (Private, ); }; };
                EDCA71B7128DDA8C00201B26 /* WKBundlePageOverlay.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A22F1001289FCD90085E74F /* WKBundlePageOverlay.cpp */; };
                F036978815F4BF0500C3A80E /* WebColorPicker.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F036978715F4BF0500C3A80E /* WebColorPicker.cpp */; };
-               F6113E25126CE1820057D0A7 /* WebUserContentURLPattern.h in Headers */ = {isa = PBXBuildFile; fileRef = F6113E24126CE1820057D0A7 /* WebUserContentURLPattern.h */; };
+               F6113E25126CE1820057D0A7 /* APIUserContentURLPattern.h in Headers */ = {isa = PBXBuildFile; fileRef = F6113E24126CE1820057D0A7 /* APIUserContentURLPattern.h */; };
                F6113E28126CE19B0057D0A7 /* WKUserContentURLPattern.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F6113E26126CE19B0057D0A7 /* WKUserContentURLPattern.cpp */; };
                F6113E29126CE19B0057D0A7 /* WKUserContentURLPattern.h in Headers */ = {isa = PBXBuildFile; fileRef = F6113E27126CE19B0057D0A7 /* WKUserContentURLPattern.h */; settings = {ATTRIBUTES = (Private, ); }; };
                F62A765C12B1ABC30005F1B6 /* WebDatabaseManagerProxy.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F62A765912B1ABC30005F1B6 /* WebDatabaseManagerProxy.cpp */; };
                F62A76B712B1B25F0005F1B6 /* WebDatabaseManagerMessages.h in Headers */ = {isa = PBXBuildFile; fileRef = F62A76B312B1B25F0005F1B6 /* WebDatabaseManagerMessages.h */; };
                F62A76B812B1B25F0005F1B6 /* WebDatabaseManagerProxyMessageReceiver.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F62A76B412B1B25F0005F1B6 /* WebDatabaseManagerProxyMessageReceiver.cpp */; };
                F62A76B912B1B25F0005F1B6 /* WebDatabaseManagerProxyMessages.h in Headers */ = {isa = PBXBuildFile; fileRef = F62A76B512B1B25F0005F1B6 /* WebDatabaseManagerProxyMessages.h */; };
-               F634445612A885C8000612D8 /* WebSecurityOrigin.h in Headers */ = {isa = PBXBuildFile; fileRef = F634445512A885C8000612D8 /* WebSecurityOrigin.h */; };
+               F634445612A885C8000612D8 /* APISecurityOrigin.h in Headers */ = {isa = PBXBuildFile; fileRef = F634445512A885C8000612D8 /* APISecurityOrigin.h */; };
                F634445C12A885E9000612D8 /* WKSecurityOrigin.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F634445A12A885E9000612D8 /* WKSecurityOrigin.cpp */; };
                F634445D12A885E9000612D8 /* WKSecurityOrigin.h in Headers */ = {isa = PBXBuildFile; fileRef = F634445B12A885E9000612D8 /* WKSecurityOrigin.h */; settings = {ATTRIBUTES = (Private, ); }; };
                F67DD7BA125E40D9007BDCB8 /* WKSerializedScriptValuePrivate.h in Headers */ = {isa = PBXBuildFile; fileRef = F67DD7B9125E40D9007BDCB8 /* WKSerializedScriptValuePrivate.h */; settings = {ATTRIBUTES = (Private, ); }; };
                A58B6F0618FCA733008CBA53 /* WKFileUploadPanel.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = WKFileUploadPanel.h; path = ios/forms/WKFileUploadPanel.h; sourceTree = "<group>"; };
                A58B6F0718FCA733008CBA53 /* WKFileUploadPanel.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; name = WKFileUploadPanel.mm; path = ios/forms/WKFileUploadPanel.mm; sourceTree = "<group>"; };
                A5EFD38B16B0E88C00B2F0E8 /* WKPageVisibilityTypes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WKPageVisibilityTypes.h; sourceTree = "<group>"; };
-               A72D5D7F1236CBA800A88B15 /* WebSerializedScriptValue.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebSerializedScriptValue.h; sourceTree = "<group>"; };
+               A72D5D7F1236CBA800A88B15 /* APISerializedScriptValue.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = APISerializedScriptValue.h; sourceTree = "<group>"; };
                A78CCDD7193AC9E3005ECC25 /* com.apple.WebKit.Databases.sb */ = {isa = PBXFileReference; lastKnownFileType = text; path = com.apple.WebKit.Databases.sb; sourceTree = "<group>"; };
                A78CCDD8193AC9E3005ECC25 /* com.apple.WebKit.Networking.sb */ = {isa = PBXFileReference; lastKnownFileType = text; path = com.apple.WebKit.Networking.sb; sourceTree = "<group>"; };
                A78CCDD9193AC9E3005ECC25 /* com.apple.WebKit.WebContent.sb */ = {isa = PBXFileReference; lastKnownFileType = text; path = com.apple.WebKit.WebContent.sb; sourceTree = "<group>"; };
                E489D2881A0A2DB80078C06A /* NetworkCacheEncoder.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = NetworkCacheEncoder.cpp; sourceTree = "<group>"; };
                E489D2891A0A2DB80078C06A /* NetworkCacheEncoder.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = NetworkCacheEncoder.h; sourceTree = "<group>"; };
                F036978715F4BF0500C3A80E /* WebColorPicker.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WebColorPicker.cpp; sourceTree = "<group>"; };
-               F6113E24126CE1820057D0A7 /* WebUserContentURLPattern.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebUserContentURLPattern.h; sourceTree = "<group>"; };
+               F6113E24126CE1820057D0A7 /* APIUserContentURLPattern.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = APIUserContentURLPattern.h; sourceTree = "<group>"; };
                F6113E26126CE19B0057D0A7 /* WKUserContentURLPattern.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WKUserContentURLPattern.cpp; sourceTree = "<group>"; };
                F6113E27126CE19B0057D0A7 /* WKUserContentURLPattern.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WKUserContentURLPattern.h; sourceTree = "<group>"; };
                F62A765712B1AB7D0005F1B6 /* WebDatabaseManager.messages.in */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = WebDatabaseManager.messages.in; sourceTree = "<group>"; };
                F62A76B312B1B25F0005F1B6 /* WebDatabaseManagerMessages.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebDatabaseManagerMessages.h; sourceTree = "<group>"; };
                F62A76B412B1B25F0005F1B6 /* WebDatabaseManagerProxyMessageReceiver.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WebDatabaseManagerProxyMessageReceiver.cpp; sourceTree = "<group>"; };
                F62A76B512B1B25F0005F1B6 /* WebDatabaseManagerProxyMessages.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebDatabaseManagerProxyMessages.h; sourceTree = "<group>"; };
-               F634445512A885C8000612D8 /* WebSecurityOrigin.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebSecurityOrigin.h; sourceTree = "<group>"; };
+               F634445512A885C8000612D8 /* APISecurityOrigin.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = APISecurityOrigin.h; sourceTree = "<group>"; };
                F634445A12A885E9000612D8 /* WKSecurityOrigin.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WKSecurityOrigin.cpp; sourceTree = "<group>"; };
                F634445B12A885E9000612D8 /* WKSecurityOrigin.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WKSecurityOrigin.h; sourceTree = "<group>"; };
                F638954F133BEF38008941D5 /* HTTPCookieAcceptPolicy.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = HTTPCookieAcceptPolicy.h; sourceTree = "<group>"; };
                                37948402150C350600E52CE9 /* WebRenderLayer.h */,
                                3760881C150413E900FC82C7 /* WebRenderObject.cpp */,
                                3760881D150413E900FC82C7 /* WebRenderObject.h */,
-                               F634445512A885C8000612D8 /* WebSecurityOrigin.h */,
-                               A72D5D7F1236CBA800A88B15 /* WebSerializedScriptValue.h */,
                                C0337DD7127A51B6008FF4F4 /* WebTouchEvent.cpp */,
-                               F6113E24126CE1820057D0A7 /* WebUserContentURLPattern.h */,
                                C0337DD0127A2980008FF4F4 /* WebWheelEvent.cpp */,
                        );
                        path = Shared;
                        children = (
                                BCDDB315124EBCFE0048D13C /* C */,
                                37DFA6FE1810BB2D001F4A9F /* Cocoa */,
+                               F634445512A885C8000612D8 /* APISecurityOrigin.h */,
+                               A72D5D7F1236CBA800A88B15 /* APISerializedScriptValue.h */,
+                               F6113E24126CE1820057D0A7 /* APIUserContentURLPattern.h */,
                        );
                        path = API;
                        sourceTree = "<group>";
                                1A002D44196B338900B9AD44 /* _WKSessionState.h in Headers */,
                                D3B9484911FF4B6500032B39 /* WebSearchPopupMenu.h in Headers */,
                                1FB00AC9185F76460019142E /* WKWebProcessPlugInPageGroupInternal.h in Headers */,
-                               F634445612A885C8000612D8 /* WebSecurityOrigin.h in Headers */,
+                               F634445612A885C8000612D8 /* APISecurityOrigin.h in Headers */,
                                BCC5715B115ADAEF001CCAF9 /* WebSystemInterface.h in Headers */,
                                BCA0EF7F12331E78007D3CFB /* WebUndoStep.h in Headers */,
                                1AC1336C18565C7A00F3EC05 /* APIPageHandle.h in Headers */,
                                51C96119183D294700D2002E /* WebIDBServerConnectionMessages.h in Headers */,
                                BCE2315D122C30CA00D5C35A /* APIURLRequest.h in Headers */,
                                BC90A1D2122DD55E00CC8C50 /* APIURLResponse.h in Headers */,
-                               F6113E25126CE1820057D0A7 /* WebUserContentURLPattern.h in Headers */,
+                               F6113E25126CE1820057D0A7 /* APIUserContentURLPattern.h in Headers */,
                                29CD55AA128E294F00133C85 /* WKAccessibilityWebPageObjectBase.h in Headers */,
                                BCDDB32D124EC2E10048D13C /* WKAPICast.h in Headers */,
                                512E34E5130B4D0500ABD19A /* WKApplicationCacheManager.h in Headers */,
index 038041b..4140ab9 100644 (file)
@@ -35,12 +35,12 @@ class HitTestResult;
 namespace WebKit {
 class WebFrame;
 class WebPage;
-class WebSecurityOrigin;
 }
 
 namespace API {
 
 class Object;
+class SecurityOrigin;
 
 namespace InjectedBundle {
 
@@ -69,8 +69,8 @@ public:
     virtual UIElementVisibility menuBarIsVisible(WebKit::WebPage*) { return UIElementVisibility::Unknown; }
     virtual UIElementVisibility toolbarsAreVisible(WebKit::WebPage*) { return UIElementVisibility::Unknown; }
 
-    virtual bool didReachApplicationCacheOriginQuota(WebKit::WebPage*, WebKit::WebSecurityOrigin*, int64_t totalBytesNeeded) { UNUSED_PARAM(totalBytesNeeded); return false; }
-    virtual uint64_t didExceedDatabaseQuota(WebKit::WebPage*, WebKit::WebSecurityOrigin*, const WTF::String& databaseName, const WTF::String& databaseDisplayName, uint64_t currentQuotaBytes, uint64_t currentOriginUsageBytes, uint64_t currentDatabaseUsageBytes, uint64_t expectedUsageBytes)
+    virtual bool didReachApplicationCacheOriginQuota(WebKit::WebPage*, SecurityOrigin*, int64_t totalBytesNeeded) { UNUSED_PARAM(totalBytesNeeded); return false; }
+    virtual uint64_t didExceedDatabaseQuota(WebKit::WebPage*, SecurityOrigin*, const WTF::String& databaseName, const WTF::String& databaseDisplayName, uint64_t currentQuotaBytes, uint64_t currentOriginUsageBytes, uint64_t currentDatabaseUsageBytes, uint64_t expectedUsageBytes)
     {
         UNUSED_PARAM(databaseName);
         UNUSED_PARAM(databaseDisplayName);
index 4c0134f..5f5752c 100644 (file)
@@ -28,6 +28,7 @@
 #include "WKBundleFramePrivate.h"
 
 #include "APIArray.h"
+#include "APISecurityOrigin.h"
 #include "InjectedBundleHitTestResult.h"
 #include "InjectedBundleNodeHandle.h"
 #include "InjectedBundleRangeHandle.h"
@@ -36,7 +37,6 @@
 #include "WKBundleAPICast.h"
 #include "WKData.h"
 #include "WebFrame.h"
-#include "WebSecurityOrigin.h"
 #include <WebCore/Document.h>
 #include <WebCore/FocusController.h>
 #include <WebCore/Frame.h>
index 9c63171..54c24ae 100644 (file)
 #include "config.h"
 #include "InjectedBundlePageUIClient.h"
 
+#include "APISecurityOrigin.h"
 #include "InjectedBundleHitTestResult.h"
 #include "WKAPICast.h"
 #include "WKBundleAPICast.h"
 #include "WebFrame.h"
-#include "WebSecurityOrigin.h"
 #include <wtf/text/WTFString.h>
 
 using namespace WebCore;
@@ -147,7 +147,7 @@ API::InjectedBundle::PageUIClient::UIElementVisibility InjectedBundlePageUIClien
     return toUIElementVisibility(m_client.toolbarsAreVisible(toAPI(page), m_client.base.clientInfo));
 }
 
-bool InjectedBundlePageUIClient::didReachApplicationCacheOriginQuota(WebPage* page, WebSecurityOrigin* origin, int64_t totalBytesNeeded)
+bool InjectedBundlePageUIClient::didReachApplicationCacheOriginQuota(WebPage* page, API::SecurityOrigin* origin, int64_t totalBytesNeeded)
 {
     if (!m_client.didReachApplicationCacheOriginQuota)
         return false;
@@ -156,7 +156,7 @@ bool InjectedBundlePageUIClient::didReachApplicationCacheOriginQuota(WebPage* pa
     return true;
 }
 
-uint64_t InjectedBundlePageUIClient::didExceedDatabaseQuota(WebPage* page, WebSecurityOrigin* origin, const String& databaseName, const String& databaseDisplayName, uint64_t currentQuotaBytes, uint64_t currentOriginUsageBytes, uint64_t currentDatabaseUsageBytes, uint64_t expectedUsageBytes)
+uint64_t InjectedBundlePageUIClient::didExceedDatabaseQuota(WebPage* page, API::SecurityOrigin* origin, const String& databaseName, const String& databaseDisplayName, uint64_t currentQuotaBytes, uint64_t currentOriginUsageBytes, uint64_t currentDatabaseUsageBytes, uint64_t expectedUsageBytes)
 {
     if (!m_client.didExceedDatabaseQuota)
         return 0;
index 63a4abb..76695c4 100644 (file)
@@ -62,8 +62,8 @@ public:
     UIElementVisibility menuBarIsVisible(WebPage*) override;
     UIElementVisibility toolbarsAreVisible(WebPage*) override;
 
-    bool didReachApplicationCacheOriginQuota(WebPage*, WebSecurityOrigin*, int64_t totalBytesNeeded) override;
-    uint64_t didExceedDatabaseQuota(WebPage*, WebSecurityOrigin*, const String& databaseName, const String& databaseDisplayName, uint64_t currentQuotaBytes, uint64_t currentOriginUsageBytes, uint64_t currentDatabaseUsageBytes, uint64_t expectedUsageBytes) override;
+    bool didReachApplicationCacheOriginQuota(WebPage*, API::SecurityOrigin*, int64_t totalBytesNeeded) override;
+    uint64_t didExceedDatabaseQuota(WebPage*, API::SecurityOrigin*, const String& databaseName, const String& databaseDisplayName, uint64_t currentQuotaBytes, uint64_t currentOriginUsageBytes, uint64_t currentDatabaseUsageBytes, uint64_t expectedUsageBytes) override;
 
     String plugInStartLabelTitle(const String& mimeType) const override;
     String plugInStartLabelSubtitle(const String& mimeType) const override;
index b8dfdf1..74dbde7 100644 (file)
@@ -27,6 +27,7 @@
 #include "config.h"
 #include "WebChromeClient.h"
 
+#include "APISecurityOrigin.h"
 #include "DrawingArea.h"
 #include "InjectedBundleNavigationAction.h"
 #include "InjectedBundleUserMessageCoders.h"
@@ -48,7 +49,6 @@
 #include "WebProcess.h"
 #include "WebProcessProxyMessages.h"
 #include "WebSearchPopupMenu.h"
-#include "WebSecurityOrigin.h"
 #include <WebCore/ApplicationCacheStorage.h>
 #include <WebCore/AXObjectCache.h>
 #include <WebCore/ColorChooser.h>
@@ -681,8 +681,8 @@ void WebChromeClient::exceededDatabaseQuota(Frame* frame, const String& database
     uint64_t currentQuota = dbManager.quotaForOrigin(origin);
     uint64_t currentOriginUsage = dbManager.usageForOrigin(origin);
     uint64_t newQuota = 0;
-    RefPtr<WebSecurityOrigin> webSecurityOrigin = WebSecurityOrigin::create(WebCore::SecurityOrigin::createFromDatabaseIdentifier(origin->databaseIdentifier()));
-    newQuota = m_page->injectedBundleUIClient().didExceedDatabaseQuota(m_page, webSecurityOrigin.get(), databaseName, details.displayName(), currentQuota, currentOriginUsage, details.currentUsage(), details.expectedUsage());
+    RefPtr<API::SecurityOrigin> securityOrigin = API::SecurityOrigin::create(WebCore::SecurityOrigin::createFromDatabaseIdentifier(origin->databaseIdentifier()));
+    newQuota = m_page->injectedBundleUIClient().didExceedDatabaseQuota(m_page, securityOrigin.get(), databaseName, details.displayName(), currentQuota, currentOriginUsage, details.currentUsage(), details.expectedUsage());
 
     if (!newQuota) {
         unsigned syncSendFlags = IPC::InformPlatformProcessWillSuspend;
@@ -706,8 +706,8 @@ void WebChromeClient::reachedMaxAppCacheSize(int64_t)
 
 void WebChromeClient::reachedApplicationCacheOriginQuota(SecurityOrigin* origin, int64_t totalBytesNeeded)
 {
-    RefPtr<WebSecurityOrigin> webSecurityOrigin = WebSecurityOrigin::createFromString(origin->toString());
-    if (m_page->injectedBundleUIClient().didReachApplicationCacheOriginQuota(m_page, webSecurityOrigin.get(), totalBytesNeeded))
+    RefPtr<API::SecurityOrigin> securityOrigin = API::SecurityOrigin::createFromString(origin->toString());
+    if (m_page->injectedBundleUIClient().didReachApplicationCacheOriginQuota(m_page, securityOrigin.get(), totalBytesNeeded))
         return;
 
     unsigned syncSendFlags = IPC::InformPlatformProcessWillSuspend;