2011-02-13 Jeremy Moskovich <jeremy@chromium.org>
authorjeremy@chromium.org <jeremy@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 13 Feb 2011 20:28:39 +0000 (20:28 +0000)
committerjeremy@chromium.org <jeremy@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 13 Feb 2011 20:28:39 +0000 (20:28 +0000)
commit88c869f76ca4c8bd8439ad5780633e7b6da96e2b
tree8d6e29ab11250d7d2455788952f259cd442d47f3
parent2cd60d7b6a1bc0742d76a17a3942cea0278d5e71
2011-02-13  Jeremy Moskovich  <jeremy@chromium.org>

        Reviewed by Adam Barth.

        Add a compile-time option to completely disable WebArchive support.
        https://bugs.webkit.org/show_bug.cgi?id=52712

        Add an ENABLE(WEB_ARCHIVE) compile-time setting and use it for all WebArchive code.
        Ports Affected:
            WebArchive support is currently enabled for all ports that define PLATFORM(CF) apart from Qt.
            This patch preserves this behavior except that it also disables support in the Chromium port.

        * wtf/Platform.h: Add ENABLE_WEB_ARCHIVE definition and turn it off explicitly for Qt & Chromium ports.
2011-02-13  Jeremy Moskovich  <jeremy@chromium.org>

        Reviewed by Adam Barth.

        Add a compile-time option to completely disable WebArchive support.
        https://bugs.webkit.org/show_bug.cgi?id=52712

        Add an ENABLE(WEB_ARCHIVE) compile-time setting and use it for all WebArchive code.

        ArchiveResource and ArchiveResourceCollection are notably still compiled in. They are used
        in Safari for functionality such as "Save Image As" and Image copy & paste independent of
        WebArchive support.

        Ports Affected:
            WebArchive support is currently enabled for all ports that define PLATFORM(CF) apart from Qt.
            This patch preserves this behavior except that it also disables support in the Chromium port.

        No behavior changes so no new tests.

        * WebCore.gyp/WebCore.gyp: Don't compile LegacyWebArchive.cpp and friends.
        * WebCore.pro: Don't compile ArchiveFactory.cpp in Qt port.
        * loader/DocumentLoader.cpp: Surround WebArchive code with #ifdef.
        (WebCore::DocumentLoader::commitLoad):
        (WebCore::DocumentLoader::setupForReplaceByMIMEType):
        (WebCore::DocumentLoader::archiveResourceForURL):
        * loader/DocumentLoader.h:
        * loader/FrameLoader.cpp:
        (WebCore::FrameLoader::loadURLIntoChildFrame):
        (WebCore::FrameLoader::stopAllLoaders):
        (WebCore::FrameLoader::finishedLoadingDocument):
        * loader/FrameLoader.h:
        * loader/ResourceLoader.cpp:
        (WebCore::ResourceLoader::start):
        * loader/archive/ArchiveFactory.cpp: Remove #ifdef since feature is now enabled/disabled wholesale.
        (WebCore::archiveMIMETypes):
        * page/Settings.cpp:
        * page/Settings.h:
        * platform/MIMETypeRegistry.cpp:
        (WebCore::initializeSupportedNonImageMimeTypes):
2011-02-13  Jeremy Moskovich  <jeremy@chromium.org>

        Reviewed by Adam Barth.

        Add a compile-time option to completely disable WebArchive support.
        https://bugs.webkit.org/show_bug.cgi?id=52712

        Add an ENABLE(WEB_ARCHIVE) compile-time setting and use it for all WebArchive code.

        * WebProcess/WebPage/WebPage.cpp:
        (WebKit::WebPage::updatePreferences):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@78439 268f45cc-cd09-0410-ab3c-d52691b4dbfc
16 files changed:
Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/wtf/Platform.h
Source/WebCore/ChangeLog
Source/WebCore/WebCore.gyp/WebCore.gyp
Source/WebCore/WebCore.pro
Source/WebCore/loader/DocumentLoader.cpp
Source/WebCore/loader/DocumentLoader.h
Source/WebCore/loader/FrameLoader.cpp
Source/WebCore/loader/FrameLoader.h
Source/WebCore/loader/ResourceLoader.cpp
Source/WebCore/loader/archive/ArchiveFactory.cpp
Source/WebCore/page/Settings.cpp
Source/WebCore/page/Settings.h
Source/WebCore/platform/MIMETypeRegistry.cpp
Source/WebKit2/ChangeLog
Source/WebKit2/WebProcess/WebPage/WebPage.cpp