WebCore:
authorantti <antti@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 10 Sep 2007 14:55:11 +0000 (14:55 +0000)
committerantti <antti@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 10 Sep 2007 14:55:11 +0000 (14:55 +0000)
commit4e908e2276a9e74e6e9df0c5950048d11af1e2c3
tree705849240628012b5164408c234fcc472141264e
parentfc9bd4f9d301cb3092e7975c8d9ea6285aaebd21
WebCore:

        Reviewed by Kevin.

        Fix <rdar://problem/5444866>
        REGRESSION: missing text in Acrobat "Getting Started" screen due to change in load ordering of large resources

        Make external scripts loaded using file: wait until all style sheet loads have completed before executing.
        Fixes a class of problems where there is a dependency between script and stylesheet and results would effectively
        get randomized based on which order the resources arrived. In Tiger file loads were effectively serialized by
        lower level components, which is why this regressed.

        Test: http/tests/local/stylesheet-and-script-load-order.html

        * dom/Document.cpp:
        (WebCore::Document::removePendingSheet):
        * dom/Tokenizer.h:
        (WebCore::Tokenizer::executeScriptsWaitingForStylesheets):
        * html/HTMLTokenizer.cpp:
        (WebCore::HTMLTokenizer::HTMLTokenizer):
        (WebCore::HTMLTokenizer::begin):
        (WebCore::HTMLTokenizer::executeScriptsWaitingForStylesheets):
        (WebCore::HTMLTokenizer::notifyFinished):
        * html/HTMLTokenizer.h:

LayoutTests:

        Reviewed by Kevin.

        Test for <rdar://problem/5444866>
        REGRESSION: missing text in Acrobat "Getting Started" screen due to change in load ordering of large resources

        * http/tests/local/stylesheet-and-script-load-order-expected.txt: Added.
        * http/tests/local/stylesheet-and-script-load-order.html: Added.
        * http/tests/local/stylesheet-dependent.js: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@25466 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/http/tests/local/stylesheet-and-script-load-order-expected.txt [new file with mode: 0644]
LayoutTests/http/tests/local/stylesheet-and-script-load-order.html [new file with mode: 0644]
LayoutTests/http/tests/local/stylesheet-dependent.js [new file with mode: 0644]
WebCore/ChangeLog
WebCore/dom/Document.cpp
WebCore/dom/Tokenizer.h
WebCore/html/HTMLTokenizer.cpp
WebCore/html/HTMLTokenizer.h