diff options
author | Ben Murdoch <benm@google.com> | 2010-08-11 14:44:44 +0100 |
---|---|---|
committer | Ben Murdoch <benm@google.com> | 2010-08-12 19:15:41 +0100 |
commit | dd8bb3de4f353a81954234999f1fea748aee2ea9 (patch) | |
tree | 729b52bf09294f0d6c67cd5ea80aee1b727b7bd8 /WebKit/chromium/public | |
parent | f3d41ba51d86bf719c7a65ab5297aea3c17e2d98 (diff) | |
download | external_webkit-dd8bb3de4f353a81954234999f1fea748aee2ea9.zip external_webkit-dd8bb3de4f353a81954234999f1fea748aee2ea9.tar.gz external_webkit-dd8bb3de4f353a81954234999f1fea748aee2ea9.tar.bz2 |
Merge WebKit at r65072 : Initial merge by git.
Change-Id: Ibcf418498376b2660aacb7f8d46ea7085ef91585
Diffstat (limited to 'WebKit/chromium/public')
20 files changed, 453 insertions, 75 deletions
diff --git a/WebKit/chromium/public/WebCString.h b/WebKit/chromium/public/WebCString.h index 2c1e137..0320eb6 100644 --- a/WebKit/chromium/public/WebCString.h +++ b/WebKit/chromium/public/WebCString.h @@ -34,11 +34,15 @@ #include "WebCommon.h" #if WEBKIT_IMPLEMENTATION -namespace WTF { class CString; } +#include <wtf/Forward.h> #else #include <string> #endif +namespace WTF { +class CString; +} + namespace WebKit { class WebCStringPrivate; diff --git a/WebKit/chromium/public/WebDevToolsAgent.h b/WebKit/chromium/public/WebDevToolsAgent.h index 0e26cc9..4fd1cbd 100644 --- a/WebKit/chromium/public/WebDevToolsAgent.h +++ b/WebKit/chromium/public/WebDevToolsAgent.h @@ -51,10 +51,11 @@ public: virtual void attach() = 0; virtual void detach() = 0; + virtual void frontendLoaded() = 0; virtual void didNavigate() = 0; - virtual void dispatchMessageFromFrontend(const WebDevToolsMessageData&) = 0; + virtual void dispatchOnInspectorBackend(const WebString& message) = 0; virtual void inspectElementAt(const WebPoint&) = 0; @@ -72,8 +73,6 @@ public: // Asynchronously request debugger to pause immediately. WEBKIT_API static void debuggerPauseScript(); - WEBKIT_API static bool dispatchMessageFromFrontendOnIOThread(WebDevToolsMessageTransport*, const WebDevToolsMessageData&); - typedef void (*MessageLoopDispatchHandler)(); // Installs dispatch handle that is going to be called periodically diff --git a/WebKit/chromium/public/WebDevToolsAgentClient.h b/WebKit/chromium/public/WebDevToolsAgentClient.h index 91fd3e8..ec013ac 100644 --- a/WebKit/chromium/public/WebDevToolsAgentClient.h +++ b/WebKit/chromium/public/WebDevToolsAgentClient.h @@ -40,7 +40,9 @@ struct WebDevToolsMessageData; class WebDevToolsAgentClient { public: - virtual void sendMessageToFrontend(const WebDevToolsMessageData&) { } + virtual void sendMessageToInspectorFrontend(const WebString&) { } + virtual void sendDebuggerOutput(const WebString&) { } + virtual void sendDispatchToAPU(const WebString&) { } // Invalidates widget which leads to the repaint. virtual void forceRepaint() { } @@ -52,7 +54,6 @@ public: virtual void runtimeFeatureStateChanged(const WebString& feature, bool enabled) { } virtual WebCString injectedScriptSource() { return WebCString(); } - virtual WebCString injectedScriptDispatcherSource() { return WebCString(); } virtual WebCString debuggerScriptSource() { return WebCString(); } class WebKitClientMessageLoop { diff --git a/WebKit/chromium/public/WebDevToolsFrontend.h b/WebKit/chromium/public/WebDevToolsFrontend.h index d95f35a..0325f92 100644 --- a/WebKit/chromium/public/WebDevToolsFrontend.h +++ b/WebKit/chromium/public/WebDevToolsFrontend.h @@ -38,7 +38,6 @@ namespace WebKit { class WebDevToolsFrontendClient; class WebString; class WebView; -struct WebDevToolsMessageData; // WebDevToolsFrontend represents DevTools client sitting in the Glue. It provides // direct and delegate Apis to the host. @@ -50,7 +49,7 @@ public: virtual ~WebDevToolsFrontend() {} - virtual void dispatchMessageFromAgent(const WebDevToolsMessageData&) = 0; + virtual void dispatchOnInspectorFrontend(const WebString&) = 0; }; } // namespace WebKit diff --git a/WebKit/chromium/public/WebDevToolsFrontendClient.h b/WebKit/chromium/public/WebDevToolsFrontendClient.h index 159a3cd..df34dc5 100644 --- a/WebKit/chromium/public/WebDevToolsFrontendClient.h +++ b/WebKit/chromium/public/WebDevToolsFrontendClient.h @@ -40,7 +40,8 @@ class WebDevToolsFrontendClient { public: WebDevToolsFrontendClient() { } - virtual void sendMessageToAgent(const WebDevToolsMessageData&) { } + virtual void sendFrontendLoaded() { } + virtual void sendMessageToBackend(const WebString&) { } virtual void sendDebuggerCommandToAgent(const WebString& command) { } virtual void sendDebuggerPauseScript() { } diff --git a/WebKit/chromium/public/WebDevToolsMessageData.h b/WebKit/chromium/public/WebDevToolsMessageData.h deleted file mode 100644 index 9bf9acd..0000000 --- a/WebKit/chromium/public/WebDevToolsMessageData.h +++ /dev/null @@ -1,48 +0,0 @@ -/* - * Copyright (C) 2009 Google Inc. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions are - * met: - * - * * Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * * 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. - * * Neither the name of Google Inc. nor the names of its - * contributors may be used to endorse or promote products derived from - * this software without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND 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 THE COPYRIGHT - * OWNER OR 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 WebDevToolsMessageData_h -#define WebDevToolsMessageData_h - -#include "WebCommon.h" -#include "WebString.h" -#include "WebVector.h" - -namespace WebKit { - -struct WebDevToolsMessageData { - WebString className; - WebString methodName; - WebVector<WebString> arguments; -}; - -} // namespace WebKit - -#endif diff --git a/WebKit/chromium/public/WebDeviceOrientation.h b/WebKit/chromium/public/WebDeviceOrientation.h new file mode 100644 index 0000000..7e8aa72 --- /dev/null +++ b/WebKit/chromium/public/WebDeviceOrientation.h @@ -0,0 +1,88 @@ +/* + * Copyright (C) 2010 Google Inc. 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 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 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 WebDeviceOrientation_h +#define WebDeviceOrientation_h + +#if WEBKIT_IMPLEMENTATION +namespace WTF { template <typename T> class PassRefPtr; } +namespace WebCore { class DeviceOrientation; } +#endif + +namespace WebKit { + +class WebDeviceOrientation { +public: + WebDeviceOrientation(bool canProvideAlpha, double alpha, bool canProvideBeta, double beta, bool canProvideGamma, double gamma) + : m_isNull(false), + m_canProvideAlpha(canProvideAlpha), + m_alpha(alpha), + m_canProvideBeta(canProvideBeta), + m_beta(beta), + m_canProvideGamma(canProvideGamma), + m_gamma(gamma) + { + } + + static WebDeviceOrientation nullOrientation() { return WebDeviceOrientation(); } + + bool isNull() { return m_isNull; } + bool canProvideAlpha() { return m_canProvideAlpha; } + double alpha() { return m_alpha; } + bool canProvideBeta() { return m_canProvideBeta; } + double beta() { return m_beta; } + bool canProvideGamma() { return m_canProvideGamma; } + double gamma() { return m_gamma; } + +#if WEBKIT_IMPLEMENTATION + WebDeviceOrientation(const WTF::PassRefPtr<WebCore::DeviceOrientation>&); + WebDeviceOrientation& operator=(const WTF::PassRefPtr<WebCore::DeviceOrientation>&); + operator WTF::PassRefPtr<WebCore::DeviceOrientation>() const; +#endif + +private: + WebDeviceOrientation() + : m_isNull(true), + m_canProvideAlpha(false), + m_alpha(0), + m_canProvideBeta(false), + m_beta(0), + m_canProvideGamma(false), + m_gamma(0) + { + } + + bool m_isNull; + bool m_canProvideAlpha; + double m_alpha; + bool m_canProvideBeta; + double m_beta; + bool m_canProvideGamma; + double m_gamma; +}; + +} // namespace WebKit + +#endif // WebDeviceOrientation_h diff --git a/WebKit/chromium/public/WebDeviceOrientationClient.h b/WebKit/chromium/public/WebDeviceOrientationClient.h new file mode 100644 index 0000000..4df8665 --- /dev/null +++ b/WebKit/chromium/public/WebDeviceOrientationClient.h @@ -0,0 +1,47 @@ +/* + * Copyright (C) 2010 Google Inc. 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 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 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 WebDeviceOrientationClient_h +#define WebDeviceOrientationClient_h + +namespace WebKit { + +class WebDeviceOrientation; +class WebDeviceOrientationController; + +class WebDeviceOrientationClient { +public: + virtual ~WebDeviceOrientationClient() {} + + virtual void setController(WebDeviceOrientationController*) = 0; + virtual void startUpdating() = 0; + virtual void stopUpdating() = 0; + + virtual WebDeviceOrientation lastOrientation() const = 0; +}; + +} // namespace WebKit + +#endif // WebDeviceOrientationClient_h diff --git a/WebKit/chromium/public/WebDeviceOrientationClientMock.h b/WebKit/chromium/public/WebDeviceOrientationClientMock.h new file mode 100644 index 0000000..fce964b --- /dev/null +++ b/WebKit/chromium/public/WebDeviceOrientationClientMock.h @@ -0,0 +1,57 @@ +/* + * Copyright (C) 2010 Google Inc. 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 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 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 WebDeviceOrientationClientMock_h +#define WebDeviceOrientationClientMock_h + +#include "WebCommon.h" +#include "WebDeviceOrientationClient.h" + +namespace WebCore { class DeviceOrientationClientMock; } + +namespace WebKit { + +class WebDeviceOrientationClientMock : public WebDeviceOrientationClient { +public: + WebDeviceOrientationClientMock() { initialize(); } + ~WebDeviceOrientationClientMock() { reset(); } + + virtual void setController(WebDeviceOrientationController*); + virtual void startUpdating(); + virtual void stopUpdating(); + virtual WebDeviceOrientation lastOrientation() const; + + WEBKIT_API void setOrientation(WebDeviceOrientation&); + +private: + WEBKIT_API void initialize(); + WEBKIT_API void reset(); + + WebCore::DeviceOrientationClientMock* m_clientMock; +}; + +} // namespace WebKit + +#endif // WebDeviceOrientationClientMock_h diff --git a/WebKit/chromium/public/WebDeviceOrientationController.h b/WebKit/chromium/public/WebDeviceOrientationController.h new file mode 100644 index 0000000..ef843ee --- /dev/null +++ b/WebKit/chromium/public/WebDeviceOrientationController.h @@ -0,0 +1,56 @@ +/* + * Copyright (C) 2010 Google Inc. 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 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 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 WebDeviceOrientationController_h +#define WebDeviceOrientationController_h + +#include "WebCommon.h" + +namespace WebCore { class DeviceOrientationController; } + +namespace WebKit { + +class WebDeviceOrientation; + +class WebDeviceOrientationController { +public: + WebDeviceOrientationController(WebCore::DeviceOrientationController* c) + : m_controller(c) + { + } + + WEBKIT_API void didChangeDeviceOrientation(const WebDeviceOrientation&); + +#if WEBKIT_IMPLEMENTATION + WebCore::DeviceOrientationController* controller() const; +#endif + +private: + WebCore::DeviceOrientationController* m_controller; +}; + +} // namespace WebKit + +#endif // WebDeviceOrientationController_h diff --git a/WebKit/chromium/public/WebFileChooserParams.h b/WebKit/chromium/public/WebFileChooserParams.h index 2a30944..8e56d70 100644 --- a/WebKit/chromium/public/WebFileChooserParams.h +++ b/WebKit/chromium/public/WebFileChooserParams.h @@ -59,6 +59,12 @@ struct WebFileChooserParams { // - replacing with other files // before opening a file chooser dialog. WebVector<WebString> selectedFiles; + + WebFileChooserParams() + : multiSelect(false) + , directory(false) + { + } }; } // namespace WebKit diff --git a/WebKit/chromium/public/WebGLES2Context.h b/WebKit/chromium/public/WebGLES2Context.h index c67faf2..45184aa 100644 --- a/WebKit/chromium/public/WebGLES2Context.h +++ b/WebKit/chromium/public/WebGLES2Context.h @@ -58,6 +58,12 @@ public: // Returns the ID of the texture used for offscreen rendering in the context of the parent. virtual unsigned getOffscreenContentParentTextureId() = 0; + + // The following function is used only on Mac OS X and is needed + // in order to report window size changes. +#if defined(__APPLE__) + virtual void resizeOnscreenContent(const WebSize&) = 0; +#endif }; } // namespace WebKit diff --git a/WebKit/chromium/public/WebIDBCallbacks.h b/WebKit/chromium/public/WebIDBCallbacks.h index cee8612..2e2c4d2 100644 --- a/WebKit/chromium/public/WebIDBCallbacks.h +++ b/WebKit/chromium/public/WebIDBCallbacks.h @@ -30,6 +30,7 @@ namespace WebKit { +class WebIDBCursor; class WebIDBDatabase; class WebIDBDatabaseError; class WebIDBKey; @@ -45,6 +46,7 @@ public: // For the rest, pass ownership to the callee via a pointer. virtual void onError(const WebIDBDatabaseError&) { WEBKIT_ASSERT_NOT_REACHED(); } virtual void onSuccess() { WEBKIT_ASSERT_NOT_REACHED(); } // For "null". + virtual void onSuccess(WebIDBCursor*) { WEBKIT_ASSERT_NOT_REACHED(); } virtual void onSuccess(WebIDBDatabase*) { WEBKIT_ASSERT_NOT_REACHED(); } virtual void onSuccess(const WebIDBKey&) { WEBKIT_ASSERT_NOT_REACHED(); } virtual void onSuccess(WebIDBIndex*) { WEBKIT_ASSERT_NOT_REACHED(); } diff --git a/WebKit/chromium/public/WebIDBCursor.h b/WebKit/chromium/public/WebIDBCursor.h new file mode 100644 index 0000000..27eb924 --- /dev/null +++ b/WebKit/chromium/public/WebIDBCursor.h @@ -0,0 +1,78 @@ +/* + * Copyright (C) 2010 Google Inc. 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 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 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 WebIDBCursor_h +#define WebIDBCursor_h + +#include "WebCommon.h" +#include "WebIDBCallbacks.h" +#include "WebIDBKey.h" +#include "WebSerializedScriptValue.h" +#include "WebString.h" + +namespace WebKit { + +// See comment in WebIndexedDatabase for a high level overview these classes. +class WebIDBCursor { +public: + virtual ~WebIDBCursor() { } + + virtual unsigned short direction() const + { + WEBKIT_ASSERT_NOT_REACHED(); + return 0; + } + + virtual WebIDBKey key() const + { + WEBKIT_ASSERT_NOT_REACHED(); + return WebIDBKey(""); + } + + virtual WebSerializedScriptValue value() const + { + WEBKIT_ASSERT_NOT_REACHED(); + return WebSerializedScriptValue(); + } + + virtual void update(const WebSerializedScriptValue&, WebIDBCallbacks*) + { + WEBKIT_ASSERT_NOT_REACHED(); + } + + virtual void continueFunction(const WebIDBKey&, WebIDBCallbacks*) + { + WEBKIT_ASSERT_NOT_REACHED(); + } + + virtual void remove(WebIDBCallbacks*) + { + WEBKIT_ASSERT_NOT_REACHED(); + } +}; + +} // namespace WebKit + +#endif // WebIDBCursor_h diff --git a/WebKit/chromium/public/WebIDBKeyRange.h b/WebKit/chromium/public/WebIDBKeyRange.h new file mode 100644 index 0000000..82953ce --- /dev/null +++ b/WebKit/chromium/public/WebIDBKeyRange.h @@ -0,0 +1,66 @@ +/* + * Copyright (C) 2010 Google Inc. 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 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 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 WebIDBKeyRange_h +#define WebIDBKeyRange_h + +#include "WebCommon.h" +#include "WebPrivatePtr.h" + +namespace WebCore { class IDBKeyRange; } + +namespace WebKit { + +class WebIDBKey; +class WebString; + +class WebIDBKeyRange { +public: + ~WebIDBKeyRange() { reset(); } + + WebIDBKeyRange(const WebIDBKeyRange& keyRange) { assign(keyRange); } + WebIDBKeyRange(const WebIDBKey& left, const WebIDBKey& right, unsigned short flags) { assign(left, right, flags); } + + WEBKIT_API WebIDBKey left() const; + WEBKIT_API WebIDBKey right() const; + WEBKIT_API unsigned short flags() const; + + WEBKIT_API void assign(const WebIDBKeyRange&); + WEBKIT_API void assign(const WebIDBKey& left, const WebIDBKey& right, unsigned short flags); + WEBKIT_API void reset(); + +#if WEBKIT_IMPLEMENTATION + WebIDBKeyRange(const WTF::PassRefPtr<WebCore::IDBKeyRange>&); + WebIDBKeyRange& operator=(const WTF::PassRefPtr<WebCore::IDBKeyRange>&); + operator WTF::PassRefPtr<WebCore::IDBKeyRange>() const; +#endif + +private: + WebPrivatePtr<WebCore::IDBKeyRange> m_private; +}; + +} // namespace WebKit + +#endif // WebIDBKeyRange_h diff --git a/WebKit/chromium/public/WebIDBObjectStore.h b/WebKit/chromium/public/WebIDBObjectStore.h index fb81fb9..7452be9 100755 --- a/WebKit/chromium/public/WebIDBObjectStore.h +++ b/WebKit/chromium/public/WebIDBObjectStore.h @@ -33,6 +33,8 @@ namespace WebKit { +class WebIDBKeyRange; + // See comment in WebIndexedDatabase for a high level overview these classes. class WebIDBObjectStore { public: @@ -79,6 +81,10 @@ public: { WEBKIT_ASSERT_NOT_REACHED(); } + virtual void openCursor(const WebIDBKeyRange&, unsigned short direction, WebIDBCallbacks*) + { + WEBKIT_ASSERT_NOT_REACHED(); + } // FIXME: finish. }; diff --git a/WebKit/chromium/public/WebRuntimeFeatures.h b/WebKit/chromium/public/WebRuntimeFeatures.h index 517aad5..9aa1f4f 100644 --- a/WebKit/chromium/public/WebRuntimeFeatures.h +++ b/WebKit/chromium/public/WebRuntimeFeatures.h @@ -77,6 +77,9 @@ public: WEBKIT_API static void enableTouch(bool); WEBKIT_API static bool isTouchEnabled(); + WEBKIT_API static void enableDeviceMotion(bool); + WEBKIT_API static bool isDeviceMotionEnabled(); + WEBKIT_API static void enableDeviceOrientation(bool); WEBKIT_API static bool isDeviceOrientationEnabled(); diff --git a/WebKit/chromium/public/WebDevToolsMessageTransport.h b/WebKit/chromium/public/WebSpeechInputControllerMock.h index 54c07f1..9a26235 100644 --- a/WebKit/chromium/public/WebDevToolsMessageTransport.h +++ b/WebKit/chromium/public/WebSpeechInputControllerMock.h @@ -28,19 +28,23 @@ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#ifndef WebDevToolsMessageTransport_h -#define WebDevToolsMessageTransport_h +#ifndef WebSpeechInputControllerMock_h +#define WebSpeechInputControllerMock_h -#include "WebCString.h" -#include "WebCommon.h" +#include "WebSpeechInputController.h" namespace WebKit { -struct WebDevToolsMessageData; -class WebDevToolsMessageTransport { +class WebString; +class WebSpeechInputListener; + +class WebSpeechInputControllerMock : public WebSpeechInputController { public: - virtual ~WebDevToolsMessageTransport() { } - virtual void sendMessageToFrontendOnIOThread(const WebDevToolsMessageData&) = 0; + WEBKIT_API static WebSpeechInputControllerMock* create( + WebSpeechInputListener* listener); + virtual ~WebSpeechInputControllerMock() { } + + virtual void setMockRecognitionResult(const WebString& result) = 0; }; } // namespace WebKit diff --git a/WebKit/chromium/public/WebString.h b/WebKit/chromium/public/WebString.h index 2c9664e..4d5e502 100644 --- a/WebKit/chromium/public/WebString.h +++ b/WebKit/chromium/public/WebString.h @@ -34,10 +34,7 @@ #include "WebCommon.h" #if WEBKIT_IMPLEMENTATION -namespace WebCore { -class String; -class AtomicString; -} +#include <wtf/Forward.h> #else #include <base/nullable_string16.h> #include <base/string16.h> @@ -102,13 +99,13 @@ public: } #if WEBKIT_IMPLEMENTATION - WebString(const WebCore::String&); - WebString& operator=(const WebCore::String&); - operator WebCore::String() const; + WebString(const WTF::String&); + WebString& operator=(const WTF::String&); + operator WTF::String() const; - WebString(const WebCore::AtomicString&); - WebString& operator=(const WebCore::AtomicString&); - operator WebCore::AtomicString() const; + WebString(const WTF::AtomicString&); + WebString& operator=(const WTF::AtomicString&); + operator WTF::AtomicString() const; #else WebString(const string16& s) : m_private(0) diff --git a/WebKit/chromium/public/WebViewClient.h b/WebKit/chromium/public/WebViewClient.h index 4628c2f..c64418b 100644 --- a/WebKit/chromium/public/WebViewClient.h +++ b/WebKit/chromium/public/WebViewClient.h @@ -44,6 +44,7 @@ namespace WebKit { class WebAccessibilityObject; +class WebDeviceOrientationClient; class WebDragData; class WebElement; class WebFileChooserCompletion; @@ -341,6 +342,11 @@ public: virtual WebSpeechInputController* speechInputController( WebSpeechInputListener*) { return 0; } + // Device Orientation -------------------------------------------------- + + // Access the embedder API for device orientation services. + virtual WebDeviceOrientationClient* deviceOrientationClient() { return 0; } + protected: ~WebViewClient() { } }; |