Title: [165748] trunk/Source
Revision
165748
Author
[email protected]
Date
2014-03-17 13:04:47 -0700 (Mon, 17 Mar 2014)

Log Message

WKThumbnailView should support snapshots
https://bugs.webkit.org/show_bug.cgi?id=130335
<rdar://problem/16255139>

Reviewed by Simon Fraser.

Add a mode where WKThumbnailView takes a software snapshot of the web content,
replacing the live layer tree with said snapshot once it returns from the
web process. This may improve animation performance in cases where the
layer tree would otherwise be very complex.

* UIProcess/API/Cocoa/WKThumbnailView.h:
Add a property, usesSnapshot, which determines whether the thumbnail view
should use the live layer tree or a snapshot of the content.

* UIProcess/API/Cocoa/WKThumbnailView.mm:
(-[WKThumbnailView initWithFrame:fromWKView:]):
(-[WKThumbnailView _viewWasUnparented]):
Clear the snapshot when unparented.

(-[WKThumbnailView _viewWasParented]):
Take a snapshot of the web content when parented, if needed.

(-[WKThumbnailView _requestSnapshotIfNeeded]):
If we're using snapshots, and haven't already dispatched an async snapshot request,
and don't already have a snapshot, request a snapshot from the web process.

When it returns, use it as the contents of the WKThumbnailView layer, and
unparent the live layer tree.

(-[WKThumbnailView setScale:]):
(-[WKThumbnailView setUsesSnapshot:]):
(-[WKThumbnailView _setThumbnailLayer:]):
(-[WKThumbnailView _thumbnailLayer]):
* UIProcess/API/Cocoa/WKThumbnailViewInternal.h:

* UIProcess/API/mac/WKView.mm:
(-[WKView _setAcceleratedCompositingModeRootLayer:]):
(-[WKView _acceleratedCompositingModeRootLayer]):
WKView should always keep track of the current root layer, instead of totally
handing control over to WKThumbnailView when it is used.

(-[WKView _setThumbnailView:]):
(-[WKView _updateThumbnailViewLayer]):
(-[WKView _reparentLayerTreeInThumbnailView]):
If needed (either we're not using snapshots, or still waiting for the snapshot to be painted),
push the WKView's live layer tree into the thumbnail view.

* UIProcess/API/mac/WKViewInternal.h:
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::internalShowContextMenu):
* UIProcess/WebPageProxy.h:
* WebProcess/WebPage/WebPage.h:
* WebProcess/WebPage/WebPage.messages.in:
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::takeThumbnailSnapshot):
Add a message that asynchronously returns a snapshot that respects the
current thumbnail scale and position.

(WebKit::WebPage::scaledSnapshotWithOptions):
Use some nullptr.

* WebProcess/WebPage/DrawingArea.cpp:
(WebKit::DrawingArea::transform):
* WebProcess/WebPage/DrawingArea.h:
* WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
Add a getter for the DrawingArea's transform.
Rename it to rootLayerTransform.

* WebCore.exp.in:

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (165747 => 165748)


--- trunk/Source/WebCore/ChangeLog	2014-03-17 19:27:53 UTC (rev 165747)
+++ trunk/Source/WebCore/ChangeLog	2014-03-17 20:04:47 UTC (rev 165748)
@@ -1,3 +1,13 @@
+2014-03-17  Tim Horton  <[email protected]>
+
+        WKThumbnailView should support snapshots
+        https://bugs.webkit.org/show_bug.cgi?id=130335
+        <rdar://problem/16255139>
+
+        Reviewed by Simon Fraser.
+
+        * WebCore.exp.in:
+
 2014-01-29  Sergio Villar Senin  <[email protected]>
 
         [CSS Grid Layout] getComputedStyle() not using author's order when showing named grid lines

Modified: trunk/Source/WebCore/WebCore.exp.in (165747 => 165748)


--- trunk/Source/WebCore/WebCore.exp.in	2014-03-17 19:27:53 UTC (rev 165747)
+++ trunk/Source/WebCore/WebCore.exp.in	2014-03-17 20:04:47 UTC (rev 165748)
@@ -1730,6 +1730,8 @@
 __ZNK7WebCore20ResourceResponseBase3urlEv
 __ZNK7WebCore20ResourceResponseBase6isHTTPEv
 __ZNK7WebCore20ResourceResponseBase8mimeTypeEv
+__ZNK7WebCore20TransformationMatrix7inverseEv
+__ZNK7WebCore20TransformationMatrix7mapRectERKNS_7IntRectE
 __ZNK7WebCore20TransformationMatrixcv13CATransform3DEv
 __ZNK7WebCore21BackForwardController12forwardCountEv
 __ZNK7WebCore21BackForwardController18canGoBackOrForwardEi

Modified: trunk/Source/WebKit2/ChangeLog (165747 => 165748)


--- trunk/Source/WebKit2/ChangeLog	2014-03-17 19:27:53 UTC (rev 165747)
+++ trunk/Source/WebKit2/ChangeLog	2014-03-17 20:04:47 UTC (rev 165748)
@@ -1,3 +1,74 @@
+2014-03-17  Tim Horton  <[email protected]>
+
+        WKThumbnailView should support snapshots
+        https://bugs.webkit.org/show_bug.cgi?id=130335
+        <rdar://problem/16255139>
+
+        Reviewed by Simon Fraser.
+
+        Add a mode where WKThumbnailView takes a software snapshot of the web content,
+        replacing the live layer tree with said snapshot once it returns from the
+        web process. This may improve animation performance in cases where the
+        layer tree would otherwise be very complex.
+
+        * UIProcess/API/Cocoa/WKThumbnailView.h:
+        Add a property, usesSnapshot, which determines whether the thumbnail view
+        should use the live layer tree or a snapshot of the content.
+
+        * UIProcess/API/Cocoa/WKThumbnailView.mm:
+        (-[WKThumbnailView initWithFrame:fromWKView:]):
+        (-[WKThumbnailView _viewWasUnparented]):
+        Clear the snapshot when unparented.
+
+        (-[WKThumbnailView _viewWasParented]):
+        Take a snapshot of the web content when parented, if needed.
+
+        (-[WKThumbnailView _requestSnapshotIfNeeded]):
+        If we're using snapshots, and haven't already dispatched an async snapshot request,
+        and don't already have a snapshot, request a snapshot from the web process.
+
+        When it returns, use it as the contents of the WKThumbnailView layer, and
+        unparent the live layer tree.
+
+        (-[WKThumbnailView setScale:]):
+        (-[WKThumbnailView setUsesSnapshot:]):
+        (-[WKThumbnailView _setThumbnailLayer:]):
+        (-[WKThumbnailView _thumbnailLayer]):
+        * UIProcess/API/Cocoa/WKThumbnailViewInternal.h:
+
+        * UIProcess/API/mac/WKView.mm:
+        (-[WKView _setAcceleratedCompositingModeRootLayer:]):
+        (-[WKView _acceleratedCompositingModeRootLayer]):
+        WKView should always keep track of the current root layer, instead of totally
+        handing control over to WKThumbnailView when it is used.
+
+        (-[WKView _setThumbnailView:]):
+        (-[WKView _updateThumbnailViewLayer]):
+        (-[WKView _reparentLayerTreeInThumbnailView]):
+        If needed (either we're not using snapshots, or still waiting for the snapshot to be painted),
+        push the WKView's live layer tree into the thumbnail view.
+
+        * UIProcess/API/mac/WKViewInternal.h:
+        * UIProcess/WebPageProxy.cpp:
+        (WebKit::WebPageProxy::internalShowContextMenu):
+        * UIProcess/WebPageProxy.h:
+        * WebProcess/WebPage/WebPage.h:
+        * WebProcess/WebPage/WebPage.messages.in:
+        * WebProcess/WebPage/WebPage.cpp:
+        (WebKit::WebPage::takeThumbnailSnapshot):
+        Add a message that asynchronously returns a snapshot that respects the
+        current thumbnail scale and position.
+
+        (WebKit::WebPage::scaledSnapshotWithOptions):
+        Use some nullptr.
+
+        * WebProcess/WebPage/DrawingArea.cpp:
+        (WebKit::DrawingArea::transform):
+        * WebProcess/WebPage/DrawingArea.h:
+        * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
+        Add a getter for the DrawingArea's transform.
+        Rename it to rootLayerTransform.
+
 2014-03-17  Zan Dobersek  <[email protected]>
 
         Use RunLoop objects through references instead of pointers

Modified: trunk/Source/WebKit2/UIProcess/API/Cocoa/WKThumbnailView.h (165747 => 165748)


--- trunk/Source/WebKit2/UIProcess/API/Cocoa/WKThumbnailView.h	2014-03-17 19:27:53 UTC (rev 165747)
+++ trunk/Source/WebKit2/UIProcess/API/Cocoa/WKThumbnailView.h	2014-03-17 20:04:47 UTC (rev 165748)
@@ -39,6 +39,7 @@
 - (instancetype)initWithFrame:(NSRect)frame fromWKView:(WKView *)wkView;
 
 @property (nonatomic) CGFloat scale;
+@property (nonatomic) BOOL usesSnapshot;
 
 @end
 

Modified: trunk/Source/WebKit2/UIProcess/API/Cocoa/WKThumbnailView.mm (165747 => 165748)


--- trunk/Source/WebKit2/UIProcess/API/Cocoa/WKThumbnailView.mm	2014-03-17 19:27:53 UTC (rev 165747)
+++ trunk/Source/WebKit2/UIProcess/API/Cocoa/WKThumbnailView.mm	2014-03-17 20:04:47 UTC (rev 165748)
@@ -54,6 +54,8 @@
     BOOL _shouldApplyThumbnailScale;
 }
 
+@synthesize _waitingForSnapshot = _waitingForSnapshot;
+
 - (instancetype)initWithFrame:(NSRect)frame fromWKView:(WKView *)wkView
 {
     if (!(self = [super initWithFrame:frame]))
@@ -76,6 +78,9 @@
         _webPageProxy->setThumbnailScale(1);
 
     [_wkView _setThumbnailView:nil];
+
+    self.layer.contents = nil;
+
     _webPageProxy->setMayStartMediaWhenInWindow(_originalMayStartMediaWhenInWindow);
 }
 
@@ -90,9 +95,32 @@
     if (!_originalSourceViewIsInWindow)
         _webPageProxy->setMayStartMediaWhenInWindow(false);
 
+    [self _requestSnapshotIfNeeded];
     [_wkView _setThumbnailView:self];
 }
 
+- (void)_requestSnapshotIfNeeded
+{
+    if (!_usesSnapshot || _waitingForSnapshot || self.layer.contents)
+        return;
+
+    _waitingForSnapshot = YES;
+
+    RetainPtr<WKThumbnailView> thumbnailView = self;
+    _webPageProxy->takeThumbnailSnapshot([thumbnailView](bool, const ShareableBitmap::Handle& imageHandle) {
+        RefPtr<ShareableBitmap> bitmap = ShareableBitmap::create(imageHandle, SharedMemory::ReadOnly);
+        RetainPtr<CGImageRef> cgImage = bitmap->makeCGImage();
+        [thumbnailView _didTakeSnapshot:cgImage.get()];
+    });
+}
+
+- (void)_didTakeSnapshot:(CGImageRef)image
+{
+    _waitingForSnapshot = NO;
+    self.layer.sublayers = @[];
+    self.layer.contents = (id)image;
+}
+
 - (void)viewDidMoveToWindow
 {
     if (self.window)
@@ -103,18 +131,37 @@
 
 - (void)setScale:(CGFloat)scale
 {
+    if (_scale == scale)
+        return;
+
     _scale = scale;
 
     if (self.window && _shouldApplyThumbnailScale)
         _webPageProxy->setThumbnailScale(_scale);
 }
 
-- (void)setThumbnailLayer:(CALayer *)layer
+- (void)setUsesSnapshot:(BOOL)usesSnapshot
 {
+    if (_usesSnapshot == usesSnapshot)
+        return;
+
+    _usesSnapshot = usesSnapshot;
+
+    if (!self.window)
+        return;
+
+    if (usesSnapshot)
+        [self _requestSnapshotIfNeeded];
+    else
+        [_wkView _reparentLayerTreeInThumbnailView];
+}
+
+- (void)_setThumbnailLayer:(CALayer *)layer
+{
     self.layer.sublayers = layer ? @[ layer ] : @[ ];
 }
 
-- (CALayer *)thumbnailLayer
+- (CALayer *)_thumbnailLayer
 {
     if (!self.layer.sublayers.count)
         return nil;

Modified: trunk/Source/WebKit2/UIProcess/API/Cocoa/WKThumbnailViewInternal.h (165747 => 165748)


--- trunk/Source/WebKit2/UIProcess/API/Cocoa/WKThumbnailViewInternal.h	2014-03-17 19:27:53 UTC (rev 165747)
+++ trunk/Source/WebKit2/UIProcess/API/Cocoa/WKThumbnailViewInternal.h	2014-03-17 20:04:47 UTC (rev 165748)
@@ -31,7 +31,8 @@
 
 @interface WKThumbnailView ()
 
-@property (nonatomic, assign) CALayer *thumbnailLayer;
+@property (nonatomic, assign, setter = _setThumbnailLayer:) CALayer *_thumbnailLayer;
+@property (nonatomic, assign, setter = _setWaitingForSnapshot:) BOOL _waitingForSnapshot;
 
 @end
 

Modified: trunk/Source/WebKit2/UIProcess/API/mac/WKView.mm (165747 => 165748)


--- trunk/Source/WebKit2/UIProcess/API/mac/WKView.mm	2014-03-17 19:27:53 UTC (rev 165747)
+++ trunk/Source/WebKit2/UIProcess/API/mac/WKView.mm	2014-03-17 20:04:47 UTC (rev 165748)
@@ -225,6 +225,8 @@
     BOOL _allowsMagnification;
     BOOL _allowsBackForwardNavigationGestures;
 
+    RetainPtr<CALayer> _rootLayer;
+
 #if WK_API_ENABLED
     WKThumbnailView *_thumbnailView;
 #endif
@@ -2498,9 +2500,11 @@
 {
     [rootLayer web_disableAllActions];
 
+    _data->_rootLayer = rootLayer;
+
 #if WK_API_ENABLED
     if (_data->_thumbnailView) {
-        _data->_thumbnailView.thumbnailLayer = rootLayer;
+        [self _updateThumbnailViewLayer];
         return;
     }
 #endif
@@ -2544,15 +2548,7 @@
 
 - (CALayer *)_acceleratedCompositingModeRootLayer
 {
-    NSView *hostView = _data->_layerHostingView.get();
-
-    if (!hostView)
-        return nullptr;
-
-    if (!hostView.layer.sublayers.count)
-        return nullptr;
-
-    return [hostView.layer.sublayers objectAtIndex:0];
+    return _data->_rootLayer.get();
 }
 
 - (RetainPtr<CGImageRef>)_takeViewSnapshot
@@ -2974,14 +2970,12 @@
 {
     ASSERT(!_data->_thumbnailView || !thumbnailView);
 
-    RetainPtr<CALayer> thumbnailLayer = _data->_thumbnailView.thumbnailLayer;
-
     _data->_thumbnailView = thumbnailView;
 
     if (thumbnailView)
-        thumbnailView.thumbnailLayer = [self _acceleratedCompositingModeRootLayer];
+        [self _updateThumbnailViewLayer];
     else
-        [self _setAcceleratedCompositingModeRootLayer:thumbnailLayer.get()];
+        [self _setAcceleratedCompositingModeRootLayer:_data->_rootLayer.get()];
 
     _data->_page->viewStateDidChange(ViewState::WindowIsActive | ViewState::IsInWindow | ViewState::IsVisible);
 }
@@ -2990,6 +2984,20 @@
 {
     return _data->_thumbnailView;
 }
+
+- (void)_updateThumbnailViewLayer
+{
+    WKThumbnailView *thumbnailView = _data->_thumbnailView;
+    ASSERT(thumbnailView);
+
+    if (!thumbnailView.usesSnapshot || thumbnailView._waitingForSnapshot)
+        [self _reparentLayerTreeInThumbnailView];
+}
+
+- (void)_reparentLayerTreeInThumbnailView
+{
+    _data->_thumbnailView._thumbnailLayer = _data->_rootLayer.get();
+}
 #endif // WK_API_ENABLED
 
 @end

Modified: trunk/Source/WebKit2/UIProcess/API/mac/WKViewInternal.h (165747 => 165748)


--- trunk/Source/WebKit2/UIProcess/API/mac/WKViewInternal.h	2014-03-17 19:27:53 UTC (rev 165747)
+++ trunk/Source/WebKit2/UIProcess/API/mac/WKViewInternal.h	2014-03-17 20:04:47 UTC (rev 165748)
@@ -109,6 +109,7 @@
 
 #if WK_API_ENABLED
 @property (nonatomic, setter=_setThumbnailView:) WKThumbnailView *_thumbnailView;
+- (void)_reparentLayerTreeInThumbnailView;
 #endif
 
 // FullScreen

Modified: trunk/Source/WebKit2/UIProcess/WebPageProxy.cpp (165747 => 165748)


--- trunk/Source/WebKit2/UIProcess/WebPageProxy.cpp	2014-03-17 19:27:53 UTC (rev 165747)
+++ trunk/Source/WebKit2/UIProcess/WebPageProxy.cpp	2014-03-17 20:04:47 UTC (rev 165748)
@@ -4567,4 +4567,17 @@
     m_process->send(Messages::WebPage::AddMIMETypeWithCustomContentProvider(mimeType), m_pageID);
 }
 
+void WebPageProxy::takeThumbnailSnapshot(ImageCallback::CallbackFunction callbackFunction)
+{
+    if (!isValid())
+        return;
+
+    RefPtr<ImageCallback> callback = ImageCallback::create(callbackFunction);
+
+    uint64_t callbackID = callback->callbackID();
+    m_imageCallbacks.set(callbackID, callback.get());
+
+    m_process->send(Messages::WebPage::TakeThumbnailSnapshot(callbackID), m_pageID);
+}
+
 } // namespace WebKit

Modified: trunk/Source/WebKit2/UIProcess/WebPageProxy.h (165747 => 165748)


--- trunk/Source/WebKit2/UIProcess/WebPageProxy.h	2014-03-17 19:27:53 UTC (rev 165747)
+++ trunk/Source/WebKit2/UIProcess/WebPageProxy.h	2014-03-17 20:04:47 UTC (rev 165748)
@@ -917,6 +917,8 @@
 
     void setThumbnailScale(double);
 
+    void takeThumbnailSnapshot(ImageCallback::CallbackFunction);
+
 private:
     WebPageProxy(PageClient&, WebProcessProxy&, uint64_t pageID, const WebPageConfiguration&);
     void platformInitialize();

Modified: trunk/Source/WebKit2/WebProcess/WebPage/DrawingArea.cpp (165747 => 165748)


--- trunk/Source/WebKit2/WebProcess/WebPage/DrawingArea.cpp	2014-03-17 19:27:53 UTC (rev 165747)
+++ trunk/Source/WebKit2/WebProcess/WebPage/DrawingArea.cpp	2014-03-17 20:04:47 UTC (rev 165748)
@@ -25,6 +25,7 @@
 
 #include "config.h"
 #include "DrawingArea.h"
+#include <WebCore/TransformationMatrix.h>
 #include <wtf/Functional.h>
 
 // Subclasses
@@ -41,6 +42,8 @@
 
 #include "WebPageCreationParameters.h"
 
+using namespace WebCore;
+
 namespace WebKit {
 
 std::unique_ptr<DrawingArea> DrawingArea::create(WebPage* webPage, const WebPageCreationParameters& parameters)
@@ -83,4 +86,9 @@
     function();
 }
 
+TransformationMatrix DrawingArea::rootLayerTransform() const
+{
+    return TransformationMatrix();
+}
+
 } // namespace WebKit

Modified: trunk/Source/WebKit2/WebProcess/WebPage/DrawingArea.h (165747 => 165748)


--- trunk/Source/WebKit2/WebProcess/WebPage/DrawingArea.h	2014-03-17 19:27:53 UTC (rev 165747)
+++ trunk/Source/WebKit2/WebProcess/WebPage/DrawingArea.h	2014-03-17 20:04:47 UTC (rev 165748)
@@ -107,7 +107,8 @@
     virtual void setRootCompositingLayer(WebCore::GraphicsLayer*) = 0;
     virtual void scheduleCompositingLayerFlush() = 0;
 
-    virtual void setTransform(const WebCore::TransformationMatrix&) { }
+    virtual WebCore::TransformationMatrix rootLayerTransform() const;
+    virtual void setRootLayerTransform(const WebCore::TransformationMatrix&) { }
 
 #if USE(COORDINATED_GRAPHICS)
     virtual void didReceiveCoordinatedLayerTreeHostMessage(IPC::Connection*, IPC::MessageDecoder&) = 0;

Modified: trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp (165747 => 165748)


--- trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp	2014-03-17 19:27:53 UTC (rev 165747)
+++ trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp	2014-03-17 20:04:47 UTC (rev 165748)
@@ -1513,15 +1513,29 @@
 }
 #endif // !PLATFORM(IOS)
 
+void WebPage::takeThumbnailSnapshot(uint64_t callbackID)
+{
+    IntRect snapshotRect(IntPoint(), m_viewSize);
+    snapshotRect = m_drawingArea->rootLayerTransform().inverse().mapRect(snapshotRect);
+
+    RefPtr<WebImage> image = scaledSnapshotWithOptions(snapshotRect, 1, SnapshotOptionsShareable | SnapshotOptionsInViewCoordinates);
+
+    ShareableBitmap::Handle handle;
+    if (image)
+        image->bitmap()->createHandle(handle, SharedMemory::ReadOnly);
+
+    send(Messages::WebPageProxy::ImageCallback(handle, callbackID));
+}
+
 PassRefPtr<WebImage> WebPage::scaledSnapshotWithOptions(const IntRect& rect, double scaleFactor, SnapshotOptions options)
 {
     Frame* coreFrame = m_mainFrame->coreFrame();
     if (!coreFrame)
-        return 0;
+        return nullptr;
 
     FrameView* frameView = coreFrame->view();
     if (!frameView)
-        return 0;
+        return nullptr;
 
     IntSize bitmapSize = rect.size();
     float combinedScaleFactor = scaleFactor * corePage()->deviceScaleFactor();
@@ -1529,7 +1543,7 @@
 
     RefPtr<WebImage> snapshot = WebImage::create(bitmapSize, snapshotOptionsToImageOptions(options));
     if (!snapshot->bitmap())
-        return 0;
+        return nullptr;
 
     auto graphicsContext = snapshot->bitmap()->createGraphicsContext();
 
@@ -4307,7 +4321,7 @@
     transform.translate((newScrollPosition.x() * inverseScale) - m_scrollPositionIgnoringThumbnailScale.x(), (newScrollPosition.y() * inverseScale) - m_scrollPositionIgnoringThumbnailScale.y());
     transform.scale(inverseScale);
 
-    drawingArea()->setTransform(transform);
+    drawingArea()->setRootLayerTransform(transform);
 }
 
 void WebPage::getBytecodeProfile(uint64_t callbackID)

Modified: trunk/Source/WebKit2/WebProcess/WebPage/WebPage.h (165747 => 165748)


--- trunk/Source/WebKit2/WebProcess/WebPage/WebPage.h	2014-03-17 19:27:53 UTC (rev 165747)
+++ trunk/Source/WebKit2/WebProcess/WebPage/WebPage.h	2014-03-17 20:04:47 UTC (rev 165748)
@@ -846,6 +846,7 @@
     void getWebArchiveOfFrame(uint64_t frameID, uint64_t callbackID);
     void runJavaScriptInMainFrame(const String&, uint64_t callbackID);
     void forceRepaint(uint64_t callbackID);
+    void takeThumbnailSnapshot(uint64_t callbackID);
 
     void preferencesDidChange(const WebPreferencesStore&);
     void platformPreferencesDidChange(const WebPreferencesStore&);

Modified: trunk/Source/WebKit2/WebProcess/WebPage/WebPage.messages.in (165747 => 165748)


--- trunk/Source/WebKit2/WebProcess/WebPage/WebPage.messages.in	2014-03-17 19:27:53 UTC (rev 165747)
+++ trunk/Source/WebKit2/WebProcess/WebPage/WebPage.messages.in	2014-03-17 20:04:47 UTC (rev 165748)
@@ -336,5 +336,7 @@
     SetThumbnailScale(double scale)
 
     GetBytecodeProfile(uint64_t callbackID)
+    
+    TakeThumbnailSnapshot(uint64_t callbackID)
 
 }

Modified: trunk/Source/WebKit2/WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h (165747 => 165748)


--- trunk/Source/WebKit2/WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h	2014-03-17 19:27:53 UTC (rev 165747)
+++ trunk/Source/WebKit2/WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h	2014-03-17 20:04:47 UTC (rev 165748)
@@ -112,7 +112,8 @@
     virtual void commitTransientZoom(double scale, WebCore::FloatPoint origin) override;
     void applyTransientZoomToPage(double scale, WebCore::FloatPoint origin);
 
-    virtual void setTransform(const WebCore::TransformationMatrix&) override;
+    virtual WebCore::TransformationMatrix rootLayerTransform() const override {  return m_transform; }
+    virtual void setRootLayerTransform(const WebCore::TransformationMatrix&) override;
 
     void updateLayerHostingContext();
 

Modified: trunk/Source/WebKit2/WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm (165747 => 165748)


--- trunk/Source/WebKit2/WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm	2014-03-17 19:27:53 UTC (rev 165747)
+++ trunk/Source/WebKit2/WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm	2014-03-17 20:04:47 UTC (rev 165748)
@@ -826,7 +826,7 @@
     m_transientZoomScale = 1;
 }
 
-void TiledCoreAnimationDrawingArea::setTransform(const TransformationMatrix& transform)
+void TiledCoreAnimationDrawingArea::setRootLayerTransform(const TransformationMatrix& transform)
 {
     m_transform = transform;
     [m_rootLayer setSublayerTransform:transform];
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to