Diff
Modified: trunk/Source/WebKit/PlatformBlackBerry.cmake (111098 => 111099)
--- trunk/Source/WebKit/PlatformBlackBerry.cmake 2012-03-17 00:31:22 UTC (rev 111098)
+++ trunk/Source/WebKit/PlatformBlackBerry.cmake 2012-03-17 00:41:19 UTC (rev 111099)
@@ -44,6 +44,7 @@
blackberry/Api/WebKitMIMETypeConverter.cpp
blackberry/Api/WebKitTextCodec.cpp
blackberry/Api/WebPage.cpp
+ blackberry/Api/WebPageCompositor.cpp
blackberry/Api/WebPageGroupLoadDeferrer.cpp
blackberry/Api/WebSettings.cpp
blackberry/WebCoreSupport/AboutData.cpp
@@ -77,7 +78,6 @@
blackberry/WebKitSupport/SurfacePool.cpp
blackberry/WebKitSupport/TouchEventHandler.cpp
blackberry/WebKitSupport/FatFingers.cpp
- blackberry/WebKitSupport/WebPageCompositor.cpp
)
IF (ENABLE_DRT)
Modified: trunk/Source/WebKit/blackberry/Api/BackingStore.h (111098 => 111099)
--- trunk/Source/WebKit/blackberry/Api/BackingStore.h 2012-03-17 00:31:22 UTC (rev 111098)
+++ trunk/Source/WebKit/blackberry/Api/BackingStore.h 2012-03-17 00:41:19 UTC (rev 111099)
@@ -40,7 +40,7 @@
class WebPage;
class WebPagePrivate;
-class WebPageCompositor;
+class WebPageCompositorPrivate;
class BackingStorePrivate;
class BackingStoreClient;
@@ -81,7 +81,7 @@
friend class BlackBerry::WebKit::BackingStoreClient;
friend class BlackBerry::WebKit::WebPage;
friend class BlackBerry::WebKit::WebPagePrivate; // FIXME: For now, we expose our internals to WebPagePrivate. See PR #120301.
- friend class BlackBerry::WebKit::WebPageCompositor;
+ friend class BlackBerry::WebKit::WebPageCompositorPrivate;
friend class WebCore::ChromeClientBlackBerry;
friend class WebCore::FrameLoaderClientBlackBerry;
friend class WebCore::GLES2Context;
Modified: trunk/Source/WebKit/blackberry/Api/WebPage.cpp (111098 => 111099)
--- trunk/Source/WebKit/blackberry/Api/WebPage.cpp 2012-03-17 00:31:22 UTC (rev 111098)
+++ trunk/Source/WebKit/blackberry/Api/WebPage.cpp 2012-03-17 00:41:19 UTC (rev 111099)
@@ -119,7 +119,7 @@
#if USE(ACCELERATED_COMPOSITING)
#include "FrameLayers.h"
-#include "WebPageCompositor.h"
+#include "WebPageCompositor_p.h"
#endif
#include <BlackBerryPlatformExecutableMessage.h>
@@ -5325,7 +5325,7 @@
}
if (!m_compositor) {
- m_compositor = adoptPtr(new WebPageCompositor(this));
+ m_compositor = adoptPtr(new WebPageCompositorPrivate(this));
m_isAcceleratedCompositingActive = m_compositor->hardwareCompositing();
if (!m_isAcceleratedCompositingActive)
m_compositor.clear();
Copied: trunk/Source/WebKit/blackberry/Api/WebPageCompositor.cpp (from rev 111098, trunk/Source/WebKit/blackberry/WebKitSupport/WebPageCompositor.cpp) (0 => 111099)
--- trunk/Source/WebKit/blackberry/Api/WebPageCompositor.cpp (rev 0)
+++ trunk/Source/WebKit/blackberry/Api/WebPageCompositor.cpp 2012-03-17 00:41:19 UTC (rev 111099)
@@ -0,0 +1,131 @@
+/*
+ * Copyright (C) 2010, 2011, 2012 Research In Motion Limited. All rights reserved.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+#include "config.h"
+
+#if USE(ACCELERATED_COMPOSITING)
+#include "WebPageCompositor_p.h"
+
+#include "BackingStore_p.h"
+#include "LayerWebKitThread.h"
+#include "WebPage_p.h"
+
+#include <BlackBerryPlatformExecutableMessage.h>
+#include <BlackBerryPlatformMessage.h>
+#include <BlackBerryPlatformMessageClient.h>
+#include <GenericTimerClient.h>
+#include <ThreadTimerClient.h>
+
+using namespace WebCore;
+
+namespace BlackBerry {
+namespace WebKit {
+
+WebPageCompositorPrivate::WebPageCompositorPrivate(WebPagePrivate* page)
+ : m_webPage(page)
+ , m_context(GLES2Context::create(page))
+ , m_layerRenderer(LayerRenderer::create(m_context.get()))
+ , m_generation(0)
+ , m_compositedGeneration(-1)
+ , m_backingStoreUsesOpenGL(false)
+ , m_animationTimer(this, &WebPageCompositorPrivate::animationTimerFired)
+ , m_timerClient(new Platform::GenericTimerClient(Platform::userInterfaceThreadTimerClient()))
+{
+ m_animationTimer.setClient(m_timerClient);
+}
+
+WebPageCompositorPrivate::~WebPageCompositorPrivate()
+{
+ m_animationTimer.stop();
+ delete m_timerClient;
+}
+
+bool WebPageCompositorPrivate::hardwareCompositing() const
+{
+ return m_layerRenderer->hardwareCompositing();
+}
+
+void WebPageCompositorPrivate::setRootLayer(LayerCompositingThread* rootLayer)
+{
+ m_rootLayer = rootLayer;
+ m_layerRenderer->setRootLayer(m_rootLayer.get());
+}
+
+void WebPageCompositorPrivate::setBackingStoreUsesOpenGL(bool backingStoreUsesOpenGL)
+{
+ m_backingStoreUsesOpenGL = backingStoreUsesOpenGL;
+ m_layerRenderer->setClearSurfaceOnDrawLayers(!backingStoreUsesOpenGL);
+}
+
+void WebPageCompositorPrivate::commit(LayerWebKitThread* rootLayer)
+{
+ if (!rootLayer)
+ return;
+
+ rootLayer->commitOnCompositingThread();
+ ++m_generation;
+}
+
+bool WebPageCompositorPrivate::drawLayers(const IntRect& dstRect, const FloatRect& contents)
+{
+ // Save a draw if we already drew this generation, for example due to a concurrent scroll operation.
+ if (m_compositedGeneration == m_generation && dstRect == m_compositedDstRect
+ && contents == m_compositedContentsRect && !m_backingStoreUsesOpenGL)
+ return false;
+
+ m_layerRenderer->drawLayers(contents, m_layoutRectForCompositing, m_contentsSizeForCompositing, dstRect);
+ m_lastCompositingResults = m_layerRenderer->lastRenderingResults();
+
+ m_compositedDstRect = dstRect;
+ m_compositedContentsRect = contents;
+ m_compositedGeneration = m_generation;
+
+ if (m_lastCompositingResults.needsAnimationFrame) {
+ ++m_generation; // The animation update moves us along one generation.
+ // Using a timeout of 0 actually won't start a timer, it will send a message.
+ m_animationTimer.start(1.0 / 60.0);
+ m_webPage->updateDelegatedOverlays();
+ }
+
+ return true;
+}
+
+void WebPageCompositorPrivate::releaseLayerResources()
+{
+ m_layerRenderer->releaseLayerResources();
+}
+
+void WebPageCompositorPrivate::animationTimerFired()
+{
+ if (m_webPage->m_backingStore->d->shouldDirectRenderingToWindow()) {
+ if (m_webPage->m_backingStore->d->isDirectRenderingAnimationMessageScheduled())
+ return; // don't send new messages as long as we haven't rerendered
+
+ m_webPage->m_backingStore->d->setDirectRenderingAnimationMessageScheduled();
+ BlackBerry::Platform::webKitThreadMessageClient()->dispatchMessage(
+ BlackBerry::Platform::createMethodCallMessage(
+ &BackingStorePrivate::renderVisibleContents, m_webPage->m_backingStore->d));
+ return;
+ }
+ m_webPage->blitVisibleContents();
+}
+
+} // namespace WebKit
+} // namespace BlackBerry
+
+#endif // USE(ACCELERATED_COMPOSITING)
Copied: trunk/Source/WebKit/blackberry/Api/WebPageCompositor_p.h (from rev 111098, trunk/Source/WebKit/blackberry/WebKitSupport/WebPageCompositor.h) (0 => 111099)
--- trunk/Source/WebKit/blackberry/Api/WebPageCompositor_p.h (rev 0)
+++ trunk/Source/WebKit/blackberry/Api/WebPageCompositor_p.h 2012-03-17 00:41:19 UTC (rev 111099)
@@ -0,0 +1,93 @@
+/*
+ * Copyright (C) 2010, 2011, 2012 Research In Motion Limited. All rights reserved.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+#ifndef WebPageCompositor_p_h
+#define WebPageCompositor_p_h
+
+#if USE(ACCELERATED_COMPOSITING)
+
+#include "GLES2Context.h"
+#include "LayerCompositingThread.h"
+#include "LayerRenderer.h"
+
+#include <BlackBerryPlatformTimer.h>
+#include <wtf/OwnPtr.h>
+#include <wtf/RefPtr.h>
+
+namespace WebCore {
+class LayerWebKitThread;
+};
+
+namespace BlackBerry {
+namespace WebKit {
+
+class WebPagePrivate;
+
+// This class may only be used on the compositing thread.
+class WebPageCompositorPrivate {
+public:
+ WebPageCompositorPrivate(WebPagePrivate*);
+ ~WebPageCompositorPrivate();
+
+ bool hardwareCompositing() const;
+
+ void setRootLayer(WebCore::LayerCompositingThread*);
+
+ void setBackingStoreUsesOpenGL(bool);
+
+ void commit(WebCore::LayerWebKitThread* rootLayerProxy);
+
+ bool drawLayers(const WebCore::IntRect& dstRect, const WebCore::FloatRect& contents);
+
+ WebCore::IntRect layoutRectForCompositing() const { return m_layoutRectForCompositing; }
+ void setLayoutRectForCompositing(const WebCore::IntRect& rect) { m_layoutRectForCompositing = rect; }
+
+ WebCore::IntSize contentsSizeForCompositing() const { return m_contentsSizeForCompositing; }
+ void setContentsSizeForCompositing(const WebCore::IntSize& size) { m_contentsSizeForCompositing = size; }
+
+ WebCore::LayerRenderingResults lastCompositingResults() const { return m_lastCompositingResults; }
+ void setLastCompositingResults(const WebCore::LayerRenderingResults& results) { m_lastCompositingResults = results; }
+
+ void releaseLayerResources();
+
+private:
+ void animationTimerFired();
+
+ WebPagePrivate* m_webPage;
+ // Please maintain this order since m_layerRenderer depends on m_context in initialization list.
+ OwnPtr<GLES2Context> m_context;
+ OwnPtr<WebCore::LayerRenderer> m_layerRenderer;
+ RefPtr<WebCore::LayerCompositingThread> m_rootLayer;
+ WebCore::IntRect m_layoutRectForCompositing;
+ WebCore::IntSize m_contentsSizeForCompositing;
+ WebCore::LayerRenderingResults m_lastCompositingResults;
+ int m_generation;
+ int m_compositedGeneration;
+ WebCore::IntRect m_compositedDstRect;
+ WebCore::FloatRect m_compositedContentsRect;
+ bool m_backingStoreUsesOpenGL;
+ BlackBerry::Platform::Timer<WebPageCompositorPrivate> m_animationTimer;
+ BlackBerry::Platform::TimerClient* m_timerClient;
+};
+
+} // namespace WebKit
+} // namespace BlackBerry
+
+#endif // USE(ACCELERATED_COMPOSITING)
+
+#endif // WebPageCompositor_p_h
Modified: trunk/Source/WebKit/blackberry/Api/WebPage_p.h (111098 => 111099)
--- trunk/Source/WebKit/blackberry/Api/WebPage_p.h 2012-03-17 00:31:22 UTC (rev 111098)
+++ trunk/Source/WebKit/blackberry/Api/WebPage_p.h 2012-03-17 00:41:19 UTC (rev 111099)
@@ -65,7 +65,7 @@
#if USE(ACCELERATED_COMPOSITING)
class FrameLayers;
-class WebPageCompositor;
+class WebPageCompositorPrivate;
#endif
// In the client code, there is screen size and viewport.
@@ -499,7 +499,7 @@
#if USE(ACCELERATED_COMPOSITING)
bool m_isAcceleratedCompositingActive;
OwnPtr<FrameLayers> m_frameLayers; // WebKit thread only.
- OwnPtr<WebPageCompositor> m_compositor; // Compositing thread only.
+ OwnPtr<WebPageCompositorPrivate> m_compositor; // Compositing thread only.
OwnPtr<WebCore::Timer<WebPagePrivate> > m_rootLayerCommitTimer;
bool m_needsOneShotDrawingSynchronization;
bool m_needsCommit;
Modified: trunk/Source/WebKit/blackberry/ChangeLog (111098 => 111099)
--- trunk/Source/WebKit/blackberry/ChangeLog 2012-03-17 00:31:22 UTC (rev 111098)
+++ trunk/Source/WebKit/blackberry/ChangeLog 2012-03-17 00:41:19 UTC (rev 111099)
@@ -1,3 +1,43 @@
+2012-03-16 Arvid Nilsson <[email protected]>
+
+ [BlackBerry] Rename the existing WebPageCompositor class to WebPageCompositorPrivate
+ https://bugs.webkit.org/show_bug.cgi?id=81108
+ RIM PR: 136687
+
+ Reviewed by Rob Buis.
+
+ This is done in anticipation of a new WebPageCompositor class in the
+ public API. The existing internal class will serve to d-pointerize the
+ new public API. In addition, it is and will be possible to create only
+ the private class, for cases where existing code paths require
+ OpenGL compositing (i.e. due to accelerated compositing layers being
+ added to the page).
+
+ Reviewed internally by Robin Cao.
+
+ * Api/BackingStore.h:
+ * Api/WebPage.cpp:
+ (BlackBerry::WebKit::WebPagePrivate::setIsAcceleratedCompositingActive):
+ * Api/WebPageCompositor.cpp: Renamed from Source/WebKit/blackberry/WebKitSupport/WebPageCompositor.cpp.
+ (BlackBerry::WebKit::WebPageCompositorPrivate::WebPageCompositorPrivate):
+ (BlackBerry::WebKit::WebPageCompositorPrivate::~WebPageCompositorPrivate):
+ (BlackBerry::WebKit::WebPageCompositorPrivate::hardwareCompositing):
+ (BlackBerry::WebKit::WebPageCompositorPrivate::setRootLayer):
+ (BlackBerry::WebKit::WebPageCompositorPrivate::setBackingStoreUsesOpenGL):
+ (BlackBerry::WebKit::WebPageCompositorPrivate::commit):
+ (BlackBerry::WebKit::WebPageCompositorPrivate::drawLayers):
+ (BlackBerry::WebKit::WebPageCompositorPrivate::releaseLayerResources):
+ (BlackBerry::WebKit::WebPageCompositorPrivate::animationTimerFired):
+ * Api/WebPageCompositor_p.h: Renamed from Source/WebKit/blackberry/WebKitSupport/WebPageCompositor.h.
+ (BlackBerry::WebKit::WebPageCompositorPrivate::layoutRectForCompositing):
+ (BlackBerry::WebKit::WebPageCompositorPrivate::setLayoutRectForCompositing):
+ (BlackBerry::WebKit::WebPageCompositorPrivate::contentsSizeForCompositing):
+ (BlackBerry::WebKit::WebPageCompositorPrivate::setContentsSizeForCompositing):
+ (BlackBerry::WebKit::WebPageCompositorPrivate::lastCompositingResults):
+ (BlackBerry::WebKit::WebPageCompositorPrivate::setLastCompositingResults):
+ * Api/WebPage_p.h:
+ * CMakeListsBlackBerry.txt:
+
2012-03-16 Nima Ghanavatian <[email protected]>
[BlackBerry] Syncing up left over bits in WebKitSupport from our local branch to upstream
Deleted: trunk/Source/WebKit/blackberry/WebKitSupport/WebPageCompositor.cpp (111098 => 111099)
--- trunk/Source/WebKit/blackberry/WebKitSupport/WebPageCompositor.cpp 2012-03-17 00:31:22 UTC (rev 111098)
+++ trunk/Source/WebKit/blackberry/WebKitSupport/WebPageCompositor.cpp 2012-03-17 00:41:19 UTC (rev 111099)
@@ -1,131 +0,0 @@
-/*
- * Copyright (C) 2010, 2011, 2012 Research In Motion Limited. All rights reserved.
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
- */
-
-#include "config.h"
-
-#if USE(ACCELERATED_COMPOSITING)
-#include "WebPageCompositor.h"
-
-#include "BackingStore_p.h"
-#include "LayerWebKitThread.h"
-#include "WebPage_p.h"
-
-#include <BlackBerryPlatformExecutableMessage.h>
-#include <BlackBerryPlatformMessage.h>
-#include <BlackBerryPlatformMessageClient.h>
-#include <GenericTimerClient.h>
-#include <ThreadTimerClient.h>
-
-using namespace WebCore;
-
-namespace BlackBerry {
-namespace WebKit {
-
-WebPageCompositor::WebPageCompositor(WebPagePrivate* page)
- : m_webPage(page)
- , m_context(GLES2Context::create(page))
- , m_layerRenderer(LayerRenderer::create(m_context.get()))
- , m_generation(0)
- , m_compositedGeneration(-1)
- , m_backingStoreUsesOpenGL(false)
- , m_animationTimer(this, &WebPageCompositor::animationTimerFired)
- , m_timerClient(new Platform::GenericTimerClient(Platform::userInterfaceThreadTimerClient()))
-{
- m_animationTimer.setClient(m_timerClient);
-}
-
-WebPageCompositor::~WebPageCompositor()
-{
- m_animationTimer.stop();
- delete m_timerClient;
-}
-
-bool WebPageCompositor::hardwareCompositing() const
-{
- return m_layerRenderer->hardwareCompositing();
-}
-
-void WebPageCompositor::setRootLayer(LayerCompositingThread* rootLayer)
-{
- m_rootLayer = rootLayer;
- m_layerRenderer->setRootLayer(m_rootLayer.get());
-}
-
-void WebPageCompositor::setBackingStoreUsesOpenGL(bool backingStoreUsesOpenGL)
-{
- m_backingStoreUsesOpenGL = backingStoreUsesOpenGL;
- m_layerRenderer->setClearSurfaceOnDrawLayers(!backingStoreUsesOpenGL);
-}
-
-void WebPageCompositor::commit(LayerWebKitThread* rootLayer)
-{
- if (!rootLayer)
- return;
-
- rootLayer->commitOnCompositingThread();
- ++m_generation;
-}
-
-bool WebPageCompositor::drawLayers(const IntRect& dstRect, const FloatRect& contents)
-{
- // Save a draw if we already drew this generation, for example due to a concurrent scroll operation.
- if (m_compositedGeneration == m_generation && dstRect == m_compositedDstRect
- && contents == m_compositedContentsRect && !m_backingStoreUsesOpenGL)
- return false;
-
- m_layerRenderer->drawLayers(contents, m_layoutRectForCompositing, m_contentsSizeForCompositing, dstRect);
- m_lastCompositingResults = m_layerRenderer->lastRenderingResults();
-
- m_compositedDstRect = dstRect;
- m_compositedContentsRect = contents;
- m_compositedGeneration = m_generation;
-
- if (m_lastCompositingResults.needsAnimationFrame) {
- ++m_generation; // The animation update moves us along one generation.
- // Using a timeout of 0 actually won't start a timer, it will send a message.
- m_animationTimer.start(1.0 / 60.0);
- m_webPage->updateDelegatedOverlays();
- }
-
- return true;
-}
-
-void WebPageCompositor::releaseLayerResources()
-{
- m_layerRenderer->releaseLayerResources();
-}
-
-void WebPageCompositor::animationTimerFired()
-{
- if (m_webPage->m_backingStore->d->shouldDirectRenderingToWindow()) {
- if (m_webPage->m_backingStore->d->isDirectRenderingAnimationMessageScheduled())
- return; // don't send new messages as long as we haven't rerendered
-
- m_webPage->m_backingStore->d->setDirectRenderingAnimationMessageScheduled();
- BlackBerry::Platform::webKitThreadMessageClient()->dispatchMessage(
- BlackBerry::Platform::createMethodCallMessage(
- &BackingStorePrivate::renderVisibleContents, m_webPage->m_backingStore->d));
- return;
- }
- m_webPage->blitVisibleContents();
-}
-
-} // namespace WebKit
-} // namespace BlackBerry
-
-#endif // USE(ACCELERATED_COMPOSITING)
Deleted: trunk/Source/WebKit/blackberry/WebKitSupport/WebPageCompositor.h (111098 => 111099)
--- trunk/Source/WebKit/blackberry/WebKitSupport/WebPageCompositor.h 2012-03-17 00:31:22 UTC (rev 111098)
+++ trunk/Source/WebKit/blackberry/WebKitSupport/WebPageCompositor.h 2012-03-17 00:41:19 UTC (rev 111099)
@@ -1,93 +0,0 @@
-/*
- * Copyright (C) 2010, 2011, 2012 Research In Motion Limited. All rights reserved.
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
- */
-
-#ifndef WebPageCompositor_h
-#define WebPageCompositor_h
-
-#if USE(ACCELERATED_COMPOSITING)
-
-#include "GLES2Context.h"
-#include "LayerCompositingThread.h"
-#include "LayerRenderer.h"
-
-#include <BlackBerryPlatformTimer.h>
-#include <wtf/OwnPtr.h>
-#include <wtf/RefPtr.h>
-
-namespace WebCore {
-class LayerWebKitThread;
-};
-
-namespace BlackBerry {
-namespace WebKit {
-
-class WebPagePrivate;
-
-// This class may only be used on the compositing thread.
-class WebPageCompositor {
-public:
- WebPageCompositor(WebPagePrivate*);
- ~WebPageCompositor();
-
- bool hardwareCompositing() const;
-
- void setRootLayer(WebCore::LayerCompositingThread*);
-
- void setBackingStoreUsesOpenGL(bool);
-
- void commit(WebCore::LayerWebKitThread* rootLayerProxy);
-
- bool drawLayers(const WebCore::IntRect& dstRect, const WebCore::FloatRect& contents);
-
- WebCore::IntRect layoutRectForCompositing() const { return m_layoutRectForCompositing; }
- void setLayoutRectForCompositing(const WebCore::IntRect& rect) { m_layoutRectForCompositing = rect; }
-
- WebCore::IntSize contentsSizeForCompositing() const { return m_contentsSizeForCompositing; }
- void setContentsSizeForCompositing(const WebCore::IntSize& size) { m_contentsSizeForCompositing = size; }
-
- WebCore::LayerRenderingResults lastCompositingResults() const { return m_lastCompositingResults; }
- void setLastCompositingResults(const WebCore::LayerRenderingResults& results) { m_lastCompositingResults = results; }
-
- void releaseLayerResources();
-
-private:
- void animationTimerFired();
-
- WebPagePrivate* m_webPage;
- // Please maintain this order since m_layerRenderer depends on m_context in initialization list.
- OwnPtr<GLES2Context> m_context;
- OwnPtr<WebCore::LayerRenderer> m_layerRenderer;
- RefPtr<WebCore::LayerCompositingThread> m_rootLayer;
- WebCore::IntRect m_layoutRectForCompositing;
- WebCore::IntSize m_contentsSizeForCompositing;
- WebCore::LayerRenderingResults m_lastCompositingResults;
- int m_generation;
- int m_compositedGeneration;
- WebCore::IntRect m_compositedDstRect;
- WebCore::FloatRect m_compositedContentsRect;
- bool m_backingStoreUsesOpenGL;
- BlackBerry::Platform::Timer<WebPageCompositor> m_animationTimer;
- BlackBerry::Platform::TimerClient* m_timerClient;
-};
-
-} // namespace WebKit
-} // namespace BlackBerry
-
-#endif // USE(ACCELERATED_COMPOSITING)
-
-#endif // WebPageCompositor_h