Changeset 112457 in webkit


Ignore:
Timestamp:
Mar 28, 2012 3:32:20 PM (12 years ago)
Author:
andersca@apple.com
Message:

Massive lag opening a link in a new background tab
https://bugs.webkit.org/show_bug.cgi?id=82542
<rdar://problem/11004502>

Reviewed by Sam Weinig.

Defer waiting for the web process to update the page size until we're actually going to display the layer.
This matches what we do in the non-tiled code path.

  • UIProcess/API/mac/WKView.mm:

(-[WKView setFrameSize:]):
(-[WKView updateLayer]):

  • UIProcess/DrawingAreaProxy.h:

(WebKit::DrawingAreaProxy::waitForPossibleGeometryUpdate):

  • UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.h:

(TiledCoreAnimationDrawingAreaProxy):

  • UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.mm:

(WebKit::TiledCoreAnimationDrawingAreaProxy::sizeDidChange):
(WebKit):
(WebKit::TiledCoreAnimationDrawingAreaProxy::waitForPossibleGeometryUpdate):

Location:
trunk/Source/WebKit2
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebKit2/ChangeLog

    r112415 r112457  
     12012-03-28  Anders Carlsson  <andersca@apple.com>
     2
     3        Massive lag opening a link in a new background tab
     4        https://bugs.webkit.org/show_bug.cgi?id=82542
     5        <rdar://problem/11004502>
     6
     7        Reviewed by Sam Weinig.
     8
     9        Defer waiting for the web process to update the page size until we're actually going to display the layer.
     10        This matches what we do in the non-tiled code path.
     11
     12        * UIProcess/API/mac/WKView.mm:
     13        (-[WKView setFrameSize:]):
     14        (-[WKView updateLayer]):
     15        * UIProcess/DrawingAreaProxy.h:
     16        (WebKit::DrawingAreaProxy::waitForPossibleGeometryUpdate):
     17        * UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.h:
     18        (TiledCoreAnimationDrawingAreaProxy):
     19        * UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.mm:
     20        (WebKit::TiledCoreAnimationDrawingAreaProxy::sizeDidChange):
     21        (WebKit):
     22        (WebKit::TiledCoreAnimationDrawingAreaProxy::waitForPossibleGeometryUpdate):
     23
    1242012-03-28  Anders Carlsson  <andersca@apple.com>
    225
  • trunk/Source/WebKit2/UIProcess/API/mac/WKView.mm

    r112415 r112457  
    29252925{
    29262926    self.layer.backgroundColor = CGColorGetConstantColor(kCGColorWhite);
     2927    _data->_page->drawingArea()->waitForPossibleGeometryUpdate();
    29272928}
    29282929#endif
  • trunk/Source/WebKit2/UIProcess/DrawingAreaProxy.h

    r111001 r112457  
    8585
    8686    virtual void pageCustomRepresentationChanged() { }
     87    virtual void waitForPossibleGeometryUpdate() { }
    8788
    8889#if USE(UI_SIDE_COMPOSITING)
  • trunk/Source/WebKit2/UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.h

    r109804 r112457  
    4444    virtual void layerHostingModeDidChange() OVERRIDE;
    4545    virtual void sizeDidChange() OVERRIDE;
     46    virtual void waitForPossibleGeometryUpdate() OVERRIDE;
    4647
    4748    virtual void enterAcceleratedCompositingMode(uint64_t backingStoreStateID, const LayerTreeContext&) OVERRIDE;
  • trunk/Source/WebKit2/UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.mm

    r109804 r112457  
    7373
    7474    sendUpdateGeometry();
     75}
     76
     77void TiledCoreAnimationDrawingAreaProxy::waitForPossibleGeometryUpdate()
     78{
     79    if (!m_isWaitingForDidUpdateGeometry)
     80        return;
    7581
    7682    if (m_webPageProxy->process()->isLaunching())
Note: See TracChangeset for help on using the changeset viewer.