Remove Web Intents code from WebKit2
authorandersca@apple.com <andersca@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 31 Jan 2013 19:11:25 +0000 (19:11 +0000)
committerandersca@apple.com <andersca@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 31 Jan 2013 19:11:25 +0000 (19:11 +0000)
https://bugs.webkit.org/show_bug.cgi?id=108506

Reviewed by Simon Fraser.

Source/WebKit2:

Since nobody builds with Web Intents enabled anymore, and since the code is going to
be removed from WebCore, remove it from WebKit2.

* Shared/API/c/WKBase.h:
* Shared/APIClientTraits.cpp:
(WebKit):
* Shared/APIObject.h:
* Shared/IntentData.cpp: Removed.
* Shared/IntentData.h: Removed.
* Shared/IntentServiceInfo.cpp: Removed.
* Shared/IntentServiceInfo.h: Removed.
* Shared/WebIntentServiceInfo.cpp: Removed.
* Shared/WebIntentServiceInfo.h: Removed.
* UIProcess/API/C/WKAPICast.h:
(WebKit):
* UIProcess/API/C/WKIntentData.cpp: Removed.
* UIProcess/API/C/WKIntentData.h: Removed.
* UIProcess/API/C/WKIntentServiceInfo.cpp: Removed.
* UIProcess/API/C/WKIntentServiceInfo.h: Removed.
* UIProcess/API/C/WKPage.cpp:
* UIProcess/API/C/WKPage.h:
* UIProcess/WebIntentData.cpp: Removed.
* UIProcess/WebIntentData.h: Removed.
* UIProcess/WebLoaderClient.cpp:
* UIProcess/WebLoaderClient.h:
(WebKit):
(WebLoaderClient):
* UIProcess/WebPageProxy.cpp:
* UIProcess/WebPageProxy.h:
(WebKit):
(WebPageProxy):
* UIProcess/WebPageProxy.messages.in:
* UIProcess/WebProcessProxy.cpp:
* UIProcess/WebProcessProxy.h:
(WebProcessProxy):
* WebProcess/InjectedBundle/API/c/WKBundleAPICast.h:
(WebKit):
* WebProcess/InjectedBundle/API/c/WKBundleIntent.cpp: Removed.
* WebProcess/InjectedBundle/API/c/WKBundleIntent.h: Removed.
* WebProcess/InjectedBundle/API/c/WKBundleIntentRequest.cpp: Removed.
* WebProcess/InjectedBundle/API/c/WKBundleIntentRequest.h: Removed.
* WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:
* WebProcess/InjectedBundle/API/c/WKBundlePage.h:
* WebProcess/InjectedBundle/InjectedBundleIntent.cpp: Removed.
* WebProcess/InjectedBundle/InjectedBundleIntent.h: Removed.
* WebProcess/InjectedBundle/InjectedBundleIntentRequest.cpp: Removed.
* WebProcess/InjectedBundle/InjectedBundleIntentRequest.h: Removed.
* WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.cpp:
* WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.h:
(WebKit):
(InjectedBundlePageLoaderClient):
* WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
(WebKit):
* WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
(WebFrameLoaderClient):
* WebProcess/WebPage/WebFrame.cpp:
* WebProcess/WebPage/WebFrame.h:
(WebCore):
(WebKit):
(WebFrame):
* WebProcess/WebPage/WebPage.cpp:
* WebProcess/WebPage/WebPage.h:
(WebCore):
(WebKit):
(WebPage):
* WebProcess/WebPage/WebPage.messages.in:
* WebProcess/WebProcess.cpp:
* WebProcess/WebProcess.h:
(WebCore):
(WebProcess):
* WebProcess/WebProcess.messages.in:

Tools:

* WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
* WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp:
(WTR::InjectedBundlePage::InjectedBundlePage):
* WebKitTestRunner/InjectedBundle/InjectedBundlePage.h:
(InjectedBundlePage):
* WebKitTestRunner/InjectedBundle/TestRunner.cpp:
* WebKitTestRunner/InjectedBundle/TestRunner.h:
(TestRunner):

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

55 files changed:
Source/WebKit2/ChangeLog
Source/WebKit2/Shared/API/c/WKBase.h
Source/WebKit2/Shared/APIClientTraits.cpp
Source/WebKit2/Shared/APIObject.h
Source/WebKit2/Shared/IntentData.cpp [deleted file]
Source/WebKit2/Shared/IntentData.h [deleted file]
Source/WebKit2/Shared/IntentServiceInfo.cpp [deleted file]
Source/WebKit2/Shared/IntentServiceInfo.h [deleted file]
Source/WebKit2/Shared/WebIntentServiceInfo.cpp [deleted file]
Source/WebKit2/Shared/WebIntentServiceInfo.h [deleted file]
Source/WebKit2/UIProcess/API/C/WKAPICast.h
Source/WebKit2/UIProcess/API/C/WKIntentData.cpp [deleted file]
Source/WebKit2/UIProcess/API/C/WKIntentData.h [deleted file]
Source/WebKit2/UIProcess/API/C/WKIntentServiceInfo.cpp [deleted file]
Source/WebKit2/UIProcess/API/C/WKIntentServiceInfo.h [deleted file]
Source/WebKit2/UIProcess/API/C/WKPage.cpp
Source/WebKit2/UIProcess/API/C/WKPage.h
Source/WebKit2/UIProcess/WebIntentData.cpp [deleted file]
Source/WebKit2/UIProcess/WebIntentData.h [deleted file]
Source/WebKit2/UIProcess/WebLoaderClient.cpp
Source/WebKit2/UIProcess/WebLoaderClient.h
Source/WebKit2/UIProcess/WebPageProxy.cpp
Source/WebKit2/UIProcess/WebPageProxy.h
Source/WebKit2/UIProcess/WebPageProxy.messages.in
Source/WebKit2/UIProcess/WebProcessProxy.cpp
Source/WebKit2/UIProcess/WebProcessProxy.h
Source/WebKit2/WebProcess/InjectedBundle/API/c/WKBundleAPICast.h
Source/WebKit2/WebProcess/InjectedBundle/API/c/WKBundleIntent.cpp [deleted file]
Source/WebKit2/WebProcess/InjectedBundle/API/c/WKBundleIntent.h [deleted file]
Source/WebKit2/WebProcess/InjectedBundle/API/c/WKBundleIntentRequest.cpp [deleted file]
Source/WebKit2/WebProcess/InjectedBundle/API/c/WKBundleIntentRequest.h [deleted file]
Source/WebKit2/WebProcess/InjectedBundle/API/c/WKBundlePage.cpp
Source/WebKit2/WebProcess/InjectedBundle/API/c/WKBundlePage.h
Source/WebKit2/WebProcess/InjectedBundle/InjectedBundleIntent.cpp [deleted file]
Source/WebKit2/WebProcess/InjectedBundle/InjectedBundleIntent.h [deleted file]
Source/WebKit2/WebProcess/InjectedBundle/InjectedBundleIntentRequest.cpp [deleted file]
Source/WebKit2/WebProcess/InjectedBundle/InjectedBundleIntentRequest.h [deleted file]
Source/WebKit2/WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.cpp
Source/WebKit2/WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.h
Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp
Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.h
Source/WebKit2/WebProcess/WebPage/WebFrame.cpp
Source/WebKit2/WebProcess/WebPage/WebFrame.h
Source/WebKit2/WebProcess/WebPage/WebPage.cpp
Source/WebKit2/WebProcess/WebPage/WebPage.h
Source/WebKit2/WebProcess/WebPage/WebPage.messages.in
Source/WebKit2/WebProcess/WebProcess.cpp
Source/WebKit2/WebProcess/WebProcess.h
Source/WebKit2/WebProcess/WebProcess.messages.in
Tools/ChangeLog
Tools/WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl
Tools/WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp
Tools/WebKitTestRunner/InjectedBundle/InjectedBundlePage.h
Tools/WebKitTestRunner/InjectedBundle/TestRunner.cpp
Tools/WebKitTestRunner/InjectedBundle/TestRunner.h

index 9bf1828..ce8cd5c 100644 (file)
@@ -1,3 +1,82 @@
+2013-01-31  Anders Carlsson  <andersca@apple.com>
+
+        Remove Web Intents code from WebKit2
+        https://bugs.webkit.org/show_bug.cgi?id=108506
+
+        Reviewed by Simon Fraser.
+
+        Since nobody builds with Web Intents enabled anymore, and since the code is going to 
+        be removed from WebCore, remove it from WebKit2.
+
+        * Shared/API/c/WKBase.h:
+        * Shared/APIClientTraits.cpp:
+        (WebKit):
+        * Shared/APIObject.h:
+        * Shared/IntentData.cpp: Removed.
+        * Shared/IntentData.h: Removed.
+        * Shared/IntentServiceInfo.cpp: Removed.
+        * Shared/IntentServiceInfo.h: Removed.
+        * Shared/WebIntentServiceInfo.cpp: Removed.
+        * Shared/WebIntentServiceInfo.h: Removed.
+        * UIProcess/API/C/WKAPICast.h:
+        (WebKit):
+        * UIProcess/API/C/WKIntentData.cpp: Removed.
+        * UIProcess/API/C/WKIntentData.h: Removed.
+        * UIProcess/API/C/WKIntentServiceInfo.cpp: Removed.
+        * UIProcess/API/C/WKIntentServiceInfo.h: Removed.
+        * UIProcess/API/C/WKPage.cpp:
+        * UIProcess/API/C/WKPage.h:
+        * UIProcess/WebIntentData.cpp: Removed.
+        * UIProcess/WebIntentData.h: Removed.
+        * UIProcess/WebLoaderClient.cpp:
+        * UIProcess/WebLoaderClient.h:
+        (WebKit):
+        (WebLoaderClient):
+        * UIProcess/WebPageProxy.cpp:
+        * UIProcess/WebPageProxy.h:
+        (WebKit):
+        (WebPageProxy):
+        * UIProcess/WebPageProxy.messages.in:
+        * UIProcess/WebProcessProxy.cpp:
+        * UIProcess/WebProcessProxy.h:
+        (WebProcessProxy):
+        * WebProcess/InjectedBundle/API/c/WKBundleAPICast.h:
+        (WebKit):
+        * WebProcess/InjectedBundle/API/c/WKBundleIntent.cpp: Removed.
+        * WebProcess/InjectedBundle/API/c/WKBundleIntent.h: Removed.
+        * WebProcess/InjectedBundle/API/c/WKBundleIntentRequest.cpp: Removed.
+        * WebProcess/InjectedBundle/API/c/WKBundleIntentRequest.h: Removed.
+        * WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:
+        * WebProcess/InjectedBundle/API/c/WKBundlePage.h:
+        * WebProcess/InjectedBundle/InjectedBundleIntent.cpp: Removed.
+        * WebProcess/InjectedBundle/InjectedBundleIntent.h: Removed.
+        * WebProcess/InjectedBundle/InjectedBundleIntentRequest.cpp: Removed.
+        * WebProcess/InjectedBundle/InjectedBundleIntentRequest.h: Removed.
+        * WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.cpp:
+        * WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.h:
+        (WebKit):
+        (InjectedBundlePageLoaderClient):
+        * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
+        (WebKit):
+        * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
+        (WebFrameLoaderClient):
+        * WebProcess/WebPage/WebFrame.cpp:
+        * WebProcess/WebPage/WebFrame.h:
+        (WebCore):
+        (WebKit):
+        (WebFrame):
+        * WebProcess/WebPage/WebPage.cpp:
+        * WebProcess/WebPage/WebPage.h:
+        (WebCore):
+        (WebKit):
+        (WebPage):
+        * WebProcess/WebPage/WebPage.messages.in:
+        * WebProcess/WebProcess.cpp:
+        * WebProcess/WebProcess.h:
+        (WebCore):
+        (WebProcess):
+        * WebProcess/WebProcess.messages.in:
+
 2013-01-31  Brady Eidson  <beidson@apple.com>
 
         Lack of a log level string should not obliterate compiled in logging channel state.
index 1a27610..4b08259 100644 (file)
@@ -117,8 +117,6 @@ typedef const struct OpaqueWKGrammarDetail* WKGrammarDetailRef;
 typedef const struct OpaqueWKHitTestResult* WKHitTestResultRef;
 typedef const struct OpaqueWKIconDatabase* WKIconDatabaseRef;
 typedef const struct OpaqueWKInspector* WKInspectorRef;
-typedef const struct OpaqueWKIntentData* WKIntentDataRef;
-typedef const struct OpaqueWKIntentServiceInfo* WKIntentServiceInfoRef;
 typedef const struct OpaqueWKKeyValueStorageManager* WKKeyValueStorageManagerRef;
 typedef const struct OpaqueWKMediaCacheManager* WKMediaCacheManagerRef;
 typedef const struct OpaqueWKNavigationData* WKNavigationDataRef;
@@ -148,8 +146,6 @@ typedef const struct OpaqueWKBundleDOMWindowExtension* WKBundleDOMWindowExtensio
 typedef const struct OpaqueWKBundleFrame* WKBundleFrameRef;
 typedef const struct OpaqueWKBundleHitTestResult* WKBundleHitTestResultRef;
 typedef const struct OpaqueWKBundleInspector* WKBundleInspectorRef;
-typedef const struct OpaqueWKBundleIntent* WKBundleIntentRef;
-typedef const struct OpaqueWKBundleIntentRequest* WKBundleIntentRequestRef;
 typedef const struct OpaqueWKBundleNavigationAction* WKBundleNavigationActionRef;
 typedef const struct OpaqueWKBundleNodeHandle* WKBundleNodeHandleRef;
 typedef const struct OpaqueWKBundlePage* WKBundlePageRef;
index eb7a51b..0f15584 100644 (file)
@@ -39,8 +39,8 @@ const size_t APIClientTraits<WKBundleClient>::interfaceSizesByVersion[] = {
 const size_t APIClientTraits<WKBundlePageLoaderClient>::interfaceSizesByVersion[] = {
     offsetof(WKBundlePageLoaderClient, didLayoutForFrame),
     offsetof(WKBundlePageLoaderClient, didFinishProgress),
-    offsetof(WKBundlePageLoaderClient, didReceiveIntentForFrame),
-    offsetof(WKBundlePageLoaderClient, registerIntentServiceForFrame),
+    offsetof(WKBundlePageLoaderClient, didReceiveIntentForFrame_unavailable),
+    offsetof(WKBundlePageLoaderClient, registerIntentServiceForFrame_unavailable),
     sizeof(WKBundlePageLoaderClient)
 };
 
@@ -62,7 +62,7 @@ const size_t APIClientTraits<WKPageContextMenuClient>::interfaceSizesByVersion[]
 
 const size_t APIClientTraits<WKPageLoaderClient>::interfaceSizesByVersion[] = {
     offsetof(WKPageLoaderClient, didDetectXSSForFrame),
-    offsetof(WKPageLoaderClient, didReceiveIntentForFrame),
+    offsetof(WKPageLoaderClient, didReceiveIntentForFrame_unavailable),
     sizeof(WKPageLoaderClient)
 };
 
index 3119de6..cac3f77 100644 (file)
@@ -91,8 +91,6 @@ public:
         TypeGrammarDetail,
         TypeIconDatabase,
         TypeInspector,
-        TypeIntentData,
-        TypeIntentServiceInfo,
         TypeKeyValueStorageManager,
         TypeMediaCacheManager,
         TypeNavigationData,
@@ -118,8 +116,6 @@ public:
         TypeBundleFrame,
         TypeBundleHitTestResult,
         TypeBundleInspector,
-        TypeBundleIntent,
-        TypeBundleIntentRequest,
         TypeBundleNavigationAction,
         TypeBundleNodeHandle,
         TypeBundlePage,
diff --git a/Source/WebKit2/Shared/IntentData.cpp b/Source/WebKit2/Shared/IntentData.cpp
deleted file mode 100644 (file)
index 757819e..0000000
+++ /dev/null
@@ -1,95 +0,0 @@
-/*
- * Copyright (C) 2012 Intel Corporation. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
- * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
- * THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#include "config.h"
-#include "IntentData.h"
-
-#if ENABLE(WEB_INTENTS)
-
-#include "APIObject.h"
-#include "DataReference.h"
-#include "WebCoreArgumentCoders.h"
-#include "WebProcess.h"
-#include <WebCore/Intent.h>
-#include <WebCore/MessagePortChannel.h>
-#include <WebCore/PlatformMessagePortChannel.h>
-
-using namespace WebCore;
-
-namespace WebKit {
-
-IntentData::IntentData(Intent* coreIntent)
-    : action(coreIntent->action())
-    , type(coreIntent->type())
-    , service(coreIntent->service())
-    , data(coreIntent->data()->data())
-    , extras(coreIntent->extras())
-    , suggestions(coreIntent->suggestions())
-{
-    MessagePortChannelArray* coreMessagePorts = coreIntent->messagePorts();
-    if (coreMessagePorts) {
-        size_t numMessagePorts = coreMessagePorts->size();
-        for (size_t i = 0; i < numMessagePorts; ++i)
-            messagePorts.append(WebProcess::shared().addMessagePortChannel((*coreMessagePorts)[i]->channel()));
-    }
-}
-
-void IntentData::encode(CoreIPC::ArgumentEncoder& encoder) const
-{
-    encoder.encode(action);
-    encoder.encode(type);
-    encoder.encode(service);
-    encoder.encode(CoreIPC::DataReference(data));
-    encoder.encode(extras);
-    encoder.encode(suggestions);
-    encoder.encode(messagePorts);
-}
-
-bool IntentData::decode(CoreIPC::ArgumentDecoder* decoder, IntentData& intentData)
-{
-    if (!decoder->decode(intentData.action))
-        return false;
-    if (!decoder->decode(intentData.type))
-        return false;
-    if (!decoder->decode(intentData.service))
-        return false;
-    CoreIPC::DataReference data;
-    if (!decoder->decode(data))
-        return false;
-    intentData.data.append(data.data(), data.size());
-    if (!decoder->decode(intentData.extras))
-        return false;
-    if (!decoder->decode(intentData.suggestions))
-        return false;
-    if (!decoder->decode(intentData.messagePorts))
-        return false;
-
-    return true;
-}
-
-} // namespace WebKit
-
-#endif // ENABLE(WEB_INTENTS)
-
diff --git a/Source/WebKit2/Shared/IntentData.h b/Source/WebKit2/Shared/IntentData.h
deleted file mode 100644 (file)
index e3adb19..0000000
+++ /dev/null
@@ -1,67 +0,0 @@
-/*
- * Copyright (C) 2012 Intel Corporation. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
- * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
- * THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#ifndef IntentData_h
-#define IntentData_h
-
-#if ENABLE(WEB_INTENTS)
-
-#include "APIObject.h"
-#include <WebCore/KURL.h>
-#include <wtf/HashMap.h>
-#include <wtf/text/WTFString.h>
-
-namespace CoreIPC {
-class ArgumentDecoder;
-class ArgumentEncoder;
-}
-
-namespace WebCore {
-class Intent;
-}
-
-namespace WebKit {
-
-struct IntentData {
-    IntentData() { }
-    explicit IntentData(WebCore::Intent*);
-
-    void encode(CoreIPC::ArgumentEncoder&) const;
-    static bool decode(CoreIPC::ArgumentDecoder*, IntentData&);
-
-    String action;
-    String type;
-    WebCore::KURL service;
-    Vector<uint8_t> data;
-    HashMap<String, String> extras;
-    Vector<WebCore::KURL> suggestions;
-    Vector<uint64_t> messagePorts;
-};
-
-} // namespace WebKit
-
-#endif // ENABLE(WEB_INTENTS)
-
-#endif // IntentData_h
diff --git a/Source/WebKit2/Shared/IntentServiceInfo.cpp b/Source/WebKit2/Shared/IntentServiceInfo.cpp
deleted file mode 100644 (file)
index 340200e..0000000
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- * Copyright (C) 2012 Intel Corporation. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
- * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
- * THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#include "config.h"
-#include "IntentServiceInfo.h"
-
-#if ENABLE(WEB_INTENTS_TAG)
-
-#include "APIObject.h"
-#include "WebCoreArgumentCoders.h"
-
-using namespace WebCore;
-
-namespace WebKit {
-
-void IntentServiceInfo::encode(CoreIPC::ArgumentEncoder& encoder) const
-{
-    encoder.encode(action);
-    encoder.encode(type);
-    encoder.encode(href);
-    encoder.encode(title);
-    encoder.encode(disposition);
-}
-
-bool IntentServiceInfo::decode(CoreIPC::ArgumentDecoder* decoder, IntentServiceInfo& intentServiceInfo)
-{
-    if (!decoder->decode(intentServiceInfo.action))
-        return false;
-    if (!decoder->decode(intentServiceInfo.type))
-        return false;
-    if (!decoder->decode(intentServiceInfo.href))
-        return false;
-    if (!decoder->decode(intentServiceInfo.title))
-        return false;
-    if (!decoder->decode(intentServiceInfo.disposition))
-        return false;
-
-    return true;
-}
-
-} // namespace WebKit
-
-#endif // ENABLE(WEB_INTENTS_TAG)
diff --git a/Source/WebKit2/Shared/IntentServiceInfo.h b/Source/WebKit2/Shared/IntentServiceInfo.h
deleted file mode 100644 (file)
index ff13d3b..0000000
+++ /dev/null
@@ -1,57 +0,0 @@
-/*
- * Copyright (C) 2012 Intel Corporation. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
- * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
- * THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#ifndef IntentServiceInfo_h
-#define IntentServiceInfo_h
-
-#if ENABLE(WEB_INTENTS_TAG)
-
-#include "APIObject.h"
-#include <WebCore/KURL.h>
-#include <wtf/text/WTFString.h>
-
-namespace CoreIPC {
-class ArgumentDecoder;
-class ArgumentEncoder;
-}
-
-namespace WebKit {
-
-struct IntentServiceInfo {
-    void encode(CoreIPC::ArgumentEncoder&) const;
-    static bool decode(CoreIPC::ArgumentDecoder*, IntentServiceInfo&);
-
-    String action;
-    String type;
-    WebCore::KURL href;
-    String title;
-    String disposition;
-};
-
-} // namespace WebKit
-
-#endif // ENABLE(WEB_INTENTS_TAG)
-
-#endif // IntentServiceInfo_h
diff --git a/Source/WebKit2/Shared/WebIntentServiceInfo.cpp b/Source/WebKit2/Shared/WebIntentServiceInfo.cpp
deleted file mode 100644 (file)
index 84329c5..0000000
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * Copyright (C) 2012 Intel Corporation. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
- * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
- * THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#include "config.h"
-#include "WebIntentServiceInfo.h"
-
-#if ENABLE(WEB_INTENTS_TAG)
-
-namespace WebKit {
-
-WebIntentServiceInfo::WebIntentServiceInfo(const IntentServiceInfo& store)
-    : m_store(store)
-{
-}
-
-} // namespace WebKit
-
-#endif // ENABLE(WEB_INTENTS_TAG)
diff --git a/Source/WebKit2/Shared/WebIntentServiceInfo.h b/Source/WebKit2/Shared/WebIntentServiceInfo.h
deleted file mode 100644 (file)
index 8694601..0000000
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- * Copyright (C) 2012 Intel Corporation. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
- * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
- * THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#ifndef WebIntentServiceInfo_h
-#define WebIntentServiceInfo_h
-
-#if ENABLE(WEB_INTENTS_TAG)
-
-#include "APIObject.h"
-#include "IntentServiceInfo.h"
-#include <wtf/PassRefPtr.h>
-
-namespace WebKit {
-
-class WebIntentServiceInfo : public APIObject {
-public:
-    static const Type APIType = TypeIntentServiceInfo;
-
-    static PassRefPtr<WebIntentServiceInfo> create(const IntentServiceInfo& store)
-    {
-        return adoptRef(new WebIntentServiceInfo(store));
-    }
-
-    virtual ~WebIntentServiceInfo() { }
-
-    const String& action() const { return m_store.action; }
-    const String& payloadType() const { return m_store.type; }
-    const WebCore::KURL& href() const { return m_store.href; }
-    const String& title() const { return m_store.title; }
-    const String& disposition() const { return m_store.disposition; }
-
-private:
-    WebIntentServiceInfo(const IntentServiceInfo&);
-
-    virtual Type type() const { return APIType; }
-
-    IntentServiceInfo m_store;
-};
-
-} // namespace WebKit
-
-#endif // ENABLE(WEB_INTENTS_TAG)
-
-#endif // WebIntentServiceInfo_h
index 232045b..d513b96 100644 (file)
@@ -74,8 +74,6 @@ class WebGrammarDetail;
 class WebHitTestResult;
 class WebIconDatabase;
 class WebInspectorProxy;
-class WebIntentData;
-class WebIntentServiceInfo;
 class WebKeyValueStorageManagerProxy;
 class WebMediaCacheManagerProxy;
 class WebNavigationData;
@@ -119,8 +117,6 @@ WK_ADD_API_MAPPING(WKGeolocationPositionRef, WebGeolocationPosition)
 WK_ADD_API_MAPPING(WKGrammarDetailRef, WebGrammarDetail)
 WK_ADD_API_MAPPING(WKHitTestResultRef, WebHitTestResult)
 WK_ADD_API_MAPPING(WKIconDatabaseRef, WebIconDatabase)
-WK_ADD_API_MAPPING(WKIntentDataRef, WebIntentData)
-WK_ADD_API_MAPPING(WKIntentServiceInfoRef, WebIntentServiceInfo)
 WK_ADD_API_MAPPING(WKKeyValueStorageManagerRef, WebKeyValueStorageManagerProxy)
 WK_ADD_API_MAPPING(WKMediaCacheManagerRef, WebMediaCacheManagerProxy)
 WK_ADD_API_MAPPING(WKNavigationDataRef, WebNavigationData)
diff --git a/Source/WebKit2/UIProcess/API/C/WKIntentData.cpp b/Source/WebKit2/UIProcess/API/C/WKIntentData.cpp
deleted file mode 100644 (file)
index 92e6187..0000000
+++ /dev/null
@@ -1,103 +0,0 @@
-/*
- * Copyright (C) 2012 Intel Corporation. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
- * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
- * THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#include "config.h"
-#include "WKIntentData.h"
-
-#include "ImmutableArray.h"
-#include "ImmutableDictionary.h"
-#include "WKAPICast.h"
-#include "WKDictionary.h"
-#include "WKString.h"
-#include "WebSerializedScriptValue.h"
-
-#if ENABLE(WEB_INTENTS)
-#include "WebIntentData.h"
-#endif
-
-using namespace WebKit;
-
-WKTypeID WKIntentDataGetTypeID()
-{
-#if ENABLE(WEB_INTENTS)
-    return toAPI(WebIntentData::APIType);
-#else
-    return 0;
-#endif
-}
-
-WKStringRef WKIntentDataCopyAction(WKIntentDataRef intentRef)
-{
-#if ENABLE(WEB_INTENTS)
-    return toCopiedAPI(toImpl(intentRef)->action());
-#else
-    return 0;
-#endif
-}
-
-WKStringRef WKIntentDataCopyType(WKIntentDataRef intentRef)
-{
-#if ENABLE(WEB_INTENTS)
-    return toCopiedAPI(toImpl(intentRef)->payloadType());
-#else
-    return 0;
-#endif
-}
-
-WKURLRef WKIntentDataCopyService(WKIntentDataRef intentRef)
-{
-#if ENABLE(WEB_INTENTS)
-    return toCopiedURLAPI(toImpl(intentRef)->service());
-#else
-    return 0;
-#endif
-}
-
-WKArrayRef WKIntentDataCopySuggestions(WKIntentDataRef intentRef)
-{
-#if ENABLE(WEB_INTENTS)
-    return toAPI(toImpl(intentRef)->suggestions().leakRef());
-#else
-    return 0;
-#endif
-}
-
-WKStringRef WKIntentDataCopyExtraValue(WKIntentDataRef intentRef, WKStringRef key)
-{
-#if ENABLE(WEB_INTENTS)
-    return toCopiedAPI(toImpl(intentRef)->extra(toWTFString(key)));
-#else
-    return 0;
-#endif
-}
-
-WKDictionaryRef WKIntentDataCopyExtras(WKIntentDataRef intentRef)
-{
-#if ENABLE(WEB_INTENTS)
-    return toAPI(toImpl(intentRef)->extras().leakRef());
-#else
-    return 0;
-#endif
-}
diff --git a/Source/WebKit2/UIProcess/API/C/WKIntentData.h b/Source/WebKit2/UIProcess/API/C/WKIntentData.h
deleted file mode 100644 (file)
index caf1b45..0000000
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Copyright (C) 2012 Intel Corporation. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
- * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
- * THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#ifndef WKIntentData_h
-#define WKIntentData_h
-
-#include <WebKit2/WKBase.h>
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-WK_EXPORT WKTypeID WKIntentDataGetTypeID();
-
-WK_EXPORT WKStringRef WKIntentDataCopyAction(WKIntentDataRef intentRef);
-WK_EXPORT WKStringRef WKIntentDataCopyType(WKIntentDataRef intentRef);
-WK_EXPORT WKURLRef WKIntentDataCopyService(WKIntentDataRef intentRef);
-WK_EXPORT WKArrayRef WKIntentDataCopySuggestions(WKIntentDataRef intentRef);
-WK_EXPORT WKStringRef WKIntentDataCopyExtraValue(WKIntentDataRef intentRef, WKStringRef key);
-WK_EXPORT WKDictionaryRef WKIntentDataCopyExtras(WKIntentDataRef intentRef);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif // WKIntentData_h
diff --git a/Source/WebKit2/UIProcess/API/C/WKIntentServiceInfo.cpp b/Source/WebKit2/UIProcess/API/C/WKIntentServiceInfo.cpp
deleted file mode 100644 (file)
index 5a30fb7..0000000
+++ /dev/null
@@ -1,89 +0,0 @@
-/*
- * Copyright (C) 2012 Intel Corporation. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
- * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
- * THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#include "config.h"
-#include "WKIntentServiceInfo.h"
-
-#include "WKAPICast.h"
-
-#if ENABLE(WEB_INTENTS_TAG)
-#include "WebIntentServiceInfo.h"
-#endif
-
-using namespace WebKit;
-
-WKTypeID WKIntentServiceInfoGetTypeID()
-{
-#if ENABLE(WEB_INTENTS_TAG)
-    return toAPI(WebIntentServiceInfo::APIType);
-#else
-    return 0;
-#endif
-}
-
-WKStringRef WKIntentServiceInfoCopyAction(WKIntentServiceInfoRef serviceRef)
-{
-#if ENABLE(WEB_INTENTS_TAG)
-    return toCopiedAPI(toImpl(serviceRef)->action());
-#else
-    return 0;
-#endif
-}
-
-WKStringRef WKIntentServiceInfoCopyType(WKIntentServiceInfoRef serviceRef)
-{
-#if ENABLE(WEB_INTENTS_TAG)
-    return toCopiedAPI(toImpl(serviceRef)->payloadType());
-#else
-    return 0;
-#endif
-}
-
-WKURLRef WKIntentServiceInfoCopyHref(WKIntentServiceInfoRef serviceRef)
-{
-#if ENABLE(WEB_INTENTS_TAG)
-    return toCopiedURLAPI(toImpl(serviceRef)->href());
-#else
-    return 0;
-#endif
-}
-
-WKStringRef WKIntentServiceInfoCopyTitle(WKIntentServiceInfoRef serviceRef)
-{
-#if ENABLE(WEB_INTENTS_TAG)
-    return toCopiedAPI(toImpl(serviceRef)->title());
-#else
-    return 0;
-#endif
-}
-
-WKStringRef WKIntentServiceInfoCopyDisposition(WKIntentServiceInfoRef serviceRef)
-{
-#if ENABLE(WEB_INTENTS_TAG)
-    return toCopiedAPI(toImpl(serviceRef)->disposition());
-#else
-    return 0;
-#endif
-}
diff --git a/Source/WebKit2/UIProcess/API/C/WKIntentServiceInfo.h b/Source/WebKit2/UIProcess/API/C/WKIntentServiceInfo.h
deleted file mode 100644 (file)
index 121cffd..0000000
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * Copyright (C) 2012 Intel Corporation. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
- * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
- * THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#ifndef WKIntentServiceInfo_h
-#define WKIntentServiceInfo_h
-
-#include <WebKit2/WKBase.h>
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-WK_EXPORT WKTypeID WKIntentServiceInfoGetTypeID();
-WK_EXPORT WKStringRef WKIntentServiceInfoCopyAction(WKIntentServiceInfoRef serviceRef);
-WK_EXPORT WKStringRef WKIntentServiceInfoCopyType(WKIntentServiceInfoRef serviceRef);
-WK_EXPORT WKURLRef WKIntentServiceInfoCopyHref(WKIntentServiceInfoRef serviceRef);
-WK_EXPORT WKStringRef WKIntentServiceInfoCopyTitle(WKIntentServiceInfoRef serviceRef);
-WK_EXPORT WKStringRef WKIntentServiceInfoCopyDisposition(WKIntentServiceInfoRef serviceRef);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif // WKIntentServiceInfo_h
index df4af68..550d7be 100644 (file)
@@ -760,13 +760,6 @@ void WKPageEndPrinting(WKPageRef page)
 }
 #endif
 
-void WKPageDeliverIntentToFrame(WKPageRef page, WKFrameRef frame, WKIntentDataRef intent)
-{
-#if ENABLE(WEB_INTENTS)
-    toImpl(page)->deliverIntentToFrame(toImpl(frame), toImpl(intent));
-#endif
-}
-
 WKImageRef WKPageCreateSnapshotOfVisibleContent(WKPageRef)
 {
     return 0;
index dea2c11..8f051dd 100644 (file)
@@ -74,8 +74,6 @@ typedef bool (*WKPageShouldGoToBackForwardListItemCallback)(WKPageRef page, WKBa
 typedef void (*WKPageDidNewFirstVisuallyNonEmptyLayoutCallback)(WKPageRef page, WKTypeRef userData, const void *clientInfo);
 typedef void (*WKPageWillGoToBackForwardListItemCallback)(WKPageRef page, WKBackForwardListItemRef item, WKTypeRef userData, const void *clientInfo);
 typedef void (*WKPagePluginDidFailCallback)(WKPageRef page, WKErrorCode errorCode, WKStringRef mimeType, WKStringRef pluginIdentifier, WKStringRef pluginVersion, const void* clientInfo);
-typedef void (*WKPageDidReceiveIntentForFrameCallback)(WKPageRef page, WKFrameRef frame, WKIntentDataRef intent, WKTypeRef userData, const void *clientInfo);
-typedef void (*WKPageRegisterIntentServiceForFrameCallback)(WKPageRef page, WKFrameRef frame, WKIntentServiceInfoRef serviceInfo, WKTypeRef userData, const void *clientInfo);
 typedef void (*WKPageDidLayoutCallback)(WKPageRef page, WKLayoutMilestones milestones, WKTypeRef userData, const void *clientInfo);
 
 // Deprecated
@@ -127,8 +125,8 @@ struct WKPageLoaderClient {
     WKPagePluginDidFailCallback                                         pluginDidFail;
 
     // Version 2
-    WKPageDidReceiveIntentForFrameCallback                              didReceiveIntentForFrame;
-    WKPageRegisterIntentServiceForFrameCallback                         registerIntentServiceForFrame;
+    void                                                                (*didReceiveIntentForFrame_unavailable)(void);
+    void                                                                (*registerIntentServiceForFrame_unavailable)(void);
 
     WKPageDidLayoutCallback                                             didLayout;
 };
@@ -489,8 +487,6 @@ WK_EXPORT void WKPageGetSelectionAsWebArchiveData(WKPageRef page, void* context,
 typedef void (*WKPageForceRepaintFunction)(WKErrorRef, void*);
 WK_EXPORT void WKPageForceRepaint(WKPageRef page, void* context, WKPageForceRepaintFunction function);
 
-WK_EXPORT void WKPageDeliverIntentToFrame(WKPageRef page, WKFrameRef frame, WKIntentDataRef intent);
-
 /*
     Some of the more common command name strings include the following, although any WebCore EditorCommand string is supported:
     
diff --git a/Source/WebKit2/UIProcess/WebIntentData.cpp b/Source/WebKit2/UIProcess/WebIntentData.cpp
deleted file mode 100644 (file)
index c6d8c64..0000000
+++ /dev/null
@@ -1,89 +0,0 @@
-/*
- * Copyright (C) 2012 Intel Corporation. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
- * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
- * THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#include "config.h"
-#include "WebIntentData.h"
-
-#if ENABLE(WEB_INTENTS)
-
-#include "ImmutableArray.h"
-#include "ImmutableDictionary.h"
-#include "WebProcessProxy.h"
-#include "WebSerializedScriptValue.h"
-#include "WebString.h"
-#include "WebURL.h"
-
-namespace WebKit {
-
-WebIntentData::WebIntentData(const IntentData& store, WebProcessProxy* process)
-    : m_store(store)
-    , m_process(process)
-{
-}
-
-WebIntentData::~WebIntentData()
-{
-    // Remove MessagePortChannels from WebProcess.
-    if (m_process) {
-        size_t numMessagePorts = m_store.messagePorts.size();
-        for (size_t i = 0; i < numMessagePorts; ++i)
-            m_process->removeMessagePortChannel(m_store.messagePorts[i]);
-    }
-}
-
-PassRefPtr<WebSerializedScriptValue> WebIntentData::data() const
-{
-    Vector<uint8_t> dataCopy = m_store.data;
-    return WebSerializedScriptValue::adopt(dataCopy);
-}
-
-PassRefPtr<ImmutableArray> WebIntentData::suggestions() const
-{
-    const size_t numSuggestions = m_store.suggestions.size();
-    Vector<RefPtr<APIObject> > wkSuggestions(numSuggestions);
-    for (unsigned i = 0; i < numSuggestions; ++i)
-        wkSuggestions[i] = WebURL::create(m_store.suggestions[i]);
-    return ImmutableArray::adopt(wkSuggestions);
-}
-
-String WebIntentData::extra(const String& key) const
-{
-    return m_store.extras.get(key);
-}
-
-PassRefPtr<ImmutableDictionary> WebIntentData::extras() const
-{
-    ImmutableDictionary::MapType wkExtras;
-    HashMap<String, String>::const_iterator end = m_store.extras.end();
-    for (HashMap<String, String>::const_iterator it = m_store.extras.begin(); it != end; ++it)
-        wkExtras.set(it->key, WebString::create(it->value));
-
-    return ImmutableDictionary::adopt(wkExtras);
-}
-
-} // namespace WebKit
-
-#endif // ENABLE(WEB_INTENTS)
-
diff --git a/Source/WebKit2/UIProcess/WebIntentData.h b/Source/WebKit2/UIProcess/WebIntentData.h
deleted file mode 100644 (file)
index 9d59f90..0000000
+++ /dev/null
@@ -1,77 +0,0 @@
-/*
- * Copyright (C) 2012 Intel Corporation. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
- * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
- * THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#ifndef WebIntentData_h
-#define WebIntentData_h
-
-#if ENABLE(WEB_INTENTS)
-
-#include "APIObject.h"
-#include "IntentData.h"
-#include <WebCore/KURL.h>
-#include <wtf/PassRefPtr.h>
-
-namespace WebKit {
-
-class ImmutableArray;
-class ImmutableDictionary;
-class WebProcessProxy;
-class WebSerializedScriptValue;
-
-class WebIntentData : public APIObject {
-public:
-    static const Type APIType = TypeIntentData;
-
-    static PassRefPtr<WebIntentData> create(const IntentData& store, WebProcessProxy* process)
-    {
-        return adoptRef(new WebIntentData(store, process));
-    }
-
-    virtual ~WebIntentData();
-
-    const String& action() const { return m_store.action; }
-    const String& payloadType() const { return m_store.type; }
-    const WebCore::KURL& service() const { return m_store.service; }
-    PassRefPtr<WebSerializedScriptValue> data() const;
-    String extra(const String& key) const;
-    PassRefPtr<ImmutableDictionary> extras() const;
-    PassRefPtr<ImmutableArray> suggestions() const;
-
-    const IntentData& store() const { return m_store; }
-
-private:
-    WebIntentData(const IntentData&, WebProcessProxy*);
-
-    virtual Type type() const { return APIType; }
-
-    IntentData m_store;
-    WebProcessProxy* m_process;
-};
-
-} // namespace WebKit
-
-#endif // ENABLE(WEB_INTENTS)
-
-#endif // WebIntentData_h
index 93c60d4..674ddb1 100644 (file)
 #include "WebBackForwardListItem.h"
 #include <string.h>
 
-#if ENABLE(WEB_INTENTS)
-#include "WebIntentData.h"
-#include "WebIntentServiceInfo.h"
-#endif
-
 using namespace WebCore;
 
 namespace WebKit {
@@ -176,26 +171,6 @@ void WebLoaderClient::didDetectXSSForFrame(WebPageProxy* page, WebFrameProxy* fr
     m_client.didDetectXSSForFrame(toAPI(page), toAPI(frame), toAPI(userData), m_client.clientInfo);
 }
 
-#if ENABLE(WEB_INTENTS)
-void WebLoaderClient::didReceiveIntentForFrame(WebPageProxy* page, WebFrameProxy* frame, WebIntentData* intentData, APIObject* userData)
-{
-    if (!m_client.didReceiveIntentForFrame)
-        return;
-
-    m_client.didReceiveIntentForFrame(toAPI(page), toAPI(frame), toAPI(intentData), toAPI(userData), m_client.clientInfo);
-}
-#endif
-
-#if ENABLE(WEB_INTENTS_TAG)
-void WebLoaderClient::registerIntentServiceForFrame(WebPageProxy* page, WebFrameProxy* frame, WebIntentServiceInfo* serviceInfo, APIObject* userData)
-{
-    if (!m_client.registerIntentServiceForFrame)
-        return;
-
-    m_client.registerIntentServiceForFrame(toAPI(page), toAPI(frame), toAPI(serviceInfo), toAPI(userData), m_client.clientInfo);
-}
-#endif
-
 bool WebLoaderClient::canAuthenticateAgainstProtectionSpaceInFrame(WebPageProxy* page, WebFrameProxy* frame, WebProtectionSpace* protectionSpace)
 {
     if (!m_client.canAuthenticateAgainstProtectionSpaceInFrame)
index 85f1072..53f24b9 100644 (file)
@@ -48,14 +48,6 @@ class WebFrameProxy;
 class WebPageProxy;
 class WebProtectionSpace;
 
-#if ENABLE(WEB_INTENTS)
-class WebIntentData;
-#endif
-
-#if ENABLE(WEB_INTENTS_TAG)
-class WebIntentServiceInfo;
-#endif
-
 class WebLoaderClient : public APIClient<WKPageLoaderClient, kWKPageLoaderClientCurrentVersion> {
 public:
     void didStartProvisionalLoadForFrame(WebPageProxy*, WebFrameProxy*, APIObject*);
@@ -73,13 +65,6 @@ public:
     void didDisplayInsecureContentForFrame(WebPageProxy*, WebFrameProxy*, APIObject*);
     void didRunInsecureContentForFrame(WebPageProxy*, WebFrameProxy*, APIObject*);
     void didDetectXSSForFrame(WebPageProxy*, WebFrameProxy*, APIObject*);
-#if ENABLE(WEB_INTENTS)
-    void didReceiveIntentForFrame(WebPageProxy*, WebFrameProxy*, WebIntentData*, APIObject*);
-#endif
-
-#if ENABLE(WEB_INTENTS_TAG)
-    void registerIntentServiceForFrame(WebPageProxy*, WebFrameProxy*, WebIntentServiceInfo*, APIObject*);
-#endif
 
     // FIXME: didNewFirstVisuallyNonEmptyLayout should be removed. We should consider removing didFirstVisuallyNonEmptyLayoutForFrame
     // as well. They are both being replaced by didLayout.
index 5c2c436..51e27af 100644 (file)
 #include <WebCore/WindowFeatures.h>
 #include <stdio.h>
 
-#if ENABLE(WEB_INTENTS)
-#include "IntentData.h"
-#include "IntentServiceInfo.h"
-#include "WebIntentData.h"
-#include "WebIntentServiceInfo.h"
-#endif
-
 #if USE(COORDINATED_GRAPHICS)
 #include "CoordinatedLayerTreeHostProxyMessages.h"
 #endif
@@ -1787,16 +1780,6 @@ void WebPageProxy::getSourceForFrame(WebFrameProxy* frame, PassRefPtr<StringCall
     m_process->send(Messages::WebPage::GetSourceForFrame(frame->frameID(), callbackID), m_pageID);
 }
 
-#if ENABLE(WEB_INTENTS)
-void WebPageProxy::deliverIntentToFrame(WebFrameProxy* frame, WebIntentData* webIntentData)
-{
-    if (!isValid())
-        return;
-
-    m_process->send(Messages::WebPage::DeliverIntentToFrame(frame->frameID(), webIntentData->store()), m_pageID);
-}
-#endif
-
 void WebPageProxy::getContentsAsString(PassRefPtr<StringCallback> prpCallback)
 {
     RefPtr<StringCallback> callback = prpCallback;
@@ -2079,22 +2062,6 @@ void WebPageProxy::didFinishProgress()
     m_loaderClient.didFinishProgress(this);
 }
 
-#if ENABLE(WEB_INTENTS_TAG)
-void WebPageProxy::registerIntentServiceForFrame(uint64_t frameID, const IntentServiceInfo& serviceInfo, CoreIPC::MessageDecoder& decoder)
-{
-    RefPtr<APIObject> userData;
-    WebContextUserMessageDecoder messageDecoder(userData, m_process.get());
-    if (!decoder.decode(messageDecoder))
-        return;
-
-    WebFrameProxy* frame = m_process->webFrame(frameID);
-    MESSAGE_CHECK(frame);
-
-    RefPtr<WebIntentServiceInfo> webIntentServiceInfo = WebIntentServiceInfo::create(serviceInfo);
-    m_loaderClient.registerIntentServiceForFrame(this, frame, webIntentServiceInfo.get(), userData.get());
-}
-#endif
-
 void WebPageProxy::didStartProvisionalLoadForFrame(uint64_t frameID, const String& url, const String& unreachableURL, CoreIPC::MessageDecoder& decoder)
 {
     clearPendingAPIRequestURL();
@@ -2382,22 +2349,6 @@ void WebPageProxy::didDetectXSSForFrame(uint64_t frameID, CoreIPC::MessageDecode
     m_loaderClient.didDetectXSSForFrame(this, frame, userData.get());
 }
 
-#if ENABLE(WEB_INTENTS)
-void WebPageProxy::didReceiveIntentForFrame(uint64_t frameID, const IntentData& intentData, CoreIPC::MessageDecoder& decoder)
-{
-    RefPtr<APIObject> userData;
-    WebContextUserMessageDecoder messageDecoder(userData, m_process.get());
-    if (!decoder.decode(messageDecoder))
-        return;
-
-    WebFrameProxy* frame = m_process->webFrame(frameID);
-    MESSAGE_CHECK(frame);
-
-    RefPtr<WebIntentData> webIntentData = WebIntentData::create(intentData, m_process.get());
-    m_loaderClient.didReceiveIntentForFrame(this, frame, webIntentData.get(), userData.get());
-}
-#endif
-
 void WebPageProxy::frameDidBecomeFrameSet(uint64_t frameID, bool value)
 {
     WebFrameProxy* frame = m_process->webFrame(frameID);
index de3ad5c..3aa20fc 100644 (file)
@@ -124,10 +124,6 @@ typedef GtkWidget* PlatformWidget;
 typedef Evas_Object* PlatformWidget;
 #endif
 
-#if ENABLE(WEB_INTENTS)
-class WebIntentData;
-#endif
-
 namespace WebKit {
 
 class NativeWebKeyboardEvent;
@@ -167,14 +163,6 @@ class WebGestureEvent;
 class WebVibrationProxy;
 #endif
 
-#if ENABLE(WEB_INTENTS)
-struct IntentData;
-#endif
-
-#if ENABLE(WEB_INTENTS_TAG)
-struct IntentServiceInfo;
-#endif
-
 typedef GenericCallback<WKStringRef, StringImpl*> StringCallback;
 typedef GenericCallback<WKSerializedScriptValueRef, WebSerializedScriptValue*> ScriptValueCallback;
 
@@ -563,10 +551,6 @@ public:
     void runJavaScriptInMainFrame(const String&, PassRefPtr<ScriptValueCallback>);
     void forceRepaint(PassRefPtr<VoidCallback>);
 
-#if ENABLE(WEB_INTENTS)
-    void deliverIntentToFrame(WebFrameProxy*, WebIntentData*);
-#endif
-
     float headerHeight(WebFrameProxy*);
     float footerHeight(WebFrameProxy*);
     void drawHeader(WebFrameProxy*, const WebCore::FloatRect&);
@@ -808,13 +792,6 @@ private:
     void didChangeProgress(double);
     void didFinishProgress();
 
-#if ENABLE(WEB_INTENTS)
-    void didReceiveIntentForFrame(uint64_t frameID, const IntentData&, CoreIPC::MessageDecoder&);
-#endif
-#if ENABLE(WEB_INTENTS_TAG)
-    void registerIntentServiceForFrame(uint64_t frameID, const IntentServiceInfo&, CoreIPC::MessageDecoder&);
-#endif
-    
     void decidePolicyForNavigationAction(uint64_t frameID, uint32_t navigationType, uint32_t modifiers, int32_t mouseButton, const WebCore::ResourceRequest&, uint64_t listenerID, CoreIPC::MessageDecoder&, bool& receivedPolicyAction, uint64_t& policyAction, uint64_t& downloadID);
     void decidePolicyForNewWindowAction(uint64_t frameID, uint32_t navigationType, uint32_t modifiers, int32_t mouseButton, const WebCore::ResourceRequest&, const String& frameName, uint64_t listenerID, CoreIPC::MessageDecoder&);
     void decidePolicyForResponse(uint64_t frameID, const WebCore::ResourceResponse&, const WebCore::ResourceRequest&, uint64_t listenerID, CoreIPC::MessageDecoder&, bool& receivedPolicyAction, uint64_t& policyAction, uint64_t& downloadID);
index 011ed3f..0f95194 100644 (file)
@@ -104,14 +104,6 @@ messages -> WebPageProxy LegacyReceiver {
     DecidePolicyForNewWindowAction(uint64_t frameID, uint32_t navigationType, uint32_t modifiers, int32_t mouseButton, WebCore::ResourceRequest request, WTF::String frameName, uint64_t listenerID, WebKit::InjectedBundleUserMessageEncoder userData) Variadic
     UnableToImplementPolicy(uint64_t frameID, WebCore::ResourceError error, WebKit::InjectedBundleUserMessageEncoder userData)  Variadic
 
-    # Intent messages
-#if ENABLE(WEB_INTENTS)
-    DidReceiveIntentForFrame(uint64_t frameID, WebKit::IntentData intent, WebKit::InjectedBundleUserMessageEncoder userData) Variadic
-#endif
-#if ENABLE(WEB_INTENTS_TAG)
-    RegisterIntentServiceForFrame(uint64_t frameID, WebKit::IntentServiceInfo serviceInfo, WebKit::InjectedBundleUserMessageEncoder userData) Variadic
-#endif
-
     # Progress messages
     DidChangeProgress(double value)
     DidFinishProgress()
index 174cd5f..c70536a 100644 (file)
@@ -214,16 +214,6 @@ Vector<WebPageProxy*> WebProcessProxy::pages() const
     return result;
 }
 
-#if ENABLE(WEB_INTENTS)
-void WebProcessProxy::removeMessagePortChannel(uint64_t channelID)
-{
-    if (!isValid())
-        return;
-
-    send(Messages::WebProcess::RemoveMessagePortChannel(channelID), /* destinationID */ 0);
-}
-#endif
-
 WebBackForwardListItem* WebProcessProxy::webBackForwardItem(uint64_t itemID) const
 {
     return m_backForwardListItemMap.get(itemID).get();
index 1402026..d2798ca 100644 (file)
@@ -85,10 +85,6 @@ public:
     void removeWebPage(uint64_t pageID);
     Vector<WebPageProxy*> pages() const;
 
-#if ENABLE(WEB_INTENTS)
-    void removeMessagePortChannel(uint64_t channelID);
-#endif
-
     WebBackForwardListItem* webBackForwardItem(uint64_t itemID) const;
 
     ResponsivenessTimer* responsivenessTimer() { return &m_responsivenessTimer; }
index 59c3570..aeccf8a 100644 (file)
@@ -44,8 +44,6 @@ class InjectedBundleBackForwardList;
 class InjectedBundleBackForwardListItem;
 class InjectedBundleDOMWindowExtension;
 class InjectedBundleHitTestResult;
-class InjectedBundleIntent;
-class InjectedBundleIntentRequest;
 class InjectedBundleNavigationAction;
 class InjectedBundleNodeHandle;
 class InjectedBundleRangeHandle;
@@ -63,8 +61,6 @@ WK_ADD_API_MAPPING(WKBundleDOMWindowExtensionRef, InjectedBundleDOMWindowExtensi
 WK_ADD_API_MAPPING(WKBundleFrameRef, WebFrame)
 WK_ADD_API_MAPPING(WKBundleHitTestResultRef, InjectedBundleHitTestResult)
 WK_ADD_API_MAPPING(WKBundleInspectorRef, WebInspector)
-WK_ADD_API_MAPPING(WKBundleIntentRef, InjectedBundleIntent)
-WK_ADD_API_MAPPING(WKBundleIntentRequestRef, InjectedBundleIntentRequest)
 WK_ADD_API_MAPPING(WKBundleNavigationActionRef, InjectedBundleNavigationAction)
 WK_ADD_API_MAPPING(WKBundleNodeHandleRef, InjectedBundleNodeHandle)
 WK_ADD_API_MAPPING(WKBundlePageGroupRef, WebPageGroupProxy)
diff --git a/Source/WebKit2/WebProcess/InjectedBundle/API/c/WKBundleIntent.cpp b/Source/WebKit2/WebProcess/InjectedBundle/API/c/WKBundleIntent.cpp
deleted file mode 100644 (file)
index 66bee90..0000000
+++ /dev/null
@@ -1,138 +0,0 @@
-/*
- * Copyright (C) 2012 Intel Corporation. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
- * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
- * THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#include "config.h"
-#include "WKBundleIntent.h"
-
-#if ENABLE(WEB_INTENTS)
-#include "ImmutableArray.h"
-#include "ImmutableDictionary.h"
-#include "InjectedBundleIntent.h"
-#include "WKAPICast.h"
-#include "WKBundleAPICast.h"
-#include "WKDictionary.h"
-#include "WKRetainPtr.h"
-#include "WKString.h"
-#include "WebSerializedScriptValue.h"
-
-using namespace WebCore;
-using namespace WebKit;
-#endif
-
-WKTypeID WKBundleIntentGetTypeID()
-{
-#if ENABLE(WEB_INTENTS)
-    return toAPI(InjectedBundleIntent::APIType);
-#else
-    return 0;
-#endif
-}
-
-WKBundleIntentRef WKBundleIntentCreate(WKDictionaryRef dictionaryRef)
-{
-#if ENABLE(WEB_INTENTS)
-    WKRetainPtr<WKStringRef> actionKey(AdoptWK, WKStringCreateWithUTF8CString("action"));
-    WKStringRef action = static_cast<WKStringRef>(WKDictionaryGetItemForKey(dictionaryRef, actionKey.get()));
-    ASSERT(action);
-    WKRetainPtr<WKStringRef> typeKey(AdoptWK, WKStringCreateWithUTF8CString("type"));
-    WKStringRef type = static_cast<WKStringRef>(WKDictionaryGetItemForKey(dictionaryRef, typeKey.get()));
-    ASSERT(type);
-    WKRetainPtr<WKStringRef> dataKey(AdoptWK, WKStringCreateWithUTF8CString("data"));
-    WKSerializedScriptValueRef data = static_cast<WKSerializedScriptValueRef>(WKDictionaryGetItemForKey(dictionaryRef, dataKey.get()));
-    MessagePortArray dummyPorts;
-    ExceptionCode ec;
-
-    RefPtr<Intent> coreIntent = Intent::create(toWTFString(action), toWTFString(type), data ? static_cast<SerializedScriptValue*>(toImpl(data)->internalRepresentation()) : 0, dummyPorts, ec);
-
-    return toAPI(InjectedBundleIntent::create(coreIntent.get()).leakRef());
-#else
-    return 0;
-#endif
-}
-
-WKStringRef WKBundleIntentCopyAction(WKBundleIntentRef intentRef)
-{
-#if ENABLE(WEB_INTENTS)
-    return toCopiedAPI(toImpl(intentRef)->action());
-#else
-    return 0;
-#endif
-}
-
-WKStringRef WKBundleIntentCopyType(WKBundleIntentRef intentRef)
-{
-#if ENABLE(WEB_INTENTS)
-    return toCopiedAPI(toImpl(intentRef)->payloadType());
-#else
-    return 0;
-#endif
-}
-
-WKURLRef WKBundleIntentCopyService(WKBundleIntentRef intentRef)
-{
-#if ENABLE(WEB_INTENTS)
-    return toCopiedURLAPI(toImpl(intentRef)->service());
-#else
-    return 0;
-#endif
-}
-
-WKArrayRef WKBundleIntentCopySuggestions(WKBundleIntentRef intentRef)
-{
-#if ENABLE(WEB_INTENTS)
-    return toAPI(toImpl(intentRef)->suggestions().leakRef());
-#else
-    return 0;
-#endif
-}
-
-WKStringRef WKBundleIntentCopyExtraValue(WKBundleIntentRef intentRef, WKStringRef key)
-{
-#if ENABLE(WEB_INTENTS)
-    return toCopiedAPI(toImpl(intentRef)->extra(toWTFString(key)));
-#else
-    return 0;
-#endif
-}
-
-WKDictionaryRef WKBundleIntentCopyExtras(WKBundleIntentRef intentRef)
-{
-#if ENABLE(WEB_INTENTS)
-    return toAPI(toImpl(intentRef)->extras().leakRef());
-#else
-    return 0;
-#endif
-}
-
-size_t WKBundleIntentMessagePortCount(WKBundleIntentRef intentRef)
-{
-#if ENABLE(WEB_INTENTS)
-    MessagePortChannelArray* messagePorts = toImpl(intentRef)->coreIntent()->messagePorts();
-
-    return messagePorts ? messagePorts->size() : 0;
-#else
-    return 0;
-#endif
-}
diff --git a/Source/WebKit2/WebProcess/InjectedBundle/API/c/WKBundleIntent.h b/Source/WebKit2/WebProcess/InjectedBundle/API/c/WKBundleIntent.h
deleted file mode 100644 (file)
index 503fe02..0000000
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * Copyright (C) 2012 Intel Corporation. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
- * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
- * THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#ifndef WKBundleIntent_h
-#define WKBundleIntent_h
-
-#include <WebKit2/WKBase.h>
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-WK_EXPORT WKTypeID WKBundleIntentGetTypeID();
-
-WK_EXPORT WKBundleIntentRef WKBundleIntentCreate(WKDictionaryRef dictionaryRef);
-
-WK_EXPORT WKStringRef WKBundleIntentCopyAction(WKBundleIntentRef intentRef);
-WK_EXPORT WKStringRef WKBundleIntentCopyType(WKBundleIntentRef intentRef);
-WK_EXPORT WKURLRef WKBundleIntentCopyService(WKBundleIntentRef intentRef);
-WK_EXPORT WKArrayRef WKBundleIntentCopySuggestions(WKBundleIntentRef intentRef);
-WK_EXPORT WKStringRef WKBundleIntentCopyExtraValue(WKBundleIntentRef intentRef, WKStringRef key);
-WK_EXPORT WKDictionaryRef WKBundleIntentCopyExtras(WKBundleIntentRef intentRef);
-WK_EXPORT size_t WKBundleIntentMessagePortCount(WKBundleIntentRef intentRef);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif // WKBundleIntent_h
diff --git a/Source/WebKit2/WebProcess/InjectedBundle/API/c/WKBundleIntentRequest.cpp b/Source/WebKit2/WebProcess/InjectedBundle/API/c/WKBundleIntentRequest.cpp
deleted file mode 100644 (file)
index a4772ea..0000000
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- * Copyright (C) 2012 Intel Corporation. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
- * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
- * THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#include "config.h"
-#include "WKBundleIntentRequest.h"
-
-#if ENABLE(WEB_INTENTS)
-#include "InjectedBundleIntent.h"
-#include "InjectedBundleIntentRequest.h"
-#include "WKAPICast.h"
-#include "WKBundleAPICast.h"
-
-using namespace WebKit;
-#endif
-
-WKTypeID WKBundleIntentRequestGetTypeID()
-{
-#if ENABLE(WEB_INTENTS)
-    return toAPI(InjectedBundleIntentRequest::APIType);
-#else
-    return 0;
-#endif
-}
-
-WKBundleIntentRef WKBundleIntentRequestCopyIntent(WKBundleIntentRequestRef requestRef)
-{
-#if ENABLE(WEB_INTENTS)
-    RefPtr<InjectedBundleIntent> webIntent = toImpl(requestRef)->intent();
-    return toAPI(webIntent.release().leakRef());
-#else
-    return 0;
-#endif
-}
-
-void WKBundleIntentRequestPostResult(WKBundleIntentRequestRef requestRef, WKSerializedScriptValueRef serializedDataRef)
-{
-#if ENABLE(WEB_INTENTS)
-    return toImpl(requestRef)->postResult(toImpl(serializedDataRef));
-#endif
-}
-
-void WKBundleIntentRequestPostFailure(WKBundleIntentRequestRef requestRef, WKSerializedScriptValueRef serializedDataRef)
-{
-#if ENABLE(WEB_INTENTS)
-    return toImpl(requestRef)->postFailure(toImpl(serializedDataRef));
-#endif
-}
diff --git a/Source/WebKit2/WebProcess/InjectedBundle/API/c/WKBundleIntentRequest.h b/Source/WebKit2/WebProcess/InjectedBundle/API/c/WKBundleIntentRequest.h
deleted file mode 100644 (file)
index 105afa4..0000000
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * Copyright (C) 2012 Intel Corporation. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
- * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
- * THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#ifndef WKBundleIntentRequest_h
-#define WKBundleIntentRequest_h
-
-#include <WebKit2/WKBase.h>
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-WK_EXPORT WKTypeID WKBundleIntentRequestGetTypeID();
-
-WK_EXPORT WKBundleIntentRef WKBundleIntentRequestCopyIntent(WKBundleIntentRequestRef request);
-
-WK_EXPORT void WKBundleIntentRequestPostResult(WKBundleIntentRequestRef request, WKSerializedScriptValueRef serializedData);
-WK_EXPORT void WKBundleIntentRequestPostFailure(WKBundleIntentRequestRef request, WKSerializedScriptValueRef serializedData);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* WKBundleIntentRequest_h */
index 5fe4c64..2a5538e 100644 (file)
 #include <WebCore/Page.h>
 #include <wtf/UnusedParam.h>
 
-#if ENABLE(WEB_INTENTS)
-#include "InjectedBundleIntent.h"
-#endif
-
 using namespace WebKit;
 
 WKTypeID WKBundlePageGetTypeID()
@@ -359,13 +355,6 @@ void WKBundlePageListenForLayoutMilestones(WKBundlePageRef pageRef, WKLayoutMile
     toImpl(pageRef)->listenForLayoutMilestones(toLayoutMilestones(milestones));
 }
 
-void WKBundlePageDeliverIntentToFrame(WKBundlePageRef pageRef, WKBundleFrameRef frameRef, WKBundleIntentRef intentRef)
-{
-#if ENABLE(WEB_INTENTS)
-    toImpl(pageRef)->deliverCoreIntentToFrame(toImpl(frameRef)->frameID(), toImpl(intentRef)->coreIntent());
-#endif
-}
-
 WKBundleInspectorRef WKBundlePageGetInspector(WKBundlePageRef pageRef)
 {
 #if ENABLE(INSPECTOR)
index 3f31aa7..73134b4 100644 (file)
@@ -109,8 +109,6 @@ typedef void (*WKBundlePageWillDisconnectDOMWindowExtensionFromGlobalObjectCallb
 typedef void (*WKBundlePageDidReconnectDOMWindowExtensionToGlobalObjectCallback)(WKBundlePageRef page, WKBundleDOMWindowExtensionRef, const void* clientInfo);
 typedef void (*WKBundlePageWillDestroyGlobalObjectForDOMWindowExtensionCallback)(WKBundlePageRef page, WKBundleDOMWindowExtensionRef, const void* clientInfo);
 typedef bool (*WKBundlePageShouldForceUniversalAccessFromLocalURLCallback)(WKBundlePageRef, WKStringRef url, const void* clientInfo);
-typedef void (*WKBundlePageDidReceiveIntentForFrameCallback)(WKBundlePageRef page, WKBundleFrameRef frame, WKBundleIntentRequestRef intentRequest, WKTypeRef* userData, const void* clientInfo);
-typedef void (*WKBundlePageRegisterIntentServiceForFrameCallback)(WKBundlePageRef page, WKBundleFrameRef frame, WKIntentServiceInfoRef serviceInfo, WKTypeRef* userData, const void* clientInfo);
 typedef void (*WKBundlePageDidLayoutCallback)(WKBundlePageRef page, WKLayoutMilestones milestones, WKTypeRef* userData, const void *clientInfo);
 
 struct WKBundlePageLoaderClient {
@@ -152,8 +150,8 @@ struct WKBundlePageLoaderClient {
     WKBundlePageShouldForceUniversalAccessFromLocalURLCallback              shouldForceUniversalAccessFromLocalURL;
 
     // Version 3
-    WKBundlePageDidReceiveIntentForFrameCallback                            didReceiveIntentForFrame;
-    WKBundlePageRegisterIntentServiceForFrameCallback                       registerIntentServiceForFrame;
+    void *                                                                  didReceiveIntentForFrame_unavailable;
+    void *                                                                  registerIntentServiceForFrame_unavailable;
 
     // Version 4
     WKBundlePageDidLayoutCallback                                           didLayout;
@@ -441,8 +439,6 @@ WK_EXPORT double WKBundlePageGetBackingScaleFactor(WKBundlePageRef page);
 
 WK_EXPORT void WKBundlePageListenForLayoutMilestones(WKBundlePageRef page, WKLayoutMilestones milestones);
 
-WK_EXPORT void WKBundlePageDeliverIntentToFrame(WKBundlePageRef page, WKBundleFrameRef frame, WKBundleIntentRef intent);
-
 WK_EXPORT WKBundleInspectorRef WKBundlePageGetInspector(WKBundlePageRef page);
 
 #ifdef __cplusplus
diff --git a/Source/WebKit2/WebProcess/InjectedBundle/InjectedBundleIntent.cpp b/Source/WebKit2/WebProcess/InjectedBundle/InjectedBundleIntent.cpp
deleted file mode 100644 (file)
index d8ac3a2..0000000
+++ /dev/null
@@ -1,100 +0,0 @@
-/*
- * Copyright (C) 2012 Intel Corporation. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
- * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
- * THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#include "config.h"
-#include "InjectedBundleIntent.h"
-
-#if ENABLE(WEB_INTENTS)
-
-#include "ImmutableArray.h"
-#include "ImmutableDictionary.h"
-#include "WebSerializedScriptValue.h"
-#include "WebString.h"
-#include "WebURL.h"
-
-using namespace WebCore;
-
-namespace WebKit {
-
-PassRefPtr<InjectedBundleIntent> InjectedBundleIntent::create(WebCore::Intent* intent)
-{
-    return adoptRef(new InjectedBundleIntent(intent));
-}
-
-InjectedBundleIntent::InjectedBundleIntent(WebCore::Intent* intent)
-    : m_intent(intent)
-{
-}
-
-String InjectedBundleIntent::action() const
-{
-    return m_intent->action();
-}
-
-String InjectedBundleIntent::payloadType() const
-{
-    return m_intent->type();
-}
-
-WebCore::KURL InjectedBundleIntent::service() const
-{
-    return m_intent->service();
-}
-
-PassRefPtr<WebSerializedScriptValue> InjectedBundleIntent::data() const
-{
-    return WebSerializedScriptValue::create(m_intent->data());
-}
-
-String InjectedBundleIntent::extra(const String& key) const
-{
-    return m_intent->extras().get(key);
-}
-
-PassRefPtr<ImmutableDictionary> InjectedBundleIntent::extras() const
-{
-    const HashMap<String, String>& extras = m_intent->extras();
-    ImmutableDictionary::MapType wkExtras;
-    HashMap<String, String>::const_iterator end = extras.end();
-    for (HashMap<String, String>::const_iterator it = extras.begin(); it != end; ++it)
-        wkExtras.set(it->key, WebString::create(it->value));
-
-    return ImmutableDictionary::adopt(wkExtras);
-}
-
-PassRefPtr<ImmutableArray> InjectedBundleIntent::suggestions() const
-{
-    const Vector<KURL>& suggestions = m_intent->suggestions();
-    const size_t numSuggestions = suggestions.size();
-    Vector<RefPtr<APIObject> > wkSuggestions(numSuggestions);
-    for (unsigned i = 0; i < numSuggestions; ++i)
-        wkSuggestions[i] = WebURL::create(suggestions[i]);
-
-    return ImmutableArray::adopt(wkSuggestions);
-}
-
-} // namespace WebKit
-
-#endif // ENABLE(WEB_INTENTS)
diff --git a/Source/WebKit2/WebProcess/InjectedBundle/InjectedBundleIntent.h b/Source/WebKit2/WebProcess/InjectedBundle/InjectedBundleIntent.h
deleted file mode 100644 (file)
index 5d3f06c..0000000
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- * Copyright (C) 2012 Intel Corporation. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
- * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
- * THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#ifndef InjectedBundleIntent_h
-#define InjectedBundleIntent_h
-
-#if ENABLE(WEB_INTENTS)
-
-#include "APIObject.h"
-#include <WebCore/Intent.h>
-#include <WebCore/KURL.h>
-#include <wtf/Forward.h>
-#include <wtf/PassRefPtr.h>
-#include <wtf/RefPtr.h>
-
-namespace WebKit {
-
-class ImmutableArray;
-class ImmutableDictionary;
-class WebSerializedScriptValue;
-
-class InjectedBundleIntent : public APIObject {
-public:
-    static const Type APIType = TypeBundleIntent;
-
-    static PassRefPtr<InjectedBundleIntent> create(WebCore::Intent*);
-
-    String action() const;
-    String payloadType() const;
-    WebCore::KURL service() const;
-    PassRefPtr<WebSerializedScriptValue> data() const;
-    String extra(const String& key) const;
-    PassRefPtr<ImmutableDictionary> extras() const;
-    PassRefPtr<ImmutableArray> suggestions() const;
-
-    WebCore::Intent* coreIntent() const { return m_intent.get(); }
-
-private:
-    explicit InjectedBundleIntent(WebCore::Intent*);
-
-    virtual Type type() const { return APIType; }
-
-    RefPtr<WebCore::Intent> m_intent;
-};
-
-} // namespace WebKit
-
-#endif // ENABLE(WEB_INTENTS)
-
-#endif // InjectedBundleIntent_h
diff --git a/Source/WebKit2/WebProcess/InjectedBundle/InjectedBundleIntentRequest.cpp b/Source/WebKit2/WebProcess/InjectedBundle/InjectedBundleIntentRequest.cpp
deleted file mode 100644 (file)
index eac0b83..0000000
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- * Copyright (C) 2012 Intel Corporation. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
- * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
- * THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#include "config.h"
-#include "InjectedBundleIntentRequest.h"
-
-#if ENABLE(WEB_INTENTS)
-#include "InjectedBundleIntent.h"
-#include <WebCore/IntentRequest.h>
-#include <WebSerializedScriptValue.h>
-
-using namespace WebCore;
-
-namespace WebKit {
-
-PassRefPtr<InjectedBundleIntentRequest> InjectedBundleIntentRequest::create(IntentRequest* request)
-{
-    return adoptRef(new InjectedBundleIntentRequest(request));
-}
-
-InjectedBundleIntentRequest::InjectedBundleIntentRequest(IntentRequest* request)
-    : m_intentRequest(request)
-{
-}
-
-void InjectedBundleIntentRequest::postResult(WebSerializedScriptValue* data)
-{
-    m_intentRequest->postResult(static_cast<SerializedScriptValue*>(data->internalRepresentation()));
-}
-
-void InjectedBundleIntentRequest::postFailure(WebSerializedScriptValue* data)
-{
-    m_intentRequest->postFailure(static_cast<SerializedScriptValue*>(data->internalRepresentation()));
-}
-
-PassRefPtr<InjectedBundleIntent> InjectedBundleIntentRequest::intent() const
-{
-    return InjectedBundleIntent::create(m_intentRequest->intent());
-}
-
-} // namespace WebKit
-
-#endif // ENABLE(WEB_INTENTS)
diff --git a/Source/WebKit2/WebProcess/InjectedBundle/InjectedBundleIntentRequest.h b/Source/WebKit2/WebProcess/InjectedBundle/InjectedBundleIntentRequest.h
deleted file mode 100644 (file)
index 33a3192..0000000
+++ /dev/null
@@ -1,68 +0,0 @@
-/*
- * Copyright (C) 2012 Intel Corporation. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
- * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
- * THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#ifndef InjectedBundleIntentRequest_h
-#define InjectedBundleIntentRequest_h
-
-#if ENABLE(WEB_INTENTS)
-
-#include "APIObject.h"
-#include <wtf/Forward.h>
-#include <wtf/PassRefPtr.h>
-#include <wtf/RefPtr.h>
-
-namespace WebCore {
-class IntentRequest;
-}
-
-namespace WebKit {
-
-class InjectedBundleIntent;
-class WebSerializedScriptValue;
-
-class InjectedBundleIntentRequest : public APIObject {
-public:
-    static const Type APIType = TypeBundleIntentRequest;
-
-    static PassRefPtr<InjectedBundleIntentRequest> create(WebCore::IntentRequest*);
-
-    void postResult(WebSerializedScriptValue*);
-    void postFailure(WebSerializedScriptValue*);
-
-    PassRefPtr<InjectedBundleIntent> intent() const;
-
-private:
-    explicit InjectedBundleIntentRequest(WebCore::IntentRequest*);
-
-    virtual Type type() const { return APIType; }
-
-    RefPtr<WebCore::IntentRequest> m_intentRequest;
-};
-
-} // namespace WebKit
-
-#endif // ENABLE(WEB_INTENTS)
-
-#endif // InjectedBundleIntentRequest_h
index 8f68a3e..9edea1e 100644 (file)
 #include "WebError.h"
 #include <wtf/text/WTFString.h>
 
-#if ENABLE(WEB_INTENTS)
-#include "InjectedBundleIntentRequest.h"
-#endif
-#if ENABLE(WEB_INTENTS_TAG)
-#include "WebIntentServiceInfo.h"
-#endif
-
 using namespace WebCore;
 
 namespace WebKit {
@@ -194,30 +187,6 @@ void InjectedBundlePageLoaderClient::didDetectXSSForFrame(WebPage* page, WebFram
     userData = adoptRef(toImpl(userDataToPass));
 }
 
-#if ENABLE(WEB_INTENTS)
-void InjectedBundlePageLoaderClient::didReceiveIntentForFrame(WebPage* page, WebFrame* frame, InjectedBundleIntentRequest* intentRequest, RefPtr<APIObject>& userData)
-{
-    if (!m_client.didReceiveIntentForFrame)
-        return;
-
-    WKTypeRef userDataToPass = 0;
-    m_client.didReceiveIntentForFrame(toAPI(page), toAPI(frame), toAPI(intentRequest), &userDataToPass, m_client.clientInfo);
-    userData = adoptRef(toImpl(userDataToPass));
-}
-#endif
-
-#if ENABLE(WEB_INTENTS_TAG)
-void InjectedBundlePageLoaderClient::registerIntentServiceForFrame(WebPage* page, WebFrame* frame, WebIntentServiceInfo* service, RefPtr<APIObject>& userData)
-{
-    if (!m_client.registerIntentServiceForFrame)
-        return;
-
-    WKTypeRef userDataToPass = 0;
-    m_client.registerIntentServiceForFrame(toAPI(page), toAPI(frame), toAPI(service), &userDataToPass, m_client.clientInfo);
-    userData = adoptRef(toImpl(userDataToPass));
-}
-#endif
-
 void InjectedBundlePageLoaderClient::didFirstLayoutForFrame(WebPage* page, WebFrame* frame, RefPtr<APIObject>& userData)
 {
     if (!m_client.didFirstLayoutForFrame)
index c6b277c..68e9408 100644 (file)
@@ -47,12 +47,6 @@ class APIObject;
 class InjectedBundleBackForwardListItem;
 class WebPage;
 class WebFrame;
-#if ENABLE(WEB_INTENTS)
-class InjectedBundleIntentRequest;
-#endif
-#if ENABLE(WEB_INTENTS_TAG)
-class WebIntentServiceInfo;
-#endif
 
 class InjectedBundlePageLoaderClient : public APIClient<WKBundlePageLoaderClient, kWKBundlePageLoaderClientCurrentVersion> {
 public:
@@ -72,13 +66,6 @@ public:
     void didRunInsecureContentForFrame(WebPage*, WebFrame*, RefPtr<APIObject>& userData);
     void didDetectXSSForFrame(WebPage*, WebFrame*, RefPtr<APIObject>& userData);
 
-#if ENABLE(WEB_INTENTS)
-    void didReceiveIntentForFrame(WebPage*, WebFrame*, InjectedBundleIntentRequest*, RefPtr<APIObject>& userData);
-#endif
-#if ENABLE(WEB_INTENTS_TAG)
-    void registerIntentServiceForFrame(WebPage*, WebFrame*, WebIntentServiceInfo*, RefPtr<APIObject>& userData);
-#endif
-
     void didFirstLayoutForFrame(WebPage*, WebFrame*, RefPtr<APIObject>& userData);
     void didFirstVisuallyNonEmptyLayoutForFrame(WebPage*, WebFrame*, RefPtr<APIObject>& userData);
     void didLayoutForFrame(WebPage*, WebFrame*);
index 2302bf2..6f422ff 100644 (file)
 #include <WebCore/Widget.h>
 #include <WebCore/WindowFeatures.h>
 
-#if ENABLE(WEB_INTENTS)
-#include "InjectedBundleIntentRequest.h"
-#include "IntentData.h"
-#include <WebCore/IntentRequest.h>
-#endif
-
-#if ENABLE(WEB_INTENTS_TAG)
-#include "IntentServiceInfo.h"
-#include "WebIntentServiceInfo.h"
-#endif
-
 using namespace WebCore;
 
 namespace WebKit {
@@ -1561,44 +1550,6 @@ NSCachedURLResponse* WebFrameLoaderClient::willCacheResponse(DocumentLoader*, un
 
 #endif // PLATFORM(MAC)
 
-#if ENABLE(WEB_INTENTS)
-void WebFrameLoaderClient::dispatchIntent(PassRefPtr<IntentRequest> request)
-{
-    WebPage* webPage = m_frame->page();
-    if (!webPage)
-        return;
-
-    RefPtr<APIObject> userData;
-    RefPtr<InjectedBundleIntentRequest> bundleIntentRequest = InjectedBundleIntentRequest::create(request.get());
-    webPage->injectedBundleLoaderClient().didReceiveIntentForFrame(webPage, m_frame, bundleIntentRequest.get(), userData);
-
-    IntentData intentData(request->intent());
-    webPage->send(Messages::WebPageProxy::DidReceiveIntentForFrame(m_frame->frameID(), intentData, InjectedBundleUserMessageEncoder(userData.get())));
-}
-#endif
-
-#if ENABLE(WEB_INTENTS_TAG)
-void WebFrameLoaderClient::registerIntentService(const String& action, const String& type, const KURL& href, const String& title, const String& disposition)
-{
-    WebPage* webPage = m_frame->page();
-    if (!webPage)
-        return;
-
-    IntentServiceInfo serviceInfo;
-    serviceInfo.action = action;
-    serviceInfo.type = type;
-    serviceInfo.href = href;
-    serviceInfo.title = title;
-    serviceInfo.disposition = disposition;
-
-    RefPtr<APIObject> userData;
-    RefPtr<WebIntentServiceInfo> webIntentServiceInfo = WebIntentServiceInfo::create(serviceInfo);
-    webPage->injectedBundleLoaderClient().registerIntentServiceForFrame(webPage, m_frame, webIntentServiceInfo.get(), userData);
-
-    webPage->send(Messages::WebPageProxy::RegisterIntentServiceForFrame(m_frame->frameID(), serviceInfo, InjectedBundleUserMessageEncoder(userData.get())));
-}
-#endif
-
 bool WebFrameLoaderClient::shouldUsePluginDocument(const String& /*mimeType*/) const
 {
     notImplemented();
index 1cb9f60..23db706 100644 (file)
 
 #include <WebCore/FrameLoaderClient.h>
 
-namespace WebCore {
-#if ENABLE(WEB_INTENTS)
-class IntentRequest;
-#endif
-}
-
 namespace WebKit {
 
 class PluginView;
@@ -220,13 +214,6 @@ private:
     virtual NSCachedURLResponse* willCacheResponse(WebCore::DocumentLoader*, unsigned long identifier, NSCachedURLResponse*) const OVERRIDE;
 #endif
 
-#if ENABLE(WEB_INTENTS)
-    virtual void dispatchIntent(PassRefPtr<WebCore::IntentRequest>) OVERRIDE;
-#endif
-#if ENABLE(WEB_INTENTS_TAG)
-    virtual void registerIntentService(const String& action, const String& type, const WebCore::KURL& href, const String& title, const String& disposition) OVERRIDE;
-#endif
-
     virtual bool shouldUsePluginDocument(const String& /*mimeType*/) const OVERRIDE;
 
     virtual void didChangeScrollOffset() OVERRIDE;
index deeaf77..97845af 100644 (file)
 #include <WebCore/TextResourceDecoder.h>
 #include <wtf/text/StringBuilder.h>
 
-#if ENABLE(WEB_INTENTS)
-#include "IntentData.h"
-#include <WebCore/DOMWindowIntents.h>
-#include <WebCore/DeliveredIntent.h>
-#include <WebCore/Intent.h>
-#include <WebCore/PlatformMessagePortChannel.h>
-#endif
-
 #if PLATFORM(MAC)
 #include <WebCore/LegacyWebArchive.h>
 #endif
@@ -275,45 +267,6 @@ void WebFrame::convertMainResourceLoadToDownload(MainResourceLoader* mainResourc
     WebProcess::shared().downloadManager().convertHandleToDownload(policyDownloadID, mainResourceLoader->loader()->handle(), request, response);
 }
 
-#if ENABLE(WEB_INTENTS)
-void WebFrame::deliverIntent(const IntentData& intentData)
-{
-    OwnPtr<DeliveredIntentClient> dummyClient;
-    Vector<uint8_t> dataCopy = intentData.data;
-
-    OwnPtr<WebCore::MessagePortChannelArray> channels;
-    if (!intentData.messagePorts.isEmpty()) {
-        channels = adoptPtr(new WebCore::MessagePortChannelArray(intentData.messagePorts.size()));
-        for (size_t i = 0; i < intentData.messagePorts.size(); ++i)
-            (*channels)[i] = MessagePortChannel::create(WebProcess::shared().messagePortChannel(intentData.messagePorts.at(i)));
-    }
-    OwnPtr<WebCore::MessagePortArray> messagePorts = WebCore::MessagePort::entanglePorts(*m_coreFrame->document()->domWindow()->scriptExecutionContext(), channels.release());
-
-    RefPtr<DeliveredIntent> deliveredIntent = DeliveredIntent::create(m_coreFrame, dummyClient.release(), intentData.action, intentData.type,
-                                                                      SerializedScriptValue::adopt(dataCopy), messagePorts.release(),
-                                                                      intentData.extras);
-    WebCore::DOMWindowIntents::from(m_coreFrame->document()->domWindow())->deliver(deliveredIntent.release());
-}
-
-void WebFrame::deliverIntent(WebCore::Intent* intent)
-{
-    OwnPtr<DeliveredIntentClient> dummyClient;
-
-    OwnPtr<WebCore::MessagePortChannelArray> channels;
-    WebCore::MessagePortChannelArray* origChannels = intent->messagePorts();
-    if (origChannels && origChannels->size()) {
-        channels = adoptPtr(new WebCore::MessagePortChannelArray(origChannels->size()));
-        for (size_t i = 0; i < origChannels->size(); ++i)
-            (*channels)[i] = origChannels->at(i).release();
-    }
-    OwnPtr<WebCore::MessagePortArray> messagePorts = WebCore::MessagePort::entanglePorts(*m_coreFrame->document()->domWindow()->scriptExecutionContext(), channels.release());
-
-    RefPtr<DeliveredIntent> deliveredIntent = DeliveredIntent::create(m_coreFrame, dummyClient.release(), intent->action(), intent->type(),
-                                                                      intent->data(), messagePorts.release(), intent->extras());
-    WebCore::DOMWindowIntents::from(m_coreFrame->document()->domWindow())->deliver(deliveredIntent.release());
-}
-#endif
-
 String WebFrame::source() const 
 {
     if (!m_coreFrame)
index 096e1fd..15e7084 100644 (file)
@@ -44,9 +44,6 @@ class Frame;
 class HTMLFrameOwnerElement;
 class IntPoint;
 class IntRect;
-#if ENABLE(WEB_INTENTS)
-class Intent;
-#endif
 class KURL;
 }
 
@@ -58,10 +55,6 @@ class InjectedBundleRangeHandle;
 class InjectedBundleScriptWorld;
 class WebPage;
 
-#if ENABLE(WEB_INTENTS)
-struct IntentData;
-#endif
-
 class WebFrame : public APIObject {
 public:
     static const Type APIType = TypeBundleFrame;
@@ -85,11 +78,6 @@ public:
     void startDownload(const WebCore::ResourceRequest&);
     void convertMainResourceLoadToDownload(WebCore::MainResourceLoader*, const WebCore::ResourceRequest&, const WebCore::ResourceResponse&);
 
-#if ENABLE(WEB_INTENTS)
-    void deliverIntent(const IntentData&);
-    void deliverIntent(WebCore::Intent*);
-#endif
-
     String source() const;
     String contentsAsString() const;
     String selectionAsString() const;
index 6f2e504..0c507f4 100644 (file)
 #include "WebNetworkInfoClient.h"
 #endif
 
-#if ENABLE(WEB_INTENTS)
-#include "IntentData.h"
-#include <WebCore/Intent.h>
-#endif
-
 #if ENABLE(VIBRATION)
 #include "WebVibrationClient.h"
 #endif
@@ -2254,23 +2249,6 @@ void WebPage::forceRepaint(uint64_t callbackID)
     send(Messages::WebPageProxy::VoidCallback(callbackID));
 }
 
-#if ENABLE(WEB_INTENTS)
-void WebPage::deliverIntentToFrame(uint64_t frameID, const IntentData& intentData)
-{
-    WebFrame* frame = WebProcess::shared().webFrame(frameID);
-    if (!frame)
-        return;
-
-    frame->deliverIntent(intentData);
-}
-
-void WebPage::deliverCoreIntentToFrame(uint64_t frameID, Intent* coreIntent)
-{
-    if (WebFrame* frame = WebProcess::shared().webFrame(frameID))
-        frame->deliverIntent(coreIntent);
-}
-#endif
-
 void WebPage::preferencesDidChange(const WebPreferencesStore& store)
 {
     WebPreferencesStore::removeTestRunnerOverrides();
index 6c7d70a..401b82f 100644 (file)
@@ -110,9 +110,6 @@ namespace WebCore {
     class Frame;
     class FrameView;
     class HTMLPlugInElement;
-#if ENABLE(WEB_INTENTS)
-    class Intent;
-#endif
     class KeyboardEvent;
     class Page;
     class PrintContext;
@@ -154,10 +151,6 @@ struct PrintInfo;
 struct WebPageCreationParameters;
 struct WebPreferencesStore;
 
-#if ENABLE(WEB_INTENTS)
-struct IntentData;
-#endif
-
 #if ENABLE(GESTURE_EVENTS)
 class WebGestureEvent;
 #endif
@@ -491,10 +484,6 @@ public:
     bool isSmartInsertDeleteEnabled() const { return m_isSmartInsertDeleteEnabled; }
 #endif
 
-#if ENABLE(WEB_INTENTS)
-    void deliverCoreIntentToFrame(uint64_t frameID, WebCore::Intent*);
-#endif
-
     void replaceSelectionWithText(WebCore::Frame*, const String&);
     void clearSelection();
 
@@ -679,10 +668,6 @@ private:
     void contextMenuHidden() { m_isShowingContextMenu = false; }
 #endif
 
-#if ENABLE(WEB_INTENTS)
-    void deliverIntentToFrame(uint64_t frameID, const IntentData&);
-#endif
-
     static void scroll(WebCore::Page*, WebCore::ScrollDirection, WebCore::ScrollGranularity);
     static void logicalScroll(WebCore::Page*, WebCore::ScrollLogicalDirection, WebCore::ScrollGranularity);
 
index 67ce311..67bce6a 100644 (file)
@@ -237,11 +237,6 @@ messages -> WebPage LegacyReceiver {
     SetCanRunBeforeUnloadConfirmPanel(bool canRunBeforeUnloadConfirmPanel)
     SetCanRunModal(bool canRunModal)
 
-    # Web Intents
-#if ENABLE(WEB_INTENTS)
-    DeliverIntentToFrame(uint64_t frameID, WebKit::IntentData intentData)
-#endif
-
 #if PLATFORM(EFL)
     SetThemePath(WTF::String themePath)
 #endif
index 0b2e908..86fbc8f 100644 (file)
 #include <wtf/HashCountedSet.h>
 #include <wtf/PassRefPtr.h>
 
-#if ENABLE(WEB_INTENTS)
-#include <WebCore/PlatformMessagePortChannel.h>
-#endif
-
 #if ENABLE(NETWORK_INFO)
 #include "WebNetworkInfoManagerMessages.h"
 #endif
@@ -685,26 +681,6 @@ WebPageGroupProxy* WebProcess::webPageGroup(const WebPageGroupData& pageGroupDat
     return result.iterator->value.get();
 }
 
-#if ENABLE(WEB_INTENTS)
-uint64_t WebProcess::addMessagePortChannel(PassRefPtr<PlatformMessagePortChannel> messagePortChannel)
-{
-    static uint64_t channelID = 0;
-    m_messagePortChannels.add(++channelID, messagePortChannel);
-
-    return channelID;
-}
-
-PlatformMessagePortChannel* WebProcess::messagePortChannel(uint64_t channelID)
-{
-    return m_messagePortChannels.get(channelID).get();
-}
-
-void WebProcess::removeMessagePortChannel(uint64_t channelID)
-{
-    m_messagePortChannels.remove(channelID);
-}
-#endif
-
 void WebProcess::clearResourceCaches(ResourceCachesToClear resourceCachesToClear)
 {
     platformClearResourceCaches(resourceCachesToClear);
index 0e52aae..80bc7e8 100644 (file)
@@ -67,10 +67,6 @@ QT_END_NAMESPACE
 namespace WebCore {
     class ResourceRequest;
     struct PluginInfo;
-
-#if ENABLE(WEB_INTENTS)
-    class PlatformMessagePortChannel;
-#endif
 }
 
 namespace WebKit {
@@ -123,12 +119,6 @@ public:
     void removeWebPage(uint64_t pageID);
     WebPage* focusedWebPage() const;
 
-#if ENABLE(WEB_INTENTS) 
-    uint64_t addMessagePortChannel(PassRefPtr<WebCore::PlatformMessagePortChannel>);
-    WebCore::PlatformMessagePortChannel* messagePortChannel(uint64_t);
-    void removeMessagePortChannel(uint64_t);
-#endif
-
     InjectedBundle* injectedBundle() const { return m_injectedBundle.get(); }
 
 #if PLATFORM(MAC)
@@ -328,10 +318,6 @@ private:
 
     HashMap<uint64_t, WebFrame*> m_frameMap;
 
-#if ENABLE(WEB_INTENTS)
-    HashMap<uint64_t, RefPtr<WebCore::PlatformMessagePortChannel> > m_messagePortChannels;
-#endif
-
     typedef HashMap<AtomicString, WebProcessSupplement*> WebProcessSupplementMap;
     WebProcessSupplementMap m_supplements;
 
index 7a70bb6..7a021a0 100644 (file)
@@ -27,10 +27,6 @@ messages -> WebProcess LegacyReceiver {
     # Create a new page.
     CreateWebPage(uint64_t newPageID, WebKit::WebPageCreationParameters pageCreationParameters)
 
-#if ENABLE(WEB_INTENTS)
-    RemoveMessagePortChannel(uint64_t channelID);
-#endif
-
     # Visited link tracking.
     SetVisitedLinkTable(WebKit::SharedMemory::Handle handle)
     VisitedLinkStateChanged(Vector<WebCore::LinkHash> linkHashes)
index 80bcd50..b74fdad 100644 (file)
@@ -1,3 +1,19 @@
+2013-01-31  Anders Carlsson  <andersca@apple.com>
+
+        Remove Web Intents code from WebKit2
+        https://bugs.webkit.org/show_bug.cgi?id=108506
+
+        Reviewed by Simon Fraser.
+
+        * WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
+        * WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp:
+        (WTR::InjectedBundlePage::InjectedBundlePage):
+        * WebKitTestRunner/InjectedBundle/InjectedBundlePage.h:
+        (InjectedBundlePage):
+        * WebKitTestRunner/InjectedBundle/TestRunner.cpp:
+        * WebKitTestRunner/InjectedBundle/TestRunner.h:
+        (TestRunner):
+
 2013-01-31  Tommy Widenflycht  <tommyw@google.com>
 
         [chromium] MediaStream API: Rename WebMediaStreamDescriptor and WebMediaStreamComponent to WebMediaStream and WebMediaStreamTrack
index f2713c7..cb3874b 100644 (file)
@@ -143,10 +143,6 @@ interface TestRunner {
     void setDefersLoading(in boolean flag);
     void setStopProvisionalFrameLoads();
 
-    // Web intents testing.
-    void sendWebIntentResponse(in DOMString reply);
-    void deliverWebIntent(in DOMString action, in DOMString type, in DOMString data);
-    
     // Focus testing.
     void addChromeInputField(in object callback);
     void removeChromeInputField(in object callback);
index e35fa70..8904589 100644 (file)
 #include "DumpRenderTreeSupportQt.h"
 #endif
 
-#if ENABLE(WEB_INTENTS)
-#include <WebKit2/WKBundleIntent.h>
-#include <WebKit2/WKBundleIntentRequest.h>
-#endif
-#if ENABLE(WEB_INTENTS_TAG)
-#include <WebKit2/WKIntentServiceInfo.h>
-#endif
-
 using namespace std;
 
 namespace WTR {
@@ -327,8 +319,8 @@ InjectedBundlePage::InjectedBundlePage(WKBundlePageRef page)
         0, // willDestroyGlobalObjectForDOMWindowExtension
         didFinishProgress, // didFinishProgress
         0, // shouldForceUniversalAccessFromLocalURL
-        didReceiveIntentForFrame, // didReceiveIntentForFrame
-        registerIntentServiceForFrame, // registerIntentServiceForFrame
+        0, // didReceiveIntentForFrame
+        0, // registerIntentServiceForFrame
         0, // didLayout
     };
     WKBundlePageSetPageLoaderClient(m_page, &loaderClient);
@@ -585,89 +577,6 @@ void InjectedBundlePage::didFinishProgress(WKBundlePageRef, const void *clientIn
     static_cast<InjectedBundlePage*>(const_cast<void*>(clientInfo))->didFinishProgress();
 }
 
-void InjectedBundlePage::didReceiveIntentForFrame(WKBundlePageRef page, WKBundleFrameRef frame, WKBundleIntentRequestRef intentRequest, WKTypeRef* userData, const void* clientInfo)
-{
-#if ENABLE(WEB_INTENTS)
-    static_cast<InjectedBundlePage*>(const_cast<void*>(clientInfo))->m_currentIntentRequest = intentRequest;
-    WKRetainPtr<WKBundleIntentRef> intent(AdoptWK, WKBundleIntentRequestCopyIntent(intentRequest));
-
-    StringBuilder stringBuilder;
-    stringBuilder.appendLiteral("Received Web Intent: action=");
-    WKRetainPtr<WKStringRef> wkAction(AdoptWK, WKBundleIntentCopyAction(intent.get()));
-    stringBuilder.append(toWTFString(wkAction.get()));
-    stringBuilder.appendLiteral(" type=");
-    WKRetainPtr<WKStringRef> wkType(AdoptWK, WKBundleIntentCopyType(intent.get()));
-    stringBuilder.append(toWTFString(wkType.get()));
-    stringBuilder.append('\n');
-
-    const size_t numMessagePorts = WKBundleIntentMessagePortCount(intent.get());
-    if (numMessagePorts) {
-        stringBuilder.appendLiteral("Have ");
-        stringBuilder.appendNumber(numMessagePorts);
-        stringBuilder.appendLiteral(" ports\n");
-    }
-
-    WKRetainPtr<WKURLRef> wkServiceUrl(AdoptWK, WKBundleIntentCopyService(intent.get()));
-    if (wkServiceUrl) {
-        WKRetainPtr<WKStringRef> wkService(AdoptWK, WKURLCopyString(wkServiceUrl.get()));
-        if (wkService && !WKStringIsEmpty(wkService.get())) {
-            stringBuilder.appendLiteral("Explicit intent service: ");
-            stringBuilder.append(toWTFString(wkService.get()));
-            stringBuilder.append('\n');
-        }
-    }
-
-    WKRetainPtr<WKDictionaryRef> wkExtras(AdoptWK, WKBundleIntentCopyExtras(intent.get()));
-    WKRetainPtr<WKArrayRef> wkExtraKeys(AdoptWK, WKDictionaryCopyKeys(wkExtras.get()));
-    const size_t numExtraKeys = WKArrayGetSize(wkExtraKeys.get());
-    for (size_t i = 0; i < numExtraKeys; ++i) {
-        WKStringRef wkKey = static_cast<WKStringRef>(WKArrayGetItemAtIndex(wkExtraKeys.get(), i));
-        WKStringRef wkValue = static_cast<WKStringRef>(WKDictionaryGetItemForKey(wkExtras.get(), wkKey));
-        stringBuilder.appendLiteral("Extras[");
-        stringBuilder.append(toWTFString(wkKey));
-        stringBuilder.appendLiteral("] = ");
-        stringBuilder.append(toWTFString(wkValue));
-        stringBuilder.append('\n');
-    }
-
-    WKRetainPtr<WKArrayRef> wkSuggestions(AdoptWK, WKBundleIntentCopySuggestions(intent.get()));
-    const size_t numSuggestions = WKArrayGetSize(wkSuggestions.get());
-    for (size_t i = 0; i < numSuggestions; ++i) {
-        WKStringRef wkSuggestion = static_cast<WKStringRef>(WKArrayGetItemAtIndex(wkSuggestions.get(), i));
-        stringBuilder.appendLiteral("Have suggestion ");
-        stringBuilder.append(toWTFString(wkSuggestion));
-        stringBuilder.append('\n');
-    }
-
-    InjectedBundle::shared().outputText(stringBuilder.toString());
-#endif
-}
-
-void InjectedBundlePage::registerIntentServiceForFrame(WKBundlePageRef page, WKBundleFrameRef frame, WKIntentServiceInfoRef serviceInfo, WKTypeRef* userData, const void* clientInfo)
-{
-#if ENABLE(WEB_INTENTS_TAG)
-    StringBuilder stringBuilder;
-    stringBuilder.appendLiteral("Registered Web Intent Service: action=");
-    WKRetainPtr<WKStringRef> wkAction(AdoptWK, WKIntentServiceInfoCopyAction(serviceInfo));
-    stringBuilder.append(toWTFString(wkAction.get()));
-    stringBuilder.appendLiteral(" type=");
-    WKRetainPtr<WKStringRef> wkType(AdoptWK, WKIntentServiceInfoCopyType(serviceInfo));
-    stringBuilder.append(toWTFString(wkType.get()));
-    stringBuilder.appendLiteral(" title=");
-    WKRetainPtr<WKStringRef> wkTitle(AdoptWK, WKIntentServiceInfoCopyTitle(serviceInfo));
-    stringBuilder.append(toWTFString(wkTitle.get()));
-    stringBuilder.appendLiteral(" url=");
-    WKRetainPtr<WKURLRef> wkUrl(AdoptWK, WKIntentServiceInfoCopyHref(serviceInfo));
-    if (wkUrl)
-        stringBuilder.append(toWTFString(adoptWK(WKURLCopyString(wkUrl.get()))));
-    stringBuilder.appendLiteral(" disposition=");
-    WKRetainPtr<WKStringRef> wkDisposition(AdoptWK, WKIntentServiceInfoCopyDisposition(serviceInfo));
-    stringBuilder.append(toWTFString(wkDisposition.get()));
-    stringBuilder.append('\n');
-    InjectedBundle::shared().outputText(stringBuilder.toString());
-#endif
-}
-
 void InjectedBundlePage::didFinishDocumentLoadForFrame(WKBundlePageRef page, WKBundleFrameRef frame, WKTypeRef*, const void* clientInfo)
 {
     static_cast<InjectedBundlePage*>(const_cast<void*>(clientInfo))->didFinishDocumentLoadForFrame(frame);
index d5b9c80..317294d 100644 (file)
@@ -40,10 +40,6 @@ public:
 
     WKBundlePageRef page() const { return m_page; }
 
-#if ENABLE(WEB_INTENTS)
-    WKBundleIntentRequestRef currentIntentRequest() const { return m_currentIntentRequest.get(); }
-#endif
-
     void dump();
 
     void stopLoading();
@@ -79,8 +75,6 @@ private:
     static void didFinishLoadForResource(WKBundlePageRef, WKBundleFrameRef, uint64_t identifier, const void*);
     static void didFailLoadForResource(WKBundlePageRef, WKBundleFrameRef, uint64_t identifier, WKErrorRef, const void*);
     static bool shouldCacheResponse(WKBundlePageRef, WKBundleFrameRef, uint64_t identifier, const void*);
-    static void didReceiveIntentForFrame(WKBundlePageRef, WKBundleFrameRef, WKBundleIntentRequestRef, WKTypeRef*, const void*);
-    static void registerIntentServiceForFrame(WKBundlePageRef, WKBundleFrameRef, WKIntentServiceInfoRef, WKTypeRef*, const void*);
 
     void didStartProvisionalLoadForFrame(WKBundleFrameRef);
     void didReceiveServerRedirectForProvisionalLoadForFrame(WKBundleFrameRef);
@@ -180,10 +174,6 @@ private:
     WKBundlePageRef m_page;
     WKRetainPtr<WKBundleScriptWorldRef> m_world;
     WKRetainPtr<WKBundleBackForwardListItemRef> m_previousTestBackForwardListItem;
-
-#if ENABLE(WEB_INTENTS)
-    WKRetainPtr<WKBundleIntentRequestRef> m_currentIntentRequest;
-#endif
 };
 
 } // namespace WTR
index 4647a9c..bd2437f 100644 (file)
 #include <wtf/text/CString.h>
 #include <wtf/text/StringBuilder.h>
 
-#if ENABLE(WEB_INTENTS)
-#include <WebKit2/WKBundleIntent.h>
-#include <WebKit2/WKBundleIntentRequest.h>
-#endif
-
 namespace WTR {
 
 const double TestRunner::waitToDumpWatchdogTimerInterval = 30;
@@ -669,52 +664,6 @@ void TestRunner::overridePreference(JSStringRef preference, JSStringRef value)
     WKBundleOverrideBoolPreferenceForTestRunner(InjectedBundle::shared().bundle(), InjectedBundle::shared().pageGroup(), toWK(preference).get(), toBool(value));
 }
 
-void TestRunner::sendWebIntentResponse(JSStringRef reply)
-{
-#if ENABLE(WEB_INTENTS)
-    WKRetainPtr<WKBundleIntentRequestRef> currentRequest = InjectedBundle::shared().page()->currentIntentRequest();
-    if (!currentRequest)
-        return;
-
-    WKBundleFrameRef mainFrame = WKBundlePageGetMainFrame(InjectedBundle::shared().page()->page());
-    JSContextRef context = WKBundleFrameGetJavaScriptContext(mainFrame);
-
-    if (reply) {
-        WKRetainPtr<WKSerializedScriptValueRef> serializedData(AdoptWK, WKSerializedScriptValueCreate(context, JSValueMakeString(context, reply), 0));
-        WKBundleIntentRequestPostResult(currentRequest.get(), serializedData.get());
-    } else {
-        JSRetainPtr<JSStringRef> errorReply(JSStringCreateWithUTF8CString("ERROR"));
-        WKRetainPtr<WKSerializedScriptValueRef> serializedData(AdoptWK, WKSerializedScriptValueCreate(context, JSValueMakeString(context, errorReply.get()), 0));
-        WKBundleIntentRequestPostFailure(currentRequest.get(), serializedData.get());
-    }
-#endif
-}
-
-void TestRunner::deliverWebIntent(JSStringRef action, JSStringRef type, JSStringRef data)
-{
-#if ENABLE(WEB_INTENTS)
-    WKBundleFrameRef mainFrame = WKBundlePageGetMainFrame(InjectedBundle::shared().page()->page());
-    JSContextRef context = WKBundleFrameGetJavaScriptContext(mainFrame);
-
-    WKRetainPtr<WKStringRef> actionWK = toWK(action);
-    WKRetainPtr<WKStringRef> typeWK = toWK(type);
-    WKRetainPtr<WKSerializedScriptValueRef> dataWK(AdoptWK, WKSerializedScriptValueCreate(context, JSValueMakeString(context, data), 0));
-
-    WKRetainPtr<WKMutableDictionaryRef> intentInitDict(AdoptWK, WKMutableDictionaryCreate());
-    WKRetainPtr<WKStringRef> actionKey(AdoptWK, WKStringCreateWithUTF8CString("action"));
-    WKDictionaryAddItem(intentInitDict.get(), actionKey.get(), actionWK.get());
-
-    WKRetainPtr<WKStringRef> typeKey(AdoptWK, WKStringCreateWithUTF8CString("type"));
-    WKDictionaryAddItem(intentInitDict.get(), typeKey.get(), typeWK.get());
-
-    WKRetainPtr<WKStringRef> dataKey(AdoptWK, WKStringCreateWithUTF8CString("data"));
-    WKDictionaryAddItem(intentInitDict.get(), dataKey.get(), dataWK.get());
-
-    WKRetainPtr<WKBundleIntentRef> wkIntent(AdoptWK, WKBundleIntentCreate(intentInitDict.get()));
-    WKBundlePageDeliverIntentToFrame(InjectedBundle::shared().page()->page(), mainFrame, wkIntent.get());
-#endif
-}
-
 void TestRunner::setAlwaysAcceptCookies(bool accept)
 {
     WKBundleSetAlwaysAcceptCookies(InjectedBundle::shared().bundle(), accept);
index 59ad12e..4bb33b4 100644 (file)
@@ -245,10 +245,6 @@ public:
 
     void overridePreference(JSStringRef preference, JSStringRef value);
 
-    // Web intents testing.
-    void sendWebIntentResponse(JSStringRef reply);
-    void deliverWebIntent(JSStringRef action, JSStringRef type, JSStringRef data);
-
     // Cookies testing
     void setAlwaysAcceptCookies(bool);