summaryrefslogtreecommitdiffstats
path: root/Source/WebKit2/WebProcess/WebPage/LayerTreeHost.h
diff options
context:
space:
mode:
Diffstat (limited to 'Source/WebKit2/WebProcess/WebPage/LayerTreeHost.h')
-rw-r--r--Source/WebKit2/WebProcess/WebPage/LayerTreeHost.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/Source/WebKit2/WebProcess/WebPage/LayerTreeHost.h b/Source/WebKit2/WebProcess/WebPage/LayerTreeHost.h
index bbb94e8..004bdb7 100644
--- a/Source/WebKit2/WebProcess/WebPage/LayerTreeHost.h
+++ b/Source/WebKit2/WebProcess/WebPage/LayerTreeHost.h
@@ -38,6 +38,7 @@ namespace WebCore {
namespace WebKit {
class LayerTreeContext;
+class UpdateInfo;
class WebPage;
class LayerTreeHost : public RefCounted<LayerTreeHost> {
@@ -45,6 +46,8 @@ public:
static PassRefPtr<LayerTreeHost> create(WebPage*);
virtual ~LayerTreeHost();
+ static bool supportsAcceleratedCompositing();
+
virtual const LayerTreeContext& layerTreeContext() = 0;
virtual void scheduleLayerFlush() = 0;
virtual void setShouldNotifyAfterNextScheduledLayerFlush(bool) = 0;
@@ -60,12 +63,29 @@ public:
virtual void didUninstallPageOverlay() = 0;
virtual void setPageOverlayNeedsDisplay(const WebCore::IntRect&) = 0;
+ virtual void pauseRendering() { }
+ virtual void resumeRendering() { }
+
+ // If a derived class overrides this function to return true, the derived class must also
+ // override the functions beneath it.
+ virtual bool participatesInDisplay() { return false; }
+ virtual bool needsDisplay() { ASSERT_NOT_REACHED(); return false; }
+ virtual double timeUntilNextDisplay() { ASSERT_NOT_REACHED(); return 0; }
+ virtual void display(UpdateInfo&) { ASSERT_NOT_REACHED(); }
+
protected:
explicit LayerTreeHost(WebPage*);
WebPage* m_webPage;
};
+#if !PLATFORM(WIN)
+inline bool LayerTreeHost::supportsAcceleratedCompositing()
+{
+ return true;
+}
+#endif
+
} // namespace WebKit
#endif // LayerTreeHost_h