1. 20 May, 2008 11 commits
    • alice.liu@apple.com's avatar
      2008-05-20 Alice Liu <alice.liu@apple.com> · d8560b94
      alice.liu@apple.com authored
              Reviewed by Brady.
      
              fix <rdar://problem/5908580> 10A58: Dictionary Panel hangs in WebCore::Cache::pruneDeadResources()
      
              * loader/Cache.cpp:
              (WebCore::Cache::requestUserCSSStyleSheet):
              Add a call to resourceAccessed() to more closely mirror what is done in requestResource()
              (WebCore::Cache::insertInLRUList):
              Assert that any resource in the LRU list has been accessed.  This is early detection of a
              potential hang later when pruning resources, and also agrees with the early return in 
              removeFromLRUList().
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33940 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      d8560b94
    • mitz@apple.com's avatar
      WebCore: · 78ceb1f5
      mitz@apple.com authored
              Reviewed by Darin Adler.
      
              - fix https://bugs.webkit.org/show_bug.cgi?id=17655
                <rdar://problem/5778077> REGRESSION (3.1.1-TOT): Reproducible crash calling querySelector on viewless Document
      
              Test: fast/dom/SelectorAPI/viewless-document.html
      
              * css/CSSStyleSelector.cpp:
              (WebCore::CSSStyleSelector::CSSStyleSelector): Updated to initialize the
              selector checker.
              (WebCore::CSSStyleSelector::init): Removed initialization of
              m_collectRulesOnly, which is now part of the selector checker.
              (WebCore::CSSStyleSelector::matchRules): Updated for renames and data
              moved into the selector checker.
              (WebCore::CSSStyleSelector::matchRulesForList): Ditto.
              (WebCore::CSSStyleSelector::initForStyleResolve): Added a PseudoId
              argument, which is used to initialize a data member of the selector
              checker. Updated for renames. Removed initialization of m_isXMLDoc
              because this bit is now initialized only once in the selector checker's
              constructor.
              (WebCore::CSSStyleSelector::SelectorChecker::SelectorChecker): Added.
              (WebCore::CSSStyleSelector::SelectorChecker::checkPseudoState): Changed
              into a SelectorChecker method.
              (WebCore::CSSStyleSelector::SelectorChecker::checkSelector): Added. Used
              by querySelector() and querySelectorAll().
              (WebCore::CSSStyleSelector::canShareStyleWithElement): Updated for data
              moved into the selector checker.
              (WebCore::CSSStyleSelector::matchUARules): Ditto.
              (WebCore::CSSStyleSelector::styleForElement):
              (WebCore::CSSStyleSelector::pseudoStyleForElement): Ditto. Also removed
              code that set the parentStyle variable after the last place it is
              accessed, and changed to ensure that m_style is set early in this
              function.
              (WebCore::CSSStyleSelector::adjustRenderStyle): Updated for data moved
              into the selector checker.
              (WebCore::CSSStyleSelector::styleRulesForElement): Ditto.
              (WebCore::CSSStyleSelector::checkSelector): Ditto. Also changed to pass
              the element's style and the parent style to the selector checker, as
              well as the dynamic pseudo variable and the selector attributes vector.
              (WebCore::CSSStyleSelector::SelectorChecker::checkOneSelector): Added
              arguments for the style of the base element and its parent. When the
              elementStyle argument is 0, the style is fetched from the element
              and its parent as needed. Also changed to take a reference to the
              dynamic pseudo ID and a pointer to the vector of attributes affecting
              the match.
              (WebCore::CSSStyleSelector::applyProperty): Updated for data moved
              into the selector checker.
              (WebCore::CSSStyleSelector::checkForGenericFamilyChange): Ditto.
              (WebCore::CSSStyleSelector::getComputedSizeFromSpecifiedSize): Ditto.
              (WebCore::CSSStyleSelector::fontSizeForKeyword): Ditto.
              (WebCore::CSSStyleSelector::getColorFromPrimitiveValue): Ditto.
              (WebCore::CSSStyleSelector::SelectorChecker::allVisitedStateChanged):
              Changed into a SelectorChecker method.
              (WebCore::CSSStyleSelector::SelectorChecker::visitedStateChanged):
              Ditto.
      
              * css/CSSStyleSelector.h:
              Added a SelectorChecker class and moved data and methods used in
              checking selectors into it.
              (WebCore::CSSStyleSelector::allVisitedStateChanged): Changed to call the
              SelectorChecker method.
              (WebCore::CSSStyleSelector::visitedStateChanged): Ditto.
              * dom/Node.cpp:
              (WebCore::Node::querySelector): Changed to use a SelectorChecker instead
              of the document's style selector.
              * dom/SelectorNodeList.cpp:
              (WebCore::SelectorNodeList::SelectorNodeList): Ditto.
      
      LayoutTests:
      
              Reviewed by Darin Adler.
      
              - test for https://bugs.webkit.org/show_bug.cgi?id=17655
                <rdar://problem/5778077> REGRESSION (3.1.1-TOT): Reproducible crash calling querySelector on viewless Document
      
              * fast/dom/SelectorAPI/resources/viewless-document.js: Added.
              * fast/dom/SelectorAPI/viewless-document-expected.txt: Added.
              * fast/dom/SelectorAPI/viewless-document.html: Added.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33939 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      78ceb1f5
    • timothy@apple.com's avatar
      Implements the Profiles panel and Profile view. · 23cf67bb
      timothy@apple.com authored
      Reviewed by Kevin McCullough.
      
      * English.lproj/localizedStrings.js: Added new strings.
      * page/inspector/Images/profileIcon.png: Added.
      * page/inspector/Images/profilesIcon.png: Changed. New icon design
      that fits in with the other toolbar icons.
      * page/inspector/ProfileView.js:
      (WebInspector.ProfileView): Remove custom table elements
      and create a DataGrid. Sorts the profile by descending total time,
      since the profiles aren't sorted by default.
      (WebInspector.ProfileView.prototype.refresh): Clears the DataGrid
      and recreates all the nodes. The selection is preserved.
      (WebInspector.ProfileView.prototype.refreshShowAsPercents): Traverse
      all the children and change showTotalTimeAsPercent and showSelfTimeAsPercent
      to match the ProfileView values. Then call refresh on the child.
      (WebInspector.ProfileView.prototype._sortData): Determine the sort
      function to call on the head profile node. Call it and then call
      refresh to rebuild the DataGrid.
      (WebInspector.ProfileView.prototype._mouseDownInDataGrid): Return early
      if the event is not a double-click. When it is a double-click, determine
      the column that was targeted and if it was total or self toggle the
      show as percent property. Call refreshShowAsPercents.
      (WebInspector.ProfileDataGridNode):
      (WebInspector.ProfileDataGridNode.prototype.get data):
      (WebInspector.ProfileDataGridNode.prototype.expand):
      (WebInspector.ProfileDataGridNode.prototype.collapse):
      (WebInspector.ProfileDataGridNode.prototype._populate):
      * page/inspector/ProfilesPanel.js:
      (WebInspector.ProfilesPanel):
      (WebInspector.ProfilesPanel.prototype.show): Populate the sidebar
      with all profiles. This is a workaround until the Inspector
      is told about new profiles.
      (WebInspector.ProfilesPanel.prototype.reset): Clear the sidebar and
      profile views.
      (WebInspector.ProfilesPanel.prototype.handleKeyEvent): Pass the key
      event to the sidebar.
      (WebInspector.ProfilesPanel.prototype.addProfile): Create a
      ProfileSidebarTreeElement object and add it to the sidebar.
      (WebInspector.ProfilesPanel.prototype.showProfile): Create a ProfileView
      and show it.
      (WebInspector.ProfilesPanel.prototype.closeVisibleView): Hide the
      visible view.
      (WebInspector.ProfilesPanel.prototype._startSidebarDragging): Call
      WebInspector.elementDragStart.
      (WebInspector.ProfilesPanel.prototype._sidebarDragging): Call _updateSidebarWidth.
      (WebInspector.ProfilesPanel.prototype._endSidebarDragging):
      Call WebInspector.elementDragEnd.
      (WebInspector.ProfilesPanel.prototype._updateSidebarWidth): Update the
      sidebar width based on the passed in value.
      (WebInspector.ProfileSidebarTreeElement): Subclass WebInspector.SidebarTreeElement.
      (WebInspector.ProfileSidebarTreeElement.prototype.onselect): Call ProfilesPanel.showProfile.
      (WebInspector.ProfileSidebarTreeElement.prototype.get mainTitle): Return profile.title.
      (WebInspector.ProfileSidebarTreeElement.prototype.set mainTitle): Do nothing.
      (WebInspector.ProfileSidebarTreeElement.prototype.get subtitle): Ditto.
      (WebInspector.ProfileSidebarTreeElement.prototype.set subtitle): Ditto.
      * page/inspector/inspector.css: New styles for the profile sidebar
      item and profile data grid columns.
      * page/inspector/inspector.js:
      * page/inspector/utilities.js:
      (Number.secondsToString): Added a higherResolution argument
      that returns fractional milliseconds.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33938 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      23cf67bb
    • cfleizach@apple.com's avatar
      <rdar://problem/5060458> Elements without AXActions should not return kAXErrorFailure · 7783493e
      cfleizach@apple.com authored
      <rdar://problem/3438014> Might need accessibility solution for context menus in web pages
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33937 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      7783493e
    • timothy@apple.com's avatar
      Expose the ProfileNode functionName sorting functions on · cf48a173
      timothy@apple.com authored
      JavaScriptProfileNode.
      
      Reviewed by Kevin McCullough.
      
      * page/JavaScriptProfileNode.cpp:
      (WebCore::sortFunctionNameDescending): Call ProfileNode.
      (WebCore::sortFunctionNameAscending): Ditto.
      (WebCore::ProfileNodeClass): Add static functions.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33936 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      cf48a173
    • darin@apple.com's avatar
      2008-05-20 Darin Adler <darin@apple.com> · f3933de7
      darin@apple.com authored
              Reviewed by Mitz.
      
              - a first small step of CSS DOM refactoring -- the eventual goal is to
                reduce StyleBase and possibly eliminate it, since it has multiple
                purposes and unneccessarily ties many classes together
      
              * css/CSSCursorImageValue.cpp:
              (WebCore::isSVGCursorIdentifier): Mark static so it has internal linkage.
              (WebCore::resourceReferencedByCursorElement): Ditto.
              (WebCore::CSSCursorImageValue::CSSCursorImageValue): Removed unused style
              argument.
              (WebCore::CSSCursorImageValue::updateIfSVGCursorIsUsed): Removed code to
              check if X and Y changed before changing them -- there's no reason to do
              that. Removed code that depended on the internals of CSSImageValue. The
              new code uses only protected functions rather than going right at the
              fields and uing internal knowledge of the base class.
              * css/CSSCursorImageValue.h: Added a create function, made constructor
              private, removed unused style argument.
      
              * css/CSSImageValue.cpp:
              (WebCore::CSSImageValue::CSSImageValue): Removed unused style argument.
              (WebCore::CSSImageValue::cachedImageURL): Added. A protected function for
              use by CSSCursorImageValue that gives the URL.
              (WebCore::CSSImageValue::clearCachedImage): Added. A protected function for
              use by CSSCursorImageValue that clears the CachedImage.
              * css/CSSImageValue.h: Added create functions, made constructors protected
              and private, removed unused style argument, made data members private, added
              some protected functions for use by CSSCursorImageValue.
      
              * css/CSSImportRule.cpp:
              (WebCore::CSSImportRule::setCSSStyleSheet): Changed to call checkLoaded on
              the parent. This is part of preparation to move the checkLoaded function from
              StyleBase to StyleSheet.
              (WebCore::CSSImportRule::insertedIntoParent): Changed code to check the URL
              of the style sheet to use the href function of the style sheet rather than
              the baseURL function. This eliminates an O(n^2) algorithm here and reduces
              the use of baseURL, part of preparation to move it from StyleBase
              to CSSStyleSheet.
      
              * css/CSSMutableStyleDeclaration.cpp:
              (WebCore::CSSMutableStyleDeclaration::setImageProperty): Changed to use create
              function instead of a direct call to new for the CSSImageValue classes.
              * css/CSSParser.cpp:
              (WebCore::CSSParser::parseValue): Ditto.
              (WebCore::CSSParser::parseContent): Ditto.
              (WebCore::CSSParser::parseFillImage): Ditto.
              (WebCore::CSSParser::parseBorderImage): Ditto.
      
              * css/CSSStyleSelector.cpp: Removed unneeded include of CSSImageValue.h.
              * rendering/style/RenderStyle.h: Removed unneeded include of
              CSSCursorImageValue.h, which was causing us to rebuild the world way too often.
      
              * xml/XSLImportRule.cpp:
              (WebCore::XSLImportRule::setXSLStyleSheet): See change to CSSImportRule above.
              (WebCore::XSLImportRule::loadSheet): Ditto.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33934 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      f3933de7
    • kmccullough@apple.com's avatar
      2008-05-20 Kevin McCullough <kmccullough@apple.com> · fe9d0e7b
      kmccullough@apple.com authored
              Rubber stamped by Adam.
      
              -Minor fix. Should not use a reference since the original may disappear.
      
              * page/Console.cpp:
              (WebCore::Console::profile):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33933 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      fe9d0e7b
    • kevino@webkit.org's avatar
      wx build fixes for PluginViewWx.cpp and WebKit/wx/WebView.cpp · 82340bb3
      kevino@webkit.org authored
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33932 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      82340bb3
    • timothy@apple.com's avatar
      Expose the ProfileNode sorting functions on JavaScriptProfileNode. · 5a0204ec
      timothy@apple.com authored
      Reviewed by Kevin McCullough.
      
      * page/JavaScriptProfileNode.cpp:
      (WebCore::sortTotalTimeDescending): Call ProfileNode.
      (WebCore::sortTotalTimeAscending): Ditto.
      (WebCore::sortSelfTimeDescending): Ditto.
      (WebCore::sortSelfTimeAscending): Ditto.
      (WebCore::sortCallsDescending): Ditto.
      (WebCore::sortCallsAscending): Ditto.
      (WebCore::ProfileNodeClass): Add static static functions.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33931 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      5a0204ec
    • timothy@apple.com's avatar
      * page/InspectorController.cpp: Change the include for · c3f9d123
      timothy@apple.com authored
      JavaScriptProfile.h to sue double quotes instead of backets.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33929 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      c3f9d123
    • timothy@apple.com's avatar
      Adds a DataGrid object that is used for multi-column data · 96ad88ab
      timothy@apple.com authored
      and can contain hierarchical content with disclosure arrows.
      A lot of DataGrid was copied from treeoutline.js. This change
      makes the database views use the DataGrid. It will later be
      used by the ProfileView.
      
      Reviewed by Adam Roben.
      
      * page/inspector/DataGrid.js: Added. Most copied from treeoutline.js
      and modified to work with table elements.
      * page/inspector/DatabaseQueryView.js:
      (WebInspector.DatabaseQueryView.prototype._queryFinished):
      Call DatabasesPanel.dataGridForResult and adds the inline style to
      the DataGrid element.
      * page/inspector/DatabaseTableView.js:
      (WebInspector.DatabaseTableView.prototype._queryFinished):
      Call DatabasesPanel.dataGridForResult.
      * page/inspector/DatabasesPanel.js:
      (WebInspector.DatabasesPanel.prototype._tableForResult): Removed.
      (WebInspector.DatabasesPanel.prototype.dataGridForResult): Added.
      Similar to the previous _tableForResult function, but makes a DataGrid.
      * page/inspector/inspector.css: Changes to the data-grid
      style rules.
      * WebCore.vcproj/WebCore.vcproj: Add DataGrid.js.
      * page/inspector/WebKit.qrc: Ditto.
      * page/inspector/inspector.html: Ditto.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33927 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      96ad88ab
  2. 19 May, 2008 21 commits
    • kmccullough@apple.com's avatar
      2008-05-19 Kevin McCullough <kmccullough@apple.com> · f0bae5cd
      kmccullough@apple.com authored
              Reviewed by Adam.
      
              -build fix.
      
              * bindings/js/JSConsoleCustom.cpp:
              (WebCore::JSConsole::profile):
              * page/Console.cpp:
              (WebCore::Console::profile):
              * page/Console.h:
              * page/Console.idl:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33595 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      f0bae5cd
    • alp@webkit.org's avatar
      2008-05-19 Alp Toker <alp@nuanti.com> · 45d20367
      alp@webkit.org authored
              Reviewed by Maciej.
      
              GTK+/soup fixes:
      
              Remove the fragment part of the URL since the file backend doesn't
              deal with it.
      
              Fix a typo in the cleanup function.
      
              * platform/network/soup/ResourceHandleSoup.cpp:
              (WebCore::cleanupGioOperation):
              (WebCore::ResourceHandle::startGio):
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33594 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      45d20367
    • kmccullough@apple.com's avatar
      JavaScriptCore: · 6fc919da
      kmccullough@apple.com authored
      2008-05-19  Kevin McCullough  <kmccullough@apple.com>
      
              Reviewed by Adam.
      
              <rdar://problem/5770054> JavaScript profiler (10928)
              - Pass the exec state to profiler when calling startProfiling so that if
              profiling is started within an execution context that location is
              recorded correctly.
      
              * JavaScriptCore.exp:
              * profiler/ProfileNode.cpp:
              (KJS::ProfileNode::printDataInspectorStyle): Dump more info for debugging
              purposes.
              * profiler/Profiler.cpp:
              (KJS::Profiler::startProfiling):
              * profiler/Profiler.h:
      
      WebCore:
      
      2008-05-19  Kevin McCullough  <kmccullough@apple.com>
      
              Reviewed by Adam.
      
              <rdar://problem/5770054> JavaScript profiler (10928)
              - Send the executing context to the profiler so it can attribute time
              correctly to parent functions when calling profile() and profileEnd()
              while nested.
      
              * page/Console.cpp:
              (WebCore::Console::profile):
              (WebCore::Console::profileEnd):
              * page/Console.h:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33593 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      6fc919da
    • alp@webkit.org's avatar
      2008-05-19 Alp Toker <alp@nuanti.com> · 3a5e7caf
      alp@webkit.org authored
              Reviewed by Anders and Beth.
      
              http://bugs.webkit.org/show_bug.cgi?id=16495
              [GTK] Accessibility support with ATK/AT-SPI
      
              Initial ATK/AT-SPI accessibility support for the GTK+ port.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33591 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      3a5e7caf
    • andersca@apple.com's avatar
      WebCore: · a961966a
      andersca@apple.com authored
      2008-05-19  Anders Carlsson  <andersca@apple.com>
      
              Reviewed by Adam.
      
              <rdar://problem/5946454>
              Support navigator.onLine from HTML5.
      
              Add Windows NetworkStateNotifier implementation using the IP Helper API.
      
              * WebCore.vcproj/WebCore.vcproj:
              * platform/network/NetworkStateNotifier.h:
              (WebCore::updateState):
              * platform/network/win/NetworkStateNotifierWin.cpp: Added.
              (WebCore::NetworkStateNotifier::updateState):
              (WebCore::NetworkStateNotifier::addressChanged):
              (WebCore::NetworkStateNotifier::callAddressChanged):
              (WebCore::NetworkStateNotifier::addrChangeCallback):
              (WebCore::NetworkStateNotifier::registerForAddressChange):
              (WebCore::NetworkStateNotifier::NetworkStateNotifier):
      
      WebKit/win:
      
      2008-05-19  Anders Carlsson  <andersca@apple.com>
      
              Reviewed by Adam.
      
              <rdar://problem/5946454>
              Support navigator.onLine from HTML5.
              
              Link with iphlpapi.lib, and make iphlpapi.dll a delay loaded library.
              
              * WebKit.vcproj/WebKit.vcproj:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33590 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      a961966a
    • sfalken@apple.com's avatar
      Disable C4273, C4565 for CSSGrammar.cpp, XPathGrammar.cpp to fix build. · f1d95df8
      sfalken@apple.com authored
              
              Reviewed by Adam Roben.
      
              * WebCore.vcproj/WebCore.vcproj:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33587 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      f1d95df8
    • aroben@apple.com's avatar
      Fix Bug 19065: Resources with a space in their URL don't get error/warning bubbles · fe1a3d2e
      aroben@apple.com authored
              <https://bugs.webkit.org/show_bug.cgi?id=19065>
      
              Reviewed by Dan Bernstein.
      
              Test: manual-tests/inspector/errors-with-space in-url.html
      
              * manual-tests/inspector/errors-with-space in-url.html: Added.
              * page/Console.cpp:
              (WebCore::Console::error):
              (WebCore::Console::info):
              (WebCore::Console::log):
              (WebCore::Console::warn):
              Pass the raw URL to the Inspector, not the pretty URL, to match the
              URL that was used when initially telling the Inspector about this
              resource. We continue to pass the pretty URL to the ChromeClient for
              backwards compatibility.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33586 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      fe1a3d2e
    • slewis@apple.com's avatar
      2008-05-19 Stephanie Lewis <slewis@apple.com> · 71dc466b
      slewis@apple.com authored
              Reviewed by Darin.
          
              more fast teardown performance work
      
              * Misc/WebDownload.m:
              (-[WebDownloadInternal downloadDidBegin:]):
              (-[WebDownloadInternal downloadDidFinish:]):
              (-[WebDownloadInternal download:didFailWithError:]):
              * WebCoreSupport/WebChromeClient.h:
              * WebCoreSupport/WebChromeClient.mm:
              (WebChromeClient::disableSuddenTermination):
              (WebChromeClient::enableSuddenTermination):
      
              more fast teardown performance work, WebCore plumbing
      
              * page/Chrome.cpp:
              (WebCore::Chrome::disableSuddenTermination):
              (WebCore::Chrome::enableSuddenTermination):
              (WebCore::ChromeClient::disableSuddenTermination):
              (WebCore::ChromeClient::enableSuddenTermination):
              * page/Chrome.h:
              * page/ChromeClient.h:
              * page/Page.cpp:
              (WebCore::Page::changePendingUnloadEventCount):
              (WebCore::Page::changePendingBeforeUnloadEventC...
      71dc466b
    • justin.garcia@apple.com's avatar
      2008-05-19 Kuchhal <kuchal@yahoo.com> · afc4aa00
      justin.garcia@apple.com authored
              Reviewed by Justin.
      
              <rdar://problem/5863412> Crash when Ctrl C is pressed after a series of specific mouse events (18506)
      
              * editing/markup.cpp:
              (WebCore::createMarkup): Null check.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33583 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      afc4aa00
    • cfleizach@apple.com's avatar
      <rdar://problem/5912195> CrashTracer: [USER] 1 crash in Mail at... · d7ead7ce
      cfleizach@apple.com authored
      <rdar://problem/5912195> CrashTracer: [USER] 1 crash in Mail at -[AccessibilityObjectWrapper accessibilityAttributeValue:forParameter:]
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33582 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      d7ead7ce
    • adachan@apple.com's avatar
      Added methods to get/set current cookie storage. · 149c8024
      adachan@apple.com authored
      WebCore:
              Added CookieStorageWin.h/cpp, introducing methods to get/set the current CFHTTPCookieStorageRef.
              When setting cookies-related attributes in CFURLRequest, make sure we get them from the
              current CFHTTPCookieStorageRef.  Also, set the cookie storage in CFURLRequest.
      
              Reviewed by Steve Falkenburg.
      
              * WebCore.vcproj/WebCore.vcproj:
              * platform/network/cf/ResourceHandleCFNet.cpp:
              (WebCore::makeFinalRequest):
              * platform/network/cf/ResourceRequestCFNet.cpp:
              (WebCore::ResourceRequest::doUpdatePlatformRequest):
              * platform/network/win/CookieJarCFNetWin.cpp:
              (WebCore::setCookies):
              (WebCore::cookies):
              (WebCore::cookiesEnabled):
              * platform/network/win/CookieStorageWin.cpp: Added.
              (WebCore::currentCookieStorage):
              (WebCore::setCurrentCookieStorage):
              * platform/network/win/CookieStorageWin.h: Added.
      
      WebKit/win:
              Added IWebCookieManager interface which allows client to set the
              CFHTTPCookieStorageRef that WebCore should use.
              
              Implement IWebCookieManager interface in WebCookieManager.
              
              Update the cookie accept policy in the current cookie storage.
      
              Reviewed by Steve Falkenburg.
      
              * ForEachCoClass.h:
              * Interfaces/IWebCookieManager.idl: Added.
              * Interfaces/WebKit.idl:
              * WebCookieManager.cpp: Added.
              (WebCookieManager::createInstance):
              (WebCookieManager::WebCookieManager):
              (WebCookieManager::~WebCookieManager):
              (WebCookieManager::QueryInterface):
              (WebCookieManager::AddRef):
              (WebCookieManager::Release):
              (WebCookieManager::cookieStorage):
              (WebCookieManager::setCookieStorage):
              * WebCookieManager.h: Added.
              * WebKit.vcproj/WebKit.vcproj:
              * WebKitClassFactory.cpp:
              * WebView.cpp:
              (updateSharedSettingsFromPreferencesIfNeeded):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33579 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      149c8024
    • ap@webkit.org's avatar
      Reviewed by Darin. · da8393a2
      ap@webkit.org authored
              http://bugs.webkit.org/show_bug.cgi?id=18308
              SVG Encoding error with fill attribute
      
              This is caused by problems with data: URL loading. Besides what is fixed by this patch,
              I filed <rdar://problem/5845875> for CFNetwork.
      
              While at it, fixed a related javascript: URL issue.
      
              Tests: fast/loader/data-url-encoding-html.html
                     fast/loader/data-url-encoding-svg.html
                     fast/loader/javascript-url-encoding.html
      
              * platform/KURL.cpp:
              (WebCore::KURL::parse): Fix a FIXME, use UTF-8 instead of dropping high bytes. This fixes
              javascript: URL handling.
              (WebCore::encodeRelativeString): Like mailto: URLs, data: ones are all UTF-8. Restructured
              the code to not search for "#" if both parts are to be encoded as UTF-8 anyway.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33578 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      da8393a2
    • ap@webkit.org's avatar
      Reviewed by Darin. · a8de74c2
      ap@webkit.org authored
              https://bugs.webkit.org/show_bug.cgi?id=18421
              <rdar://problem/5857369> XMLHttpRequest does not properly encode & and < in outgoing messages
      
              Test: http/tests/xmlhttprequest/serialize-document.html
      
              * bindings/js/JSXMLHttpRequestCustom.cpp:
              (WebCore::JSXMLHttpRequest::send): Use createMarkup() instead of Document::toString().
      
              * dom/Attr.cpp:
              * dom/Attr.h:
              * dom/Document.cpp:
              * dom/Document.h:
              * dom/DocumentFragment.cpp:
              * dom/DocumentFragment.h:
              * dom/Element.cpp:
              * dom/Element.h:
              * dom/Entity.cpp:
              * dom/Entity.h:
              * dom/EntityReference.cpp:
              * dom/EntityReference.h:
              * dom/Node.h:
              * dom/Text.cpp:
              * dom/Text.h:
              * html/HTMLElement.cpp:
              * html/HTMLElement.h:
              Removed most Node::toString() methods, which were massively wrong, and only used for
              XMLHttpRequest::send(). The remanining ones are still used in markup.cpp, but should probably
              be folded into it for consistency.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33577 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      a8de74c2
    • andersca@apple.com's avatar
      2008-05-19 Anders Carlsson <andersca@apple.com> · 4ff2b98d
      andersca@apple.com authored
              Fix Windows build.
              
              * plugins/win/PluginViewWin.cpp:
              (WebCore::PluginView::userAgentStatic):
              (WebCore::PluginView::getValueStatic):
              (WebCore::PluginView::getValue):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33576 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      4ff2b98d
    • cfleizach@apple.com's avatar
      <rdar://problem/5935694> AX: crash in text marker range · fc0f4ac4
      cfleizach@apple.com authored
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33575 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      fc0f4ac4
    • darin@apple.com's avatar
      2008-05-19 Darin Adler <darin@apple.com> · cc8bf398
      darin@apple.com authored
              - fix WebKit build
      
              * WebCore.xcodeproj/project.pbxproj: Make CSSReflectionDirection.h "private" instead of "project".
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33574 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      cc8bf398
    • cfleizach@apple.com's avatar
      <rdar://problem/5700830> VO: VoiceOver should fall back to title attr if form... · 02df5a3b
      cfleizach@apple.com authored
      <rdar://problem/5700830> VO: VoiceOver should fall back to title attr if form element is not labeled
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33573 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      02df5a3b
    • darin@apple.com's avatar
      2008-05-19 Darin Adler <darin@apple.com> · a79c5fb7
      darin@apple.com authored
              Reviewed by Mitz.
      
              - tweak CSSReflectValue, possibly fixing the leaks seen on the buildbot
      
              * WebCore.vcproj/WebCore.vcproj: Added CSSReflectionDirection.h. 
              * WebCore.xcodeproj/project.pbxproj: Ditto.
              * css/CSSReflectionDirection.h: Added.
      
              * css/CSSComputedStyleDeclaration.cpp:
              (WebCore::valueForReflection): Changed to use CSSReflectValue::create.
              * css/CSSParser.cpp:
              (WebCore::CSSParser::parseReflect): Ditto.
      
              * css/CSSReflectValue.h: Added a create function. Got rid of the setter
              functions, which had const PassRefPtr& arguments -- those probably caused
              the leaks although I'm not exactly sure why. Made the contructor and all
              the data members private.
      
              * rendering/style/RenderStyle.h: Changed to include CSSReflectionDirection.h
              instead of CSSReflectValue.h so we can tweak CSSReflectValue without
              recompiling the world.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33572 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      a79c5fb7
    • zecke@webkit.org's avatar
      2008-05-19 Holger Hans Peter Freyther <zecke@selfish.org> · 88462144
      zecke@webkit.org authored
              Rubber Stamped by Simon.
      
              Enforce the WebKit Coding Style.
      
              * plugins/PluginView.cpp:
              (WebCore::PluginView::load):
              (WebCore::PluginView::setValue):
              * plugins/gtk/PluginViewGtk.cpp:
              (WebCore::PluginView::setFocus):
              (WebCore::PluginView::show):
              (WebCore::PluginView::hide):
              (WebCore::PluginView::attachToWindow):
              (WebCore::PluginView::detachFromWindow):
              (WebCore::PluginView::getValueStatic):
              (WebCore::PluginView::getValue):
              * plugins/qt/PluginViewQt.cpp:
              (WebCore::PluginView::updateWindow):
              (WebCore::PluginView::detachFromWindow):
              (WebCore::PluginView::handlePostReadFile):
              (WebCore::PluginView::getValueStatic):
              (WebCore::PluginView::getValue):
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33571 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      88462144
    • zecke@webkit.org's avatar
      2008-05-14 Marc Ordinas i Llopis <marc.ordinasillopis@collabora.co.uk> · b3b076ce
      zecke@webkit.org authored
              Reviewed by Holger.
      
              https://bugs.webkit.org/show_bug.cgi?id=18882
              https://bugs.webkit.org/show_bug.cgi?id=18892
              Based also on work by Chris Lord.
      
              Provides support for NPAPI plugins that pass NULL as their instance
              info. There are two kinds:
              - Some call NPN_UserAgent and NPN_GetValue before a PluginView has
              been created. For those we provide static versions of those functions.
              - Others call NPN_* functions with a NULL instance inside NPP_*
              calls, for those we've added extra currentPluginView guards.
      
              * plugins/PluginView.cpp: Add additional currentPluginView guards and
              some small style changes.
              (WebCore::PluginView::start):
              (WebCore::PluginView::performRequest):
              (WebCore::PluginView::bindingInstance):
              (WebCore::PluginView::handlePost):
              * plugins/PluginView.h: Added static versions of NPN_UserAgent and
              NPN_GetValue.
              * plugins/gtk/PluginViewGtk.cpp: Add additional currentPluginView
              guards and some small style changes.
              (WebCore::PluginView::setNPWindowRect):
              (WebCore::PluginView::stop):
              (WebCore::PluginView::userAgentStatic): Added to deal with plugins
              that query this before having a PluginView.
              (WebCore::PluginView::getValueStatic): Added to deal with plugins
              that call this before we have created a PluginView.
              (WebCore::PluginView::getValue): Moved some code to getValueStatic.
              (WebCore::PluginView::init):
              * plugins/npapi.cpp: Call PluginView::userAgentStatic
              and PluginView::getValueStatic if no PluginView is
              present.
              (NPN_UserAgent):
              (NPN_GetValue):
              * plugins/qt/PluginPackageQt.cpp:
              (WebCore::PluginPackage::fetchInfo): Corrected split args because ignoring
              empty entries crashed.
              (WebCore::PluginPackage::load): Resolve all symbols when loading plugins
              to protect against XPCOM dependencies.
              * plugins/qt/PluginViewQt.cpp: Add additional currentPluginView guards and
              some small style changes.
              (WebCore::PluginView::updateWindow):
              (WebCore::PluginView::setNPWindowRect):
              (WebCore::PluginView::stop):
              (WebCore::PluginView::userAgentStatic): Added to deal with plugins
              that query this before having a PluginView.
              (WebCore::PluginView::handlePostReadFile):
              (WebCore::PluginView::getValueStatic): Added to deal with plugins
              that call this before we have created a PluginView.
              (WebCore::PluginView::getValue): Moved some code to getValueStatic.
              (WebCore::PluginView::init): m_needsXEmbed init was moved to constructor.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33570 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      b3b076ce
    • alp@webkit.org's avatar
      2008-05-19 Alp Toker <alp@nuanti.com> · 2649634d
      alp@webkit.org authored
              GTK+ build fix on Mac. Conditionalize XP_UNIX use.
      
              * plugins/gtk/PluginPackageGtk.cpp:
              (WebCore::PluginPackage::fetchInfo):
              (WebCore::PluginPackage::load):
              * plugins/gtk/PluginViewGtk.cpp:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33569 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      2649634d
  3. 18 May, 2008 3 commits
    • cfleizach@apple.com's avatar
    • darin@apple.com's avatar
      WebCore: · 251dd172
      darin@apple.com authored
      2008-05-18  Darin Adler  <darin@apple.com>
      
              Reviewed by Sam.
      
              - fix <rdar://problem/5943569> crash due to stale ownerNode pointer
      
              Test: fast/dom/StyleSheet/ownerNode-lifetime.html
      
              * bindings/js/JSStyleSheetCustom.cpp:
              (WebCore::JSStyleSheet::mark): Added code to mark ownerNode. Includes a comment about how
              it would be even better to solve this in the DOM rather than just in the JavaScript binding.
      
              * css/StyleSheet.idl: Added CustomMarkFunction attribute.
      
      LayoutTests:
      
      2008-05-18  Darin Adler  <darin@apple.com>
      
              Reviewed by Sam.
      
              - test for <rdar://problem/5943569> crash due to stale ownerNode pointer
      
              * fast/dom/StyleSheet: Added.
              * fast/dom/StyleSheet/ownerNode-lifetime-expected.txt: Added.
              * fast/dom/StyleSheet/ownerNode-lifetime.html: Added.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33567 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      251dd172
    • beidson@apple.com's avatar
      WebCore: · 625503cf
      beidson@apple.com authored
      2008-05-18  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Sam Weinig
      
              Fix for https://bugs.webkit.org/show_bug.cgi?id=19111
              Allow `delete storage.itemName` syntax as an alias for `storage.removeItem("itemName")`
      
              Tests: storage/domstorage/localstorage/delete-removal.html
                     storage/domstorage/sessionstorage/delete-removal.html
      
              * bindings/js/JSStorageCustom.cpp:
              (WebCore::JSStorage::deleteProperty): Only do the delete for non-built in properties
              * storage/Storage.idl:
      
      LayoutTests:
      
      2008-05-18  Brady Eidson  <beidson@apple.com>
      
              Reviewed by Sam Weinig
      
              Fix for https://bugs.webkit.org/show_bug.cgi?id=19111
              Allow `delete storage.itemName` syntax as an alias for `storage.removeItem("itemName")`
      
              * storage/domstorage/localstorage/delete-removal-expected.txt: Added.
              * storage/domstorage/localstorage/delete-removal.html: Added.
              * storage/domstorage/sessionstorage/delete-removal-expected....
      625503cf
  4. 17 May, 2008 4 commits
    • weinig@apple.com's avatar
      2008-05-17 Sam Weinig <sam@webkit.org> · 0b212a94
      weinig@apple.com authored
              Reviewed by Mark Rowe.
      
              Re-factor core setRequestHeader logic into setRequestHeaderInternal.
      
              * xml/XMLHttpRequest.cpp:
              (WebCore::XMLHttpRequest::sameOriginRequest):
              (WebCore::XMLHttpRequest::setRequestHeader):
              (WebCore::XMLHttpRequest::setRequestHeaderInternal):
              * xml/XMLHttpRequest.h:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33561 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      0b212a94
    • weinig@apple.com's avatar
      WebCore: · 87a569ca
      weinig@apple.com authored
      2008-05-17  Sam Weinig  <sam@webkit.org>
      
              Reviewed by Mark Rowe.
      
              Differentiate between cancelation errors and generic network error in XHR.
      
              * loader/FrameLoader.cpp:
              (WebCore::FrameLoader::requestFromDelegate):
              (WebCore::FrameLoader::cancelledError):
              * platform/network/ResourceErrorBase.h:
              (WebCore::ResourceErrorBase::setIsCancelation):
              (WebCore::ResourceErrorBase::isCancelation):
              (WebCore::ResourceErrorBase::ResourceErrorBase):
              Add state that differentiates between errors created by cancelation and those made
              by all other generic network errors as this differentiation is needed by some specs.
      
              * xml/XMLHttpRequest.cpp:
              (WebCore::XMLHttpRequest::open):
              (WebCore::XMLHttpRequest::loadRequestSynchronously):
              (WebCore::XMLHttpRequest::clearResponseEntityBody):
              (WebCore::XMLHttpRequest::genericError):
              (WebCore::XMLHttpRequest::networkError):
              (WebCore::XMLHttpRequest::abortError):
              (WebCore::XMLHttpRequest::didFail):
              * xml/XMLHttpRequest.h:
              * xml/XMLHttpRequestException.h:
              (WebCore::XMLHttpRequestException::):
              * xml/XMLHttpRequestException.idl:
              Add ABORT_ERR. This error cannot be raised with the current WebKit architecture
              as it requires the ability to cancel a synchronous XHR, which we cannot currently
              do.  It may be possible in the future though.
      
      LayoutTests:
      
      2008-05-17  Sam Weinig  <sam@webkit.org>
      
              Reviewed by Mark Rowe.
      
              Update expected results for new ABORT_ERR.
      
              * fast/dom/Window/window-properties-expected.txt:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33559 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      87a569ca
    • mrowe@apple.com's avatar
      2008-05-17 Mark Rowe <mrowe@apple.com> · 212d5880
      mrowe@apple.com authored
              Reviewed by Sam Weinig.
      
              Including wtf/Platform.h or using any of the macros it defines in headers that may be
              included from outside of the WebKit project causes any project using those headers to
              fail to build.
      
              * page/mac/WebDashboardRegion.h:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33555 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      212d5880
    • weinig@apple.com's avatar
      2008-05-17 Sam Weinig <sam@webkit.org> · 4e530433
      weinig@apple.com authored
              Reviewed by Brady Eidson.
      
              Re-factor send() logic a little to make adding cross-site requests easier.
      
              * xml/XMLHttpRequest.cpp:
              (WebCore::XMLHttpRequest::send):
              (WebCore::XMLHttpRequest::sameOriginRequest):
              (WebCore::XMLHttpRequest::loadRequestSynchronously):
              (WebCore::XMLHttpRequest::loadRequestAsynchronously):
              * xml/XMLHttpRequest.h:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33554 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      4e530433
  5. 16 May, 2008 1 commit