1. 06 May, 2008 1 commit
  2. 05 May, 2008 1 commit
    • justin.garcia@apple.com's avatar
      WebCore: · 692743d4
      justin.garcia@apple.com authored
      2008-05-05  Justin Garcia  <justin.garcia@apple.com>
      
              Reviewed by Darin.
      
              <rdar://problem/5865171> REGRESSION: Creating a new quote places caret at beginning of quote instead of the end
              
              Disable Range mutation on document modifications in Tiger and Leopard Mail,
              since they do their own mutation which interferes with ours.
      
              * WebCore.base.exp:
              * dom/Document.cpp:
              (WebCore::Document::nodeChildrenChanged):
              (WebCore::Document::nodeWillBeRemoved):
              (WebCore::Document::textInserted):
              (WebCore::Document::textRemoved):
              (WebCore::Document::textNodesMerged):
              (WebCore::Document::textNodeSplit):
              * page/Settings.cpp:
              (WebCore::Settings::Settings):
              (WebCore::Settings::disableRangeMutationForOldAppleMail):
              * page/Settings.h:
              (WebCore::Settings::rangeMutationDisabledForOldAppleMail):
      
      WebKit/mac:
      
      2008-05-05  Justin Garcia  <justin.garcia@apple.com>
      
              Reviewed by Darin.
              
              <rdar://problem/5865171> REGRESSION: Creating a new quote places caret at beginning of quote instead of the end
      
              * WebView/WebView.mm:
              (-[WebView _updateSettingsFromPreferences:]): Disable Range mutation on changes to
              the document for Tiger and Leopard Mail.  There is code in Mail that does it, and
              the two interfere.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@32883 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      692743d4
  3. 01 May, 2008 1 commit
  4. 29 Apr, 2008 2 commits
    • ddkilzer@apple.com's avatar
      BUILD FIX for export of WTF::RefCounted<WebCore::FormData>::deref() · 7b3b129e
      ddkilzer@apple.com authored
              On the buildbot, this is a fatal error:
      
              ld: symbols names listed in -exported_symbols_list: WebKitBuild/Release/DerivedSources/WebCore/WebCore.exp not in linked objects
              __ZN3WTF10RefCountedIN7WebCore8FormDataEE5derefEv
              /usr/bin/libtool: internal link edit command failed
      
              Newer dev tools only produce a warning:
      
              ld warning: cannot export hidden symbol __ZN3WTF10RefCountedIN7WebCore8FormDataEE5derefEv from WebKitBuild/WebCore.build/Release/WebCore.build/Objects-normal/i386/DocumentLoader.o
      
              * WebCore.base.exp: Remove hidden symbol from export list.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@32716 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      7b3b129e
    • ddkilzer@apple.com's avatar
      JavaScriptCore: · 8fe65866
      ddkilzer@apple.com authored
      2008-04-29  Greg Bolsinga  <bolsinga@apple.com>
      
              Reviewed by Darin.
      
              Wrapped Dashboard code with ENABLE(DASHBOARD_SUPPORT)
      
              * wtf/Platform.h:
      
      WebCore:
      
      2008-04-29  Greg Bolsinga  <bolsinga@apple.com>
      
              Reviewed by Darin.
      
              Wrapped Dashboard code with ENABLE(DASHBOARD_SUPPORT)
      
              * DerivedSources.make:
              * WebCore.DashboardSupport.exp: Added.
              * WebCore.base.exp:
              * WebCore.xcodeproj/project.pbxproj:
              * bindings/js/JSDOMWindowCustom.cpp:
              (WebCore::JSDOMWindow::setLocation):
              * css/CSSComputedStyleDeclaration.cpp:
              (WebCore::):
              (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
              * css/CSSParser.cpp:
              (WebCore::CSSParser::parseValue):
              * css/CSSPrimitiveValue.cpp:
              (WebCore::CSSPrimitiveValue::cleanup):
              (WebCore::CSSPrimitiveValue::cssText):
              * css/CSSPropertyNames.in:
              * css/CSSStyleSelector.cpp:
              (WebCore::CSSStyleSelector::applyProperty):
              * css/DashboardRegion.h:
              * css/DashboardSupportCSSPropertyNames.in: Added.
              * dom/DOMImplementation.cpp:
              (WebCore::DOMImplementation::createDocument):
              * dom/Document.cpp:
              (WebCore::Document::Document):
              (WebCore::Document::importNode):
              * dom/Document.h:
              * html/CanvasRenderingContext2D.cpp:
              (WebCore::CanvasRenderingContext2D::fill):
              (WebCore::CanvasRenderingContext2D::stroke):
              (WebCore::CanvasRenderingContext2D::clip):
              * html/CanvasRenderingContext2D.h:
              * html/HTMLCanvasElement.cpp:
              * html/HTMLCanvasElement.h:
              * page/Chrome.cpp:
              * page/ChromeClient.h:
              * page/Frame.cpp:
              (WebCore::Frame::paint):
              * page/Frame.h:
              * page/FrameView.cpp:
              (WebCore::FrameView::layout):
              * page/FrameView.h:
              * page/Settings.cpp:
              (WebCore::Settings::Settings):
              * page/Settings.h:
              * page/mac/EventHandlerMac.mm:
              (WebCore::EventHandler::needsKeyboardEventDisambiguationQuirks):
              * page/mac/FrameMac.mm:
              * page/mac/WebDashboardRegion.h:
              * page/mac/WebDashboardRegion.m:
              * rendering/RenderLayer.cpp:
              (WebCore::RenderLayer::scrollToOffset):
              (WebCore::RenderLayer::setHasHorizontalScrollbar):
              (WebCore::RenderLayer::setHasVerticalScrollbar):
              (WebCore::RenderLayer::updateScrollInfoAfterLayout):
              * rendering/RenderObject.cpp:
              (WebCore::RenderObject::setStyle):
              * rendering/RenderObject.h:
              * rendering/RenderStyle.cpp:
              (WebCore::StyleRareNonInheritedData::operator==):
              (WebCore::RenderStyle::diff):
              * rendering/RenderStyle.h:
              * xml/XMLHttpRequest.cpp:
              (WebCore::XMLHttpRequest::send):
              (WebCore::XMLHttpRequest::setRequestHeader):
      
      WebKit/mac:
      
      2008-04-29  Greg Bolsinga  <bolsinga@apple.com>
      
              Reviewed by Darin.
      
              Wrapped Dashboard code with ENABLE(DASHBOARD_SUPPORT)
      
              * WebCoreSupport/WebChromeClient.h:
              * WebCoreSupport/WebChromeClient.mm:
              * WebView/WebClipView.m:
              (-[WebClipView scrollWheel:]):
              * WebView/WebHTMLView.mm:
              (-[WebHTMLView addMouseMovedObserver]):
              (-[WebHTMLView removeMouseMovedObserver]):
              (-[WebHTMLView acceptsFirstMouse:]):
              * WebView/WebUIDelegatePrivate.h:
              * WebView/WebView.mm:
              (-[WebViewPrivate init]):
              * WebView/WebViewPrivate.h:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@32700 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      8fe65866
  5. 28 Apr, 2008 2 commits
    • adele@apple.com's avatar
      WebCore: · f3d6b894
      adele@apple.com authored
      2008-04-28  Adele Peterson  <adele@apple.com>
      
              Reviewed by Dan Bernstein, Tim Hatcher, Anders Carlsson, and Darin Adler.
      
              WebCore part of fix for <rdar://problem/3709505>
              Safari should have a way to upload bundles from the file upload control (as zip)
      
              * WebCore.base.exp: Added symbols.
      
              * html/HTMLFormElement.cpp: (WebCore::HTMLFormElement::formData): Ask the application if a file will need to be replaced before it's uploaded.
                It will also give the replacement filename which is used to determine the correct mime-type and to construct the correct header.
      
              * loader/FrameLoader.cpp:
              (WebCore::FrameLoader::submitForm): Asks the application to generate any files for the form data before a form submission starts.
              (WebCore::FrameLoader::loadItem): ditto.
              * loader/ResourceLoader.cpp:
              (WebCore::ResourceLoader::didReceiveResponse): Tells the FormData from the request to remove any generated files if it needs to.
              (WebCore::ResourceLoader::didCancel): ditto.
              (WebCore::ResourceLoader::didFail): ditto.
      
              * platform/network/FormData.cpp:
              (WebCore::FormData::FormData): Initializes m_hasGeneratedFiles, which keeps track of whether there are files that will need to be removed.
              (WebCore::FormData::~FormData): Added.  Assert that there are no files that need to be removed, but if there are, release builds will still remove them here.
              (WebCore::FormData::appendFile): Passes along a shouldGenerateFile flag to the FormDataElement.
              (WebCore::FormData::generateFiles): Added. Iterates through the FormDataElements, and using the ChromeClient pointer, asks the application to
               create any compressed files so the FormDataElements can store the paths.
              (WebCore::FormData::removeGeneratedFilesIfNeeded): Added.  Removes generated files and their directories (if empty).
              * platform/network/FormData.h:
              (WebCore::FormDataElement::FormDataElement): Added a boolean to track whether the file will need to be generated,
               and a string to hold the path of the generated file.
      
              * platform/network/mac/FormDataStreamMac.mm:
              (WebCore::advanceCurrentStream): Uses the generated file path instead of the original file path when streaming the file.
              (WebCore::setHTTPBody): Uses the generated file path when determining the size of the file to be uploaded.
      
              * platform/FileSystem.h: Added directoryName.
              * platform/posix/FileSystemPOSIX.cpp: (WebCore::directoryName): Added.
              * platform/gtk/FileSystemGtk.cpp: (WebCore::directoryName): Added empty implementation.
              * platform/qt/FileSystemQt.cpp: (WebCore::directoryName): ditto.
              * platform/win/FileSystemWin.cpp: (WebCore::directoryName): ditto.
              * platform/wx/FileSystemWx.cpp: (WebCore::directoryName): ditto.
      
              Added new ChromeClient methods to give the application control over the file compression for uploading.
              * page/Chrome.cpp:
              (WebCore::ChromeClient::shouldReplaceWithGeneratedFileForUpload): Added a default implementation.
              (WebCore::ChromeClient::generateReplacementFile): ditto.
              * page/ChromeClient.h:
      
      WebKit/mac:
      
      2008-04-28  Adele Peterson  <adele@apple.com>
      
              Reviewed by Dan Bernstein, Tim Hatcher, Anders Carlsson, and Darin Adler.
      
              WebKit part of fix for <rdar://problem/3709505>
              Safari should have a way to upload bundles from the file upload control (as zip)
      
              Added UIDelegate methods to let the application handle generating replacement files for uploads.
              In this case, Safari will create archived files for bundles so they can be uploaded properly.
      
              * DefaultDelegates/WebDefaultUIDelegate.m:
              (-[WebDefaultUIDelegate webView:shouldReplaceUploadFile:usingGeneratedFilename:]):
              (-[WebDefaultUIDelegate webView:generateReplacementFile:]):
              * WebCoreSupport/WebChromeClient.h:
              * WebCoreSupport/WebChromeClient.mm:
              (WebChromeClient::shouldReplaceWithGeneratedFileForUpload):
              (WebChromeClient::generateReplacementFile):
              * WebView/WebUIDelegatePrivate.h:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@32666 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      f3d6b894
    • andersca@apple.com's avatar
      WebCore: · 321e25f7
      andersca@apple.com authored
      2008-04-28  Anders Carlsson  <andersca@apple.com>
      
              Reviewed by Sam, Mark, Adele and Darin.
      
              Add a (currently not called) method for opening the application cache database.
              
              * WebCore.base.exp:
              * loader/appcache/ApplicationCacheStorage.cpp:
              (WebCore::ApplicationCacheStorage::setCacheDirectory):
              (WebCore::ApplicationCacheStorage::openDatabase):
              * loader/appcache/ApplicationCacheStorage.h:
      
      WebKit/mac:
      
      2008-04-28  Anders Carlsson  <andersca@apple.com>
      
              Reviewed by Sam, Mark, Adele and Darin.
      
              Initialize the application cache path.
              
              * WebView/WebView.mm:
              (WebKitInitializeApplicationCachePathIfNecessary):
              (-[WebView _commonInitializationWithFrameName:groupName:]):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@32665 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      321e25f7
  6. 26 Apr, 2008 1 commit
    • weinig@apple.com's avatar
      WebCore: · 205006ed
      weinig@apple.com authored
      2008-04-26  Adam Barth  <hk9565@gmail.com>
      
              Reviewed by Adam Roben and Sam Weinig.
      
              Fixes bug http://bugs.webkit.org/show_bug.cgi?id=17331
              Fixes bug http://bugs.webkit.org/show_bug.cgi?id=16848
              
              Updates postMessage implementation to match HTML 5 specification:
              1) Adds origin parameter to postMessage.
              2) Removes domain and uri attributes of MessageEvent in favor of
                 origin attribute.
      
              In order to do this correctly, we need to distinguish between hosts and domains
              in the SecurityOrigin class. There are now three ways to compare security origins:
              1) isSameSchemeHostPort compares scheme, host, and port, and is used for postMessage
              2) equal compares all aspects of the security origin, and is used for hash keys
              3) canAccess understands the semantics of schemes such as file:// and data:// URLs,
                 and should be used for scripting access checks.
      
              Changed SecurityOrigin::toString() to generate identifiers that are suitable for 
              being used as a MessageEvent's origin property. In the future, they could be used 
              as database string identifiers as well. Re-used KURL parser to parse serialized 
              SecurityOrigins.
      
              Collin Jackson <collinj-webkit@collinjackson.com> also contributed to this patch.
              
              Tests: http/tests/security/postMessage/invalid-origin-throws-exception.html
                     http/tests/security/postMessage/javascript-page-still-sends-origin.html
                     http/tests/security/postMessage/origin-unaffected-by-base-tag.html
                     http/tests/security/postMessage/origin-unaffected-by-document-domain.html
                     http/tests/security/postMessage/target-origin.html
      
              * WebCore.base.exp:
              * bindings/js/JSDOMWindowCustom.cpp:
              (WebCore::JSDOMWindow::postMessage):
              * dom/Document.cpp:
              (WebCore::Document::domain):
              * dom/MessageEvent.cpp:
              (WebCore::MessageEvent::MessageEvent):
              (WebCore::MessageEvent::initMessageEvent):
              * dom/MessageEvent.h:
              (WebCore::MessageEvent::origin):
              * dom/MessageEvent.idl:
              * html/CanvasRenderingContext2D.cpp:
              (WebCore::CanvasRenderingContext2D::checkOrigin):
              (WebCore::CanvasRenderingContext2D::createPattern):
              * page/DOMWindow.cpp:
              (WebCore::DOMWindow::postMessage):
              * page/DOMWindow.h:
              * page/DOMWindow.idl:
              * platform/SecurityOrigin.cpp:
              (WebCore::SecurityOrigin::SecurityOrigin):
              (WebCore::SecurityOrigin::create):
              (WebCore::SecurityOrigin::createForFrame):
              (WebCore::SecurityOrigin::copy):
              (WebCore::SecurityOrigin::setDomainFromDOM):
              (WebCore::SecurityOrigin::canAccess):
              (WebCore::SecurityOrigin::isSecureTransitionTo):
              (WebCore::SecurityOrigin::toString):
              (WebCore::SecurityOrigin::createFromString):
              (WebCore::SecurityOrigin::createFromDatabaseIdentifier):
              (WebCore::SecurityOrigin::databaseIdentifier):
              (WebCore::SecurityOrigin::equal):
              (WebCore::SecurityOrigin::isSameSchemeHostPort):
              * platform/SecurityOrigin.h:
              (WebCore::SecurityOrigin::host):
              (WebCore::SecurityOrigin::domain):
              * platform/SecurityOriginHash.h:
              (WebCore::SecurityOriginTraits::deletedValue):
              * storage/DatabaseTracker.cpp:
              (WebCore::DatabaseTracker::hasEntryForDatabase):
              (WebCore::DatabaseTracker::originPath):
              (WebCore::DatabaseTracker::fullPathForDatabase):
              (WebCore::DatabaseTracker::populateOrigins):
              (WebCore::DatabaseTracker::databaseNamesForOrigin):
              (WebCore::DatabaseTracker::detailsForNameAndOrigin):
              (WebCore::DatabaseTracker::setDatabaseDetails):
              (WebCore::DatabaseTracker::setQuota):
              (WebCore::DatabaseTracker::addDatabase):
              (WebCore::DatabaseTracker::deleteOrigin):
              (WebCore::DatabaseTracker::deleteDatabase):
      
      WebKit/mac:
      
      2008-04-20 Adam Barth <hk9565@gmail.com>
      
              Reviewed by Adam Roben and Sam Weinig.
      
              Updated WebSecurityOrigin to match new SecurityOrigin API.
      
              Collin Jackson <collinj-webkit@collinjackson.com> also contributed to this patch.
      
              * Storage/WebSecurityOrigin.mm:
              (-[WebSecurityOrigin host]):
              (-[WebSecurityOrigin domain]):
              * Storage/WebSecurityOriginPrivate.h:
      
      WebKit/win:
      
      2008-04-26  Adam Barth <hk9565@gmail.com>
      
              Reviewed by Adam Roben and Sam Weinig.
      
              Renamed "domain" method to "host" to match SecurityOrigin.
      
              * Interfaces/IWebSecurityOrigin.idl:
              * WebSecurityOrigin.cpp:
              (WebSecurityOrigin::host):
              * WebSecurityOrigin.h:
      
      WebKitTools:
      
      2008-04-26  Adam Barth <hk9565@gmail.com>
      
              Reviewed by Adam Roben and Sam Weinig.
      
              Updates LayoutTestController to use host instead of domain.
      
              Collin Jackson <collinj-webkit@collinjackson.com> also contributed to this patch.
      
              * DumpRenderTree/mac/LayoutTestControllerMac.mm:
              (LayoutTestController::setDatabaseQuota):
              * DumpRenderTree/mac/UIDelegate.mm:
              (-[UIDelegate webView:frame:exceededDatabaseQuotaForSecurityOrigin:database:]):
      
      LayoutTests:
      
      2008-04-26  Adam Barth  <hk9565@gmail.com>
      
              Reviewed by Adam Roben and Sam Weinig.
      
              Update LayoutTests for new postMessage API.
      
              Collin Jackson <collinj-webkit@collinjackson.com> also contributed to this patch.
      
              * http/tests/security/postMessage/domain-and-uri-unaffected-by-base-tag-expected.txt: Removed.
              * http/tests/security/postMessage/domain-and-uri-unaffected-by-base-tag.html: Removed.
              * http/tests/security/postMessage/domain-unaffected-by-document-domain-expected.txt: Removed.
              * http/tests/security/postMessage/domain-unaffected-by-document-domain.html: Removed.
              * http/tests/security/postMessage/invalid-origin-throws-exception-expected.txt: Added.
              * http/tests/security/postMessage/invalid-origin-throws-exception.html: Added.
              * http/tests/security/postMessage/javascript-page-still-sends-domain-expected.txt: Removed.
              * http/tests/security/postMessage/javascript-page-still-sends-domain.html: Removed.
              * http/tests/security/postMessage/javascript-page-still-sends-origin-expected.txt: Copied from LayoutTests/http/tests/security/postMessage/javascript-page-still-sends-domain-expected.txt.
              * http/tests/security/postMessage/javascript-page-still-sends-origin.html: Copied from LayoutTests/http/tests/security/postMessage/javascript-page-still-sends-domain.html.
              * http/tests/security/postMessage/origin-unaffected-by-base-tag-expected.txt: Copied from LayoutTests/http/tests/security/postMessage/domain-and-uri-unaffected-by-base-tag-expected.txt.
              * http/tests/security/postMessage/origin-unaffected-by-base-tag.html: Copied from LayoutTests/http/tests/security/postMessage/domain-and-uri-unaffected-by-base-tag.html.
              * http/tests/security/postMessage/origin-unaffected-by-document-domain-expected.txt: Copied from LayoutTests/http/tests/security/postMessage/domain-unaffected-by-document-domain-expected.txt.
              * http/tests/security/postMessage/origin-unaffected-by-document-domain.html: Copied from LayoutTests/http/tests/security/postMessage/domain-unaffected-by-document-domain.html.
              * http/tests/security/postMessage/target-origin-expected.txt: Added.
              * http/tests/security/postMessage/target-origin.html: Added.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@32597 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      205006ed
  7. 25 Apr, 2008 2 commits
    • andersca@apple.com's avatar
      WebCore: · c3a561b4
      andersca@apple.com authored
      2008-04-25  Anders Carlsson  <andersca@apple.com>
      
              Reviewed by Sam.
      
              Add and honor offlineWebApplicationCacheEnabled setting.
              
              * WebCore.base.exp:
              * loader/DocumentLoader.cpp:
              (WebCore::DocumentLoader::scheduleApplicationCacheLoad):
              * loader/MainResourceLoader.cpp:
              (WebCore::MainResourceLoader::load):
              * loader/appcache/ApplicationCacheGroup.cpp:
              (WebCore::ApplicationCacheGroup::selectCache):
              (WebCore::ApplicationCacheGroup::selectCacheWithoutManifestURL):
              * page/Settings.cpp:
              (WebCore::Settings::Settings):
              (WebCore::Settings::setOfflineWebApplicationCacheEnabled):
              * page/Settings.h:
              (WebCore::Settings::offlineWebApplicationCacheEnabled):
      
      WebKit/mac:
      
      2008-04-25  Anders Carlsson  <andersca@apple.com>
      
              Reviewed by Sam.
      
              Add offlineWebApplicationCacheEnabled preference.
              
              * WebView/WebPreferenceKeysPrivate.h:
              * WebView/WebPreferences.m:
              (+[WebPreferences initialize]):
              (-[WebPreferences offlineWebApplicationCacheEnabled]):
              (-[WebPreferences setOfflineWebApplicationCacheEnabled:]):
              * WebView/WebPreferencesPrivate.h:
              * WebView/WebView.mm:
              (-[WebView _updateSettingsFromPreferences:]):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@32581 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      c3a561b4
    • mrowe@apple.com's avatar
      2008-04-24 Mark Rowe <mrowe@apple.com> · 2b2670b7
      mrowe@apple.com authored
              Rubber-stamped by Oliver Hunt.
      
              * WebCore.base.exp: Remove two symbols from the export list that don't need to be exported.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@32534 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      2b2670b7
  8. 24 Apr, 2008 3 commits
    • mrowe@apple.com's avatar
      Remove code for calculating the glyph cache size. · f248276b
      mrowe@apple.com authored
      Reviewed by Sam Weinig.
      
      WebCore:
      * WebCore.base.exp: Remove unused symbol.
      * platform/graphics/mac/FontCacheMac.mm: Remove code that is unused now that we do not compute the glyph cache size.
      * platform/mac/WebCoreSystemInterface.h: Remove unused symbol.
      * platform/mac/WebCoreSystemInterface.mm: Ditto.
      
      WebKit:
      * WebCoreSupport/WebSystemInterface.m:
      (InitWebCoreSystemInterface): Remove unused symbol.
      
      WebKitSystemInterface:
      * WebKitSystemInterface.h: Remove unused symbol.
      * libWebKitSystemInterfaceLeopard.a:
      * libWebKitSystemInterfaceTiger.a:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@32530 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      f248276b
    • beidson@apple.com's avatar
      2008-04-24 Brady Eidson <beidson@apple.com> · ab528fba
      beidson@apple.com authored
              Reviewed by Teh Mitzpettel
      
              Make it so PageGroups know what their own name is.
      
              * WebCore.base.exp:
      
              * page/Page.cpp:
              (WebCore::Page::setGroupName):
              (WebCore::Page::groupName):
              * page/Page.h:
      
              * page/PageGroup.cpp: Move the PageGroupMap into the PageGroup class.
              (WebCore::PageGroup::PageGroup): Added a c'tor that takes the group name as an argument instead of
                the initial Page.
              (WebCore::PageGroup::pageGroup): Handles creating and mapping names to groups
              * page/PageGroup.h:
              (WebCore::PageGroup::name):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@32524 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      ab528fba
    • mitz@apple.com's avatar
      WebCore: · 576e84e8
      mitz@apple.com authored
              Reviewed by Darin Adler.
      
              - preparation for https://bugs.webkit.org/show_bug.cgi?id=3729
                <rdar://problem/4036353> REGRESSION: arrow keys move insertion bar backwards in RTL text
      
              The three main changes in this patch are:
      
              1) Making all inline boxes know their bidi level, instead of just text
                 boxes knowing whether their bidi level is odd or even. This is
                 required for the next change.
      
              2) Replacing RenderObject::inlineBox() with
                 Position::getInlineBoxAndOffset() in recognition of the fact that the
                 inline box containing the primary caret for a position in a given
                 node may belong to a different node's renderer.
      
              3) Changing RenderObject::caretRect() to take an InlineBox parameter,
                 and changing callers to call VisiblePosition::caretRect(), which
                 locates the inline box, then calls caretRect() on the renderer for
                 that box. This, combined with the previous change, ensures that the
                 primary caret is rendered at the right place for positions that
                 lie on a directionality boundary.
      
              Test: platform/mac/editing/input/caret-primary-bidi.html
      
              * WebCore.base.exp: Added the VisiblePosition(Node*, int, EAffinity)
              constructor and VisiblePosition::caretRect(), and sorted.
      
              * dom/Position.cpp:
              (WebCore::nextRenderedEditable): Adjusted for the removal of
              RenderObject::inlineBox().
              (WebCore::previousRenderedEditable): Ditto.
              (WebCore::Position::rendersInDifferentPosition): Ditto.
              (WebCore::Position::getInlineBoxAndOffset): Added. Gets the inline box
              and the offset within that box at which the primary caret for this
              position should render.
      
              * dom/Position.h:
      
              * editing/DeleteSelectionCommand.cpp:
              (WebCore::DeleteSelectionCommand::mergeParagraphs): Changed to call
              VisiblePosition::caretRect() instead of calling the RenderObject method.
      
              * editing/SelectionController.cpp:
              (WebCore::caretY): Ditto.
              (WebCore::SelectionController::xPosForVerticalArrowNavigation): Ditto.
              (WebCore::SelectionController::layout): Ditto.
      
              * editing/VisiblePosition.cpp:
              (WebCore::VisiblePosition::caretRect): Changed to call
              getInlineBoxAndOffset() to get the correct inline box and call the
              renderer for that box.
      
              * editing/VisiblePosition.h:
              (WebCore::VisiblePosition::getInlineBoxAndOffset): Added convenience
              methods for getting the inline box and caret offset for a visible
              position, accounting for its affinity.
      
              * editing/visible_units.cpp:
              (WebCore::rootBoxForLine): Changed to use getInlineBoxAndOffset()
              instead of RenderObject::inlineBox().
              (WebCore::startPositionForLine):
              (WebCore::endPositionForLine):
              (WebCore::previousLinePosition): Ditto.
              (WebCore::nextLinePosition): Ditto.
      
              * page/AccessibilityObject.cpp:
              (WebCore::updateAXLineStartForVisiblePosition): Ditto.
      
              * page/Frame.cpp:
              (WebCore::Frame::firstRectForRange): Ditto.
      
              * rendering/InlineBox.cpp:
              (WebCore::InlineBox::caretMinOffset): Changed to forward to the
              renderer.
              (WebCore::InlineBox::caretMaxOffset): Ditto.
              * rendering/InlineBox.h: Replaced the m_reversed bit, intended for use
              in InlineTextBox only, with six bits of the bidi level of the box,
              intended for use in all leaf inline boxes.
              (WebCore::InlineBox::InlineBox): Added missing initializer for
              m_dirOverride and initialized the bidi level.
              (WebCore::InlineBox::bidiLevel): Added this accessor.
              (WebCore::InlineBox::setBidiLevel): Ditto.
              (WebCore::InlineBox::direction): Ditto.
              (WebCore::InlineBox::caretLeftmostOffset): Added this convenience
              method.
              (WebCore::InlineBox::caretRightmostOffset): Ditto.
      
              * rendering/InlineTextBox.cpp: Replaced all references to m_reversed
              with checking of direction().
              (WebCore::InlineTextBox::selectionRect):
              (WebCore::InlineTextBox::placeEllipsisBox):
              (WebCore::InlineTextBox::paint):
              (WebCore::InlineTextBox::paintSelection):
              (WebCore::InlineTextBox::paintCompositionBackground):
              (WebCore::InlineTextBox::paintSpellingOrGrammarMarker):
              (WebCore::InlineTextBox::paintTextMatchMarker):
              (WebCore::InlineTextBox::textPos):
              (WebCore::InlineTextBox::offsetForPosition):
              (WebCore::InlineTextBox::positionForOffset):
      
              * rendering/RenderBR.cpp: Removed inlineBox().
              * rendering/RenderBR.h: Ditto.
      
              * rendering/RenderBox.cpp:
              (WebCore::RenderBox::caretRect): Changed to take an inline box and
              account for the direction of the box (or the renderer) in positioning
              the caret: in right-to-left boxes, the "before" position is to the right
              while "after" is to the left.
              * rendering/RenderBox.h:
      
              * rendering/RenderFlow.cpp:
              (WebCore::RenderFlow::caretRect): Updated the signature.
              * rendering/RenderFlow.h:
      
              * rendering/RenderObject.cpp:
              (WebCore::RenderObject::caretRect): Updated the signature.
              (WebCore::RenderObject::caretMaxOffset): Changed to return the child
              node count (or 1 if there are no children) for replaced elements, such
              as <select>s.
              * rendering/RenderObject.h:
      
              * rendering/RenderReplaced.cpp: Removed caretMinOffset() and
              caretMaxOffset() because the base class implementation does the right
              thing for replaced objects now.
              * rendering/RenderReplaced.h:
      
              * rendering/RenderSVGInlineText.cpp:
              (WebCore::RenderSVGInlineText::caretRect): Updated the signature.
              (WebCore::RenderSVGInlineText::positionForCoordinates): Updated for
              the change from m_reversed to direction().
              * rendering/RenderSVGInlineText.h:
      
              * rendering/RenderText.cpp:
              (WebCore::RenderText::caretRect): Changed to take an inline box and
              removed the code that used to find the inline for the given position.
              Changed use of m_reversed to use direction().
              (WebCore::RenderText::position): Changed use of m_reversed to use
              direction().
              * rendering/RenderText.h:
      
              * rendering/RenderTextControl.cpp:
              (WebCore::RenderTextControl::textWithHardLineBreaks): Adjusted for the
              removal of RenderObject::inlineBox().
      
              * rendering/RenderTreeAsText.cpp:
              (WebCore::writeTextRun): Changed to use direction() instead of
              m_reversed.
      
              * rendering/SVGInlineTextBox.cpp: Ditto.
              (WebCore::SVGInlineTextBox::calculateGlyphBoundaries):
              (WebCore::SVGInlineTextBoxClosestCharacterToPositionWalker::chunkPortionCallback):
              (WebCore::SVGInlineTextBox::svgCharacterHitsPosition):
      
              * rendering/SVGRenderTreeAsText.cpp: Ditto.
              (WebCore::writeSVGInlineTextBox):
      
              * rendering/SVGRootInlineBox.cpp: Ditto.
              (WebCore::svgTextRunForInlineTextBox):
              (WebCore::cummulatedWidthOrHeightOfTextChunk):
              (WebCore::SVGRootInlineBox::buildLayoutInformationForTextBox):
      
              * rendering/bidi.cpp:
              (WebCore::RenderBlock::constructLine): Made this function set the
              bidi level on all leaf boxes.
      
              * svg/SVGTextContentElement.cpp: Changed to use direction() instead of
              m_reversed.
              (WebCore::cumulativeCharacterRangeLength):
              (WebCore::SVGInlineTextBoxQueryWalker::chunkPortionCallback):
      
      WebKit/mac:
      
              Reviewed by Darin Adler.
      
              - preparation for https://bugs.webkit.org/show_bug.cgi?id=3729
                <rdar://problem/4036353> REGRESSION: arrow keys move insertion bar backwards in RTL text
      
              * WebView/WebFrame.mm:
              (-[WebFrame _caretRectAtNode:offset:affinity:]): Changed to use
              VisiblePosition::caretRect() instead of the RenderObject method which
              was removed.
      
      LayoutTests:
      
              Reviewed by Darin Adler.
      
              - test the visual position of the primary caret in bidirectional text
      
              * platform/mac/editing/input/caret-primary-bidi-expected.txt: Added.
              * platform/mac/editing/input/caret-primary-bidi.html: Added.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@32508 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      576e84e8
  9. 21 Apr, 2008 1 commit
    • eric@webkit.org's avatar
      Reviewed by eseidel. Landed by eseidel. · 14774f44
      eric@webkit.org authored
              Add FrameLoader::policyDocumentLoader, and change
              provisionalDocumentLoader to have a const signature to be
              consistent with documentLoader and activeDocumentLoader.
      
              * WebCore.base.exp:
              * WebCore.order:
              * loader/FrameLoader.cpp:
              (WebCore::FrameLoader::policyDocumentLoader):
              (WebCore::FrameLoader::provisionalDocumentLoader):
              * loader/FrameLoader.h:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@32320 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      14774f44
  10. 19 Apr, 2008 1 commit
    • beidson@apple.com's avatar
      WebCore: · b2da40e5
      beidson@apple.com authored
      2008-04-19  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Tim Hatcher
      
              Add LocalStorageDatabasePath to the settings for the location of persistent local storage.
      
              * WebCore.base.exp:
      
              * page/Settings.cpp:
              (WebCore::Settings::setLocalStorageDatabasePath):
              * page/Settings.h:
              (WebCore::Settings::localStorageDatabasePath):
      
      WebKit/mac:
      
      2008-04-19  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Tim Hatcher
      
              Add a WebPreference for the path of the local storage persistent store.
      
              * WebView/WebPreferenceKeysPrivate.h:
      
              * WebView/WebPreferences.m:
              (-[WebPreferences _localStorageDatabasePath]):
              (-[WebPreferences _setLocalStorageDatabasePath:]):
              * WebView/WebPreferencesPrivate.h:
      
              * WebView/WebView.mm:
              (-[WebView _preferencesChangedNotification:]):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@32261 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      b2da40e5
  11. 18 Apr, 2008 1 commit
    • eric@webkit.org's avatar
      Reviewed by beth. · 25a1cdf3
      eric@webkit.org authored
              Rename Frame::renderer() to contentRenderer() and fix uses.
      
              * WebCore.base.exp:
              * editing/Editor.cpp:
              (WebCore::Editor::respondToChangedContents):
              * loader/FrameLoader.cpp:
              (WebCore::FrameLoader::gotoAnchor):
              * page/DragController.cpp:
              (WebCore::DragController::canProcessDrag):
              (WebCore::DragController::mayStartDragAtEventLocation):
              (WebCore::DragController::startDrag):
              * page/EventHandler.cpp:
              (WebCore::EventHandler::eventMayStartDrag):
              (WebCore::EventHandler::updateSelectionForMouseDrag):
              (WebCore::EventHandler::hitTestResultAtPoint):
              (WebCore::EventHandler::hoverTimerFired):
              (WebCore::EventHandler::handleDrag):
              * page/Frame.cpp:
              (WebCore::Frame::selectionLayoutChanged):
              (WebCore::Frame::contentRenderer):
              (WebCore::Frame::paint):
              (WebCore::Frame::markAllMatchesForText):
              (WebCore::Frame::documentAtPoint):
              * page/Frame.h:
              * page/FrameView.cpp:
              (WebCore::FrameView::~FrameView):
              (WebCore::FrameView::adjustViewSize):
              (WebCore::FrameView::layout):
              (WebCore::FrameView::scheduleRelayoutOfSubtree):
              (WebCore::FrameView::needsLayout):
              (WebCore::FrameView::setNeedsLayout):
              (WebCore::FrameView::updateControlTints):
              * rendering/RenderTreeAsText.cpp:
              (WebCore::write):
              * svg/graphics/SVGImage.cpp:
              (WebCore::SVGImage::nativeImageForCurrentFrame):
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@32231 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      25a1cdf3
  12. 14 Apr, 2008 1 commit
    • beidson@apple.com's avatar
      WebCore: · 21c04acd
      beidson@apple.com authored
      2008-04-14  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Anders
      
              Lay the underpinnings for LocalStorage.
      
              For now, this just exposes window.localStorage to the dom which returns an in-memory Storage object, much
              like SessionStorage.  The primary difference at this point is that the object returned is shared globally,
              and isn't copied for new top-level browsing contexts like SessionStorage.
      
              Later, I'll add proper event dispatch and a persistent storage backing.
      
              * GNUmakefile.am:
              * WebCore.base.exp:
              * WebCore.pro:
              * WebCore.vcproj/WebCore.vcproj:
              * WebCore.xcodeproj/project.pbxproj:
              * WebCoreSources.bkl:
      
              * bindings/js/JSDOMWindowCustom.cpp:
              (WebCore::JSDOMWindow::mark): Mark the optionalLocalStorage
      
              * page/DOMWindow.cpp:
              (WebCore::DOMWindow::clear):
              (WebCore::DOMWindow::localStorage):
              * page/DOMWindow.h:
              (WebCore::DOMWindow::optionalLocalStorage):
      
              * storage/LocalStorage.cpp: Added.
              (WebCore::LocalStorage::sharedLocalStorage):
              (WebCore::LocalStorage::LocalStorage):
              (WebCore::LocalStorage::storageArea):
              (WebCore::LocalStorage::itemChanged):
              (WebCore::LocalStorage::itemRemoved):
              (WebCore::LocalStorage::dispatchStorageEvent):
              * storage/LocalStorage.h: Added.
      
              * storage/SessionStorage.cpp: Refactor to use the client interface for event dispatching for sessionStorage objects
              (WebCore::SessionStorage::SessionStorage):
              (WebCore::SessionStorage::copy):
              (WebCore::SessionStorage::storageArea):
              (WebCore::SessionStorage::itemChanged):
              (WebCore::SessionStorage::itemRemoved):
              (WebCore::SessionStorage::dispatchStorageEvent):
              * storage/SessionStorage.h:
      
              * storage/StorageArea.cpp: Add a client parameter, and call to the client when an item is changed or removed.
              (WebCore::StorageArea::create):
              (WebCore::StorageArea::StorageArea):
              (WebCore::StorageArea::copy):
              (WebCore::StorageArea::setItem):
              (WebCore::StorageArea::removeItem):
              (WebCore::StorageArea::setClient):
              * storage/StorageArea.h:
              (WebCore::StorageArea::page):
              (WebCore::StorageArea::securityOrigin):
      
              * storage/StorageAreaClient.h: Added.  Break out "itemChanged" and "itemRemoved" to a StorageAreaClient
                This way, both SessionStorage and LocalStorage areas can have different behavior on changes with
                that behavior managed from a central location.
              (WebCore::StorageAreaClient::~StorageAreaClient):
              (WebCore::StorageAreaClient::StorageAreaClient):
              (WebCore::StorageAreaClient::itemChanged):
              (WebCore::StorageAreaClient::itemRemoved):
      
      LayoutTests:
      
      2008-04-14  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Anders
      
              As underpinnings for LocalStorage are laid, it is exposed to the dom - update the relevant layout tests.
      
              * fast/dom/Window/window-properties-expected.txt:
              * storage/domstorage/window-attributes-exist-expected.txt:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31893 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      21c04acd
  13. 11 Apr, 2008 2 commits
    • hyatt@apple.com's avatar
      WebCore: · 2c814c47
      hyatt@apple.com authored
      2008-04-11  David Hyatt  <hyatt@apple.com>
      
              Rename CachedResource's ref/deref methods to addClient/removeClient.  This matches the new
              StyleImage class and is a more accurate description of what those methods really do.
      
              Reviewed by olliej
      
              * WebCore.base.exp:
              * css/CSSCursorImageValue.cpp:
              (WebCore::CSSCursorImageValue::updateIfSVGCursorIsUsed):
              * css/CSSFontFaceSource.cpp:
              (WebCore::CSSFontFaceSource::CSSFontFaceSource):
              (WebCore::CSSFontFaceSource::~CSSFontFaceSource):
              * css/CSSImageValue.cpp:
              (WebCore::CSSImageValue::~CSSImageValue):
              (WebCore::CSSImageValue::image):
              * css/CSSImportRule.cpp:
              (WebCore::CSSImportRule::~CSSImportRule):
              (WebCore::CSSImportRule::insertedIntoParent):
              * dom/ProcessingInstruction.cpp:
              (WebCore::ProcessingInstruction::~ProcessingInstruction):
              (WebCore::ProcessingInstruction::checkStyleSheet):
              (WebCore::ProcessingInstruction::parseStyleSheet):
              * dom/XMLTokenizer.cpp:
              (WebCore::XMLTokenizer::~XMLTokenizer):
              (WebCore::XMLTokenizer::endElementNs):
              (WebCore::XMLTokenizer::notifyFinished):
              * html/CanvasPattern.cpp:
              (WebCore::CanvasPattern::CanvasPattern):
              (WebCore::CanvasPattern::~CanvasPattern):
              * html/HTMLImageLoader.cpp:
              (WebCore::HTMLImageLoader::~HTMLImageLoader):
              (WebCore::HTMLImageLoader::setImage):
              (WebCore::HTMLImageLoader::updateFromElement):
              * html/HTMLLinkElement.cpp:
              (WebCore::HTMLLinkElement::~HTMLLinkElement):
              (WebCore::HTMLLinkElement::process):
              * html/HTMLScriptElement.cpp:
              (WebCore::HTMLScriptElement::~HTMLScriptElement):
              (WebCore::HTMLScriptElement::parseMappedAttribute):
              (WebCore::HTMLScriptElement::insertedIntoDocument):
              (WebCore::HTMLScriptElement::removedFromDocument):
              (WebCore::HTMLScriptElement::notifyFinished):
              * html/HTMLTokenizer.cpp:
              (WebCore::HTMLTokenizer::reset):
              (WebCore::HTMLTokenizer::scriptHandler):
              (WebCore::HTMLTokenizer::notifyFinished):
              * loader/CachedCSSStyleSheet.cpp:
              (WebCore::CachedCSSStyleSheet::addClient):
              * loader/CachedCSSStyleSheet.h:
              * loader/CachedFont.cpp:
              (WebCore::CachedFont::addClient):
              * loader/CachedFont.h:
              * loader/CachedImage.cpp:
              (WebCore::CachedImage::addClient):
              * loader/CachedImage.h:
              * loader/CachedResource.cpp:
              (WebCore::CachedResource::addClient):
              (WebCore::CachedResource::removeClient):
              * loader/CachedResource.h:
              * loader/CachedScript.cpp:
              (WebCore::CachedScript::addClient):
              * loader/CachedScript.h:
              * loader/CachedXBLDocument.h:
              * loader/CachedXSLStyleSheet.cpp:
              (WebCore::CachedXSLStyleSheet::addClient):
              * loader/CachedXSLStyleSheet.h:
              * loader/mac/UserStyleSheetLoader.cpp:
              (UserStyleSheetLoader::UserStyleSheetLoader):
              (UserStyleSheetLoader::~UserStyleSheetLoader):
              * platform/mac/ClipboardMac.mm:
              (WebCore::ClipboardMac::setDragImage):
              * rendering/RenderImage.cpp:
              (WebCore::RenderImage::~RenderImage):
              (WebCore::RenderImage::setCachedImage):
              * rendering/RenderListMarker.cpp:
              (WebCore::RenderListMarker::~RenderListMarker):
              (WebCore::RenderListMarker::setStyle):
              * rendering/RenderObject.cpp:
              (WebCore::RenderObject::updateBackgroundImages):
              (WebCore::RenderObject::arenaDelete):
              * rendering/RenderStyle.cpp:
              (WebCore::StyleCachedImage::addClient):
              (WebCore::StyleCachedImage::removeClient):
              * svg/SVGImageLoader.cpp:
              (WebCore::SVGImageLoader::updateFromElement):
              * xml/XSLImportRule.cpp:
              (WebCore::XSLImportRule::~XSLImportRule):
              (WebCore::XSLImportRule::loadSheet):
      
      WebKit/mac:
      
      2008-04-11  David Hyatt  <hyatt@apple.com>
      
              Rename CachedResource ref/deref methods to addClient/removeClient.
      
              Reviewed by olliej
      
              * WebView/WebHTMLView.mm:
              (-[WebHTMLViewPrivate dealloc]):
              (-[WebHTMLViewPrivate finalize]):
              (-[WebHTMLViewPrivate clear]):
              (-[WebHTMLView setPromisedDragTIFFDataSource:WebCore::]):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31834 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      2c814c47
    • andersca@apple.com's avatar
      2008-04-11 Anders Carlsson <andersca@apple.com> · 471c8007
      andersca@apple.com authored
              Fix release build.
              
              * WebCore.base.exp:
              
              * loader/archive/ArchiveResource.h:
              (WebCore::ArchiveResource::response):
              This should be const.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31828 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      471c8007
  14. 08 Apr, 2008 1 commit
    • weinig@apple.com's avatar
      JavaScriptCore: · 41dbaab8
      weinig@apple.com authored
      2008-04-04  Sam Weinig  <sam@webkit.org>
      
              Reviewed by Geoffrey Garen.
      
              First step in implementing the "split window"
      
              - Add a GlobalThisValue to ExecState which should be used 
                in places that used to implement the "use the global object
                as this if null" rule.
              - Factor out lookupGetter/lookupSetter into virtual methods 
                on JSObject so that they can be forwarded.
              - Make defineGetter/defineSetter virtual methods for the same
                reason.
              - Have PrototypeReflexiveFunction store the globalObject used
                to create it so that it can be used to get the correct thisObject
                for eval.
      
              * API/JSObjectRef.cpp:
              (JSObjectCallAsFunction):
              * JavaScriptCore.exp:
              * kjs/Activation.h:
              * kjs/ExecState.cpp:
              (KJS::ExecState::ExecState):
              (KJS::GlobalExecState::GlobalExecState):
              * kjs/ExecState.h:
              (KJS::ExecState::globalThisValue):
              * kjs/ExecStateInlines.h:
              (KJS::ExecState::ExecState):
              (KJS::FunctionExecState::FunctionExecState):
              * kjs/JSGlobalObject.cpp:
              (KJS::JSGlobalObject::reset):
              (KJS::JSGlobalObject::toGlobalObject):
              * kjs/JSGlobalObject.h:
              (KJS::JSGlobalObject::JSGlobalObjectData::JSGlobalObjectData):
              (KJS::JSGlobalObject::JSGlobalObject):
              * kjs/array_instance.cpp:
              (KJS::CompareWithCompareFunctionArguments::CompareWithCompareFunctionArguments):
              (KJS::compareWithCompareFunctionForQSort):
              * kjs/array_object.cpp:
              (KJS::arrayProtoFuncSort):
              (KJS::arrayProtoFuncFilter):
              (KJS::arrayProtoFuncMap):
              (KJS::arrayProtoFuncEvery):
              (KJS::arrayProtoFuncForEach):
              (KJS::arrayProtoFuncSome):
              * kjs/function.cpp:
              (KJS::FunctionImp::callAsFunction):
              (KJS::ActivationImp::toThisObject):
              (KJS::globalFuncEval):
              (KJS::PrototypeReflexiveFunction::PrototypeReflexiveFunction):
              (KJS::PrototypeReflexiveFunction::mark):
              * kjs/function.h:
              (KJS::PrototypeReflexiveFunction::cachedGlobalObject):
              * kjs/function_object.cpp:
              (KJS::functionProtoFuncApply):
              (KJS::functionProtoFuncCall):
              * kjs/nodes.cpp:
              (KJS::ExpressionNode::resolveAndCall):
              (KJS::FunctionCallValueNode::evaluate):
              (KJS::LocalVarFunctionCallNode::inlineEvaluate):
              (KJS::ScopedVarFunctionCallNode::inlineEvaluate):
              (KJS::FunctionCallBracketNode::evaluate):
              (KJS::FunctionCallDotNode::inlineEvaluate):
              * kjs/object.cpp:
              (KJS::JSObject::call):
              (KJS::JSObject::put):
              (KJS::tryGetAndCallProperty):
              (KJS::JSObject::lookupGetter):
              (KJS::JSObject::lookupSetter):
              (KJS::JSObject::toThisObject):
              (KJS::JSObject::toGlobalObject):
              (KJS::JSObject::fillGetterPropertySlot):
              * kjs/object.h:
              * kjs/object_object.cpp:
              (KJS::objectProtoFuncLookupGetter):
              (KJS::objectProtoFuncLookupSetter):
              * kjs/string_object.cpp:
              (KJS::replace):
      
      WebCore:
      
      2008-04-04  Sam Weinig  <sam@webkit.org>
      
              Reviewed by Geoffrey Garen.
      
              First step in implementing the "split window"
      
              - This patch takes the first step in changing the window navigation model
                from clearing the window properties on navigation, to replacing
                an inner window.  This is necessary to safely perform security checks
                using the lexical global object.
      
                This first step adds a new class called JSDOMWindowWrapper, which wraps
                the real window object.  All JS calls that would go to the window object
                now go to it, which it forwards to the current inner window.  To accomplish
                this, the wrapper window is used as the ThisValue wherever the window was used
                before.
      
              * WebCore.base.exp:
              * WebCore.xcodeproj/project.pbxproj:
              * bindings/js/JSDOMWindowBase.cpp:
              (WebCore::JSDOMWindowBase::JSDOMWindowBase):
              (WebCore::JSDOMWindowBase::clear): Reset the wrapper windows prototype too.
              (WebCore::JSDOMWindowBase::toThisObject):
              (WebCore::JSDOMWindowBase::wrapper):
              (WebCore::windowProtoFuncAToB):
              (WebCore::windowProtoFuncBToA):
              (WebCore::windowProtoFuncOpen):
              (WebCore::windowProtoFuncSetTimeout):
              (WebCore::windowProtoFuncClearTimeout):
              (WebCore::windowProtoFuncSetInterval):
              (WebCore::windowProtoFuncAddEventListener):
              (WebCore::windowProtoFuncRemoveEventListener):
              (WebCore::windowProtoFuncShowModalDialog):
              (WebCore::windowProtoFuncNotImplemented):
              (WebCore::toJS):
              * bindings/js/JSDOMWindowBase.h:
              Fix to expect the wrapper as the thisObj.
              * bindings/js/JSDOMWindowCustom.cpp:
              (WebCore::JSDOMWindow::postMessage):
              (WebCore::toDOMWindow):
              * bindings/js/JSDOMWindowWrapper.cpp: Added.
              (WebCore::):
              (WebCore::JSDOMWindowWrapper::JSDOMWindowWrapper):
              (WebCore::JSDOMWindowWrapper::~JSDOMWindowWrapper):
              (WebCore::JSDOMWindowWrapper::mark):
              (WebCore::JSDOMWindowWrapper::className):
              (WebCore::JSDOMWindowWrapper::getOwnPropertySlot):
              (WebCore::JSDOMWindowWrapper::put):
              (WebCore::JSDOMWindowWrapper::deleteProperty):
              (WebCore::JSDOMWindowWrapper::getPropertyNames):
              (WebCore::JSDOMWindowWrapper::getPropertyAttributes):
              (WebCore::JSDOMWindowWrapper::defineGetter):
              (WebCore::JSDOMWindowWrapper::defineSetter):
              (WebCore::JSDOMWindowWrapper::lookupGetter):
              (WebCore::JSDOMWindowWrapper::lookupSetter):
              (WebCore::JSDOMWindowWrapper::toGlobalObject):
              (WebCore::JSDOMWindowWrapper::impl):
              (WebCore::JSDOMWindowWrapper::disconnectFrame):
              (WebCore::JSDOMWindowWrapper::clear):
              (WebCore::toJS):
              * bindings/js/JSDOMWindowWrapper.h: Added.
              (WebCore::JSDOMWindowWrapper::innerWindow):
              (WebCore::JSDOMWindowWrapper::setInnerWindow):
              (WebCore::JSDOMWindowWrapper::classInfo):
              Forward methods to the innerWindow.
              * bindings/js/JSHTMLDocumentCustom.cpp:
              (WebCore::JSHTMLDocument::open):
              * bindings/js/ScheduledAction.cpp:
              (WebCore::ScheduledAction::execute):
              * bindings/js/kjs_events.cpp:
              (WebCore::JSAbstractEventListener::handleEvent):
              * bindings/js/kjs_proxy.cpp:
              (WebCore::KJSProxy::~KJSProxy):
              (WebCore::KJSProxy::evaluate):
              (WebCore::KJSProxy::clear):
              (WebCore::KJSProxy::initScript):
              (WebCore::KJSProxy::clearDocumentWrapper):
              (WebCore::KJSProxy::processingUserGesture):
              (WebCore::KJSProxy::attachDebugger):
              * bindings/js/kjs_proxy.h:
              (WebCore::KJSProxy::haveWindowWrapper):
              (WebCore::KJSProxy::windowWrapper):
              (WebCore::KJSProxy::globalObject):
              (WebCore::KJSProxy::initScriptIfNeeded):
              Hold onto the wrapper window instead of global object.  As a convenience,
              keep the globalObject() as a forward to the inner window.
              * bindings/objc/DOMUtility.mm:
              (KJS::createDOMWrapper):
              * bindings/scripts/CodeGeneratorJS.pm:
              * dom/Document.cpp:
              (WebCore::Document::domWindow):
              * dom/Document.h:
              (WebCore::Document::defaultView):
              * loader/FrameLoader.cpp:
              (WebCore::FrameLoader::dispatchWindowObjectAvailable):
              * page/DOMWindow.idl:
              * page/Frame.cpp:
              (WebCore::Frame::~Frame):
              (WebCore::Frame::pageDestroyed):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31746 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      41dbaab8
  15. 03 Apr, 2008 1 commit
  16. 01 Apr, 2008 1 commit
    • darin@apple.com's avatar
      2008-04-01 Darin Adler <darin@apple.com> · 98ac4575
      darin@apple.com authored
              Reviewed by Sam and Antti.
      
              - fix <rdar://problem/5829565> paste performance slowed down with the Range Acid3 changes
      
              Added a new class, RangeBoundaryPoint, to use for range boundary points. The "truth" of
              the offset is now stored as a node pointer, and the offset is computed as and when needed.
              This allows us to efficiently update when the DOM tree is changed -- computation of the
              node offsets is deferred until the Range is used later.
      
              * WebCore.base.exp: Export nodeIndex().
      
              * WebCore.xcodeproj/project.pbxproj: Added RangeBoundaryPoint.h, removed NodeWithIndexBefore.h
              and NodeWIthIndexAfter.h. Also let Xcode tweak the file formatting.
      
              * dom/ContainerNode.cpp:
              (WebCore::ContainerNode::childrenChanged): Pass fewer arguments to Document.
      
              * dom/Document.cpp:
              (WebCore::Document::nodeChildrenChanged): Pass fewer arguments to Range.
              (WebCore::Document::nodeWillBeRemoved): Pass node to range as a raw node pointer; no need for
              the index.
              * dom/Document.h: Take fewer arguments.
      
              * dom/NodeWithIndexAfter.h: Removed.
              * dom/NodeWithIndexBefore.h: Removed.
      
              * dom/Range.cpp:
              (WebCore::Range::Range): Changed to use the new RangeBoundaryPoint constructor.
              (WebCore::Range::create): Updated to use RangeBoundaryPoint instead of Position.
              (WebCore::Range::~Range): Ditto.
              (WebCore::Range::startContainer): Ditto.
              (WebCore::Range::startOffset): Ditto.
              (WebCore::Range::endContainer): Ditto.
              (WebCore::Range::endOffset): Ditto.
              (WebCore::Range::commonAncestorContainer): Ditto.
              (WebCore::Range::collapsed): Ditto.
              (WebCore::Range::setStart): Ditto.
              (WebCore::Range::setEnd): Ditto.
              (WebCore::Range::collapse): Ditto.
              (WebCore::Range::isPointInRange): Ditto.
              (WebCore::Range::comparePoint): Ditto.
              (WebCore::Range::compareNode): Ditto.
              (WebCore::Range::compareBoundaryPoints): Ditto.
              (WebCore::Range::boundaryPointsValid): Ditto.
              (WebCore::Range::intersectsNode): Ditto.
              (WebCore::Range::processContents): Ditto.
              (WebCore::Range::cloneContents): Ditto.
              (WebCore::Range::insertNode): Updated to use RangeBoundaryPoint. Also simplified the code
              at the end that updates the range -- not all of it is needed now since most of the fixup
              is done automatically by the range document mutation machinery. The one bit that remains
              is arguably a bug, but we need to keep it to keep passing Acid3 until we get clarification
              that it is indeed a bug (and then Acid3 will probably have to change).
              (WebCore::Range::toString): Update to use RangeBoundaryPoint instead of Position.
              (WebCore::Range::text): Ditto.
              (WebCore::Range::createContextualFragment): Ditto.
              (WebCore::Range::detach): Ditto.
              (WebCore::Range::checkNodeWOffset): Changed case where the offset is a node offset to
              be more efficient by using childNode instead of childNodeCount, and also return the node
              before which is needed to set the value of a RangeBoundaryPoint.
              (WebCore::Range::cloneRange): Ditto.
              (WebCore::Range::setStartAfter): Ditto.
              (WebCore::Range::setEndBefore): Ditto.
              (WebCore::Range::setEndAfter): Ditto.
              (WebCore::Range::selectNode): Ditto.
              (WebCore::Range::selectNodeContents): Ditto.
              (WebCore::Range::surroundContents): Ditto.
              (WebCore::Range::setStartBefore): Ditto.
              (WebCore::Range::checkDeleteExtract): Ditto.
              (WebCore::Range::containedByReadOnly): Ditto.
              (WebCore::Range::firstNode): Ditto.
              (WebCore::Range::editingStartPosition): Ditto.
              (WebCore::Range::pastLastNode): Ditto.
              (WebCore::Range::addLineBoxRects): Ditto.
              (WebCore::Range::formatForDebugger): Ditto.
              (WebCore::Range::maxStartOffset): Ditto.
              (WebCore::Range::maxEndOffset): Ditto.
              (WebCore::boundaryNodeChildrenChanged): Updated to use RangeBoundaryPoint instead of
              Position. Also changed name and changed to just call invalidateOffset.
              (WebCore::Range::nodeChildrenChanged): Changed to take just a container node.
              (WebCore::boundaryNodeWillBeRemoved): Updated to use RangeBoundaryPoint instead of
              Position. Also changed name and changed to update childBefore.
              (WebCore::Range::nodeWillBeRemoved): Changed to just take a Node*.
              (WebCore::boundaryTextInserted): Updated to use RangeBoundaryPoint instead of
              Position. Also changed name.
              (WebCore::Range::textInserted): Ditto.
              (WebCore::boundaryTextRemoved): Ditto.
              (WebCore::Range::textRemoved): Ditto.
              (WebCore::boundaryTextNodesMerged): Ditto.
              (WebCore::Range::textNodesMerged): Ditto.
              (WebCore::boundaryTextNodesSplit): Ditto.
              (WebCore::Range::textNodeSplit): Ditto.
      
              * dom/Range.h: Updated to use RangeBoundaryPoint instead of Position.
      
              * dom/RangeBoundaryPoint.h: Added.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31549 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      98ac4575
  17. 28 Mar, 2008 4 commits
    • beidson@apple.com's avatar
      WebCore: · 1f3e63cb
      beidson@apple.com authored
      2008-03-28  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Darin Adler
      
              More Kit->Core WebArchive changes.
      
              Create an archive from the current selection in a frame
      
              * WebCore.base.exp:
      
              * loader/archive/cf/LegacyWebArchive.cpp:
              (WebCore::LegacyWebArchive::createFromSelection):
              * loader/archive/cf/LegacyWebArchive.h:
      
      WebKit/mac:
      
      2008-03-28  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Darin Adler
      
              More Kit->Core WebArchive changes.
      
              Create an archive from the current selection in a frame
      
              * WebView/WebArchiver.mm: Remove one more *undeclared* method, the last method will drop off
                easily in a followup
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31419 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      1f3e63cb
    • beidson@apple.com's avatar
      WebCore: · fe921ca2
      beidson@apple.com authored
      2008-03-28  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Sam Weinig
      
              WebArchive saga continues - Can now make archives from ranges in WebCore
      
              Again, previous layout test coverage exercised this code
      
              * WebCore.base.exp:
      
              * editing/markup.cpp:
              (WebCore::createFullMarkup): Added a "markup from range" variant that copies the previous WebKit implementation
              * editing/markup.h:
      
              * loader/archive/cf/LegacyWebArchive.cpp:
              (WebCore::LegacyWebArchive::create):
              * loader/archive/cf/LegacyWebArchive.h:
      
      WebKit/mac:
      
      2008-03-28  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Sam Weinig
      
              WebArchive saga continues - Can now make archives from ranges in WebCore
      
              * DOM/WebDOMOperations.mm:
              (-[DOMRange webArchive]):
              (-[DOMRange markupString]):
      
              * WebView/WebArchiver.h: Remove newly obsolete [WebArchiver archiveRange:]
              * WebView/WebArchiver.mm:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31412 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      fe921ca2
    • beidson@apple.com's avatar
      WebCore: · c170591d
      beidson@apple.com authored
      2008-03-28  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Sam Weinig
      
              More Kit->Core webarchive code movement
      
              * WebCore.base.exp:
              * editing/markup.cpp:
              (WebCore::createFullMarkup): Replacement for [DOMNode markupString], creating full markup at this node including 
                the document type string, which the WebKit implementation did indirectly
              * editing/markup.h:
      
      WebKit/mac:
      
      2008-03-28  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Sam Weinig
      
              More Kit->Core webarchive code movement
      
              * DOM/WebDOMOperations.mm:
              (-[DOMNode markupString]): Call createFullMarkup() instead
      
              * WebView/WebFrame.mm: Remove obsolete _markupStringFromNode
              * WebView/WebFrameInternal.h: Ditto
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31409 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      c170591d
    • beidson@apple.com's avatar
      WebCore: · f4058d68
      beidson@apple.com authored
      2008-03-28  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Darin
      
              "Yet another transitional step" to empty out WebKit-based code for archiving.
      
              With this patch, the key operation of "Creating a WebArchive rooted at a single Node" takes place
              entirely within WebCore, and opens the door to saving WebArchives on Windows.
      
              This is another "zero behavior change" patch, and current editing/ and webarchive/ layout tests
              covered the relevant code
      
              * WebCore.base.exp:
              * loader/archive/cf/LegacyWebArchive.cpp:
              (WebCore::LegacyWebArchive::create):
              * loader/archive/cf/LegacyWebArchive.h:
      
      WebKit/mac:
      
      2008-03-28  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Darin
      
              "Yet another transitional step" to empty out WebKit-based code for archiving.
      
              With this patch, the key operation of "Creating a WebArchive rooted at a single Node" takes place
              entirely within WebCore, and opens the door to saving WebArchives on Windows.
      
              * DOM/WebDOMOperations.mm:
              * WebView/WebArchiver.mm:
              (+[WebArchiver _archiveWithMarkupString:fromFrame:nodes:]):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31400 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      f4058d68
  18. 27 Mar, 2008 2 commits
    • beidson@apple.com's avatar
      WebCore: · 59712ce1
      beidson@apple.com authored
      2008-03-27  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Adam Roben
      
              Move [WebDataSource mainResource] and [WebDataSource subresources] down into WebCore
              as the push to core-ify WebArchives continues.
      
              This patch also introduces a behavior change.  WebCore allows ArchiveResources with null or empty data.  
              WebKit has had the inexplicable distinction of allowing empty Data in a WebResource, but not null.  
              Since WebResource is API, I decided to leave it be to avoid a behavior change.  But internally created resources 
              (as in "while archiving a page") are accepting of null or empty data.
      
              This actually fixes a bug where not all subframes are archived, and resulted in a layout test change.
      
              * WebCore.base.exp:
              * loader/DocumentLoader.cpp:
              (WebCore::DocumentLoader::archiveResourceForURL): Make this const
              (WebCore::DocumentLoader::mainResource):
              (WebCore::DocumentLoader::subresource): Make this const and relocate
              (WebCore::DocumentLoader::getSubresources):
              * loader/DocumentLoader.h:
      
      WebKit/mac:
      
      2008-03-27  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Adam Roben
      
              Move [WebDataSource mainResource] and [WebDataSource subresources] down into WebCore
              as the push to core-ify WebArchives continues.
      
              This patch also introduces a behavior change.  WebCore allows ArchiveResources with null or empty data.  
              WebKit has had the inexplicable distinction of allowing empty Data in a WebResource, but not null.  
              Since WebResource is API, I decided to leave it be to avoid a behavior change.  But internally created resources 
              (as in "while archiving a page") are accepting of null or empty data.
      
              This actually fixes a bug where not all subframes are archived, and resulted in a layout test change. 
      
              * WebView/WebDataSource.mm:
              (-[WebDataSource mainResource]): Call DocumentLoader implementation
              (-[WebDataSource subresources]): Ditto
              * WebView/WebFrame.mm: Remove [WebFrame _getAllResourceDatas:andResponses:] as its only caller is obsolete
              * WebView/WebFrameInternal.h:
      
      LayoutTests:
      
      2008-03-27  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Adam Roben
      
              Updated results, as we now more consistently archive empty frames/empty resources
      
              * webarchive/archive-empty-frame-source-expected.txt:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31384 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      59712ce1
    • ddkilzer@apple.com's avatar
      Removed whitespace that crept in from r31357. · 66deecf1
      ddkilzer@apple.com authored
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31371 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      66deecf1
  19. 26 Mar, 2008 4 commits
    • mrowe@apple.com's avatar
      Mac build fix. · af2d5c36
      mrowe@apple.com authored
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31363 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      af2d5c36
    • beidson@apple.com's avatar
      WebCore: · a4fb38f9
      beidson@apple.com authored
      2008-03-26  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Darin
      
              When we create a WebArchive, we walk every node from some starting point, asking each node
              along the way "What are your subresource URLs?"
      
              That logic is currently in DOMNode in WebKitMac - this patch moves that ability down into
              WebCore::Node
      
              * WebCore.base.exp:
              
              * dom/Node.cpp:
              (WebCore::Node::getSubresourceURLs):
              (WebCore::Node::getSubresourceAttributeStrings):  Virtual and empty.  Subclasses of Node that have 
                subresources will override it.
      
              * dom/ProcessingInstruction.cpp:
              (WebCore::ProcessingInstruction::getSubresourceAttributeStrings):
              * dom/ProcessingInstruction.h:
              * html/HTMLBodyElement.cpp:
              (WebCore::HTMLBodyElement::getSubresourceAttributeStrings):
              * html/HTMLBodyElement.h:
              * html/HTMLEmbedElement.cpp:
              (WebCore::HTMLEmbedElement::getSubresourceAttributeStrings):
              * html/HTMLEmbedElement.h:
              * html/HTMLImageElement.cpp:
              (WebCore::HTMLImageElement::getSubresourceAttributeStrings):
              * html/HTMLImageElement.h:
              * html/HTMLInputElement.cpp:
              (WebCore::HTMLInputElement::getSubresourceAttributeStrings):
              * html/HTMLInputElement.h:
              * html/HTMLLinkElement.cpp:
              (WebCore::HTMLLinkElement::getSubresourceAttributeStrings):
              * html/HTMLLinkElement.h:
              * html/HTMLObjectElement.cpp:
              (WebCore::HTMLObjectElement::getSubresourceAttributeStrings):
              * html/HTMLObjectElement.h:
              * html/HTMLParamElement.cpp:
              (WebCore::HTMLParamElement::getSubresourceAttributeStrings):
              * html/HTMLParamElement.h:
              * html/HTMLScriptElement.cpp:
              (WebCore::HTMLScriptElement::getSubresourceAttributeStrings):
              * html/HTMLScriptElement.h:
              * html/HTMLTableCellElement.cpp:
              (WebCore::HTMLTableCellElement::getSubresourceAttributeStrings):
              * html/HTMLTableCellElement.h:
              * html/HTMLTableElement.cpp:
              (WebCore::HTMLTableElement::getSubresourceAttributeStrings):
              * html/HTMLTableElement.h:
              * svg/SVGCursorElement.cpp:
              (WebCore::SVGCursorElement::getSubresourceAttributeStrings):
              * svg/SVGCursorElement.h:
              * svg/SVGFEImageElement.cpp:
              (WebCore::SVGFEImageElement::getSubresourceAttributeStrings):
              * svg/SVGFEImageElement.h:
              * svg/SVGImageElement.cpp:
              (WebCore::SVGImageElement::getSubresourceAttributeStrings):
              * svg/SVGImageElement.h:
              * svg/SVGScriptElement.cpp:
              (WebCore::SVGScriptElement::getSubresourceAttributeStrings):
              * svg/SVGScriptElement.h:
      
      WebKit/mac:
      
      2008-03-26  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Darin
      
              When we create a WebArchive, we walk every node from some starting point, asking each node
              along the way "What are your subresource URLs?"
      
              That logic is currently in DOMNode in WebKitMac - this patch moves that ability down into
              WebCore::Node
      
              * DOM/WebDOMOperations.mm:
              (-[DOMNode _subresourceURLs]): One generic DOMNode method can now handle all DOMNodes by
                calling into individual WebCore::Node implementations
              * DOM/WebDOMOperationsPrivate.h:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31357 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      a4fb38f9
    • beidson@apple.com's avatar
      WebCore: · b00be861
      beidson@apple.com authored
      2008-03-26  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Mark Rowe
      
              Part of the continued push to move WebArchive-related code down to WebCore, this
              moves [WebDataSource subresourceForURL:] down to DocumentLoader->subresource()
      
              * WebCore.base.exp:
              * loader/DocumentLoader.cpp:
              (WebCore::DocumentLoader::subresource): Create an ArchiveResource from a CachedResource if it exists
                Otherwise, fallback to an ArchiveResource from the current Archive if any.  Otherwise, return null
              * loader/DocumentLoader.h:
      
              * loader/archive/ArchiveResource.cpp:
              (WebCore::ArchiveResource::create):
              (WebCore::ArchiveResource::ArchiveResource):
              * loader/archive/ArchiveResource.h:
      
      WebKit/mac:
      
      2008-03-26  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Mark Rowe
      
              Part of the continued push to move WebArchive-related code down to WebCore, this
              moves [WebDataSource subresourceForURL:] down to DocumentLoader->subresource()
      
              * WebView/WebDataSource.mm:
              (-[WebDataSource subresourceForURL:]): Call through to the DocumentLoader 
      
              * WebView/WebFrame.mm: Remove [WebFrame _getData:andResponse:forURL:], as its only use
                has now been ported down to WebCore
              * WebView/WebFrameInternal.h:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31355 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      b00be861
    • eric@webkit.org's avatar
      Reviewed by darin. · 4f9b2dd1
      eric@webkit.org authored
              Fix, makes us pass Test 70
              XML documents should be strict about encoding checks
              http://bugs.webkit.org/show_bug.cgi?id=17079
      
              Test: fast/encoding/invalid-xml.html
      
              * WebCore.base.exp:
              * dom/XMLTokenizer.cpp:
              (WebCore::XMLTokenizer::write):
              * loader/CachedFont.cpp:
              (WebCore::CachedFont::ensureSVGFontData):
              * loader/TextResourceDecoder.cpp:
              (WebCore::TextResourceDecoder::TextResourceDecoder):
              (WebCore::TextResourceDecoder::decode):
              * loader/TextResourceDecoder.h:
              * platform/text/TextCodec.h:
              (WebCore::TextCodec::decode):
              * platform/text/TextCodecICU.cpp:
              (WebCore::TextCodecICU::decodeToBuffer):
              (WebCore::ErrorCallbackSetter::ErrorCallbackSetter):
              (WebCore::ErrorCallbackSetter::~ErrorCallbackSetter):
              (WebCore::TextCodecICU::decode):
              * platform/text/TextCodecICU.h:
              * platform/text/TextCodecLatin1.cpp:
              * platform/text/TextCodecLatin1.h:
              * platform/text/TextCodecUTF16.cpp:
              * platform/text/TextCodecUTF16.h:
              * platform/text/TextCodecUserDefined.cpp:
              * platform/text/TextCodecUserDefined.h:
              * platform/text/TextDecoder.cpp:
              (WebCore::TextDecoder::checkForBOM):
              * platform/text/TextDecoder.h:
              (WebCore::TextDecoder::decode):
              * platform/text/TextEncoding.cpp:
              (WebCore::TextEncoding::decode):
              * platform/text/TextEncoding.h:
              (WebCore::TextEncoding::decode):
              * platform/text/mac/TextCodecMac.cpp:
              (WebCore::TextCodecMac::decode):
              * platform/text/mac/TextCodecMac.h:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31316 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      4f9b2dd1
  20. 25 Mar, 2008 2 commits
    • beidson@apple.com's avatar
      WebCore: · fe11a74c
      beidson@apple.com authored
      2008-03-25  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Adam Roben
      
              <rdar://problem/5819308> - View Source is empty when view webarchives
      
              * WebCore.base.exp:
              * loader/DocumentLoader.cpp:
              (WebCore::DocumentLoader::setParsedArchiveData):
              (WebCore::DocumentLoader::parsedArchiveData):
              * loader/DocumentLoader.h:
      
              * loader/FrameLoader.cpp:
              (WebCore::FrameLoader::finishedLoadingDocument): Set the archive's MainResource data as the parsedArchiveData
                in the DocumentLoader
      
      WebKit/mac:
      
      2008-03-25  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Adam Roben
      
              <rdar://problem/5819308> - View Source is empty when view webarchives
      
              * WebCore.base.exp:
              * loader/DocumentLoader.cpp:
              (WebCore::DocumentLoader::setParsedArchiveData):
              (WebCore::DocumentLoader::parsedArchiveData):
              * loader/DocumentLoader.h:
      
              * loader/FrameLoader.cpp:
              (WebCore::FrameLoader::finishedLoadingDocument): Set the archive's MainResource data as the parsedArchiveData
                in the DocumentLoader
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31293 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      fe11a74c
    • beidson@apple.com's avatar
      WebCore: · f36a4a19
      beidson@apple.com authored
      2008-03-25  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Darin
      
              <rdar://problem/4516169> - Support WebArchives on Windows
              And pave the way for many future WebArchive bug fixes and enhancements
      
              This patch accomplishes two main goals:
              1 - Consolidates much of the spread out WebKitMac archive code into one place in WebCore.  This allows for cleaner refactoring 
                  in the future as well as adding more archive formats with ease.
              2 - Hooks up WebArchive support on Windows.  Safari-style .webarchive files are nothing more than property lists readable by
                  CoreFoundation.  While there are still some outstanding issues, including an NSKeyedArchiver chunk of data for the 
                  ResourceResponse for each resource, this patch manually parses through the property list on CoreFoundation platforms and
                  gets many archives loading on Windows
      
              My goal for this first cut was zero behavior change.  As such, I went for a direct port of the WebKitMac code.  There will be
              opportunities for redesign and refactoring as followups.
      
              * WebCore.base.exp:
      
              * loader/DocumentLoader.cpp:
              (WebCore::DocumentLoader::setupForReplaceByMIMEType): Ported from WebKitMac, WebDataSource
              (WebCore::DocumentLoader::addAllArchiveResources):
              (WebCore::DocumentLoader::addArchiveResource):
              (WebCore::DocumentLoader::archiveResourceForURL):
              (WebCore::DocumentLoader::popArchiveForSubframe):
              (WebCore::DocumentLoader::clearArchiveResources):
              * loader/DocumentLoader.h:
      
              * loader/FrameLoader.cpp: Moved WebFrameLoaderClient and WebFrame code down into their more appropriate FrameLoader home
              (WebCore::FrameLoader::FrameLoader):
              (WebCore::FrameLoader::setDefersLoading):
              (WebCore::FrameLoader::deliverArchivedResourcesAfterDelay):
              (WebCore::FrameLoader::archiveResourceDeliveryTimerFired):
              (WebCore::FrameLoader::loadURLIntoChildFrame):
              (WebCore::FrameLoader::loadArchive):
              (WebCore::FrameLoader::scheduleArchiveLoad):
              (WebCore::FrameLoader::stopAllLoaders):
              (WebCore::FrameLoader::cancelPendingArchiveLoad):
              (WebCore::FrameLoader::isArchiveLoadPending):
              (WebCore::FrameLoader::finishedLoadingDocument):
              * loader/FrameLoader.h:
      
              * loader/ResourceLoader.cpp:
              (WebCore::ResourceLoader::load):
      
              * loader/archive/Archive.h: Generic "Archive of web resources" class that is only useful when subclassed.  
                  Contains a MainResource, subresources, and Archives for subframes
              (WebCore::Archive::mainResource):
              (WebCore::Archive::subresources):
              (WebCore::Archive::subframeArchives):
              (WebCore::Archive::setMainResource):
              (WebCore::Archive::addSubresource):
              (WebCore::Archive::addSubframeArchive):
      
              * loader/archive/ArchiveFactory.cpp: A class that will take raw archive data and the MIMEtype, and create the
                  appropriate Archive class for it.  Additionally it handles registering the known MIMEtypes for all known archive formats
              (WebCore::archiveFactoryCreate):
              (WebCore::archiveMIMETypes):
              (WebCore::ArchiveFactory::isArchiveMimeType):
              (WebCore::ArchiveFactory::create):
              (WebCore::ArchiveFactory::registerKnownArchiveMIMETypes):
              * loader/archive/ArchiveFactory.h:
      
              * loader/archive/ArchiveResource.cpp: Analog to "WebResource" in WebKitMac.  Contains the data and other important
                  attributes of an archived resource
              (WebCore::ArchiveResource::create):
              (WebCore::ArchiveResource::ArchiveResource):
              (WebCore::ArchiveResource::response):
              * loader/archive/ArchiveResource.h:
              (WebCore::ArchiveResource::data):
              (WebCore::ArchiveResource::url):
              (WebCore::ArchiveResource::mimeType):
              (WebCore::ArchiveResource::textEncoding):
              (WebCore::ArchiveResource::frameName):
              (WebCore::ArchiveResource::ignoreWhenUnarchiving):
              (WebCore::ArchiveResource::shouldIgnoreWhenUnarchiving):
      
              * loader/archive/ArchiveResourceCollection.cpp: Analog of "WebUnarchivingState" in WebKitMac.  Contains a hash of
                  all the resources for every frame in an archive, and contains the archives for each subframe needed to load a multi-frame archive
              (WebCore::ArchiveResourceCollection::ArchiveResourceCollection):
              (WebCore::ArchiveResourceCollection::addAllResources):
              (WebCore::ArchiveResourceCollection::addResource):
              (WebCore::ArchiveResourceCollection::archiveResourceForURL):
              (WebCore::ArchiveResourceCollection::popSubframeArchive):
              * loader/archive/ArchiveResourceCollection.h:
      
              * loader/archive/cf/LegacyWebArchive.cpp: Subclass of Archive specifically for Webkit's Objective-C based ".webarchive" format.
                  Mostly a collection of static methods involved in parsing and serializing a WebKit-style .webarchive.  Is mostly supported
                  for any CF platform.
              (WebCore::createPropertyListRepresentationFromResource):
              (WebCore::createPropertyListRep):
              (WebCore::createResourceResponseFromPropertyListData):
              (WebCore::createResource):
              (WebCore::LegacyWebArchive::create):
              (WebCore::LegacyWebArchive::LegacyWebArchive):
              (WebCore::LegacyWebArchive::init):
              (WebCore::LegacyWebArchive::extract):
              (WebCore::LegacyWebArchive::rawDataRepresentation):
              (WebCore::createResourceResponseFromMacArchivedData):
              (WebCore::propertyListDataFromResourceResponse):
              * loader/archive/cf/LegacyWebArchive.h:
              * loader/archive/cf/LegacyWebArchiveMac.mm:
              (WebCore::createResourceResponseFromMacArchivedData):
              (WebCore::propertyListDataFromResourceResponse):
      
              * platform/network/mac/ResourceRequest.h:
              * platform/network/mac/ResourceRequestMac.mm:
              (WebCore::ResourceRequest::applyWebArchiveHackForMail): Tweak the resource request for Mac clients when loading WebArchives
      
      WebKit:
      
      2008-03-25  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Darin
      
              <rdar://problem/4516169> - Support WebArchives on Windows
      
              * WebKit.xcodeproj/project.pbxproj:
      
      WebKit/mac:
      
      2008-03-25  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Darin
      
              <rdar://problem/4516169> - Support WebArchives on Windows
              And paves the way for many future WebArchive bug fixes and enhancements
      
              This change moves most of the real workhorse code about WebArchives into WebCore.  It maintains 
              1-to-1 relationships between a few objects in WebCore and WebKit.  Such as:
               * WebArchive <-> LegacyWebArchive
               * WebResource <-> ArchiveResource
               * WebUnarchivingState <-> ArchiveResourceCollection
       
              The other biggest changes involve many FrameLoaderClient methods that existed soley for WebArchives 
              and now exist in WebCore
      
              * WebCoreSupport/WebFrameLoaderClient.mm:
              (WebFrameLoaderClient::clearUnarchivingState): Emptied - to be removed in a followup patch
              (WebFrameLoaderClient::finalSetupForReplace):
              (WebFrameLoaderClient::setDefersLoading):
              (WebFrameLoaderClient::willUseArchive):
              (WebFrameLoaderClient::isArchiveLoadPending):
              (WebFrameLoaderClient::cancelPendingArchiveLoad):
              (WebFrameLoaderClient::clearArchivedResources):
              (WebFrameLoaderClient::createFrame):
      
              * WebView/WebArchive.mm:
              (+[WebArchivePrivate initialize]):
              (-[WebArchivePrivate init]):
              (-[WebArchivePrivate initWithCoreArchive:]):
              (-[WebArchivePrivate coreArchive]):
              (-[WebArchivePrivate setCoreArchive:]):
              (-[WebArchivePrivate dealloc]):
              (-[WebArchivePrivate finalize]):
              (-[WebArchive init]):
              (-[WebArchive initWithMainResource:subresources:subframeArchives:]):
              (-[WebArchive initWithData:]):
              (-[WebArchive initWithCoder:]):
              (-[WebArchive encodeWithCoder:]):
              (-[WebArchive mainResource]):
              (-[WebArchive subresources]):
              (-[WebArchive subframeArchives]):
              (-[WebArchive data]):
              (-[WebArchive _initWithCoreLegacyWebArchive:WebCore::]):
              (-[WebArchive WebCore::]):
              * WebView/WebArchiveInternal.h: Added.
      
              * WebView/WebDataSource.mm:
              (-[WebDataSourcePrivate dealloc]):
              (-[WebDataSource _addSubframeArchives:]):
              (-[WebDataSource _documentFragmentWithArchive:]):
              (-[WebDataSource subresourceForURL:]):
              (-[WebDataSource addSubresource:]):
              * WebView/WebDataSourceInternal.h:
      
              * WebView/WebFrame.mm:
              (-[WebFrame loadArchive:]):
              * WebView/WebFrameInternal.h:
      
              * WebView/WebHTMLRepresentation.mm:
              (-[WebHTMLRepresentation finishedLoadingWithDataSource:]):
      
              * WebView/WebResource.mm:
              (+[WebResourcePrivate initialize]):
              (-[WebResourcePrivate init]):
              (-[WebResourcePrivate initWithCoreResource:]):
              (-[WebResourcePrivate dealloc]):
              (-[WebResourcePrivate finalize]):
              (-[WebResource initWithCoder:]):
              (-[WebResource encodeWithCoder:]):
              (-[WebResource data]):
              (-[WebResource URL]):
              (-[WebResource MIMEType]):
              (-[WebResource textEncodingName]):
              (-[WebResource frameName]):
              (-[WebResource _initWithCoreResource:WebCore::]):
              (-[WebResource WebCore::]):
              (-[WebResource _ignoreWhenUnarchiving]):
              (-[WebResource _initWithData:URL:MIMEType:textEncodingName:frameName:response:copyData:]):
              (-[WebResource _fileWrapperRepresentation]):
              (-[WebResource _response]):
              (-[WebResource _stringValue]):
              * WebView/WebResourceInternal.h: Added.
              * WebView/WebResourcePrivate.h:
      
              * WebView/WebUnarchivingState.h: Removed.
              * WebView/WebUnarchivingState.m: Removed.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31281 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      f36a4a19
  21. 20 Mar, 2008 1 commit
    • aroben@apple.com's avatar
      Make WebNodeHighlightView use InspectorController to do its painting · ad382725
      aroben@apple.com authored
       WebCore:
      
               Export InspectorController::drawNodeHighlight
      
               Reviewed by Tim Hatcher.
      
               * WebCore.base.exp: Also sorted this file.
      
       WebKit:
      
               Mark WebNodeHighlight.m and WebNodeHighlightView.m Obj-C++
      
               Reviewed by Tim Hatcher.
      
               * WebKit.xcodeproj/project.pbxproj:
      
       WebKit/mac:
      
               Make WebNodeHighlightView use InspectorController to do its painting
      
               Reviewed by Tim Hatcher.
      
               * WebCoreSupport/WebInspectorClient.mm:
               (-[WebInspectorWindowController highlightNode:]): Pass the
               InspectorController to the WebNodeHighlight, and don't call
               setHighlightedNode: (which has been removed).
               (-[WebInspectorWindowController hideHighlight]): Removed call to
               setHighlightedNode:.
               * WebInspector/WebNodeHighlight.h:
                 - Replaced _highlightNode with _inspectorController
                 - Removed _highlightedNode accessors
                 - Added -inspectorController method
               * WebInspector/WebNodeHighlight.m:
               (-[WebNodeHighlight initWithTargetView:inspectorController:]): Now
               takes an InspectorController* and stores it in _inspectorController.
               (-[WebNodeHighlight dealloc]): Removed code dealing with
               _highlightedNode.
               (-[WebNodeHighlight inspectorController]): Added.
               * WebInspector/WebNodeHighlightView.m: Removed FileInternal category.
               (-[WebNodeHighlightView isFlipped]): Added. WebCore expects all
               GraphicsContexts to be based on a flipped CGContext, so we have to
               specify that this view is flipped.
               (-[WebNodeHighlightView drawRect:]): Changed to create a
               GraphicsContext and pass it to InspectorController::drawNodeHighlight.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31177 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      ad382725
  22. 14 Mar, 2008 1 commit
    • ddkilzer@apple.com's avatar
      JavaScriptCore: · 77d5b49b
      ddkilzer@apple.com authored
              Unify concept of enabling the Mac Java bridge.
      
              Reviewed by Darin and Anders.
      
              * wtf/Platform.h: Define ENABLE_MAC_JAVA_BRIDGE here.
      
      WebCore:
      
              Unify concept of enabling the Mac Java bridge.
      
              Reviewed by Darin and Anders.
      
              No test cases added since there is no change in functionality.
      
              * DerivedSources.make: Added check for ENABLE_MAC_JAVA_BRIDGE macro.
              If defined as "1", add WebCore.JNI.exp to WEBCORE_EXPORT_DEPENDENCIES.
              * WebCore.JNI.exp: Added.
              * WebCore.base.exp: Moved exported JNI methods to WebCore.JNI.exp.
      
              * bridge/jni/jni_class.cpp: Added #if ENABLE(MAC_JAVA_BRIDGE) guard.
              * bridge/jni/jni_class.h: Ditto.
              * bridge/jni/jni_instance.cpp: Ditto.
              * bridge/jni/jni_instance.h: Ditto.
              * bridge/jni/jni_jsobject.cpp: Ditto.
              * bridge/jni/jni_jsobject.h: Ditto.
              * bridge/jni/jni_objc.mm: Ditto.
              * bridge/jni/jni_runtime.cpp: Ditto.
              * bridge/jni/jni_runtime.h: Ditto.
              * bridge/jni/jni_utility.cpp: Ditto.
              * bridge/jni/jni_utility.h: Ditto.
      
              * bridge/runtime.cpp: Removed unused #include statements.
              * bridge/runtime.h:
              (KJS::Bindings::Instance::BindingLanguage): Added #if ENABLE(MAC_JAVA_BRIDGE)
              guard for JavaLanguage enum.  Also added #if PLATFORM(MAC) guard for
              ObjectiveCLanguage enum to match corresponding code in runtime.cpp.
      
              * config.h: Removed definition of HAVE_JNI.
      
              * loader/FrameLoaderClient.h:
              (WebCore::FrameLoaderClient::javaApplet): Added #if ENABLE(MAC_JAVA_BRIDGE) guard.
              * page/Frame.cpp:
              (WebCore::Frame::Frame): Ditto.
              * page/Frame.h:
              (WebCore::Frame::initJavaJSBindings): Ditto.
              * page/mac/FrameMac.mm:
              (WebCore::Frame::createScriptInstanceForWidget): Ditto.
              (WebCore::Frame::initJavaJSBindings): Ditto.
      
      WebKit/mac:
      
              Unify concept of enabling the Mac Java bridge.
      
              Reviewed by Darin and Anders.
      
              * Plugins/WebPluginJava.h: Removed unused file.
              * WebCoreSupport/WebFrameLoaderClient.h:
              (WebFrameLoaderClient::javaApplet): Added #if ENABLE(MAC_JAVA_BRIDGE) guard.
              * WebCoreSupport/WebFrameLoaderClient.mm: Ditto for #import and NSView SPI method.
              (WebFrameLoaderClient::javaApplet): Ditto.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31056 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      77d5b49b
  23. 13 Mar, 2008 1 commit
  24. 12 Mar, 2008 3 commits
    • mrowe@apple.com's avatar
      Mac build fix. · 998fc45e
      mrowe@apple.com authored
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31018 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      998fc45e
    • darin@apple.com's avatar
      WebCore: · b46f9fdd
      darin@apple.com authored
              Reviewed by Anders.
      
              - http://bugs.webkit.org/show_bug.cgi?id=17640
                eliminate WebCoreFrameBridge
      
              * WebCore.base.exp: Added more exports, needed by code moved from WebCoreFrameBridge
              to WebFrame in WebKit.
              * WebCore.xcodeproj/project.pbxproj: Added more headers, same reason. Also deleted
              WebCoreFrameBridge.h and WebCoreFrameBridge.mm.
      
              * page/Frame.cpp:
              (WebCore::Frame::Frame): Added call to initJavaJSBindings(), formerly handled by
              the WebCoreFrameBridge.
              * page/Frame.h: Added initJavaJSBindings function.
      
              * page/mac/FrameMac.mm:
              (WebCore::updateRenderingForBindings): Moved here from WebCoreFrameBridge.
              (WebCore::Frame::initJavaJSBindings): Ditto; code was in the init function.
      
              * page/mac/WebCoreFrameBridge.h: Removed.
              * page/mac/WebCoreFrameBridge.mm: Removed.
      
      WebKit:
      
              Reviewed by Anders.
      
              - http://bugs.webkit.org/show_bug.cgi?id=17640
                eliminate WebCoreFrameBridge
      
              * StringsNotToBeLocalized.txt: Updated for recent changes.
              * WebKit.xcodeproj/project.pbxproj: Removed WebFrameBridge.h and WebFrameBridge.mm.
      
      WebKit/mac:
      
              Reviewed by Anders.
      
              - http://bugs.webkit.org/show_bug.cgi?id=17640
                eliminate WebCoreFrameBridge
      
              Moved all the code from the bridge into WebFrame. This need not be the final
              home of these methods -- they can be moved closer to their callers and improved
              further -- but it eliminates the bridge without requiring a rewrite of the code.
              It's a fairly mechanical process (just adding underscores to method names really).
      
              There's even a chance that some of the methods are unused. Those we can remove
              after checking if that's so.
      
              * DOM/WebDOMOperations.mm:
              (-[DOMNode markupString]): Use WebFrame rather than bridge.
              (-[DOMDocument webFrame]): Changed to use the core and kit functions
              instead of using the bridge.
              (-[DOMDocument URLWithAttributeString:]): Use WebFrame rather than bridge.
              (-[DOMRange markupString]): Ditto.
              * DOM/WebDOMOperationsPrivate.h: Removed _bridge methods.
      
              * DefaultDelegates/WebDefaultContextMenuDelegate.mm: Removed unneeded import.
              * History/WebHistoryItem.mm: Ditto.
      
              * MigrateHeaders.make: Added DOMDocumentFragmentInternal.h.
              * Misc/WebCoreStatistics.mm:
              (-[WebFrame renderTreeAsExternalRepresentation]): Use WebFrame rather than bridge.
      
              * Misc/WebElementDictionary.mm: Removed unneeded import.
      
              * Misc/WebKitStatistics.m:
              (+[WebKitStatistics bridgeCount]): Removed WebBridgeCount and just return 0.
              * Misc/WebKitStatisticsPrivate.h: Ditto.
      
              * Misc/WebNSAttributedStringExtras.mm: Removed unneeded import.
              * Misc/WebNSPasteboardExtras.mm: Ditto.
      
              * Plugins/WebBaseNetscapePluginView.mm:
              (-[WebBaseNetscapePluginView evaluateJavaScriptPluginRequest:]): Use WebFrame
              rather than bridge.
      
              * Plugins/WebNetscapePluginEmbeddedView.mm: Removed unneeded import.
              * Plugins/WebNetscapePluginStream.mm: Ditto.
      
              * Plugins/WebPluginContainerCheck.mm:
              (-[WebPluginContainerCheck _isForbiddenFileLoad]): Use WebFrame rather than
              bridge to get to the WebCore::Frame.
      
              * Plugins/WebPluginController.h: Declare webFrame method and remove bridge method.
              * Plugins/WebPluginController.mm:
              (-[WebPluginController webPlugInContainerLoadRequest:inFrame:]): Use WebFrame
              rather than bridge.
      
              * WebCoreSupport/WebEditorClient.mm:
              (selectorForKeyEvent): Tweaked comment.
      
              * WebCoreSupport/WebFrameBridge.h: Removed.
              * WebCoreSupport/WebFrameBridge.mm: Removed.
      
              * WebCoreSupport/WebFrameLoaderClient.mm:
              (WebFrameLoaderClient::frameLoaderDestroyed): Removed bridge assertion.
              (WebFrameLoaderClient::detachedFromParent4): Removed bridge teardown code.
              I could remove this function entirely, but it looks like the Qt port is using it.
      
              * WebCoreSupport/WebViewFactory.mm: Removed unneeded import.
      
              * WebView/WebArchiver.mm:
              (+[WebArchiver archiveRange:]): Use WebFrame rather than bridge.
              (+[WebArchiver archiveNode:]): Ditto.
              (+[WebArchiver archiveSelectionInFrame:]): Ditto.
      
              * WebView/WebDataSource.mm:
              (-[WebDataSource _replaceSelectionWithArchive:selectReplacement:]): Ditto.
              (-[WebDataSource _documentFragmentWithArchive:]): Ditto.
              (-[WebDataSource subresources]): Ditto.
              (-[WebDataSource subresourceForURL:]): Ditto.
      
              * WebView/WebDataSourceInternal.h: Removed _bridge method.
      
              * WebView/WebFrame.mm:
              (-[WebFramePrivate dealloc]): Removed code to release the bridge.
              (core): Go directly to the core frame, not via the bridge.
              (+[WebFrame _createFrameWithPage:frameName:frameView:ownerElement:]):
              Remove the code to deal with the bridge.
              (-[WebFrame _initWithWebFrameView:webView:]): Ditto. Also added code to set the
              shouldCreateRenderers flag, formerly on the bridge.
              (-[WebFrame _updateBackground]): Change to call mehods on self, not bridge.
              (aeDescFromJSValue): Moved here from bridge.
              (-[WebFrame _domain]): Ditto.
              (-[WebFrame _addData:]): Ditto.
              (-[WebFrame _stringWithDocumentTypeStringAndMarkupString:]): Ditto.
              (-[WebFrame _nodesFromList:]): Ditto.
              (-[WebFrame _markupStringFromNode:nodes:]): Ditto.
              (-[WebFrame _markupStringFromRange:nodes:]): Ditto.
              (-[WebFrame _selectedString]): Ditto.
              (-[WebFrame _stringForRange:]): Ditto.
              (-[WebFrame _forceLayoutAdjustingViewSize:]): Ditto.
              (-[WebFrame _forceLayoutWithMinimumPageWidth:maximumPageWidth:adjustingViewSize:]): Ditto.
              (-[WebFrame _sendScrollEvent]): Ditto.
              (-[WebFrame _drawRect:]): Ditto.
              (-[WebFrame _computePageRectsWithPrintWidthScaleFactor:printHeight:]): Ditto.
              (-[WebFrame _adjustPageHeightNew:top:bottom:limit:]): Ditto.
              (-[WebFrame _copyRenderNode:copier:]): Ditto.
              (-[WebFrame _copyRenderTree:]): Ditto.
              (inputElementFromDOMElement): Ditto.
              (formElementFromDOMElement): Ditto.
              (-[WebFrame _elementWithName:inForm:]): Ditto.
              (-[WebFrame _elementDoesAutoComplete:]): Ditto.
              (-[WebFrame _elementIsPassword:]): Ditto.
              (-[WebFrame _formForElement:]): Ditto.
              (-[WebFrame _currentForm]): Ditto.
              (-[WebFrame _controlsInForm:]): Ditto.
              (-[WebFrame _searchForLabels:beforeElement:]): Ditto.
              (-[WebFrame _matchLabels:againstElement:]): Ditto.
              (-[WebFrame _URLWithAttributeString:]): Ditto.
              (-[WebFrame _searchFor:direction:caseSensitive:wrap:startInSelection:]): Ditto.
              (-[WebFrame _markAllMatchesForText:caseSensitive:limit:]): Ditto.
              (-[WebFrame _markedTextMatchesAreHighlighted]): Ditto.
              (-[WebFrame _setMarkedTextMatchesAreHighlighted:]): Ditto.
              (-[WebFrame _unmarkAllTextMatches]): Ditto.
              (-[WebFrame _rectsForTextMatches]): Ditto.
              (-[WebFrame _stringByEvaluatingJavaScriptFromString:]): Ditto.
              (-[WebFrame _stringByEvaluatingJavaScriptFromString:forceUserGesture:]): Ditto.
              (-[WebFrame _aeDescByEvaluatingJavaScriptFromString:]): Ditto.
              (-[WebFrame _caretRectAtNode:offset:affinity:]): Ditto.
              (-[WebFrame _firstRectForDOMRange:]): Ditto.
              (-[WebFrame _scrollDOMRangeToVisible:]): Ditto.
              (-[WebFrame _baseURL]): Ditto.
              (-[WebFrame _stringWithData:]): Ditto.
              (+[WebFrame _stringWithData:textEncodingName:]): Ditto.
              (-[WebFrame _needsLayout]): Ditto.
              (-[WebFrame _renderTreeAsExternalRepresentation]): Ditto.
              (-[WebFrame _accessibilityTree]): Ditto.
              (-[WebFrame _setBaseBackgroundColor:]): Ditto.
              (-[WebFrame _setDrawsBackground:]): Ditto.
              (-[WebFrame _rangeByAlteringCurrentSelection:SelectionController::direction:SelectionController::granularity:]):
              Ditto.
              (-[WebFrame _selectionGranularity]): Ditto.
              (-[WebFrame _convertToNSRange:]): Ditto.
              (-[WebFrame _convertToDOMRange:]): Ditto.
              (-[WebFrame _convertNSRangeToDOMRange:]): Ditto.
              (-[WebFrame _convertDOMRangeToNSRange:]): Ditto.
              (-[WebFrame _markDOMRange]): Ditto.
              (-[WebFrame _markedTextNSRange]): Ditto.
              (-[WebFrame _smartDeleteRangeForProposedRange:]): Ditto.
              (-[WebFrame _smartInsertForString:replacingRange:beforeString:afterString:]): Ditto.
              (-[WebFrame _documentFragmentWithMarkupString:baseURLString:]): Ditto.
              (-[WebFrame _documentFragmentWithText:inContext:]): Ditto.
              (-[WebFrame _documentFragmentWithNodesAsParagraphs:]): Ditto.
              (-[WebFrame _replaceSelectionWithFragment:selectReplacement:smartReplace:matchStyle:]): Ditto.
              (-[WebFrame _replaceSelectionWithNode:selectReplacement:smartReplace:matchStyle:]): Ditto.
              (-[WebFrame _replaceSelectionWithMarkupString:baseURLString:selectReplacement:smartReplace:]): Ditto.
              (-[WebFrame _replaceSelectionWithText:selectReplacement:smartReplace:]): Ditto.
              (-[WebFrame _insertParagraphSeparatorInQuotedContent]): Ditto.
              (-[WebFrame _visiblePositionForPoint:]): Ditto.
              (-[WebFrame _characterRangeAtPoint:]): Ditto.
              (-[WebFrame _typingStyle]): Ditto.
              (-[WebFrame _setTypingStyle:withUndoAction:]): Ditto.
              (-[WebFrame _fontForSelection:]): Ditto.
              (-[WebFrame _dragSourceMovedTo:]): Ditto.
              (-[WebFrame _dragSourceEndedAt:operation:]): Ditto.
              (-[WebFrame _getData:andResponse:forURL:]): Ditto.
              (-[WebFrame _getAllResourceDatas:andResponses:]): Ditto.
              (-[WebFrame _canProvideDocumentSource]): Ditto.
              (-[WebFrame _canSaveAsWebArchive]): Ditto.
              (-[WebFrame _receivedData:textEncodingName:]): Ditto.
              (-[WebFrame _setShouldCreateRenderers:]): Put the code from the bridge in this preexisting
              function. Couldn't just keep the bridge method because this was already here with the same name.
              (-[WebFrame _selectedNSRange]): Ditto.
              (-[WebFrame _selectNSRange:]): Ditto.
              (-[WebFrame dealloc]): Remove bridge-related code.
              (-[WebFrame finalize]): Ditto.
      
              * WebView/WebFrameInternal.h: Added all the method declarations from the bridge.
              Removed the bridge parameter from the init method. Removed the #if blocks that
              tried to make this header work in non-C++ ObjC files -- they were broken and unused.
              Removed the _bridge method.
      
              * WebView/WebFrameView.mm: Removed the _bridge method.
      
              * WebView/WebHTMLRepresentation.mm:
              (-[WebHTMLRepresentation setDataSource:]): Removed the code to set up the bridge
              field.
              (-[WebHTMLRepresentation receivedData:withDataSource:]): Use WebFrame instead of bridge.
              (-[WebHTMLRepresentation finishedLoadingWithDataSource:]): Ditto.
              (-[WebHTMLRepresentation canProvideDocumentSource]): Ditto.
              (-[WebHTMLRepresentation canSaveAsWebArchive]): Ditto.
              (-[WebHTMLRepresentation documentSource]): Ditto.
              (-[WebHTMLRepresentation DOMDocument]): Ditto.
              (-[WebHTMLRepresentation elementWithName:inForm:]): Ditto.
              (-[WebHTMLRepresentation elementDoesAutoComplete:]): Ditto.
              (-[WebHTMLRepresentation elementIsPassword:]): Ditto.
              (-[WebHTMLRepresentation formForElement:]): Ditto.
              (-[WebHTMLRepresentation currentForm]): Ditto.
              (-[WebHTMLRepresentation controlsInForm:]): Ditto.
              (-[WebHTMLRepresentation searchForLabels:beforeElement:]): Ditto.
              (-[WebHTMLRepresentation matchLabels:againstElement:]): Ditto.
      
              * WebView/WebHTMLRepresentationPrivate.h: Removed the _bridge method.
      
              * WebView/WebHTMLView.mm:
              (-[WebHTMLView _documentFragmentWithPaths:]): Use WebFrame instead of bridge.
              (-[WebHTMLView _pasteWithPasteboard:allowPlainText:]): Ditto.
              (-[WebHTMLView _pasteAsPlainTextWithPasteboard:]): Ditto.
              (-[WebHTMLView _updateTextSizeMultiplier]): Ditto.
              (-[WebHTMLView _frameOrBoundsChanged]): Ditto.
              (-[WebHTMLView _smartInsertForString:replacingRange:beforeString:afterString:]): Ditto.
              (-[WebHTMLView _documentFragmentFromPasteboard:forType:inContext:subresources:]): Ditto.
              (-[WebHTMLView layoutToMinimumPageWidth:maximumPageWidth:adjustingViewSize:]): Ditto.
              (-[WebHTMLView drawSingleRect:]): Ditto.
              (-[WebHTMLView draggedImage:movedTo:]): Ditto.
              (-[WebHTMLView draggedImage:endedAt:operation:]): Ditto.
              (-[WebHTMLView adjustPageHeightNew:top:bottom:limit:]): Ditto.
              (-[WebHTMLView knowsPageRange:]): Ditto.
              (-[WebHTMLView accessibilityAttributeValue:]): Ditto.
              (-[WebHTMLView accessibilityFocusedUIElement]): Ditto.
              (-[WebHTMLView accessibilityHitTest:]): Ditto.
              (-[WebHTMLView _accessibilityParentForSubview:]): Ditto.
              (-[WebHTMLView changeDocumentBackgroundColor:]): Ditto.
              (-[WebHTMLView _changeWordCaseWithSelector:]): Ditto.
              (-[WebHTMLView _changeSpellingToWord:]): Ditto.
              (-[WebHTMLView startSpeaking:]): Ditto.
              (-[WebHTMLView _updateFontPanel]): Ditto.
              (-[WebHTMLView _canSmartCopyOrDelete]): Ditto.
              (-[WebHTMLView _layoutIfNeeded]): Ditto.
              (-[WebHTMLView characterIndexForPoint:]): Ditto.
              (-[WebHTMLView firstRectForCharacterRange:]): Ditto.
              (-[WebHTMLView selectedRange]): Ditto.
              (-[WebHTMLView markedRange]): Ditto.
              (-[WebHTMLView attributedSubstringFromRange:]): Ditto.
              (-[WebHTMLView setMarkedText:selectedRange:]): Ditto.
              (-[WebHTMLView insertText:]): Ditto.
              (-[WebTextCompleteController _insertMatch:]): Ditto.
              (-[WebTextCompleteController doCompletion]): Ditto.
              (-[WebTextCompleteController endRevertingChange:moveLeft:]): Ditto.
              (-[WebHTMLView string]): Ditto.
              (-[WebHTMLView selectedString]): Ditto.
              (-[WebHTMLView searchFor:direction:caseSensitive:wrap:startInSelection:]): Ditto.
              (-[WebHTMLView markAllMatchesForText:caseSensitive:limit:]): Ditto.
              (-[WebHTMLView setMarkedTextMatchesAreHighlighted:]): Ditto.
              (-[WebHTMLView markedTextMatchesAreHighlighted]): Ditto.
              (-[WebHTMLView unmarkAllTextMatches]): Ditto.
              (-[WebHTMLView rectsForTextMatches]): Ditto.
              * WebView/WebRenderNode.mm:
              (-[WebRenderNode initWithWebFrameView:]): Ditto.
              * WebView/WebResource.mm:
              (-[WebResource _stringValue]): Ditto.
      
              * WebView/WebScriptDebugDelegate.mm: Removed unneeded include.
      
              * WebView/WebView.mm:
              (-[WebView _dashboardRegions]): Use WebFrame instead of bridge.
              (-[WebView setProhibitsMainFrameScrolling:]): Ditto.
              (-[WebView _setInViewSourceMode:]): Ditto.
              (-[WebView _inViewSourceMode]): Ditto.
              (-[WebView _executeCoreCommandByName:value:]): Ditto.
              (-[WebView stringByEvaluatingJavaScriptFromString:]): Ditto.
              (-[WebView aeDescByEvaluatingJavaScriptFromString:]): Ditto.
              (-[WebView scrollDOMRangeToVisible:]): Ditto.
              (-[WebView setSelectedDOMRange:affinity:]): Ditto.
              (-[WebView setEditable:]): Ditto.
              (-[WebView setTypingStyle:]): Ditto.
              (-[WebView typingStyle]): Ditto.
              (-[WebView replaceSelectionWithNode:]): Ditto.
              (-[WebView replaceSelectionWithText:]): Ditto.
              (-[WebView replaceSelectionWithMarkupString:]): Ditto.
              (-[WebView replaceSelectionWithArchive:]): Ditto.
              (-[WebView _insertNewlineInQuotedContent]): Ditto.
              (-[WebView _replaceSelectionWithNode:matchStyle:]): Ditto.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31014 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      b46f9fdd
    • hyatt@apple.com's avatar
      WebCore: · 29be35f6
      hyatt@apple.com authored
              Make the zoom factor a float and not a percent.
      
              Reviewed by antti
      
              * WebCore.base.exp:
              * css/CSSStyleSelector.cpp:
              (WebCore::CSSStyleSelector::applyProperty):
              (WebCore::CSSStyleSelector::getComputedSizeFromSpecifiedSize):
              * page/Frame.cpp:
              (WebCore::Frame::zoomFactor):
              (WebCore::Frame::setZoomFactor):
              * page/Frame.h:
              * page/FramePrivate.h:
              * svg/SVGSVGElement.cpp:
              (WebCore::SVGSVGElement::currentScale):
              (WebCore::SVGSVGElement::setCurrentScale):
      
      WebKit/mac:
      
              Make the zoom factor a float and not a percent.
      
              Reviewed by antti
      
              * WebView/WebView.mm:
              (-[WebView _setZoomMultiplier:isTextOnly:]):
      
      WebKit/win:
      
              Make the zoom factor a float and not a percent.
      
              Reviewed by antti
      
              * WebFrame.cpp:
              (WebFrame::setTextSizeMultiplier):
      
      WebKit/wx:
      
              Make the zoom factor a float and not a percent.
      
              Reviewed by antti
      
              * WebView.cpp:
              (wxWebView::IncreaseTextSize):
              (wxWebView::DecreaseTextSize):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@31003 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      29be35f6