2011-05-16 Ian Henderson <ianh@apple.com>
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 17 May 2011 00:50:20 +0000 (00:50 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 17 May 2011 00:50:20 +0000 (00:50 +0000)
commit071ce2eb950509f528a15f1940d1ed7ec110addc
tree95733b5f0122d4ac1556c792f9447a9bde19a154
parentf5b6ceaeda571db76e2ad8a98a55f8ef496dfc53
2011-05-16  Ian Henderson  <ianh@apple.com>

        Reviewed by Joseph Pecoraro.

        Page::goToItem doesn't work while loading is deferred
        https://bugs.webkit.org/show_bug.cgi?id=60412

        * loader/navigation-while-deferring-loads-expected.txt: Added.
        * loader/navigation-while-deferring-loads.html: Added.
        * platform/gtk/Skipped:
        * platform/qt/Skipped:
        * platform/win/Skipped:
2011-05-16  Ian Henderson  <ianh@apple.com>

        Reviewed by Joseph Pecoraro.

        Page::goToItem doesn't work while loading is deferred
        https://bugs.webkit.org/show_bug.cgi?id=60412

        If goToItem is called while loading is deferred, save the arguments
        and try again later instead of doing nothing.

        Test: loader/navigation-while-deferring-loads.html

        * loader/FrameLoader.cpp:
        (WebCore::FrameLoader::setDefersLoading):
        Pipe the "defersLoading" state into HistoryController.
        * loader/HistoryController.cpp:
        (WebCore::HistoryController::HistoryController):
        (WebCore::HistoryController::goToItem):
        Save the HistoryItem and FrameLoadType if loading is deferred.
        (WebCore::HistoryController::setDefersLoading):
        If we have a saved HistoryItem after resuming, try going to it.
        * loader/HistoryController.h:
        * page/Page.cpp:
        (WebCore::Page::goToItem):
        No longer bail early if loading is deferred, since HistoryController
        now handles this case.
2011-05-16  Ian Henderson  <ianh@apple.com>

        Reviewed by Joseph Pecoraro.

        Page::goToItem doesn't work while loading is deferred
        https://bugs.webkit.org/show_bug.cgi?id=60412

        Add setDefersLoading and goBack methods to LayoutTestController.  We
        need to use goBack() instead of history.back() because the latter goes
        through NavigationScheduler, hence doesn't exhibit the bug.

        * DumpRenderTree/LayoutTestController.cpp:
        (goBackCallback):
        (setDefersLoadingCallback):
        (LayoutTestController::staticFunctions):
        * DumpRenderTree/LayoutTestController.h:
        * DumpRenderTree/gtk/LayoutTestControllerGtk.cpp:
        (LayoutTestController::goBack):
        (LayoutTestController::setDefersLoading):
        * DumpRenderTree/mac/LayoutTestControllerMac.mm:
        (LayoutTestController::goBack):
        (LayoutTestController::setDefersLoading):
        * DumpRenderTree/win/LayoutTestControllerWin.cpp:
        (LayoutTestController::goBack):
        (LayoutTestController::setDefersLoading):
        * DumpRenderTree/wx/LayoutTestControllerWx.cpp:
        (LayoutTestController::goBack):
        (LayoutTestController::setDefersLoading):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@86644 268f45cc-cd09-0410-ab3c-d52691b4dbfc
19 files changed:
LayoutTests/ChangeLog
LayoutTests/loader/navigation-while-deferring-loads-expected.txt [new file with mode: 0644]
LayoutTests/loader/navigation-while-deferring-loads.html [new file with mode: 0644]
LayoutTests/platform/chromium/test_expectations.txt
LayoutTests/platform/gtk/Skipped
LayoutTests/platform/qt/Skipped
LayoutTests/platform/win/Skipped
Source/WebCore/ChangeLog
Source/WebCore/loader/FrameLoader.cpp
Source/WebCore/loader/HistoryController.cpp
Source/WebCore/loader/HistoryController.h
Source/WebCore/page/Page.cpp
Tools/ChangeLog
Tools/DumpRenderTree/LayoutTestController.cpp
Tools/DumpRenderTree/LayoutTestController.h
Tools/DumpRenderTree/gtk/LayoutTestControllerGtk.cpp
Tools/DumpRenderTree/mac/LayoutTestControllerMac.mm
Tools/DumpRenderTree/win/LayoutTestControllerWin.cpp
Tools/DumpRenderTree/wx/LayoutTestControllerWx.cpp