WebCore:
authormitz <mitz@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 19 Oct 2007 00:33:19 +0000 (00:33 +0000)
committermitz <mitz@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 19 Oct 2007 00:33:19 +0000 (00:33 +0000)
commit449235d88312fec5588ea4ab113d1afec672f14c
treee057b240aad208bf4a9129c10b46db488d6cf921
parente1b706aaa85c0320ba1cfa147c28de4090081eeb
WebCore:

        Reviewed by Adam Roben.

        - fix <rdar://problem/5313523>
        REGRESSION(Leopard): http/tests/incremental/slow-utf8-text.pl fails on Leopard

        * platform/network/mac/ResourceResponseMac.mm:
        (WebCore::ResourceResponse::doUpdateResourceResponse): Work around
        <rdar://problem/5321972> by testing for the case of a response
        with a MIME type of application/octet-stream and a Content-Type header
        starting with text/plain and setting the MIME type to text/plain in
        that case.

WebKit:

        Reviewed by Adam Roben.

        - fix <rdar://problem/5313523>
        REGRESSION(Leopard): http/tests/incremental/slow-utf8-text.pl fails on Leopard

        * WebCoreSupport/WebFrameLoaderClient.mm:
        (WebFrameLoaderClient::makeDocumentView): Changed to use _responseMIMEType.
        * WebView/WebDataSource.mm:
        (-[WebDataSource _MIMETypeOfResponse:]): Added. Works around
        <rdar://problem/5321972> by testing for the case of an NSHTTPURLResponse
        with a MIMEType of application/octet-stream and a Content-Type header
        starting with text/plain and returning text/plain as the MIME type in
        that case.
        (-[WebDataSource _responseMIMEType]): Added. Used to get the correct
        response MIME type.
        (-[WebDataSource _isDocumentHTML]): Changed to use _responseMIMEType.
        (-[WebDataSource _makeRepresentation]): Ditto.
        (-[WebDataSource mainResource]): Ditto.
        (-[WebDataSource subresources]): Changed to use _MIMETypeOfResponse and
        pass the MIME type explicitly.
        (-[WebDataSource subresourceForURL:]): Ditto.
        * WebView/WebDataSourcePrivate.h:
        * WebView/WebFrameView.mm:
        (-[WebFrameView _makeDocumentViewForDataSource:]): Changed to use
        _responseMIMEType.
        * WebView/WebResource.mm:
        (-[WebResource _initWithData:URL:response:MIMEType:]): Changed this
        method to take a MIME type instead of extracting it from the response,
        so that WebDataSource could pass the correct MIME type.
        * WebView/WebResourcePrivate.h:

WebKitTools:

        Reviewed by Adam Roben.

        - fix <rdar://problem/5313523>
        REGRESSION(Leopard): http/tests/incremental/slow-utf8-text.pl fails on Leopard

        * DumpRenderTree/mac/DumpRenderTree.mm:
        (dump): Changed to use _responseMIMEType.

LayoutTests:

        Reviewed by Adam Roben.

        - removing fixed test

        * platform/mac-leopard/Skipped:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@26758 268f45cc-cd09-0410-ab3c-d52691b4dbfc
13 files changed:
LayoutTests/ChangeLog
LayoutTests/platform/mac-leopard/Skipped
WebCore/ChangeLog
WebCore/platform/network/mac/ResourceResponseMac.mm
WebKit/ChangeLog
WebKit/WebCoreSupport/WebFrameLoaderClient.mm
WebKit/WebView/WebDataSource.mm
WebKit/WebView/WebDataSourcePrivate.h
WebKit/WebView/WebFrameView.mm
WebKit/WebView/WebResource.mm
WebKit/WebView/WebResourcePrivate.h
WebKitTools/ChangeLog
WebKitTools/DumpRenderTree/mac/DumpRenderTree.mm