Changeset 132422 in webkit


Ignore:
Timestamp:
Oct 24, 2012 4:40:28 PM (11 years ago)
Author:
timothy_horton@apple.com
Message:

Update main frame scroll position immediately for programmatic scrolls
https://bugs.webkit.org/show_bug.cgi?id=98074

Reviewed by Simon Fraser.

Immediately update the main frame scroll position after a programmatic scroll,
so that performing a scrollBy or scrollTo will be instantly reflected in
all of the scroll offset accessors.

No new tests; this will be tested by many scrolling tests once WebKitTestRunner
can use threaded scrolling.

  • page/scrolling/ScrollingCoordinator.cpp:

(WebCore::ScrollingCoordinator::requestScrollPositionUpdate):

Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r132421 r132422  
     12012-10-24  Tim Horton  <timothy_horton@apple.com>
     2
     3        Update main frame scroll position immediately for programmatic scrolls
     4        https://bugs.webkit.org/show_bug.cgi?id=98074
     5
     6        Reviewed by Simon Fraser.
     7
     8        Immediately update the main frame scroll position after a programmatic scroll,
     9        so that performing a scrollBy or scrollTo will be instantly reflected in
     10        all of the scroll offset accessors.
     11
     12        No new tests; this will be tested by many scrolling tests once WebKitTestRunner
     13        can use threaded scrolling.
     14
     15        * page/scrolling/ScrollingCoordinator.cpp:
     16        (WebCore::ScrollingCoordinator::requestScrollPositionUpdate):
     17
    1182012-10-24  Mihai Parparita  <mihaip@chromium.org>
    219
  • trunk/Source/WebCore/page/scrolling/mac/ScrollingCoordinatorMac.mm

    r131804 r132422  
    184184        return false;
    185185
    186     if (frameView->frame()->document()->inPageCache()) {
    187         // If this frame view's document is being put into the page cache, we don't want to update our
    188         // main frame scroll position. Just let the FrameView think that we did.
     186    if (frameView->inProgrammaticScroll() || frameView->frame()->document()->inPageCache())
    189187        updateMainFrameScrollPosition(scrollPosition, frameView->inProgrammaticScroll());
     188
     189    // If this frame view's document is being put into the page cache, we don't want to update our
     190    // main frame scroll position. Just let the FrameView think that we did.
     191    if (frameView->frame()->document()->inPageCache())
    190192        return true;
    191     }
    192193
    193194    ScrollingStateScrollingNode* stateNode = stateNodeForID(frameView->scrollLayerID());
Note: See TracChangeset for help on using the changeset viewer.