summaryrefslogtreecommitdiff
path: root/Source/WebKit/chromium/src
diff options
context:
space:
mode:
Diffstat (limited to 'Source/WebKit/chromium/src')
-rw-r--r--Source/WebKit/chromium/src/ChromeClientImpl.cpp3
-rw-r--r--Source/WebKit/chromium/src/IDBDatabaseCallbacksProxy.cpp5
-rw-r--r--Source/WebKit/chromium/src/IDBDatabaseCallbacksProxy.h1
-rw-r--r--Source/WebKit/chromium/src/LinkHighlight.cpp10
-rw-r--r--Source/WebKit/chromium/src/ScrollbarGroup.h50
-rw-r--r--Source/WebKit/chromium/src/WebAnimationImpl.cpp27
-rw-r--r--Source/WebKit/chromium/src/WebAnimationImpl.h7
-rw-r--r--Source/WebKit/chromium/src/WebBindings.cpp1
-rw-r--r--Source/WebKit/chromium/src/WebDOMMessageEvent.cpp4
-rw-r--r--Source/WebKit/chromium/src/WebDevToolsAgentImpl.cpp1
-rw-r--r--Source/WebKit/chromium/src/WebFloatAnimationCurveImpl.cpp (renamed from Source/WebKit/chromium/src/WebFloatAnimationCurve.cpp)40
-rw-r--r--Source/WebKit/chromium/src/WebFloatAnimationCurveImpl.h62
-rw-r--r--Source/WebKit/chromium/src/WebIDBDatabaseCallbacksImpl.cpp5
-rw-r--r--Source/WebKit/chromium/src/WebIDBDatabaseCallbacksImpl.h1
-rw-r--r--Source/WebKit/chromium/src/WebIDBDatabaseImpl.cpp14
-rw-r--r--Source/WebKit/chromium/src/WebIDBDatabaseImpl.h3
-rw-r--r--Source/WebKit/chromium/src/WebLayerImpl.cpp8
-rw-r--r--Source/WebKit/chromium/src/WebLayerImpl.h1
-rw-r--r--Source/WebKit/chromium/src/WebMediaPlayerClientImpl.cpp7
-rw-r--r--Source/WebKit/chromium/src/WebTransformAnimationCurveImpl.cpp81
-rw-r--r--Source/WebKit/chromium/src/WebTransformAnimationCurveImpl.h (renamed from Source/WebKit/chromium/src/WebTransformAnimationCurve.cpp)56
21 files changed, 279 insertions, 108 deletions
diff --git a/Source/WebKit/chromium/src/ChromeClientImpl.cpp b/Source/WebKit/chromium/src/ChromeClientImpl.cpp
index 329a99f19..d73654578 100644
--- a/Source/WebKit/chromium/src/ChromeClientImpl.cpp
+++ b/Source/WebKit/chromium/src/ChromeClientImpl.cpp
@@ -71,9 +71,6 @@
#include "SecurityOrigin.h"
#include "Settings.h"
#include "TextFieldDecorationElement.h"
-#if USE(V8)
-#include "V8Proxy.h"
-#endif
#include "WebAccessibilityObject.h"
#if ENABLE(INPUT_TYPE_COLOR)
#include "WebColorChooser.h"
diff --git a/Source/WebKit/chromium/src/IDBDatabaseCallbacksProxy.cpp b/Source/WebKit/chromium/src/IDBDatabaseCallbacksProxy.cpp
index 019e59ba0..31897da9e 100644
--- a/Source/WebKit/chromium/src/IDBDatabaseCallbacksProxy.cpp
+++ b/Source/WebKit/chromium/src/IDBDatabaseCallbacksProxy.cpp
@@ -48,6 +48,11 @@ IDBDatabaseCallbacksProxy::~IDBDatabaseCallbacksProxy()
{
}
+void IDBDatabaseCallbacksProxy::onForcedClose()
+{
+ m_callbacks->onForcedClose();
+}
+
void IDBDatabaseCallbacksProxy::onVersionChange(int64_t oldVersion, int64_t newVersion)
{
m_callbacks->onVersionChange(oldVersion, newVersion);
diff --git a/Source/WebKit/chromium/src/IDBDatabaseCallbacksProxy.h b/Source/WebKit/chromium/src/IDBDatabaseCallbacksProxy.h
index 9995abd2b..cb1ddb346 100644
--- a/Source/WebKit/chromium/src/IDBDatabaseCallbacksProxy.h
+++ b/Source/WebKit/chromium/src/IDBDatabaseCallbacksProxy.h
@@ -40,6 +40,7 @@ public:
static PassRefPtr<IDBDatabaseCallbacksProxy> create(PassOwnPtr<WebIDBDatabaseCallbacks>);
virtual ~IDBDatabaseCallbacksProxy();
+ virtual void onForcedClose();
virtual void onVersionChange(const String& requestedVersion);
virtual void onVersionChange(int64_t oldVersion, int64_t newVersion);
diff --git a/Source/WebKit/chromium/src/LinkHighlight.cpp b/Source/WebKit/chromium/src/LinkHighlight.cpp
index fa34d1d0d..2c804a8cd 100644
--- a/Source/WebKit/chromium/src/LinkHighlight.cpp
+++ b/Source/WebKit/chromium/src/LinkHighlight.cpp
@@ -200,13 +200,13 @@ void LinkHighlight::startHighlightAnimation()
m_contentLayer->layer()->setOpacity(startOpacity);
- WebFloatAnimationCurve curve;
- curve.add(WebFloatKeyframe(0, startOpacity));
- curve.add(WebFloatKeyframe(duration / 2, startOpacity));
+ OwnPtr<WebFloatAnimationCurve> curve = adoptPtr(WebFloatAnimationCurve::create());
+ curve->add(WebFloatKeyframe(0, startOpacity));
+ curve->add(WebFloatKeyframe(duration / 2, startOpacity));
// For layout tests we don't fade out.
- curve.add(WebFloatKeyframe(duration, WebKit::layoutTestMode() ? startOpacity : 0));
+ curve->add(WebFloatKeyframe(duration, WebKit::layoutTestMode() ? startOpacity : 0));
- m_animation = adoptPtr(WebAnimation::create(curve, WebAnimation::TargetPropertyOpacity));
+ m_animation = adoptPtr(WebAnimation::create(*curve, WebAnimation::TargetPropertyOpacity));
m_contentLayer->layer()->setDrawsContent(true);
m_contentLayer->layer()->addAnimation(m_animation.get());
diff --git a/Source/WebKit/chromium/src/ScrollbarGroup.h b/Source/WebKit/chromium/src/ScrollbarGroup.h
index a0479c206..b2df772f4 100644
--- a/Source/WebKit/chromium/src/ScrollbarGroup.h
+++ b/Source/WebKit/chromium/src/ScrollbarGroup.h
@@ -49,31 +49,31 @@ public:
void setFrameRect(const WebCore::IntRect&);
// WebCore::ScrollableArea methods
- virtual int scrollSize(WebCore::ScrollbarOrientation) const;
- virtual int scrollPosition(WebCore::Scrollbar*) const;
- virtual void setScrollOffset(const WebCore::IntPoint&);
- virtual void invalidateScrollbarRect(WebCore::Scrollbar*, const WebCore::IntRect&);
- virtual void invalidateScrollCornerRect(const WebCore::IntRect&);
- virtual bool isActive() const;
- virtual ScrollableArea* enclosingScrollableArea() const;
- virtual WebCore::IntRect scrollCornerRect() const { return WebCore::IntRect(); }
- virtual bool isScrollCornerVisible() const;
- virtual void getTickmarks(Vector<WebCore::IntRect>&) const;
- virtual WebCore::IntPoint convertFromContainingViewToScrollbar(const WebCore::Scrollbar*, const WebCore::IntPoint& parentPoint) const;
- virtual WebCore::Scrollbar* horizontalScrollbar() const;
- virtual WebCore::Scrollbar* verticalScrollbar() const;
- virtual WebCore::IntPoint scrollPosition() const;
- virtual WebCore::IntPoint minimumScrollPosition() const;
- virtual WebCore::IntPoint maximumScrollPosition() const;
- virtual int visibleHeight() const;
- virtual int visibleWidth() const;
- virtual WebCore::IntSize contentsSize() const;
- virtual WebCore::IntSize overhangAmount() const;
- virtual WebCore::IntPoint currentMousePosition() const;
- virtual bool shouldSuspendScrollAnimations() const;
- virtual void scrollbarStyleChanged(int newStyle, bool forceUpdate);
- virtual bool isOnActivePage() const;
- virtual WebCore::IntRect scrollableAreaBoundingBox() const;
+ virtual int scrollSize(WebCore::ScrollbarOrientation) const OVERRIDE;
+ virtual int scrollPosition(WebCore::Scrollbar*) const OVERRIDE;
+ virtual void setScrollOffset(const WebCore::IntPoint&) OVERRIDE;
+ virtual void invalidateScrollbarRect(WebCore::Scrollbar*, const WebCore::IntRect&) OVERRIDE;
+ virtual void invalidateScrollCornerRect(const WebCore::IntRect&) OVERRIDE;
+ virtual bool isActive() const OVERRIDE;
+ virtual ScrollableArea* enclosingScrollableArea() const OVERRIDE;
+ virtual WebCore::IntRect scrollCornerRect() const OVERRIDE { return WebCore::IntRect(); }
+ virtual bool isScrollCornerVisible() const OVERRIDE;
+ virtual void getTickmarks(Vector<WebCore::IntRect>&) const OVERRIDE;
+ virtual WebCore::IntPoint convertFromContainingViewToScrollbar(const WebCore::Scrollbar*, const WebCore::IntPoint& parentPoint) const OVERRIDE;
+ virtual WebCore::Scrollbar* horizontalScrollbar() const OVERRIDE;
+ virtual WebCore::Scrollbar* verticalScrollbar() const OVERRIDE;
+ virtual WebCore::IntPoint scrollPosition() const OVERRIDE;
+ virtual WebCore::IntPoint minimumScrollPosition() const OVERRIDE;
+ virtual WebCore::IntPoint maximumScrollPosition() const OVERRIDE;
+ virtual int visibleHeight() const OVERRIDE;
+ virtual int visibleWidth() const OVERRIDE;
+ virtual WebCore::IntSize contentsSize() const OVERRIDE;
+ virtual WebCore::IntSize overhangAmount() const OVERRIDE;
+ virtual WebCore::IntPoint currentMousePosition() const OVERRIDE;
+ virtual bool shouldSuspendScrollAnimations() const OVERRIDE;
+ virtual void scrollbarStyleChanged(int newStyle, bool forceUpdate) OVERRIDE;
+ virtual bool isOnActivePage() const OVERRIDE;
+ virtual WebCore::IntRect scrollableAreaBoundingBox() const OVERRIDE;
private:
WebCore::FrameView* m_frameView;
diff --git a/Source/WebKit/chromium/src/WebAnimationImpl.cpp b/Source/WebKit/chromium/src/WebAnimationImpl.cpp
index 187272ef2..e5d9ef2a3 100644
--- a/Source/WebKit/chromium/src/WebAnimationImpl.cpp
+++ b/Source/WebKit/chromium/src/WebAnimationImpl.cpp
@@ -29,6 +29,8 @@
#include "AnimationIdVendor.h"
#include "CCActiveAnimation.h"
#include "CCAnimationCurve.h"
+#include "WebFloatAnimationCurveImpl.h"
+#include "WebTransformAnimationCurveImpl.h"
#include <public/WebAnimation.h>
#include <public/WebAnimationCurve.h>
#include <wtf/OwnPtr.h>
@@ -46,7 +48,30 @@ WebAnimation* WebAnimation::create(const WebAnimationCurve& curve, TargetPropert
WebAnimation* WebAnimation::create(const WebAnimationCurve& curve, int animationId, int groupId, TargetProperty targetProperty)
{
- return new WebAnimationImpl(CCActiveAnimation::create(curve, animationId, groupId, static_cast<WebCore::CCActiveAnimation::TargetProperty>(targetProperty)));
+ return new WebAnimationImpl(curve, animationId, groupId, targetProperty);
+}
+
+WebAnimationImpl::WebAnimationImpl(const WebAnimationCurve& webCurve, int animationId, int groupId, TargetProperty targetProperty)
+{
+ WebAnimationCurve::AnimationCurveType curveType = webCurve.type();
+ OwnPtr<WebCore::CCAnimationCurve> curve;
+ switch (curveType) {
+ case WebAnimationCurve::AnimationCurveTypeFloat: {
+ const WebFloatAnimationCurveImpl* floatCurveImpl = static_cast<const WebFloatAnimationCurveImpl*>(&webCurve);
+ curve = floatCurveImpl->cloneToCCAnimationCurve();
+ break;
+ }
+ case WebAnimationCurve::AnimationCurveTypeTransform: {
+ const WebTransformAnimationCurveImpl* transformCurveImpl = static_cast<const WebTransformAnimationCurveImpl*>(&webCurve);
+ curve = transformCurveImpl->cloneToCCAnimationCurve();
+ break;
+ }
+ }
+ m_animation = CCActiveAnimation::create(curve.release(), animationId, groupId, static_cast<WebCore::CCActiveAnimation::TargetProperty>(targetProperty));
+}
+
+WebAnimationImpl::~WebAnimationImpl()
+{
}
WebAnimation::TargetProperty WebAnimationImpl::targetProperty() const
diff --git a/Source/WebKit/chromium/src/WebAnimationImpl.h b/Source/WebKit/chromium/src/WebAnimationImpl.h
index 8677b9c60..d7ceba51f 100644
--- a/Source/WebKit/chromium/src/WebAnimationImpl.h
+++ b/Source/WebKit/chromium/src/WebAnimationImpl.h
@@ -37,11 +37,8 @@ namespace WebKit {
class WebAnimationImpl : public WebAnimation {
public:
- explicit WebAnimationImpl(PassOwnPtr<WebCore::CCActiveAnimation> animation)
- : m_animation(animation)
- {
- }
- virtual ~WebAnimationImpl() { }
+ WebAnimationImpl(const WebAnimationCurve&, int animationId, int groupId, TargetProperty);
+ virtual ~WebAnimationImpl();
// WebAnimation implementation
virtual TargetProperty targetProperty() const OVERRIDE;
diff --git a/Source/WebKit/chromium/src/WebBindings.cpp b/Source/WebKit/chromium/src/WebBindings.cpp
index 71a74db1b..c44dc429e 100644
--- a/Source/WebKit/chromium/src/WebBindings.cpp
+++ b/Source/WebKit/chromium/src/WebBindings.cpp
@@ -45,7 +45,6 @@
#include "V8DOMWrapper.h"
#include "V8Element.h"
#include "V8NPUtils.h"
-#include "V8Proxy.h"
#include "V8Range.h"
#include <wtf/ArrayBufferView.h>
// FIXME: Remove the USE(JSC) ifdefs because we don't support USE(JSC) anymore.
diff --git a/Source/WebKit/chromium/src/WebDOMMessageEvent.cpp b/Source/WebKit/chromium/src/WebDOMMessageEvent.cpp
index 06cf66fc5..383c7de21 100644
--- a/Source/WebKit/chromium/src/WebDOMMessageEvent.cpp
+++ b/Source/WebKit/chromium/src/WebDOMMessageEvent.cpp
@@ -42,10 +42,6 @@
#include "platform/WebSerializedScriptValue.h"
#include "platform/WebString.h"
-#if USE(V8)
-#include "V8Proxy.h"
-#endif
-
using namespace WebCore;
namespace WebKit {
diff --git a/Source/WebKit/chromium/src/WebDevToolsAgentImpl.cpp b/Source/WebKit/chromium/src/WebDevToolsAgentImpl.cpp
index e3a80e0d4..c639f674d 100644
--- a/Source/WebKit/chromium/src/WebDevToolsAgentImpl.cpp
+++ b/Source/WebKit/chromium/src/WebDevToolsAgentImpl.cpp
@@ -51,7 +51,6 @@
#include "ResourceRequest.h"
#include "ResourceResponse.h"
#include "V8Binding.h"
-#include "V8Proxy.h"
#include "V8Utilities.h"
#include "WebDataSource.h"
#include "WebDevToolsAgentClient.h"
diff --git a/Source/WebKit/chromium/src/WebFloatAnimationCurve.cpp b/Source/WebKit/chromium/src/WebFloatAnimationCurveImpl.cpp
index e8cf7c2d2..9f5665cb8 100644
--- a/Source/WebKit/chromium/src/WebFloatAnimationCurve.cpp
+++ b/Source/WebKit/chromium/src/WebFloatAnimationCurveImpl.cpp
@@ -24,8 +24,9 @@
#include "config.h"
-#include <public/WebFloatAnimationCurve.h>
+#include "WebFloatAnimationCurveImpl.h"
+#include "CCAnimationCurve.h"
#include "CCKeyframedAnimationCurve.h"
#include "CCTimingFunction.h"
#include "WebAnimationCurveCommon.h"
@@ -34,39 +35,48 @@
namespace WebKit {
-void WebFloatAnimationCurve::add(const WebFloatKeyframe& keyframe)
+WebFloatAnimationCurve* WebFloatAnimationCurve::create()
+{
+ return new WebFloatAnimationCurveImpl(WebCore::CCKeyframedFloatAnimationCurve::create());
+}
+
+WebFloatAnimationCurveImpl::WebFloatAnimationCurveImpl(PassOwnPtr<WebCore::CCKeyframedFloatAnimationCurve> curve)
+ : m_curve(curve)
{
- add(keyframe, TimingFunctionTypeEase);
}
-void WebFloatAnimationCurve::add(const WebFloatKeyframe& keyframe, TimingFunctionType type)
+WebFloatAnimationCurveImpl::~WebFloatAnimationCurveImpl()
{
- m_private->addKeyframe(WebCore::CCFloatKeyframe::create(keyframe.time, keyframe.value, createTimingFunction(type)));
}
-void WebFloatAnimationCurve::add(const WebFloatKeyframe& keyframe, double x1, double y1, double x2, double y2)
+WebAnimationCurve::AnimationCurveType WebFloatAnimationCurveImpl::type() const
{
- m_private->addKeyframe(WebCore::CCFloatKeyframe::create(keyframe.time, keyframe.value, WebCore::CCCubicBezierTimingFunction::create(x1, y1, x2, y2)));
+ return WebAnimationCurve::AnimationCurveTypeFloat;
+}
+
+void WebFloatAnimationCurveImpl::add(const WebFloatKeyframe& keyframe)
+{
+ add(keyframe, TimingFunctionTypeEase);
}
-float WebFloatAnimationCurve::getValue(double time) const
+void WebFloatAnimationCurveImpl::add(const WebFloatKeyframe& keyframe, TimingFunctionType type)
{
- return m_private->getValue(time);
+ m_curve->addKeyframe(WebCore::CCFloatKeyframe::create(keyframe.time, keyframe.value, createTimingFunction(type)));
}
-WebFloatAnimationCurve::operator PassOwnPtr<WebCore::CCAnimationCurve>() const
+void WebFloatAnimationCurveImpl::add(const WebFloatKeyframe& keyframe, double x1, double y1, double x2, double y2)
{
- return m_private->clone();
+ m_curve->addKeyframe(WebCore::CCFloatKeyframe::create(keyframe.time, keyframe.value, WebCore::CCCubicBezierTimingFunction::create(x1, y1, x2, y2)));
}
-void WebFloatAnimationCurve::initialize()
+float WebFloatAnimationCurveImpl::getValue(double time) const
{
- m_private.reset(WebCore::CCKeyframedFloatAnimationCurve::create().leakPtr());
+ return m_curve->getValue(time);
}
-void WebFloatAnimationCurve::destroy()
+PassOwnPtr<WebCore::CCAnimationCurve> WebFloatAnimationCurveImpl::cloneToCCAnimationCurve() const
{
- m_private.reset(0);
+ return m_curve->clone();
}
} // namespace WebKit
diff --git a/Source/WebKit/chromium/src/WebFloatAnimationCurveImpl.h b/Source/WebKit/chromium/src/WebFloatAnimationCurveImpl.h
new file mode 100644
index 000000000..e8f1620d6
--- /dev/null
+++ b/Source/WebKit/chromium/src/WebFloatAnimationCurveImpl.h
@@ -0,0 +1,62 @@
+/*
+ * 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 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 WebFloatAnimationCurveImpl_h
+#define WebFloatAnimationCurveImpl_h
+
+#include <public/WebFloatAnimationCurve.h>
+#include <wtf/OwnPtr.h>
+#include <wtf/PassOwnPtr.h>
+
+namespace WebCore {
+class CCAnimationCurve;
+class CCKeyframedFloatAnimationCurve;
+}
+
+namespace WebKit {
+
+class WebFloatAnimationCurveImpl : public WebFloatAnimationCurve {
+public:
+ explicit WebFloatAnimationCurveImpl(PassOwnPtr<WebCore::CCKeyframedFloatAnimationCurve>);
+ virtual ~WebFloatAnimationCurveImpl();
+
+ // WebAnimationCurve implementation.
+ virtual AnimationCurveType type() const OVERRIDE;
+
+ // WebFloatAnimationCurve implementation.
+ virtual void add(const WebFloatKeyframe&) OVERRIDE;
+ virtual void add(const WebFloatKeyframe&, TimingFunctionType) OVERRIDE;
+ virtual void add(const WebFloatKeyframe&, double x1, double y1, double x2, double y2) OVERRIDE;
+
+ virtual float getValue(double time) const OVERRIDE;
+
+ PassOwnPtr<WebCore::CCAnimationCurve> cloneToCCAnimationCurve() const;
+
+private:
+ OwnPtr<WebCore::CCKeyframedFloatAnimationCurve> m_curve;
+};
+
+}
+
+#endif // WebFloatAnimationCurveImpl_h
diff --git a/Source/WebKit/chromium/src/WebIDBDatabaseCallbacksImpl.cpp b/Source/WebKit/chromium/src/WebIDBDatabaseCallbacksImpl.cpp
index 14757bac6..5ae86a679 100644
--- a/Source/WebKit/chromium/src/WebIDBDatabaseCallbacksImpl.cpp
+++ b/Source/WebKit/chromium/src/WebIDBDatabaseCallbacksImpl.cpp
@@ -44,6 +44,11 @@ WebIDBDatabaseCallbacksImpl::~WebIDBDatabaseCallbacksImpl()
{
}
+void WebIDBDatabaseCallbacksImpl::onForcedClose()
+{
+ m_callbacks->onForcedClose();
+}
+
void WebIDBDatabaseCallbacksImpl::onVersionChange(long long oldVersion, long long newVersion)
{
m_callbacks->onVersionChange(oldVersion, newVersion);
diff --git a/Source/WebKit/chromium/src/WebIDBDatabaseCallbacksImpl.h b/Source/WebKit/chromium/src/WebIDBDatabaseCallbacksImpl.h
index 1857ca658..b0737eeb2 100644
--- a/Source/WebKit/chromium/src/WebIDBDatabaseCallbacksImpl.h
+++ b/Source/WebKit/chromium/src/WebIDBDatabaseCallbacksImpl.h
@@ -43,6 +43,7 @@ public:
WebIDBDatabaseCallbacksImpl(PassRefPtr<WebCore::IDBDatabaseCallbacks>);
virtual ~WebIDBDatabaseCallbacksImpl();
+ virtual void onForcedClose();
virtual void onVersionChange(long long oldVersion, long long newVersion);
virtual void onVersionChange(const WebString& version);
diff --git a/Source/WebKit/chromium/src/WebIDBDatabaseImpl.cpp b/Source/WebKit/chromium/src/WebIDBDatabaseImpl.cpp
index 9343281cf..0d142bc02 100644
--- a/Source/WebKit/chromium/src/WebIDBDatabaseImpl.cpp
+++ b/Source/WebKit/chromium/src/WebIDBDatabaseImpl.cpp
@@ -99,8 +99,18 @@ void WebIDBDatabaseImpl::close()
m_closePending = true;
return;
}
- m_databaseBackend->close(m_databaseCallbacks);
- m_databaseCallbacks = 0;
+ m_databaseBackend->close(m_databaseCallbacks.release());
+}
+
+void WebIDBDatabaseImpl::forceClose()
+{
+ if (!m_databaseCallbacks) {
+ m_closePending = true;
+ return;
+ }
+ RefPtr<IDBDatabaseCallbacksProxy> callbacks = m_databaseCallbacks.release();
+ m_databaseBackend->close(callbacks);
+ callbacks->onForcedClose();
}
void WebIDBDatabaseImpl::open(WebIDBDatabaseCallbacks* callbacks)
diff --git a/Source/WebKit/chromium/src/WebIDBDatabaseImpl.h b/Source/WebKit/chromium/src/WebIDBDatabaseImpl.h
index 1409cb65f..4a8284ce5 100644
--- a/Source/WebKit/chromium/src/WebIDBDatabaseImpl.h
+++ b/Source/WebKit/chromium/src/WebIDBDatabaseImpl.h
@@ -28,6 +28,7 @@
#if ENABLE(INDEXED_DATABASE)
+#include "IDBDatabaseCallbacksProxy.h"
#include "platform/WebCommon.h"
#include "WebExceptionCode.h"
#include "WebIDBDatabase.h"
@@ -38,7 +39,6 @@ namespace WebCore { class IDBDatabaseBackendInterface; }
namespace WebKit {
-class IDBDatabaseCallbacksProxy;
class WebIDBDatabaseCallbacks;
class WebIDBDatabaseMetadata;
class WebIDBObjectStore;
@@ -56,6 +56,7 @@ public:
virtual void deleteObjectStore(const WebString& name, const WebIDBTransaction&, WebExceptionCode&);
virtual void setVersion(const WebString& version, WebIDBCallbacks*, WebExceptionCode&);
virtual WebIDBTransaction* transaction(const WebDOMStringList& names, unsigned short mode, WebExceptionCode&);
+ virtual void forceClose();
virtual void close();
// FIXME: Rename "open" to registerFrontendCallbacks.
diff --git a/Source/WebKit/chromium/src/WebLayerImpl.cpp b/Source/WebKit/chromium/src/WebLayerImpl.cpp
index 40ced485d..bf64a8f2a 100644
--- a/Source/WebKit/chromium/src/WebLayerImpl.cpp
+++ b/Source/WebKit/chromium/src/WebLayerImpl.cpp
@@ -123,14 +123,6 @@ void WebLayerImpl::replaceChild(WebLayer* reference, WebLayer* newLayer)
m_layer->replaceChild(static_cast<WebLayerImpl*>(reference)->layer(), static_cast<WebLayerImpl*>(newLayer)->layer());
}
-void WebLayerImpl::setChildren(const WebVector<WebLayer*>& webChildren)
-{
- Vector<RefPtr<LayerChromium> > children(webChildren.size());
- for (size_t i = 0; i < webChildren.size(); ++i)
- children[i] = static_cast<WebLayerImpl*>(webChildren[i])->layer();
- m_layer->setChildren(children);
-}
-
void WebLayerImpl::removeFromParent()
{
m_layer->removeFromParent();
diff --git a/Source/WebKit/chromium/src/WebLayerImpl.h b/Source/WebKit/chromium/src/WebLayerImpl.h
index 7e3b533bc..0a61826a5 100644
--- a/Source/WebKit/chromium/src/WebLayerImpl.h
+++ b/Source/WebKit/chromium/src/WebLayerImpl.h
@@ -47,7 +47,6 @@ public:
virtual void addChild(WebLayer*) OVERRIDE;
virtual void insertChild(WebLayer*, size_t index) OVERRIDE;
virtual void replaceChild(WebLayer* reference, WebLayer* newLayer) OVERRIDE;
- virtual void setChildren(const WebVector<WebLayer*>&) OVERRIDE;
virtual void removeFromParent() OVERRIDE;
virtual void removeAllChildren() OVERRIDE;
virtual void setAnchorPoint(const WebFloatPoint&) OVERRIDE;
diff --git a/Source/WebKit/chromium/src/WebMediaPlayerClientImpl.cpp b/Source/WebKit/chromium/src/WebMediaPlayerClientImpl.cpp
index cb756233e..72e871637 100644
--- a/Source/WebKit/chromium/src/WebMediaPlayerClientImpl.cpp
+++ b/Source/WebKit/chromium/src/WebMediaPlayerClientImpl.cpp
@@ -7,6 +7,7 @@
#if ENABLE(VIDEO)
+#include "AudioBus.h"
#include "AudioSourceProvider.h"
#include "AudioSourceProviderClient.h"
#include "Frame.h"
@@ -45,13 +46,13 @@ using namespace WebCore;
namespace WebKit {
-static PassOwnPtr<WebMediaPlayer> createWebMediaPlayer(WebMediaPlayerClient* client, Frame* frame)
+static PassOwnPtr<WebMediaPlayer> createWebMediaPlayer(WebMediaPlayerClient* client, const WebURL& url, Frame* frame)
{
WebFrameImpl* webFrame = WebFrameImpl::fromFrame(frame);
if (!webFrame->client())
return nullptr;
- return adoptPtr(webFrame->client()->createMediaPlayer(webFrame, client));
+ return adoptPtr(webFrame->client()->createMediaPlayer(webFrame, url, client));
}
bool WebMediaPlayerClientImpl::m_isEnabled = false;
@@ -321,7 +322,7 @@ void WebMediaPlayerClientImpl::loadInternal()
#endif
Frame* frame = static_cast<HTMLMediaElement*>(m_mediaPlayer->mediaPlayerClient())->document()->frame();
- m_webMediaPlayer = createWebMediaPlayer(this, frame);
+ m_webMediaPlayer = createWebMediaPlayer(this, KURL(ParsedURLString, m_url), frame);
if (m_webMediaPlayer) {
#if ENABLE(WEB_AUDIO)
// Make sure if we create/re-create the WebMediaPlayer that we update our wrapper.
diff --git a/Source/WebKit/chromium/src/WebTransformAnimationCurveImpl.cpp b/Source/WebKit/chromium/src/WebTransformAnimationCurveImpl.cpp
new file mode 100644
index 000000000..201042e95
--- /dev/null
+++ b/Source/WebKit/chromium/src/WebTransformAnimationCurveImpl.cpp
@@ -0,0 +1,81 @@
+/*
+ * 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 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 "WebTransformAnimationCurveImpl.h"
+
+#include "CCKeyframedAnimationCurve.h"
+#include "CCTimingFunction.h"
+#include "WebAnimationCurveCommon.h"
+#include <wtf/OwnPtr.h>
+#include <wtf/PassOwnPtr.h>
+
+namespace WebKit {
+
+WebTransformAnimationCurve* WebTransformAnimationCurve::create()
+{
+ return new WebTransformAnimationCurveImpl(WebCore::CCKeyframedTransformAnimationCurve::create());
+}
+
+WebTransformAnimationCurveImpl::WebTransformAnimationCurveImpl(PassOwnPtr<WebCore::CCKeyframedTransformAnimationCurve> curve)
+ : m_curve(curve)
+{
+}
+
+WebTransformAnimationCurveImpl::~WebTransformAnimationCurveImpl()
+{
+}
+
+WebAnimationCurve::AnimationCurveType WebTransformAnimationCurveImpl::type() const
+{
+ return WebAnimationCurve::AnimationCurveTypeTransform;
+}
+
+void WebTransformAnimationCurveImpl::add(const WebTransformKeyframe& keyframe)
+{
+ add(keyframe, TimingFunctionTypeEase);
+}
+
+void WebTransformAnimationCurveImpl::add(const WebTransformKeyframe& keyframe, TimingFunctionType type)
+{
+ m_curve->addKeyframe(WebCore::CCTransformKeyframe::create(keyframe.time, keyframe.value, createTimingFunction(type)));
+}
+
+void WebTransformAnimationCurveImpl::add(const WebTransformKeyframe& keyframe, double x1, double y1, double x2, double y2)
+{
+ m_curve->addKeyframe(WebCore::CCTransformKeyframe::create(keyframe.time, keyframe.value, WebCore::CCCubicBezierTimingFunction::create(x1, y1, x2, y2)));
+}
+
+WebTransformationMatrix WebTransformAnimationCurveImpl::getValue(double time) const
+{
+ return m_curve->getValue(time);
+}
+
+PassOwnPtr<WebCore::CCAnimationCurve> WebTransformAnimationCurveImpl::cloneToCCAnimationCurve() const
+{
+ return m_curve->clone();
+}
+
+} // namespace WebKit
diff --git a/Source/WebKit/chromium/src/WebTransformAnimationCurve.cpp b/Source/WebKit/chromium/src/WebTransformAnimationCurveImpl.h
index dad084987..45a03ef06 100644
--- a/Source/WebKit/chromium/src/WebTransformAnimationCurve.cpp
+++ b/Source/WebKit/chromium/src/WebTransformAnimationCurveImpl.h
@@ -22,51 +22,41 @@
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-#include "config.h"
+#ifndef WebTransformAnimationCurveImpl_h
+#define WebTransformAnimationCurveImpl_h
#include <public/WebTransformAnimationCurve.h>
-
-#include "CCKeyframedAnimationCurve.h"
-#include "CCTimingFunction.h"
-#include "WebAnimationCurveCommon.h"
#include <wtf/OwnPtr.h>
#include <wtf/PassOwnPtr.h>
+namespace WebCore {
+class CCAnimationCurve;
+class CCKeyframedTransformAnimationCurve;
+}
+
namespace WebKit {
-void WebTransformAnimationCurve::add(const WebTransformKeyframe& keyframe)
-{
- add(keyframe, TimingFunctionTypeEase);
-}
+class WebTransformAnimationCurveImpl : public WebTransformAnimationCurve {
+public:
+ explicit WebTransformAnimationCurveImpl(PassOwnPtr<WebCore::CCKeyframedTransformAnimationCurve>);
+ virtual ~WebTransformAnimationCurveImpl();
-void WebTransformAnimationCurve::add(const WebTransformKeyframe& keyframe, TimingFunctionType type)
-{
- m_private->addKeyframe(WebCore::CCTransformKeyframe::create(keyframe.time, keyframe.value, createTimingFunction(type)));
-}
+ // WebAnimationCurve implementation.
+ virtual AnimationCurveType type() const OVERRIDE;
-void WebTransformAnimationCurve::add(const WebTransformKeyframe& keyframe, double x1, double y1, double x2, double y2)
-{
- m_private->addKeyframe(WebCore::CCTransformKeyframe::create(keyframe.time, keyframe.value, WebCore::CCCubicBezierTimingFunction::create(x1, y1, x2, y2)));
-}
+ // WebTransformAnimationCurve implementation.
+ virtual void add(const WebTransformKeyframe&) OVERRIDE;
+ virtual void add(const WebTransformKeyframe&, TimingFunctionType) OVERRIDE;
+ virtual void add(const WebTransformKeyframe&, double x1, double y1, double x2, double y2) OVERRIDE;
-WebTransformationMatrix WebTransformAnimationCurve::getValue(double time) const
-{
- return m_private->getValue(time);
-}
+ virtual WebTransformationMatrix getValue(double time) const OVERRIDE;
-WebTransformAnimationCurve::operator PassOwnPtr<WebCore::CCAnimationCurve>() const
-{
- return m_private->clone();
-}
+ PassOwnPtr<WebCore::CCAnimationCurve> cloneToCCAnimationCurve() const;
-void WebTransformAnimationCurve::initialize()
-{
- m_private.reset(WebCore::CCKeyframedTransformAnimationCurve::create().leakPtr());
-}
+private:
+ OwnPtr<WebCore::CCKeyframedTransformAnimationCurve> m_curve;
+};
-void WebTransformAnimationCurve::destroy()
-{
- m_private.reset(0);
}
-} // namespace WebKit
+#endif // WebTransformAnimationCurveImpl_h