summaryrefslogtreecommitdiff
path: root/Source/WebKit/chromium/public
diff options
context:
space:
mode:
authorSimon Hausmann <simon.hausmann@nokia.com>2012-02-03 09:55:33 +0100
committerSimon Hausmann <simon.hausmann@nokia.com>2012-02-03 09:55:33 +0100
commitcd44dc59cdfc39534aef4d417e9f3c412e3be139 (patch)
tree8d89889ba95ed6ec9322e733846cc9cce9d7dff1 /Source/WebKit/chromium/public
parentd11f84f5b5cdc0d92a08af01b13472fdd5f9acb9 (diff)
downloadqtwebkit-cd44dc59cdfc39534aef4d417e9f3c412e3be139.tar.gz
Imported WebKit commit fce473cb4d55aa9fe9d0b0322a2fffecb731b961 (http://svn.webkit.org/repository/webkit/trunk@106560)
Diffstat (limited to 'Source/WebKit/chromium/public')
-rw-r--r--Source/WebKit/chromium/public/WebAccessibilityObject.h7
-rw-r--r--Source/WebKit/chromium/public/WebContentSecurityPolicy.h (renamed from Source/WebKit/chromium/public/WebWorker.h)31
-rw-r--r--Source/WebKit/chromium/public/WebDevToolsFrontendClient.h1
-rw-r--r--Source/WebKit/chromium/public/WebDeviceOrientation.h14
-rw-r--r--Source/WebKit/chromium/public/WebFrame.h2
-rw-r--r--Source/WebKit/chromium/public/WebFrameClient.h12
-rw-r--r--Source/WebKit/chromium/public/WebIDBKey.h5
-rw-r--r--Source/WebKit/chromium/public/WebInputEvent.h13
-rw-r--r--Source/WebKit/chromium/public/WebIntent.h32
-rw-r--r--Source/WebKit/chromium/public/WebIntentRequest.h79
-rw-r--r--Source/WebKit/chromium/public/WebIntentServiceInfo.h5
-rw-r--r--Source/WebKit/chromium/public/WebNode.h2
-rw-r--r--Source/WebKit/chromium/public/WebRuntimeFeatures.h3
-rw-r--r--Source/WebKit/chromium/public/WebScreenInfo.h6
-rw-r--r--Source/WebKit/chromium/public/WebSecurityPolicy.h3
-rw-r--r--Source/WebKit/chromium/public/WebSettings.h3
-rw-r--r--Source/WebKit/chromium/public/WebSharedWorker.h3
-rw-r--r--Source/WebKit/chromium/public/WebSharedWorkerClient.h5
-rw-r--r--Source/WebKit/chromium/public/WebSocket.h23
-rw-r--r--Source/WebKit/chromium/public/WebSocketClient.h6
-rw-r--r--Source/WebKit/chromium/public/WebSpeechInputResult.h7
-rw-r--r--Source/WebKit/chromium/public/WebSpellCheckClient.h9
-rw-r--r--Source/WebKit/chromium/public/WebTextCheckingResult.h47
-rw-r--r--Source/WebKit/chromium/public/WebTextCheckingType.h (renamed from Source/WebKit/chromium/public/WebSpeechInputControllerMock.h)31
-rw-r--r--Source/WebKit/chromium/public/WebUserMediaClient.h6
-rw-r--r--Source/WebKit/chromium/public/WebUserMediaRequest.h3
-rw-r--r--Source/WebKit/chromium/public/WebView.h7
-rw-r--r--Source/WebKit/chromium/public/WebViewClient.h7
-rw-r--r--Source/WebKit/chromium/public/WebWidget.h17
-rw-r--r--Source/WebKit/chromium/public/WebWidgetClient.h15
-rw-r--r--Source/WebKit/chromium/public/WebWorkerInfo.h44
-rw-r--r--Source/WebKit/chromium/public/platform/WebGraphicsContext3D.h12
-rw-r--r--Source/WebKit/chromium/public/platform/WebKitPlatformSupport.h11
-rw-r--r--Source/WebKit/chromium/public/platform/WebMediaStreamDescriptor.h17
-rw-r--r--Source/WebKit/chromium/public/platform/WebMediaStreamSource.h9
-rw-r--r--Source/WebKit/chromium/public/platform/WebSolidColorLayer.h48
-rw-r--r--Source/WebKit/chromium/public/platform/WebThread.h10
37 files changed, 445 insertions, 110 deletions
diff --git a/Source/WebKit/chromium/public/WebAccessibilityObject.h b/Source/WebKit/chromium/public/WebAccessibilityObject.h
index 9c67b7766..c52b830a9 100644
--- a/Source/WebKit/chromium/public/WebAccessibilityObject.h
+++ b/Source/WebKit/chromium/public/WebAccessibilityObject.h
@@ -164,6 +164,13 @@ public:
WEBKIT_EXPORT unsigned cellRowIndex() const;
WEBKIT_EXPORT unsigned cellRowSpan() const;
+ // Make this object visible by scrolling as many nested scrollable views as needed.
+ WEBKIT_EXPORT void scrollToMakeVisible() const;
+ // Same, but if the whole object can't be made visible, try for this subrect, in local coordinates.
+ WEBKIT_EXPORT void scrollToMakeVisibleWithSubFocus(const WebRect&) const;
+ // Scroll this object to a given point in global coordinates of the top-level window.
+ WEBKIT_EXPORT void scrollToGlobalPoint(const WebPoint&) const;
+
#if WEBKIT_IMPLEMENTATION
WebAccessibilityObject(const WTF::PassRefPtr<WebCore::AccessibilityObject>&);
WebAccessibilityObject& operator=(const WTF::PassRefPtr<WebCore::AccessibilityObject>&);
diff --git a/Source/WebKit/chromium/public/WebWorker.h b/Source/WebKit/chromium/public/WebContentSecurityPolicy.h
index c70a87361..cafd17aba 100644
--- a/Source/WebKit/chromium/public/WebWorker.h
+++ b/Source/WebKit/chromium/public/WebContentSecurityPolicy.h
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2009 Google Inc. All rights reserved.
+ * Copyright (C) 2012 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
@@ -28,33 +28,14 @@
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-#ifndef WebWorker_h
-#define WebWorker_h
-
-#include "WebMessagePortChannel.h"
+#ifndef WebContentSecurityPolicy_h
+#define WebContentSecurityPolicy_h
namespace WebKit {
-class WebString;
-class WebURL;
-class WebWorkerClient;
-
-// Provides an interface to the script execution context for a worker.
-class WebWorker {
-public:
- // Instantiates a built-in WebWorker.
- WEBKIT_EXPORT static WebWorker* create(WebWorkerClient*);
-
- virtual ~WebWorker() { }
- virtual void startWorkerContext(const WebURL& scriptURL,
- const WebString& userAgent,
- const WebString& sourceCode) = 0;
- virtual void terminateWorkerContext() = 0;
- virtual void postMessageToWorkerContext(
- const WebString&,
- const WebMessagePortChannelArray&) = 0;
- virtual void workerObjectDestroyed() = 0;
- virtual void clientDestroyed() = 0;
+enum WebContentSecurityPolicyType {
+ WebContentSecurityPolicyTypeReportOnly,
+ WebContentSecurityPolicyTypeEnforcePolicy
};
} // namespace WebKit
diff --git a/Source/WebKit/chromium/public/WebDevToolsFrontendClient.h b/Source/WebKit/chromium/public/WebDevToolsFrontendClient.h
index acb5f9849..c09f514c1 100644
--- a/Source/WebKit/chromium/public/WebDevToolsFrontendClient.h
+++ b/Source/WebKit/chromium/public/WebDevToolsFrontendClient.h
@@ -49,6 +49,7 @@ public:
virtual void requestUndockWindow() { }
virtual void requestSetDockSide(const WebString& side) { }
virtual void moveWindowBy(const WebFloatPoint&) { }
+ virtual void openInNewTab(const WebString& side) { }
virtual void saveAs(const WebString& fileName, const WebString& content) { }
protected:
diff --git a/Source/WebKit/chromium/public/WebDeviceOrientation.h b/Source/WebKit/chromium/public/WebDeviceOrientation.h
index 7e8aa7244..282dc7157 100644
--- a/Source/WebKit/chromium/public/WebDeviceOrientation.h
+++ b/Source/WebKit/chromium/public/WebDeviceOrientation.h
@@ -35,14 +35,16 @@ namespace WebKit {
class WebDeviceOrientation {
public:
- WebDeviceOrientation(bool canProvideAlpha, double alpha, bool canProvideBeta, double beta, bool canProvideGamma, double gamma)
+ WebDeviceOrientation(bool canProvideAlpha, double alpha, bool canProvideBeta, double beta, bool canProvideGamma, double gamma, bool canProvideAbsolute = false, bool absolute = false)
: m_isNull(false),
m_canProvideAlpha(canProvideAlpha),
m_alpha(alpha),
m_canProvideBeta(canProvideBeta),
m_beta(beta),
m_canProvideGamma(canProvideGamma),
- m_gamma(gamma)
+ m_gamma(gamma),
+ m_canProvideAbsolute(canProvideAbsolute),
+ m_absolute(absolute)
{
}
@@ -55,6 +57,8 @@ public:
double beta() { return m_beta; }
bool canProvideGamma() { return m_canProvideGamma; }
double gamma() { return m_gamma; }
+ bool canProvideAbsolute() {return m_canProvideAbsolute; }
+ bool absolute() { return m_absolute; }
#if WEBKIT_IMPLEMENTATION
WebDeviceOrientation(const WTF::PassRefPtr<WebCore::DeviceOrientation>&);
@@ -70,7 +74,9 @@ private:
m_canProvideBeta(false),
m_beta(0),
m_canProvideGamma(false),
- m_gamma(0)
+ m_gamma(0),
+ m_canProvideAbsolute(false),
+ m_absolute(false)
{
}
@@ -81,6 +87,8 @@ private:
double m_beta;
bool m_canProvideGamma;
double m_gamma;
+ bool m_canProvideAbsolute;
+ bool m_absolute;
};
} // namespace WebKit
diff --git a/Source/WebKit/chromium/public/WebFrame.h b/Source/WebKit/chromium/public/WebFrame.h
index 85bbda108..9574c490e 100644
--- a/Source/WebKit/chromium/public/WebFrame.h
+++ b/Source/WebKit/chromium/public/WebFrame.h
@@ -418,7 +418,7 @@ public:
// Spell-checking support.
virtual void enableContinuousSpellChecking(bool) = 0;
virtual bool isContinuousSpellCheckingEnabled() const = 0;
-
+ virtual void requestTextChecking(const WebElement&) = 0;
// Selection -----------------------------------------------------------
diff --git a/Source/WebKit/chromium/public/WebFrameClient.h b/Source/WebKit/chromium/public/WebFrameClient.h
index 94abe83fb..d0507e3d1 100644
--- a/Source/WebKit/chromium/public/WebFrameClient.h
+++ b/Source/WebKit/chromium/public/WebFrameClient.h
@@ -55,8 +55,9 @@ class WebDataSource;
class WebDOMEvent;
class WebFormElement;
class WebFrame;
-class WebIntentServiceInfo;
class WebIntent;
+class WebIntentRequest;
+class WebIntentServiceInfo;
class WebMediaPlayer;
class WebMediaPlayerClient;
class WebNode;
@@ -83,9 +84,6 @@ public:
virtual WebPlugin* createPlugin(WebFrame*, const WebPluginParams&) { return 0; }
// May return null.
- virtual WebWorker* createWorker(WebFrame*, WebSharedWorkerClient*) { return 0; }
-
- // May return null.
virtual WebSharedWorker* createSharedWorker(WebFrame*, const WebURL&, const WebString&, unsigned long long) { return 0; }
// May return null.
@@ -383,9 +381,9 @@ public:
// Register a service to handle Web Intents.
virtual void registerIntentService(WebFrame*, const WebIntentServiceInfo&) { }
- // Start a Web Intents activity. Replies to this request should be sent to
- // the WebFrame starting the activity.
- virtual void dispatchIntent(WebFrame*, const WebIntent&) { }
+ // Start a Web Intents activity. The callee uses the |WebIntentRequest|
+ // object to coordinate replies to the intent invocation.
+ virtual void dispatchIntent(WebFrame*, const WebIntentRequest&) { }
// Messages ------------------------------------------------------
diff --git a/Source/WebKit/chromium/public/WebIDBKey.h b/Source/WebKit/chromium/public/WebIDBKey.h
index e47971755..a78142345 100644
--- a/Source/WebKit/chromium/public/WebIDBKey.h
+++ b/Source/WebKit/chromium/public/WebIDBKey.h
@@ -49,6 +49,7 @@ public:
WEBKIT_EXPORT static WebIDBKey createDate(double);
WEBKIT_EXPORT static WebIDBKey createNumber(double);
WEBKIT_EXPORT static WebIDBKey createInvalid();
+ WEBKIT_EXPORT static WebIDBKey createNull();
WEBKIT_EXPORT static WebIDBKey createFromValueAndKeyPath(const WebSerializedScriptValue&, const WebIDBKeyPath&);
WEBKIT_EXPORT static WebSerializedScriptValue injectIDBKeyIntoSerializedValue(const WebIDBKey&, const WebSerializedScriptValue&, const WebIDBKeyPath&);
@@ -65,6 +66,7 @@ public:
WEBKIT_EXPORT void assignDate(double);
WEBKIT_EXPORT void assignNumber(double);
WEBKIT_EXPORT void assignInvalid();
+ WEBKIT_EXPORT void assignNull();
WEBKIT_EXPORT void reset();
enum Type {
@@ -72,7 +74,8 @@ public:
ArrayType,
StringType,
DateType,
- NumberType
+ NumberType,
+ NullType,
};
WEBKIT_EXPORT Type type() const;
diff --git a/Source/WebKit/chromium/public/WebInputEvent.h b/Source/WebKit/chromium/public/WebInputEvent.h
index 65bc87232..57b1f4b5c 100644
--- a/Source/WebKit/chromium/public/WebInputEvent.h
+++ b/Source/WebKit/chromium/public/WebInputEvent.h
@@ -107,6 +107,8 @@ public:
GestureFlingStart,
GestureFlingCancel,
GestureTap,
+ GestureTapDown,
+ GestureDoubleTap,
// WebTouchEvent
TouchStart,
@@ -304,11 +306,12 @@ class WebMouseWheelEvent : public WebMouseEvent {
public:
enum Phase {
PhaseNone = 0,
- PhaseBegan = 1 << 1,
- PhaseStationary = 1 << 2,
- PhaseChanged = 1 << 3,
- PhaseEnded = 1 << 4,
- PhaseCancelled = 1 << 5,
+ PhaseBegan = 1 << 0,
+ PhaseStationary = 1 << 1,
+ PhaseChanged = 1 << 2,
+ PhaseEnded = 1 << 3,
+ PhaseCancelled = 1 << 4,
+ PhaseMayBegin = 1 << 5,
};
float deltaX;
diff --git a/Source/WebKit/chromium/public/WebIntent.h b/Source/WebKit/chromium/public/WebIntent.h
index 4ce0342b7..d01098fe5 100644
--- a/Source/WebKit/chromium/public/WebIntent.h
+++ b/Source/WebKit/chromium/public/WebIntent.h
@@ -32,8 +32,11 @@
#define WebIntent_h
#include "platform/WebCommon.h"
+#include "platform/WebPrivatePtr.h"
#include "platform/WebString.h"
+namespace WebCore { class Intent; }
+
namespace WebKit {
// Holds data passed through a Web Intents invocation call from the Javascript
@@ -41,29 +44,30 @@ namespace WebKit {
// See spec at http://www.chromium.org/developers/design-documents/webintentsapi
class WebIntent {
public:
- ~WebIntent() { }
+ WebIntent() { }
+ WebIntent(const WebIntent& other) { assign(other); }
+ ~WebIntent() { reset(); }
- WEBKIT_EXPORT WebString action() const;
- WEBKIT_EXPORT void setAction(const WebString&);
+ WebIntent& operator=(const WebIntent& other)
+ {
+ assign(other);
+ return *this;
+ }
+ WEBKIT_EXPORT void reset();
+ WEBKIT_EXPORT bool isNull() const;
+ WEBKIT_EXPORT bool equals(const WebIntent&) const;
+ WEBKIT_EXPORT void assign(const WebIntent&);
+ WEBKIT_EXPORT WebString action() const;
WEBKIT_EXPORT WebString type() const;
- WEBKIT_EXPORT void setType(const WebString&);
-
WEBKIT_EXPORT WebString data() const;
- WEBKIT_EXPORT void setData(const WebString&);
-
- WEBKIT_EXPORT int identifier() const;
- WEBKIT_EXPORT void setIdentifier(int);
#if WEBKIT_IMPLEMENTATION
- WebIntent();
+ WebIntent(const WTF::PassRefPtr<WebCore::Intent>&);
#endif
private:
- WebString m_action;
- WebString m_type;
- WebString m_data;
- int m_identifier;
+ WebPrivatePtr<WebCore::Intent> m_private;
};
} // namespace WebKit
diff --git a/Source/WebKit/chromium/public/WebIntentRequest.h b/Source/WebKit/chromium/public/WebIntentRequest.h
new file mode 100644
index 000000000..7934f1327
--- /dev/null
+++ b/Source/WebKit/chromium/public/WebIntentRequest.h
@@ -0,0 +1,79 @@
+/*
+ * Copyright (C) 2011 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 WebIntentRequest_h
+#define WebIntentRequest_h
+
+#include "platform/WebCommon.h"
+#include "platform/WebPrivatePtr.h"
+#include "platform/WebString.h"
+
+namespace WebCore { class IntentRequest; }
+
+namespace WebKit {
+
+class WebIntent;
+class WebSerializedScriptValue;
+
+// Holds data passed through a Web Intents invocation call from the Javascript
+// Intent object.
+// See spec at http://www.chromium.org/developers/design-documents/webintentsapi
+class WebIntentRequest {
+public:
+ WebIntentRequest() { }
+ WebIntentRequest(const WebIntentRequest& other) { assign(other); }
+ ~WebIntentRequest() { reset(); }
+
+ WebIntentRequest& operator=(const WebIntentRequest& other)
+ {
+ assign(other);
+ return *this;
+ }
+ WEBKIT_EXPORT void reset();
+ WEBKIT_EXPORT bool isNull() const;
+ WEBKIT_EXPORT bool equals(const WebIntentRequest&) const;
+ WEBKIT_EXPORT void assign(const WebIntentRequest&);
+
+ WEBKIT_EXPORT void postResult(const WebSerializedScriptValue&);
+ WEBKIT_EXPORT void postFailure(const WebSerializedScriptValue&);
+
+ WEBKIT_EXPORT WebIntent intent() const;
+
+#if WEBKIT_IMPLEMENTATION
+ WebIntentRequest(const WTF::PassRefPtr<WebCore::IntentRequest>&);
+#endif
+
+private:
+ WebPrivatePtr<WebCore::IntentRequest> m_private;
+};
+
+} // namespace WebKit
+
+#endif // WebIntentRequest_h
diff --git a/Source/WebKit/chromium/public/WebIntentServiceInfo.h b/Source/WebKit/chromium/public/WebIntentServiceInfo.h
index 5879be8aa..b296ca46e 100644
--- a/Source/WebKit/chromium/public/WebIntentServiceInfo.h
+++ b/Source/WebKit/chromium/public/WebIntentServiceInfo.h
@@ -67,6 +67,11 @@ public:
WEBKIT_EXPORT WebString disposition() const;
WEBKIT_EXPORT void setDisposition(const WebString&);
+#if WEBKIT_IMPLEMENTATION
+ WebIntentServiceInfo(const WebString& action, const WebString& type, const WebURL& href,
+ const WebString& title, const WebString& disposition);
+#endif
+
private:
WebString m_action;
WebString m_type;
diff --git a/Source/WebKit/chromium/public/WebNode.h b/Source/WebKit/chromium/public/WebNode.h
index 38be3b66f..d4ee874e9 100644
--- a/Source/WebKit/chromium/public/WebNode.h
+++ b/Source/WebKit/chromium/public/WebNode.h
@@ -42,6 +42,7 @@ class WebDOMEvent;
class WebDOMEventListener;
class WebDOMEventListenerPrivate;
class WebDocument;
+class WebElement;
class WebFrame;
class WebNodeList;
@@ -109,6 +110,7 @@ public:
WEBKIT_EXPORT bool dispatchEvent(const WebDOMEvent&);
WEBKIT_EXPORT void simulateClick();
WEBKIT_EXPORT WebNodeList getElementsByTagName(const WebString&) const;
+ WEBKIT_EXPORT WebElement rootEditableElement() const;
// Returns true if the node has a non-empty bounding box in layout.
// This does not 100% guarantee the user can see it, but is pretty close.
diff --git a/Source/WebKit/chromium/public/WebRuntimeFeatures.h b/Source/WebKit/chromium/public/WebRuntimeFeatures.h
index 5fff989e5..7e29ab0db 100644
--- a/Source/WebKit/chromium/public/WebRuntimeFeatures.h
+++ b/Source/WebKit/chromium/public/WebRuntimeFeatures.h
@@ -121,6 +121,9 @@ public:
WEBKIT_EXPORT static void enableGamepad(bool);
WEBKIT_EXPORT static bool isGamepadEnabled();
+ WEBKIT_EXPORT static void enableShadowDOM(bool);
+ WEBKIT_EXPORT static bool isShadowDOMEnabled();
+
private:
WebRuntimeFeatures();
};
diff --git a/Source/WebKit/chromium/public/WebScreenInfo.h b/Source/WebKit/chromium/public/WebScreenInfo.h
index ac92e1667..bd885f424 100644
--- a/Source/WebKit/chromium/public/WebScreenInfo.h
+++ b/Source/WebKit/chromium/public/WebScreenInfo.h
@@ -69,16 +69,12 @@ struct WebScreenInfo {
// some of the rectangle's coordinates may be negative values".
WebRect availableRect;
- // Measured in frames per second. 0 if the rate is unknown or not applicable.
- double refreshRate;
-
WebScreenInfo()
: horizontalDPI(0)
, verticalDPI(0)
, depth(0)
, depthPerComponent(0)
- , isMonochrome(false)
- , refreshRate(0) { }
+ , isMonochrome(false) { }
};
} // namespace WebKit
diff --git a/Source/WebKit/chromium/public/WebSecurityPolicy.h b/Source/WebKit/chromium/public/WebSecurityPolicy.h
index 4063f91cc..466d98684 100644
--- a/Source/WebKit/chromium/public/WebSecurityPolicy.h
+++ b/Source/WebKit/chromium/public/WebSecurityPolicy.h
@@ -61,6 +61,9 @@ public:
// included by an HTTPS page.
WEBKIT_EXPORT static void registerURLSchemeAsSecure(const WebString&);
+ // Registers a non-HTTP URL scheme which can be sent CORS requests.
+ WEBKIT_EXPORT static void registerURLSchemeAsCORSEnabled(const WebString&);
+
// Support for whitelisting access to origins beyond the same-origin policy.
WEBKIT_EXPORT static void addOriginAccessWhitelistEntry(
const WebURL& sourceOrigin, const WebString& destinationProtocol,
diff --git a/Source/WebKit/chromium/public/WebSettings.h b/Source/WebKit/chromium/public/WebSettings.h
index cce47e2e2..b5da4e6ba 100644
--- a/Source/WebKit/chromium/public/WebSettings.h
+++ b/Source/WebKit/chromium/public/WebSettings.h
@@ -85,6 +85,7 @@ public:
virtual void setJavaScriptCanAccessClipboard(bool) = 0;
virtual void setXSSAuditorEnabled(bool) = 0;
virtual void setDNSPrefetchingEnabled(bool) = 0;
+ virtual void setFixedElementsLayoutRelativeToFrame(bool) = 0;
virtual void setLocalStorageEnabled(bool) = 0;
virtual void setEditableLinkBehaviorNeverLive() = 0;
virtual void setFrameFlatteningEnabled(bool) = 0;
@@ -114,11 +115,13 @@ public:
virtual void setAcceleratedCompositingForPluginsEnabled(bool) = 0;
virtual void setAcceleratedCompositingForAnimationEnabled(bool) = 0;
virtual void setAccelerated2dCanvasEnabled(bool) = 0;
+ virtual void setDeferred2dCanvasEnabled(bool) = 0;
virtual void setAcceleratedCompositingForFixedPositionEnabled(bool) = 0;
virtual void setMinimumAccelerated2dCanvasSize(int) = 0;
virtual void setAcceleratedFiltersEnabled(bool) = 0;
virtual void setMemoryInfoEnabled(bool) = 0;
virtual void setHyperlinkAuditingEnabled(bool) = 0;
+ virtual void setLayoutFallbackWidth(int) = 0;
virtual void setAsynchronousSpellCheckingEnabled(bool) = 0;
virtual void setUnifiedTextCheckerEnabled(bool) = 0;
virtual void setCaretBrowsingEnabled(bool) = 0;
diff --git a/Source/WebKit/chromium/public/WebSharedWorker.h b/Source/WebKit/chromium/public/WebSharedWorker.h
index 447f7f486..f97ab9e4b 100644
--- a/Source/WebKit/chromium/public/WebSharedWorker.h
+++ b/Source/WebKit/chromium/public/WebSharedWorker.h
@@ -31,6 +31,7 @@
#ifndef WebSharedWorker_h
#define WebSharedWorker_h
+#include "WebContentSecurityPolicy.h"
#include "platform/WebCommon.h"
namespace WebCore {
@@ -61,6 +62,8 @@ public:
const WebString& name,
const WebString& userAgent,
const WebString& sourceCode,
+ const WebString& contentSecurityPolicy,
+ WebContentSecurityPolicyType,
long long scriptResourceAppCacheID) = 0;
class ConnectListener {
diff --git a/Source/WebKit/chromium/public/WebSharedWorkerClient.h b/Source/WebKit/chromium/public/WebSharedWorkerClient.h
index 01700c6c1..a085a3ea2 100644
--- a/Source/WebKit/chromium/public/WebSharedWorkerClient.h
+++ b/Source/WebKit/chromium/public/WebSharedWorkerClient.h
@@ -76,11 +76,6 @@ public:
// is owned by the object implementing WebCommonWorkerClient.
virtual WebNotificationPresenter* notificationPresenter() = 0;
- // This can be called on any thread to create a nested WebWorker.
- // WebSharedWorkers are not instantiated via this API - instead
- // they are created via the WebSharedWorkerRepository.
- virtual WebWorker* createWorker(WebSharedWorkerClient*) = 0;
-
// Called on the main webkit thread in the worker process during initialization.
virtual WebApplicationCacheHost* createApplicationCacheHost(WebApplicationCacheHostClient*) = 0;
diff --git a/Source/WebKit/chromium/public/WebSocket.h b/Source/WebKit/chromium/public/WebSocket.h
index f00b7957a..c10c372ad 100644
--- a/Source/WebKit/chromium/public/WebSocket.h
+++ b/Source/WebKit/chromium/public/WebSocket.h
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2011 Google Inc. All rights reserved.
+ * Copyright (C) 2011, 2012 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
@@ -38,7 +38,7 @@ namespace WebCore { class WebSocketChannel; }
namespace WebKit {
-class WebData;
+class WebArrayBuffer;
class WebDocument;
class WebString;
class WebURL;
@@ -60,13 +60,28 @@ public:
CloseEventCodeMaximumUserDefined = 4999
};
+ enum BinaryType {
+ BinaryTypeBlob = 0,
+ BinaryTypeArrayBuffer = 1
+ };
+
WEBKIT_EXPORT static WebSocket* create(const WebDocument&, WebSocketClient*);
virtual ~WebSocket() { }
+ // These functions come from binaryType attribute of the WebSocket API
+ // specification. It specifies binary object type for receiving binary
+ // frames representation. Receiving text frames are always mapped to
+ // WebString type regardless of this attribute.
+ // Default type is BinaryTypeBlob. But currently it is not supported.
+ // Set BinaryTypeArrayBuffer here ahead of using binary communication.
+ // See also, The WebSocket API - http://www.w3.org/TR/websockets/ .
+ virtual BinaryType binaryType() const = 0;
+ virtual bool setBinaryType(BinaryType) = 0;
+
virtual void connect(const WebURL&, const WebString& protocol) = 0;
virtual WebString subprotocol() = 0;
- virtual bool sendText(const WebString& message) = 0;
- virtual bool sendBinary(const WebData& binaryData) = 0;
+ virtual bool sendText(const WebString&) = 0;
+ virtual bool sendArrayBuffer(const WebArrayBuffer&) = 0;
virtual unsigned long bufferedAmount() const = 0;
virtual void close(int code, const WebString& reason) = 0;
virtual void fail(const WebString& reason) = 0;
diff --git a/Source/WebKit/chromium/public/WebSocketClient.h b/Source/WebKit/chromium/public/WebSocketClient.h
index b3a856bd2..06670626a 100644
--- a/Source/WebKit/chromium/public/WebSocketClient.h
+++ b/Source/WebKit/chromium/public/WebSocketClient.h
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2011 Google Inc. All rights reserved.
+ * Copyright (C) 2011, 2012 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
@@ -32,10 +32,10 @@
#define WebSocketClient_h
#include "platform/WebCommon.h"
-#include "platform/WebData.h"
namespace WebKit {
+class WebArrayBuffer;
class WebString;
class WebSocketClient {
@@ -48,7 +48,7 @@ public:
virtual ~WebSocketClient() { }
virtual void didConnect() { }
virtual void didReceiveMessage(const WebString& message) { }
- virtual void didReceiveBinaryData(const WebData& binaryData) { }
+ virtual void didReceiveArrayBuffer(const WebArrayBuffer& arrayBuffer) { }
virtual void didReceiveMessageError() { }
virtual void didUpdateBufferedAmount(unsigned long bufferedAmount) { }
virtual void didStartClosingHandshake() { }
diff --git a/Source/WebKit/chromium/public/WebSpeechInputResult.h b/Source/WebKit/chromium/public/WebSpeechInputResult.h
index a316fd230..82eb74aaa 100644
--- a/Source/WebKit/chromium/public/WebSpeechInputResult.h
+++ b/Source/WebKit/chromium/public/WebSpeechInputResult.h
@@ -42,9 +42,14 @@ namespace WebKit {
class WebSpeechInputResult {
public:
WebSpeechInputResult() { }
+ WebSpeechInputResult(const WebSpeechInputResult& other) { assign(other); }
~WebSpeechInputResult() { reset(); }
- WEBKIT_EXPORT void set(const WebString& utterance, double confidence);
+ // FIXME: Remove this when Chromium has been updated.
+ void set(const WebString& utterance, double confidence) { assign(utterance, confidence); }
+
+ WEBKIT_EXPORT void assign(const WebString& utterance, double confidence);
+ WEBKIT_EXPORT void assign(const WebSpeechInputResult& other);
WEBKIT_EXPORT void reset();
#if WEBKIT_IMPLEMENTATION
diff --git a/Source/WebKit/chromium/public/WebSpellCheckClient.h b/Source/WebKit/chromium/public/WebSpellCheckClient.h
index 457bd13c9..3005f2490 100644
--- a/Source/WebKit/chromium/public/WebSpellCheckClient.h
+++ b/Source/WebKit/chromium/public/WebSpellCheckClient.h
@@ -31,6 +31,7 @@
#ifndef WebSpellCheckClient_h
#define WebSpellCheckClient_h
+#include "WebTextCheckingType.h"
#include "platform/WebString.h"
#include "platform/WebVector.h"
@@ -38,6 +39,7 @@ namespace WebKit {
class WebString;
class WebTextCheckingCompletion;
+struct WebTextCheckingResult;
class WebSpellCheckClient {
public:
@@ -51,6 +53,13 @@ public:
int& misspelledOffset,
int& misspelledLength,
WebVector<WebString>* optionalSuggestions) { }
+
+ // The client should perform spell-checking on the given text. This function will
+ // enumerate all misspellings at once.
+ virtual void checkTextOfParagraph(const WebString&,
+ WebTextCheckingTypeMask mask,
+ WebVector<WebTextCheckingResult>* results) { }
+
// Requests asynchronous spelling and grammar checking, whose result should be
// returned by passed completion object.
virtual void requestCheckingOfText(const WebString&, WebTextCheckingCompletion*) { }
diff --git a/Source/WebKit/chromium/public/WebTextCheckingResult.h b/Source/WebKit/chromium/public/WebTextCheckingResult.h
index 010aa1abf..dfd0181e5 100644
--- a/Source/WebKit/chromium/public/WebTextCheckingResult.h
+++ b/Source/WebKit/chromium/public/WebTextCheckingResult.h
@@ -31,27 +31,66 @@
#ifndef WebTextCheckingResult_h
#define WebTextCheckingResult_h
+#include "WebTextCheckingType.h"
#include "platform/WebCommon.h"
+#include "platform/WebString.h"
+#include "platform/WebVector.h"
+
+namespace WebCore {
+struct TextCheckingResult;
+}
namespace WebKit {
// A checked entry of text checking.
struct WebTextCheckingResult {
+ // FIXME: Should be removed after we confirm Chromium does not use it.
enum Error {
ErrorSpelling = 1 << 0,
ErrorGrammar = 1 << 1
};
- explicit WebTextCheckingResult(Error e = ErrorSpelling, int p = 0, int l = 0)
- : error(e)
+ explicit WebTextCheckingResult(Error e = ErrorSpelling, int p = 0, int l = 0)
+ : type(WebTextCheckingTypeSpelling)
+ , error(e)
, position(p)
+ , location(p)
, length(l)
{
+ if (e & ErrorSpelling)
+ type = WebTextCheckingTypeSpelling;
+ else if (e & ErrorGrammar)
+ type = WebTextCheckingTypeGrammar;
+ else
+ WEBKIT_ASSERT_NOT_REACHED();
+ }
+
+ WebTextCheckingResult(WebTextCheckingType type, int location, int length, const WebString& replacement = WebString())
+ : type(type)
+ , error(ErrorSpelling)
+ , position(location)
+ , location(location)
+ , length(length)
+ , replacement(replacement)
+ {
+ if (type & WebTextCheckingTypeSpelling)
+ error = ErrorSpelling;
+ else if (type & WebTextCheckingTypeGrammar)
+ error = ErrorGrammar;
+ else
+ WEBKIT_ASSERT_NOT_REACHED();
}
- Error error;
- int position;
+#if WEBKIT_IMPLEMENTATION
+ operator WebCore::TextCheckingResult() const;
+#endif
+
+ WebTextCheckingType type;
+ Error error; // FIXME: Should be removed after we confirm Chromium does not use it.
+ int position; // FIXME: Should be removed after we confirm Chromium does not use it.
+ int location;
int length;
+ WebString replacement;
};
} // namespace WebKit
diff --git a/Source/WebKit/chromium/public/WebSpeechInputControllerMock.h b/Source/WebKit/chromium/public/WebTextCheckingType.h
index d4e543f02..b22139bcf 100644
--- a/Source/WebKit/chromium/public/WebSpeechInputControllerMock.h
+++ b/Source/WebKit/chromium/public/WebTextCheckingType.h
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2010 Google Inc. All rights reserved.
+ * Copyright (C) 2011 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
@@ -28,27 +28,24 @@
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-#ifndef WebSpeechInputControllerMock_h
-#define WebSpeechInputControllerMock_h
-
-#include "WebSpeechInputController.h"
+#ifndef WebTextCheckingType_h
+#define WebTextCheckingType_h
namespace WebKit {
-class WebString;
-class WebSpeechInputListener;
-
-class WebSpeechInputControllerMock : public WebSpeechInputController {
-public:
- WEBKIT_EXPORT static WebSpeechInputControllerMock* create(
- WebSpeechInputListener* listener);
- virtual ~WebSpeechInputControllerMock() { }
-
- virtual void addMockRecognitionResult(const WebString& result, double confidence, const WebString& language) = 0;
-
- virtual void clearResults() = 0;
+enum WebTextCheckingType {
+ WebTextCheckingTypeSpelling = 1 << 1,
+ WebTextCheckingTypeGrammar = 1 << 2,
+ WebTextCheckingTypeLink = 1 << 5,
+ WebTextCheckingTypeQuote = 1 << 6,
+ WebTextCheckingTypeDash = 1 << 7,
+ WebTextCheckingTypeReplacement = 1 << 8,
+ WebTextCheckingTypeCorrection = 1 << 9,
+ WebTextCheckingTypeShowCorrectionPanel = 1 << 10
};
+typedef unsigned WebTextCheckingTypeMask;
+
} // namespace WebKit
#endif
diff --git a/Source/WebKit/chromium/public/WebUserMediaClient.h b/Source/WebKit/chromium/public/WebUserMediaClient.h
index a4b75e940..2998159ee 100644
--- a/Source/WebKit/chromium/public/WebUserMediaClient.h
+++ b/Source/WebKit/chromium/public/WebUserMediaClient.h
@@ -41,7 +41,11 @@ class WebUserMediaClient {
public:
virtual ~WebUserMediaClient() { }
- virtual void requestUserMedia(const WebUserMediaRequest&, const WebVector<WebMediaStreamSource>&) = 0;
+ // DEPRECATED
+ virtual void requestUserMedia(const WebUserMediaRequest&, const WebVector<WebMediaStreamSource>&) { }
+
+ virtual void requestUserMedia(const WebUserMediaRequest&, const WebVector<WebMediaStreamSource>& audioSources, const WebVector<WebMediaStreamSource>& videoSources) { }
+
virtual void cancelUserMediaRequest(const WebUserMediaRequest&) = 0;
};
diff --git a/Source/WebKit/chromium/public/WebUserMediaRequest.h b/Source/WebKit/chromium/public/WebUserMediaRequest.h
index ab88125d6..38fb1898b 100644
--- a/Source/WebKit/chromium/public/WebUserMediaRequest.h
+++ b/Source/WebKit/chromium/public/WebUserMediaRequest.h
@@ -68,7 +68,10 @@ public:
WEBKIT_EXPORT bool cameraPreferenceEnvironment() const;
WEBKIT_EXPORT WebSecurityOrigin securityOrigin() const;
+ // DEPRECATED
WEBKIT_EXPORT void requestSucceeded(const WebVector<WebMediaStreamSource>&);
+
+ WEBKIT_EXPORT void requestSucceeded(const WebVector<WebMediaStreamSource>& audioSources, const WebVector<WebMediaStreamSource>& videoSources);
WEBKIT_EXPORT void requestFailed();
#if WEBKIT_IMPLEMENTATION
diff --git a/Source/WebKit/chromium/public/WebView.h b/Source/WebKit/chromium/public/WebView.h
index c72b6133c..ed853e23a 100644
--- a/Source/WebKit/chromium/public/WebView.h
+++ b/Source/WebKit/chromium/public/WebView.h
@@ -242,13 +242,6 @@ public:
// Sets the ratio as computed by computeViewportAttributes.
virtual void setDeviceScaleFactor(float) = 0;
- // Indicates whether position:fixed elements should be laid out relative
- // to the frame or relative to the page.
- virtual bool shouldLayoutFixedElementsRelativeToFrame() const = 0;
-
- // Sets the relative layout of position:fixed elements.
- virtual void setShouldLayoutFixedElementsRelativeToFrame(bool) = 0;
-
// Fixed Layout --------------------------------------------------------
diff --git a/Source/WebKit/chromium/public/WebViewClient.h b/Source/WebKit/chromium/public/WebViewClient.h
index 5a4d4e8e4..1b42a48a8 100644
--- a/Source/WebKit/chromium/public/WebViewClient.h
+++ b/Source/WebKit/chromium/public/WebViewClient.h
@@ -42,6 +42,7 @@
#include "WebTextDirection.h"
#include "WebWidgetClient.h"
#include "platform/WebColor.h"
+#include "platform/WebGraphicsContext3D.h"
#include "platform/WebString.h"
namespace WebKit {
@@ -109,6 +110,12 @@ public:
// Create a session storage namespace object associated with this WebView.
virtual WebStorageNamespace* createSessionStorageNamespace(unsigned quota) { return 0; }
+ // Creates a graphics context associated with the client's WebView.
+ // renderDirectlyToWebView means whether the context should be setup to
+ // render directly to the WebView (e.g. compositor context), or to an
+ // offscreen surface (e.g. WebGL context).
+ virtual WebGraphicsContext3D* createGraphicsContext3D(const WebGraphicsContext3D::Attributes&, bool renderDirectlyToWebView) { return 0; }
+
// Misc ----------------------------------------------------------------
// A new message was added to the console.
diff --git a/Source/WebKit/chromium/public/WebWidget.h b/Source/WebKit/chromium/public/WebWidget.h
index 3f594f369..ca160a26e 100644
--- a/Source/WebKit/chromium/public/WebWidget.h
+++ b/Source/WebKit/chromium/public/WebWidget.h
@@ -44,6 +44,7 @@
namespace WebKit {
class WebInputEvent;
+class WebMouseEvent;
class WebString;
struct WebPoint;
template <typename T> class WebVector;
@@ -170,6 +171,22 @@ public:
// to render its contents.
virtual bool isAcceleratedCompositingActive() const { return false; }
+ // Calling WebWidgetClient::requestPointerLock() will result in one
+ // return call to didAcquirePointerLock() or didNotAcquirePointerLock().
+ virtual void didAcquirePointerLock() { }
+ virtual void didNotAcquirePointerLock() { }
+
+ // Pointer lock was held, but has been lost. This may be due to a
+ // request via WebWidgetClient::requestPointerUnlock(), or for other
+ // reasons such as the user exiting lock, window focus changing, etc.
+ virtual void didLosePointerLock() { }
+
+ // Informs the WebWidget that the resizer rect changed. Happens for example
+ // on mac, when a widget appears below the WebWidget without changing the
+ // WebWidget's size (WebWidget::resize() automatically checks the resizer
+ // rect.)
+ virtual void didChangeWindowResizerRect() { }
+
protected:
~WebWidget() { }
};
diff --git a/Source/WebKit/chromium/public/WebWidgetClient.h b/Source/WebKit/chromium/public/WebWidgetClient.h
index e5b405dea..24cd9c6ac 100644
--- a/Source/WebKit/chromium/public/WebWidgetClient.h
+++ b/Source/WebKit/chromium/public/WebWidgetClient.h
@@ -126,6 +126,21 @@ public:
// reset the input method by cancelling any ongoing composition.
virtual void resetInputMethod() { }
+ // Requests to lock the mouse cursor. If true is returned, the success
+ // result will be asynchronously returned via a single call to
+ // WebWidget::didAcquirePointerLock() or
+ // WebWidget::didNotAcquirePointerLock().
+ // If false, the request has been denied synchronously.
+ virtual bool requestPointerLock() { return false; }
+
+ // Cause the pointer lock to be released. This may be called at any time,
+ // including when a lock is pending but not yet acquired.
+ // WebWidget::didLosePointerLock() is called when unlock is complete.
+ virtual void requestPointerUnlock() { }
+
+ // Returns true iff the pointer is locked to this widget.
+ virtual bool isPointerLocked() { return false; }
+
protected:
~WebWidgetClient() { }
};
diff --git a/Source/WebKit/chromium/public/WebWorkerInfo.h b/Source/WebKit/chromium/public/WebWorkerInfo.h
new file mode 100644
index 000000000..24cfa8961
--- /dev/null
+++ b/Source/WebKit/chromium/public/WebWorkerInfo.h
@@ -0,0 +1,44 @@
+/*
+ * Copyright (C) 2012 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 WebWorkerInfo_h
+#define WebWorkerInfo_h
+
+#include "platform/WebCommon.h"
+
+namespace WebKit {
+
+class WebWorkerInfo {
+public:
+ WEBKIT_EXPORT static unsigned dedicatedWorkerCount();
+};
+
+}
+#endif
diff --git a/Source/WebKit/chromium/public/platform/WebGraphicsContext3D.h b/Source/WebKit/chromium/public/platform/WebGraphicsContext3D.h
index 3811436c2..57f9d7985 100644
--- a/Source/WebKit/chromium/public/platform/WebGraphicsContext3D.h
+++ b/Source/WebKit/chromium/public/platform/WebGraphicsContext3D.h
@@ -118,6 +118,12 @@ public:
virtual ~WebGraphicsContextLostCallback() { }
};
+ class WebGraphicsErrorMessageCallback {
+ public:
+ virtual void onErrorMessage(const WebString&, WGC3Dint) = 0;
+ virtual ~WebGraphicsErrorMessageCallback() { }
+ };
+
class WebGraphicsSwapBuffersCompleteCallbackCHROMIUM {
public:
virtual void onSwapBuffersComplete() = 0;
@@ -127,9 +133,8 @@ public:
// This destructor needs to be public so that using classes can destroy instances if initialization fails.
virtual ~WebGraphicsContext3D() {}
- // Initializes the graphics context; should be the first operation performed
- // on newly-constructed instances. Returns true on success.
- virtual bool initialize(Attributes, WebView*, bool renderDirectlyToWebView) = 0;
+ // This function is deprecated and will be removed soon.
+ virtual bool initialize(Attributes, WebView*, bool renderDirectlyToWebView) { return false; }
// Makes the OpenGL context current on the current thread. Returns true on
// success.
@@ -369,6 +374,7 @@ public:
virtual void deleteTexture(WebGLId) = 0;
virtual void setContextLostCallback(WebGraphicsContextLostCallback* callback) {}
+ virtual void setErrorMessageCallback(WebGraphicsErrorMessageCallback* callback) { }
// GL_ARB_robustness
//
// This entry point must provide slightly different semantics than
diff --git a/Source/WebKit/chromium/public/platform/WebKitPlatformSupport.h b/Source/WebKit/chromium/public/platform/WebKitPlatformSupport.h
index 6c0e74f12..0acc9eafa 100644
--- a/Source/WebKit/chromium/public/platform/WebKitPlatformSupport.h
+++ b/Source/WebKit/chromium/public/platform/WebKitPlatformSupport.h
@@ -36,6 +36,7 @@
#include "WebCommon.h"
#include "WebData.h"
#include "WebGamepads.h"
+#include "WebGraphicsContext3D.h"
#include "WebLocalizedString.h"
#include "WebSerializedScriptValue.h"
#include "WebString.h"
@@ -313,10 +314,12 @@ public:
// Callable from a background WebKit thread.
virtual void callOnMainThread(void (*func)(void*), void* context) { }
- // WebGL --------------------------------------------------------------
-
- // May return null if WebGL is not supported.
- // Returns newly allocated WebGraphicsContext3D instance.
+ // GPU ----------------------------------------------------------------
+ //
+ // May return null if GPU is not supported.
+ // Returns newly allocated and initialized offscreen WebGraphicsContext3D instance.
+ virtual WebGraphicsContext3D* createOffscreenGraphicsContext3D(const WebGraphicsContext3D::Attributes&) { return 0; }
+ // Deprecated.
virtual WebGraphicsContext3D* createGraphicsContext3D() { return 0; }
// Audio --------------------------------------------------------------
diff --git a/Source/WebKit/chromium/public/platform/WebMediaStreamDescriptor.h b/Source/WebKit/chromium/public/platform/WebMediaStreamDescriptor.h
index 52c63d321..ff8bd19cb 100644
--- a/Source/WebKit/chromium/public/platform/WebMediaStreamDescriptor.h
+++ b/Source/WebKit/chromium/public/platform/WebMediaStreamDescriptor.h
@@ -42,15 +42,32 @@ class WebString;
class WebMediaStreamDescriptor {
public:
WebMediaStreamDescriptor() { }
+ WebMediaStreamDescriptor(const WebMediaStreamDescriptor& other) { assign(other); }
~WebMediaStreamDescriptor() { reset(); }
+ WebMediaStreamDescriptor& operator=(const WebMediaStreamDescriptor& other)
+ {
+ assign(other);
+ return *this;
+ }
+
+ WEBKIT_EXPORT void assign(const WebMediaStreamDescriptor&);
+
+ // DEPRECATED
WEBKIT_EXPORT void initialize(const WebString& label, const WebVector<WebMediaStreamSource>&);
+
+ WEBKIT_EXPORT void initialize(const WebString& label, const WebVector<WebMediaStreamSource>& audioSources, const WebVector<WebMediaStreamSource>& videoSources);
WEBKIT_EXPORT void reset();
bool isNull() const { return m_private.isNull(); }
WEBKIT_EXPORT WebString label() const;
+
+ // DEPRECATED
WEBKIT_EXPORT void sources(WebVector<WebMediaStreamSource>&) const;
+ WEBKIT_EXPORT void audioSources(WebVector<WebMediaStreamSource>&) const;
+ WEBKIT_EXPORT void videoSources(WebVector<WebMediaStreamSource>&) const;
+
#if WEBKIT_IMPLEMENTATION
WebMediaStreamDescriptor(const WTF::PassRefPtr<WebCore::MediaStreamDescriptor>&);
operator WTF::PassRefPtr<WebCore::MediaStreamDescriptor>() const;
diff --git a/Source/WebKit/chromium/public/platform/WebMediaStreamSource.h b/Source/WebKit/chromium/public/platform/WebMediaStreamSource.h
index b65e996bd..142d59866 100644
--- a/Source/WebKit/chromium/public/platform/WebMediaStreamSource.h
+++ b/Source/WebKit/chromium/public/platform/WebMediaStreamSource.h
@@ -51,8 +51,17 @@ public:
};
WebMediaStreamSource() { }
+ WebMediaStreamSource(const WebMediaStreamSource& other) { assign(other); }
~WebMediaStreamSource() { reset(); }
+ WebMediaStreamSource& operator=(const WebMediaStreamSource& other)
+ {
+ assign(other);
+ return *this;
+ }
+
+ WEBKIT_EXPORT void assign(const WebMediaStreamSource&);
+
WEBKIT_EXPORT void initialize(const WebString& id, Type, const WebString& name);
WEBKIT_EXPORT void reset();
bool isNull() const { return m_private.isNull(); }
diff --git a/Source/WebKit/chromium/public/platform/WebSolidColorLayer.h b/Source/WebKit/chromium/public/platform/WebSolidColorLayer.h
new file mode 100644
index 000000000..ad9123d96
--- /dev/null
+++ b/Source/WebKit/chromium/public/platform/WebSolidColorLayer.h
@@ -0,0 +1,48 @@
+/*
+ * Copyright (C) 2012 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 WebSolidColorLayer_h
+#define WebSolidColorLayer_h
+
+#include "WebCommon.h"
+#include "WebFloatRect.h"
+#include "WebLayer.h"
+
+namespace WebKit {
+class WebSolidColorLayerImpl;
+
+class WebSolidColorLayer : public WebLayer {
+public:
+ WEBKIT_EXPORT static WebSolidColorLayer create();
+ WEBKIT_EXPORT void setBackgroundColor(const WebColor&);
+
+#if WEBKIT_IMPLEMENTATION
+ WebSolidColorLayer(const WTF::PassRefPtr<WebSolidColorLayerImpl>&);
+#endif
+};
+
+} // namespace WebKit
+
+#endif // WebSolidColorLayer_h
diff --git a/Source/WebKit/chromium/public/platform/WebThread.h b/Source/WebKit/chromium/public/platform/WebThread.h
index a7b372fee..b54bee849 100644
--- a/Source/WebKit/chromium/public/platform/WebThread.h
+++ b/Source/WebKit/chromium/public/platform/WebThread.h
@@ -51,9 +51,19 @@ public:
virtual void postTask(Task*) = 0;
virtual void postDelayedTask(Task*, long long delayMs) = 0;
+
virtual void addTaskObserver(TaskObserver*) { }
virtual void removeTaskObserver(TaskObserver*) { }
+ // enterRunLoop() processes tasks posted to this WebThread. This call does not return until some task calls exitRunLoop().
+ // WebThread does not support nesting, meaning that once the run loop is entered for a given WebThread it is not valid to
+ // call enterRunLoop() again.
+ virtual void enterRunLoop() = 0;
+
+ // exitRunLoop() runs tasks until there are no tasks available to run, then returns control to the caller of enterRunLoop().
+ // Must be called when the WebThread is running.
+ virtual void exitRunLoop() = 0;
+
virtual ~WebThread() { }
};