WebKit-https.git
14 years ago Reviewed by.
kmccullo [Thu, 7 Dec 2006 02:47:32 +0000 (02:47 +0000)]
    Reviewed by.

        - Removed a confilct marker

        * ChangeLog:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18054 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years agoLayoutTests:
justing [Thu, 7 Dec 2006 02:46:54 +0000 (02:46 +0000)]
LayoutTests:

        Reviewed by darin

        <rdar://problem/4818134>
        Crash in WebCore::selectRange when invoking WebView:insertNewLine in any empty content editable DIV.

        * editing/selection/select-line-expected.txt: Added.
        * editing/selection/select-line.html: Added.

WebCore:

        Reviewed by darin

        <rdar://problem/4818134>
        Crash in WebCore::selectRange when invoking WebView:insertNewLine in any empty content editable DIV.

        * WebCore.vcproj/WebCore/WebCore.vcproj: Removed RebalanceWhitespaceCommand.*.
        * editing/visible_units.cpp:
        (WebCore::startOfLine): There are VisiblePositions at offset 0 in blocks without
        RootInlineBoxes, like empty editable blocks and bordered blocks.
        (WebCore::endOfLine): Ditto.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18053 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by.
kmccullo [Thu, 7 Dec 2006 02:40:10 +0000 (02:40 +0000)]
    Reviewed by.

        - Removed a confilct marker

        * ChangeLog:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18052 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by john
kmccullo [Thu, 7 Dec 2006 02:24:59 +0000 (02:24 +0000)]
    Reviewed by john

        <rdar://problem/4854869>
        Inserting a new line in a contenteditable=true SPAN whose parent is a DIV asserts

        * editing/htmlediting.cpp:
        (WebCore::enclosingBlock): Use enclosingNodeWithType to prevent escape
        from editable content.
        * editing/markup.cpp:
        (WebCore::createMarkup): A null commonAncestorBlock will happen
        if commonAncestor is inside an inline editable root that doesn't
        contain any blocks.  Removed an early return for this case: the
        code below the early return can and must handle it.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18051 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years agoLayoutTests:
justing [Thu, 7 Dec 2006 01:01:13 +0000 (01:01 +0000)]
LayoutTests:

        Reviewed by john

        <rdar://problem/4854869>
        Inserting a new line in a contenteditable=true SPAN whose parent is a DIV asserts

        * editing/deleting/delete-mixed-editable-content-001-expected.txt:
        * editing/inserting/editable-inline-element-expected.checksum: Added.
        * editing/inserting/editable-inline-element-expected.txt: Added.
        * editing/inserting/editable-inline-element-expected.png: Added.
        * editing/inserting/editable-inline-element.html: Added.

WebCore:

        Reviewed by john

        <rdar://problem/4854869>
        Inserting a new line in a contenteditable=true SPAN whose parent is a DIV asserts

        * editing/htmlediting.cpp:
        (WebCore::enclosingBlock): Use enclosingNodeWithType to prevent escape
        from editable content.
        * editing/markup.cpp:
        (WebCore::createMarkup): A null commonAncestorBlock will happen
        if commonAncestor is inside an inline editable root that doesn't
        contain any blocks.  Removed an early return for this case: the
        code below the early return can and must handle it.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18050 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by John Sullivan
beidson [Thu, 7 Dec 2006 00:41:17 +0000 (00:41 +0000)]
    Reviewed by John Sullivan

        Fixes http://bugs.webkit.org/show_bug.cgi?id=11675 and <rdar://4857669>
        Now we need to explicitly set the data source when loading from a page cache

        * History/WebHistoryItem.mm:
        (-[WebHistoryItem _scheduleRelease]): Enhanced a logging message
        (+[WebHistoryItem _releasePageCache:]): Ditto
        (+[WebHistoryItem _releaseAllPendingPageCaches]): Ditto
        * WebCoreSupport/WebFrameLoaderClient.mm:
        (WebFrameLoaderClient::setDocumentViewFromPageCache): Reset the View's DataSource from the cache, effectively reopening it
        * WebView/WebHTMLView.m:
        (-[NSArray setDataSource:]): Properly Handle resetting the DataSource and "reopening" the view

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18049 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Mark Rowe.
thatcher [Thu, 7 Dec 2006 00:22:54 +0000 (00:22 +0000)]
    Reviewed by Mark Rowe.

        <rdar://problem/4843505> Fix cross-library ivar use for 64-bit Objective-C

        Adds a new WebCore.LP64.exp file that gets appended to the normal export file.
        This new file will have 64-bit only symbols we need to export.

        * WebCore.LP64.exp: Added.
        * WebCore.xcodeproj/project.pbxproj:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18048 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Maciej.
andersca [Thu, 7 Dec 2006 00:08:55 +0000 (00:08 +0000)]
    Reviewed by Maciej.

        Change SubresourceLoader to use a ResourceHandle, and change ResourceHandle to use a NSURLConnection.

        * loader/ResourceLoader.h:
        * loader/SubresourceLoader.cpp:
        (WebCore::SubresourceLoader::create):
        (WebCore::SubresourceLoader::didReceiveData):
        (WebCore::SubresourceLoader::didFinishLoading):
        (WebCore::SubresourceLoader::didFail):
        * loader/SubresourceLoader.h:
        (WebCore::SubresourceLoader::didReceiveAuthenticationChallenge):
        (WebCore::SubresourceLoader::didCancelAuthenticationChallenge):
        (WebCore::SubresourceLoader::willStopBufferingData):
        (WebCore::SubresourceLoader::willCacheResponse):
        (WebCore::SubresourceLoader::receivedCredential):
        (WebCore::SubresourceLoader::receivedRequestToContinueWithoutCredential):
        (WebCore::SubresourceLoader::receivedCancellation):
        * loader/SubresourceLoaderClient.h:
        (WebCore::SubresourceLoaderClient::didFail):
        * loader/icon/IconLoader.cpp:
        (WebCore::IconLoader::didFail):
        * loader/icon/IconLoader.h:
        * loader/loader.cpp:
        (WebCore::Loader::didFail):
        * loader/loader.h:
        * loader/mac/ResourceLoaderMac.mm:
        (WebCore::ResourceLoader::ResourceLoader):
        (WebCore::ResourceLoader::addData):
        (WebCore::ResourceLoader::resourceData):
        * loader/mac/SubresourceLoaderMac.mm:
        (WebCore::SubresourceLoader::SubresourceLoader):
        (WebCore::SubresourceLoader::setDefersLoading):
        (WebCore::SubresourceLoader::resourceData):
        (WebCore::SubresourceLoader::load):
        (WebCore::SubresourceLoader::create):
        (WebCore::SubresourceLoader::willSendRequest):
        (WebCore::SubresourceLoader::didReceiveResponse):
        (WebCore::SubresourceLoader::didReceiveData):
        (WebCore::SubresourceLoader::didFinishLoading):
        (WebCore::SubresourceLoader::didFail):
        (WebCore::SubresourceLoader::didCancel):
        * platform/network/ResourceHandle.cpp:
        (WebCore::ResourceHandle::ResourceHandle):
        (WebCore::ResourceHandle::create):
        * platform/network/ResourceHandle.h:
        * platform/network/ResourceHandleClient.h:
        (WebCore::ResourceHandleClient::didReceiveData):
        (WebCore::ResourceHandleClient::didFail):
        (WebCore::ResourceHandleClient::didReceiveAuthenticationChallenge):
        (WebCore::ResourceHandleClient::didCancelAuthenticationChallenge):
        (WebCore::ResourceHandleClient::willStopBufferingData):
        (WebCore::ResourceHandleClient::willCacheResponse):
        (WebCore::ResourceHandleClient::receivedCredential):
        (WebCore::ResourceHandleClient::receivedRequestToContinueWithoutCredential):
        (WebCore::ResourceHandleClient::receivedCancellation):
        * platform/network/ResourceHandleInternal.h:
        (WebCore::ResourceHandleInternal::ResourceHandleInternal):
        * platform/network/mac/ResourceHandleMac.mm:
        (WebCore::ResourceHandle::~ResourceHandle):
        (WebCore::ResourceHandle::start):
        (WebCore::ResourceHandle::cancel):
        (WebCore::ResourceHandle::setDefersLoading):
        (WebCore::ResourceHandle::delegate):
        (WebCore::ResourceHandle::releaseDelegate):
        (WebCore::ResourceHandle::supportsBufferedData):
        (WebCore::ResourceHandle::bufferedData):
        (-[WebCoreResourceHandleAsDelegate initWithHandle:]):
        (-[WebCoreResourceHandleAsDelegate detachHandle]):
        (-[WebCoreResourceHandleAsDelegate connection:willSendRequest:redirectResponse:]):
        (-[WebCoreResourceHandleAsDelegate connection:didReceiveAuthenticationChallenge:]):
        (-[WebCoreResourceHandleAsDelegate connection:didCancelAuthenticationChallenge:]):
        (-[WebCoreResourceHandleAsDelegate connection:didReceiveResponse:]):
        (-[WebCoreResourceHandleAsDelegate connection:didReceiveData:lengthReceived:]):
        (-[WebCoreResourceHandleAsDelegate connection:willStopBufferingData:]):
        (-[WebCoreResourceHandleAsDelegate connectionDidFinishLoading:]):
        (-[WebCoreResourceHandleAsDelegate connection:didFailWithError:]):
        (-[WebCoreResourceHandleAsDelegate connection:willCacheResponse:]):
        (-[WebCoreResourceHandleAsDelegate useCredential:forAuthenticationChallenge:]):
        (-[WebCoreResourceHandleAsDelegate continueWithoutCredentialForAuthenticationChallenge:]):
        (-[WebCoreResourceHandleAsDelegate cancelAuthenticationChallenge:]):
        * xml/xmlhttprequest.cpp:
        (WebCore::XMLHttpRequest::didFail):
        * xml/xmlhttprequest.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18047 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Adam and Oliver
beidson [Wed, 6 Dec 2006 21:55:35 +0000 (21:55 +0000)]
    Reviewed by Adam and Oliver

        While working on http://bugs.webkit.org/show_bug.cgi?id=11675 I
        decided to fix much of the null-deref problems that creeped in via
        the loader refactoring.  This isn't changing behavior, just reintroducing
        the free nil checking we used to have with pure ObjC

        * WebView/WebHTMLView.m:
        (-[NSArray menuForEvent:]):  Explicitly check for null frames
        (-[NSArray mouseDown:]):  Ditto
        (-[NSArray mouseDragged:]):  Ditto
        (-[NSArray mouseUp:]):  Ditto
        (-[NSArray performKeyEquivalent:]):  Ditto
        (-[WebHTMLView elementAtPoint:allowShadowContent:]):  Ditto

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18046 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Adam.
bdakin [Wed, 6 Dec 2006 21:54:47 +0000 (21:54 +0000)]
    Reviewed by Adam.

        There are two bugs with WebCore ContextMenus due to the static
        ContextMenuItems. One bug is that we often crashed in
        NSAutoreleasePool upon quitting the browser. The other bug is that
        we were adding static NSMenuItems to multiple NSMenus, which is
        disallowed. To fix these bugs, the MenuItems are no longer static.
        This is in line with the current design in WebKit anyway. I made
        some re-arrangements in the code because I also removed the macro
        that was used to create the menu items since it was a bit
        confusing.

        * platform/ContextMenu.cpp:
        (WebCore::createFontSubMenu):
        (WebCore::createSpellingAndGrammarSubMenu):
        (WebCore::createSpellingSubMenu):
        (WebCore::createSpeechSubMenu):
        (WebCore::createWritingDirectionSubMenu):
        (WebCore::ContextMenu::populate):
        * platform/ContextMenuItem.h:
        * platform/mac/ContextMenuItemMac.mm:
        (WebCore::ContextMenuItem::ContextMenuItem): Use the NSMenuItem
        global separator item if we have SeparatorType.
        * platform/mac/ContextMenuMac.mm:
        (WebCore::setMenuItemTarget):  Change name of getNSMenuItem since
        that is no longer accurate.
        (WebCore::ContextMenu::appendItem): Above name change.
        (WebCore::ContextMenu::insertItem): Same.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18045 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Geof.
kmccullo [Wed, 6 Dec 2006 21:46:18 +0000 (21:46 +0000)]
    Reviewed by Geof.

        - Returned the semantic meaning of the mask to be the actual repeat count,
        and changed auto_repeat to correctly differnetiate between keypressed and keydown.

        * platform/win/KeyEventWin.cpp:
        (WebCore::PlatformKeyboardEvent::PlatformKeyboardEvent):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18044 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years agoLayoutTests:
justing [Wed, 6 Dec 2006 21:01:30 +0000 (21:01 +0000)]
LayoutTests:

        Reviewed by harrison

        <rdar://problem/4753545>
        REGRESSION: Edited whitespace sequences are all nbsps (10636)

        * editing/inserting/edited-whitespace-1-expected.checksum: Added.
        * editing/inserting/edited-whitespace-1-expected.png: Added.
        * editing/inserting/edited-whitespace-1-expected.txt: Added.
        * editing/inserting/edited-whitespace-1.html: Added.

WebCore:

        Reviewed by harrison

        <rdar://problem/4753545>
        REGRESSION: Edited whitespace sequences are all nbsps (10636)

        * WebCore.xcodeproj/project.pbxproj: Removed RebalanceWhitespaceCommand.* from the project.
        * editing/CompositeEditCommand.cpp:
        (WebCore::isWhitespace): Moved from htmlediting.
        (WebCore::CompositeEditCommand::rebalanceWhitespaceAt): Moved the work that was
        once done in its own command here.
        (WebCore::CompositeEditCommand::prepareWhitespaceAtPositionForSplit): Prevents
        whitespace around a position from collapsing when it's pushed apart during Paste.
        This function can eventually be deployed to eliminate the need for leading/trailing
        whitespace handling in InsertParagraphSeparator, InsertLineBreak, Delete, and BreakBlockquote.
        (WebCore::CompositeEditCommand::rebalanceWhitespace): Cleaned up.
        * editing/CompositeEditCommand.h:
        * editing/DeleteSelectionCommand.cpp:
        (WebCore::DeleteSelectionCommand::doApply): Do rebalanceWhitespaceAt *before*
        saving the typing style, because whitespace rebalancing is no longer it's own
        command that claims to preserve the typing style.
        * editing/RebalanceWhitespaceCommand.cpp: Removed.
        * editing/RebalanceWhitespaceCommand.h: Removed.
        * editing/ReplaceSelectionCommand.cpp:
        (WebCore::ReplaceSelectionCommand::doApply): Moved the code to prepare whitespace
        arond a position for being pushed aparat to its own method.
        * editing/htmlediting.cpp:
        (WebCore::stringWithRebalancedWhitespace): Added.  Returns a rebalanced string.
        Takes in whether or not the beginning of that string will be at the start of
        a paragraph, because a space at such a position must have be nbsp, even if
        that doesn't follow the nbsp/space pattern used.  Similar stuff for the end
        of a paragraph.
        * editing/htmlediting.h:
        * editing/markup.cpp:
        (WebCore::fillContainerFromString): Call stringWithRelabacedWhitespace.  Pass
        it the startOfParagraph/endOfParagraph bools.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18043 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Brady.
rwlbuis [Wed, 6 Dec 2006 20:39:23 +0000 (20:39 +0000)]
    Reviewed by Brady.

        http://bugs.webkit.org/show_bug.cgi?id=10254
        A few grammar and spelling corrections on the WebKit website

        Grammar and spelling corrections by Jonathan Johnsson.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18042 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years agoWebCore:
sullivan [Wed, 6 Dec 2006 18:50:27 +0000 (18:50 +0000)]
WebCore:

        Reviewed by Beth

        Moved spelling and grammar code from Frame to Editor

        * WebCore.exp:
        updated for these changes

        * page/Frame.h:
        removed declarations of spelling and grammar functions

        * bridge/mac/FrameMac.h:
        removed declarations of spelling and grammar functions

        * bridge/mac/FrameMac.mm:
        moved implementation of spelling and grammar functions from here
        (WebCore::FrameMac::respondToChangedSelection):
        updated for moved functions

        * editing/Editor.h:
        moved declarations of spelling and grammar functions to here

        * editing/mac/EditorMac.mm:
        moved implementation of spelling and grammar functions to here; changed
        only to make it compile (e.g. removing "editor()->" and adding "frame()->"
        where appropraite.
        (WebCore::findFirstMisspellingInRange):
        (WebCore::paragraphAlignedRangeForRange):
        (WebCore::findFirstGrammarDetailInRange):
        (WebCore::findFirstBadGrammarInRange):
        (WebCore::Editor::advanceToNextMisspelling):
        (WebCore::Editor::isSelectionMisspelled):
        (WebCore::isRangeUngrammatical):
        (WebCore::Editor::isSelectionUngrammatical):
        (WebCore::Editor::guessesForUngrammaticalSelection):
        (WebCore::core):
        (WebCore::Editor::guessesForMisspelledSelection):
        (WebCore::Editor::markMisspellingsInAdjacentWords):
        (WebCore::markAllMisspellingsInRange):
        (WebCore::markAllBadGrammarInRange):
        (WebCore::Editor::markMisspellings):

        * platform/ContextMenu.cpp:
        (WebCore::ContextMenu::populate):
        updated for moved functions

        * editing/TypingCommand.cpp:
        (WebCore::TypingCommand::markMisspellingsAfterTyping):
        updated for moved functions

WebKit:

        Reviewed by Beth

        Updated to match Frame -> Editor changes in WebCore

        * DefaultDelegates/WebDefaultContextMenuDelegate.m:
        (-[WebDefaultUIDelegate editingContextMenuItemsForElement:defaultMenuItems:]):
        guessesForUngrammaticalSelection() is now in Editor

        * WebView/WebHTMLView.m:
        (-[WebHTMLView _isSelectionUngrammatical]):
        isSelectionUngrammatical() is now in Editor
        (-[WebHTMLView _isSelectionMisspelled]):
        isSelectionMisspelled() is now in Editor

        (-[WebHTMLView checkSpelling:]):
        advanceToNextMisspelling() is now in Editor
        (-[WebHTMLView showGuessPanel:]):
        ditto

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18041 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Maciej.
andersca [Wed, 6 Dec 2006 02:09:30 +0000 (02:09 +0000)]
    Reviewed by Maciej.

        General cleanup, get rid of PlatformResponse (we have ResourceResponse now)
        and remove a couple of functions that were unused.

        * loader/CachedResource.h:
        * loader/LoaderFunctions.h:
        * loader/mac/LoaderFunctionsMac.mm:
        * platform/network/ResourceHandle.h:
        * platform/network/ResourceHandleClient.h:
        * platform/network/mac/ResourceHandleMac.mm:
        (WebCore::ResourceHandle::~ResourceHandle):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18039 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by John.
kmccullo [Wed, 6 Dec 2006 02:01:03 +0000 (02:01 +0000)]
    Reviewed by John.

        - keydown is now a keydown event instead of a keypress event.
          Fixes some form submission odditties.

        * platform/win/KeyEventWin.cpp:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18038 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Tiger build fix
sullivan [Wed, 6 Dec 2006 00:18:34 +0000 (00:18 +0000)]
    Tiger build fix

        * editing/mac/EditorMac.mm:
        declare -[NSSpellChecker learnWord:], on Tiger only (it's API on Leopard)

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18036 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Geoff Garen
sullivan [Tue, 5 Dec 2006 23:48:04 +0000 (23:48 +0000)]
    Reviewed by Geoff Garen

        * page/Frame.h:
        remove declarations of ignoreSpelling() and learnSpelling()

        * bridge/mac/FrameMac.h:
        remove declarations of ignoreSpelling() and learnSpelling()
        * bridge/mac/FrameMac.mm:
        moved implementations of ignoreSpelling() and learnSpelling() from here

        * editing/Editor.h:
        added declarations of ignoreSpelling() and learnSpelling()

        * editing/mac/EditorMac.mm:
        (WebCore::Editor::ignoreSpelling):
        moved here from FrameMac.mm
        (WebCore::Editor::learnSpelling):
        ditto

        * page/ContextMenuController.cpp:
        (WebCore::ContextMenuController::contextMenuItemSelected):
        updated callers to use frame()->editor() rather than frame()

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18035 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago2006-12-04 Steve Falkenburg <sfalken@apple.com>
sfalken [Tue, 5 Dec 2006 23:15:09 +0000 (23:15 +0000)]
2006-12-04  Steve Falkenburg  <sfalken@apple.com>

        Reviewed by Darin.

        Make extract-localizable-strings compatible with cpp file extensions.

        * Scripts/extract-localizable-strings:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18034 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years agoWebCore:
sullivan [Tue, 5 Dec 2006 22:34:54 +0000 (22:34 +0000)]
WebCore:

        Reviewed by Adam

        New context-menu mechanism fix for:
        <rdar://problem/4864351> Should leave out "No Guesses Found" from context menu for bad grammar

        * platform/ContextMenu.cpp:
        (WebCore::ContextMenu::populate):
        Leave out "No Guesses Found" and separator for grammar-checking case.

WebKit:

        Reviewed by Adam

        Old context-menu mechanism fix for:
        <rdar://problem/4864351> Should leave out "No Guesses Found" from context menu for bad grammar

        * DefaultDelegates/WebDefaultContextMenuDelegate.m:
        (-[WebDefaultUIDelegate editingContextMenuItemsForElement:defaultMenuItems:]):
        Leave out "No Guesses Found" and separator for grammar-checking case.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18033 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Mitz.
rwlbuis [Tue, 5 Dec 2006 21:47:46 +0000 (21:47 +0000)]
    Reviewed by Mitz.

        http://bugs.webkit.org/show_bug.cgi?id=11686
        WebKit draws Carto.net tabgroup example completely incorrectly (ff does fine)

        Make sure the SVG render objects are laid out before measuring their
        dimensions using relativeBBox.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18032 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Darin
sullivan [Tue, 5 Dec 2006 21:24:03 +0000 (21:24 +0000)]
    Reviewed by Darin

        Grammar/Spelling code re-homing, baby step one: put isGrammarCheckingEnabled in Editor
        since that's where isContinousSpellCheckingEnabled lives.

        * editing/Editor.h:
        * editing/Editor.cpp:
        (WebCore::Editor::isGrammarCheckingEnabled):
        new method, calls through to client a la isContinuousSpellCheckingEnabled

        * bridge/mac/FrameMac.mm:
        (WebCore::FrameMac::advanceToNextMisspelling):
        call editor() rather than editor()->client()
        (WebCore::FrameMac::markMisspellings):
        ditto

        * platform/ContextMenu.cpp:
        (WebCore::ContextMenu::populate):
        ditto

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18031 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Geoff.
darin [Tue, 5 Dec 2006 21:08:55 +0000 (21:08 +0000)]
    Reviewed by Geoff.

        - a little cleanup

        * html/HTMLInputElement.h: Removed unneeded includes of RenderObject.h
        and RenderStyle.h.
        * html/HTMLSelectElement.h: Removed unneeded include of RenderStyle.h.
        * ksvg2/svg/SVGStyledElement.h: Removed unneeded include of RenderStyle.h.

        * ksvg2/svg/SVGSVGElement.h: Remove unneeded parameter to createSVGPoint.
        * ksvg2/svg/SVGSVGElement.cpp: (WebCore::SVGSVGElement::createSVGPoint):
        Ditto.

        * ksvg2/scripts/generateJSBindings.pl: Removed unused script.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18030 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago * doc: Removed empty directory. It's not clear this is a good place for
darin [Tue, 5 Dec 2006 19:49:53 +0000 (19:49 +0000)]
    * doc: Removed empty directory. It's not clear this is a good place for
        documentation, so lets add it back later if we actually start using it.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18027 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Brady, Darin.
andersca [Tue, 5 Dec 2006 19:03:43 +0000 (19:03 +0000)]
    Reviewed by Brady, Darin.

        * loader/loader.cpp:
        (WebCore::Loader::receivedAllData):
        Remove ref() call that was left around by mistake.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18024 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago build fix
sullivan [Tue, 5 Dec 2006 19:01:50 +0000 (19:01 +0000)]
    build fix

        * WebView/WebViewPrivate.h:
        * WebView/WebView.mm:
        (-[WebView isGrammarCheckingEnabled]):
        define isGrammarCheckingEnabled whether on Tiger or not (just return NO on Tiger)

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18023 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Tim H.
weinig [Tue, 5 Dec 2006 18:40:59 +0000 (18:40 +0000)]
    Reviewed by Tim H.

        Fix for http://bugs.webkit.org/show_bug.cgi?id=11758
        Don't compile custom SVG and XSLT bindings in non-svg build

        * bindings/js/JSSVGNumber.cpp:
        * bindings/js/JSSVGNumber.h:
        * bindings/js/JSSVGPoint.cpp:
        * bindings/js/JSSVGPoint.h:
        * bindings/js/JSSVGRect.cpp:
        * bindings/js/JSSVGRect.h:
        * bindings/js/JSXSLTProcessor.cpp:
        * bindings/js/JSXSLTProcessor.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18022 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years agoWebCore:
sullivan [Tue, 5 Dec 2006 18:36:06 +0000 (18:36 +0000)]
WebCore:

        Reviewed by Darin

        WebCore part of fix for:
        <rdar://problem/4817188> Context menu for bad grammar should include suggestions and "Ignore Grammar"

        The context menu mechanism is currently in flux; the old mechanism is still in place, but an
        up-and-coming new mechanism is waiting in the wings. I updated both of them, but couldn't
        test the new mechanism because it doesn't work well enough yet. Also, some of this code
        should move from Frame to Editor, but that will wait for another checkin.

        * page/Frame.h:
        added pure virtual function declarations for isSelectionUngrammatical() and guessesForUngrammaticalSelection()

        * bridge/mac/FrameMac.h:
        added virtual functions declarations for isSelectionUngrammatical() and guessesForUngrammaticalSelection()

        * bridge/mac/FrameMac.mm:
        (WebCore::FrameMac::isSelectionMisspelled):
        now updates spelling panel (whether or not it's showing), since this is now needed to make -[NSSSpellChecker
        ignoreWord:inSpellDocumentWithTag:] work correctly
        (WebCore::isRangeUngrammatical):
        new function, helper used by both isSelectionUngrammatical() and guessesForUngrammaticalSelection()
        (WebCore::FrameMac::isSelectionUngrammatical):
        new function, calls isRangeUngrammatical
        (WebCore::FrameMac::guessesForUngrammaticalSelection):
        ditto

        * platform/ContextMenu.cpp:
        (WebCore::ContextMenu::populate):
        now considers bad grammar as well as misspellings

        * platform/ContextMenuItem.h:
        added ContextMenuItemTagIgnoreGrammar

WebKit:

        Reviewed by Darin

        WebKit part of fix for:
        <rdar://problem/4817188> Context menu for bad grammar should include suggestions and "Ignore Grammar"

        The context menu mechanism is currently in flux; the old mechanism is still in place, but an
        up-and-coming new mechanism is waiting in the wings. I updated both of them, but couldn't
        test the new mechanism because it doesn't work well enough yet. Most of this WebKit code
        can be deleted when the new mechanism is in place.

        * WebView/WebUIDelegatePrivate.h:
        added WebMenuItemTagIgnoreGrammar

        * DefaultDelegates/WebDefaultContextMenuDelegate.m:
        (-[WebDefaultUIDelegate menuItemWithTag:target:representedObject:]):
        added case for WebMenuItemTagIgnoreGrammar
        (-[WebDefaultUIDelegate editingContextMenuItemsForElement:defaultMenuItems:]):
        now considers adding grammar-related items as well as spelling-related items

        * WebView/WebHTMLViewPrivate.h:
        declared _isSelectionUngrammatical

        * WebView/WebHTMLView.m:
        (-[WebHTMLView _isSelectionUngrammatical]):
        new method, calls through to WebCore
        (-[WebHTMLView _ignoreGrammarFromMenu:]):
        new method, calls _ignoreSpellingFromMenu: since NSSpellChecker has one method for both

        * English.lproj/Localizable.strings:
        updated for "Ignore Grammar" menu item title

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18021 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago2006-12-05 Kirby White <KWhiteRight@gmail.com>
ap [Tue, 5 Dec 2006 12:31:52 +0000 (12:31 +0000)]
2006-12-05  Kirby White  <KWhiteRight@gmail.com>

        Reviewed, tweaked and landed by Alexey.

        <http://bugs.webkit.org/show_bug.cgi?id=11639> Form buttons don't look different when clicked

        * rendering/RenderThemeWin.cpp:
        (WebCore::RenderThemeWin::determineState): Moved test for active
        state before test for hover state, since active should override hover
        when both are true.

        * platform/gdk/RenderThemeGdk.cpp:
        (WebCore::RenderThemeGdk::determineState): Same fix.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18020 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago2006-12-05 Kirby White <KWhiteRight@gmail.com>
ap [Tue, 5 Dec 2006 10:23:25 +0000 (10:23 +0000)]
2006-12-05  Kirby White  <KWhiteRight@gmail.com>

        Reviewed and landed by Alexey.

        http://bugs.webkit.org/show_bug.cgi?id=11681
        Don't select the first option when resetting a listbox-style form
        control (i.e., a multi-select control or one with size > 1) that
        has no default selection.

        Test: fast/dom/HTMLSelectElement/listbox-select-reset.html

        * html/HTMLSelectElement.cpp:
        (WebCore::HTMLSelectElement::reset):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18019 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Rob.
ap [Tue, 5 Dec 2006 08:51:18 +0000 (08:51 +0000)]
    Reviewed by Rob.

        Make this test pass on PowerPC, too (the calculation was giving 4.7e-16 instead of zero,
        now rounding it to 15 digits).

        * svg/custom/getTransformToElement.svg:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18018 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago2006-12-05 Lars Naesbye Christensen <larsnaesbye@stud.ku.dk>
ap [Tue, 5 Dec 2006 08:26:38 +0000 (08:26 +0000)]
2006-12-05  Lars Naesbye Christensen  <larsnaesbye@stud.ku.dk>

        Reviewed and landed by Alexey.

        http://bugs.webkit.org/show_bug.cgi?id=11752
        [CSS 3] missing support for cursor selector 'copy'

        * Resources/copyCursor.png: Added.
        * WebCore.xcodeproj/project.pbxproj:
        * css/CSSComputedStyleDeclaration.cpp:
        (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
        * css/CSSValueKeywords.in:
        * manual-tests/cursor.html:
        * page/EventHandler.cpp:
        (WebCore::selectCursor):
        * platform/Cursor.h:
        * platform/mac/CursorMac.mm:
        (WebCore::copyCursor):
        * rendering/RenderStyle.h:
        (WebCore::):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18017 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Geoff.
bdakin [Tue, 5 Dec 2006 06:50:04 +0000 (06:50 +0000)]
    Reviewed by Geoff.

        Fix from last check-in. This line was badbad.

        * platform/mac/ContextMenuMac.mm:
        (WebCore::ContextMenu::~ContextMenu):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18016 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Geoff.
bdakin [Tue, 5 Dec 2006 06:33:03 +0000 (06:33 +0000)]
    Reviewed by Geoff.

        With the new changes to ContextMenuItems, WebCore context menus
        stopped appearing at all. And then when I got them to appear, they
        crashed. This fixes both of these problems.

        * platform/mac/ContextMenuItemMac.mm:
        (WebCore::ContextMenuItem::ContextMenuItem): keyEquivalent cannot
        be nil. This was causing Obj-C to throw an exception preventing the
        menus from popping up at all.
        * platform/mac/ContextMenuMac.mm:
        (+[WebCoreMenuTarget sharedMenuTarget]): Re-name our static
        MenuTarget so that it is more clear that it is a static and shared
        WebCoreMenuTarget.
        (WebCore::ContextMenu::ContextMenu): Initialize the
        WebCoreMenuTarget's controller in the ContextMenu constructor
        instead of in getNSMenuItem since the controller will only possibly
        change when a new ContextMenu has been created.
        (WebCore::ContextMenu::~ContextMenu): Set the target's controller
        to 0.
        (WebCore::getNSMenuItem): A lot of this work is being done other
        places now. Call new class method on WebCoreMenuTarget to get the
        shared target.
        (WebCore::ContextMenu::appendItem): We should not be releasing the
        menuItem here! This caused the crashes I saw.
        (WebCore::ContextMenu::insertItem): Same.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18015 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Fix the build.
andersca [Tue, 5 Dec 2006 03:37:31 +0000 (03:37 +0000)]
    Fix the build.

        * loader/mac/SubresourceLoaderMac.mm:
        (WebCore::SubresourceLoader::~SubresourceLoader):
        Add back the destructor.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18014 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Darin.
andersca [Tue, 5 Dec 2006 03:07:16 +0000 (03:07 +0000)]
    Reviewed by Darin.

        Change all ResourceHandleClients to be SubresourceLoaderClients instead. Also,
        make SubresourceLoader a ResourceHandleClient. This is a first step towards turning ResourceHandle into a
        standalone class which doesn't need to know about SubresourceLoader.

        * WebCore.xcodeproj/project.pbxproj:
        * loader/ResourceLoader.cpp:
        (WebCore::ResourceLoader::~ResourceLoader):
        (WebCore::ResourceLoader::ResourceLoader):
        (WebCore::ResourceLoader::setDefersLoading):
        * loader/SubresourceLoader.cpp:
        (WebCore::SubresourceLoader::SubresourceLoader):
        (WebCore::SubresourceLoader::~SubresourceLoader):
        (WebCore::SubresourceLoader::create):
        (WebCore::SubresourceLoader::willSendRequest):
        (WebCore::SubresourceLoader::didReceiveResponse):
        (WebCore::SubresourceLoader::didReceiveData):
        (WebCore::SubresourceLoader::didFinishLoading):
        (WebCore::SubresourceLoader::didFailWithError):
        (WebCore::SubresourceLoader::receivedAllData):
        * loader/SubresourceLoader.h:
        (WebCore::SubresourceLoader::loaderAsResourceHandleClient):
        (WebCore::SubresourceLoader::handle):
        * loader/SubresourceLoaderClient.h: Added.
        (WebCore::SubresourceLoaderClient::~SubresourceLoaderClient):
        (WebCore::SubresourceLoaderClient::willSendRequest):
        (WebCore::SubresourceLoaderClient::didReceiveResponse):
        (WebCore::SubresourceLoaderClient::didReceiveData):
        (WebCore::SubresourceLoaderClient::didFinishLoading):
        (WebCore::SubresourceLoaderClient::didFailWithError):
        (WebCore::SubresourceLoaderClient::receivedAllData):
        * loader/icon/IconLoader.cpp:
        (WebCore::IconLoader::startLoading):
        (WebCore::IconLoader::stopLoading):
        (WebCore::IconLoader::didReceiveResponse):
        (WebCore::IconLoader::didReceiveData):
        (WebCore::IconLoader::didFailWithError):
        (WebCore::IconLoader::didFinishLoading):
        (WebCore::IconLoader::clearLoadingState):
        * loader/icon/IconLoader.h:
        * loader/loader.cpp:
        (WebCore::Loader::servePendingRequests):
        (WebCore::Loader::receivedAllData):
        (WebCore::Loader::didFailWithError):
        (WebCore::Loader::didReceiveResponse):
        (WebCore::Loader::didReceiveData):
        (WebCore::Loader::cancelRequests):
        * loader/loader.h:
        * loader/mac/SubresourceLoaderMac.mm:
        (WebCore::SubresourceLoader::SubresourceLoader):
        (WebCore::SubresourceLoader::create):
        (WebCore::SubresourceLoader::willSendRequest):
        (WebCore::SubresourceLoader::didReceiveResponse):
        (WebCore::SubresourceLoader::didReceiveData):
        (WebCore::SubresourceLoader::didFinishLoading):
        (WebCore::SubresourceLoader::didFail):
        (WebCore::SubresourceLoader::didCancel):
        * platform/network/ResourceHandle.cpp:
        (WebCore::ResourceHandle::ResourceHandle):
        (WebCore::ResourceHandle::create):
        * platform/network/ResourceHandle.h:
        * platform/network/ResourceHandleClient.h:
        * platform/network/ResourceHandleInternal.h:
        (WebCore::ResourceHandleInternal::ResourceHandleInternal):
        * platform/network/mac/ResourceHandleMac.mm:
        (WebCore::ResourceHandle::start):
        (WebCore::ResourceHandle::finishJobAndHandle):
        (WebCore::ResourceHandle::loader):
        * xml/xmlhttprequest.cpp:
        (WebCore::XMLHttpRequest::send):
        (WebCore::XMLHttpRequest::didFailWithError):
        (WebCore::XMLHttpRequest::didFinishLoading):
        (WebCore::XMLHttpRequest::willSendRequest):
        (WebCore::XMLHttpRequest::didReceiveResponse):
        (WebCore::XMLHttpRequest::didReceiveData):
        * xml/xmlhttprequest.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18013 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years agoLayoutTests:
darin [Tue, 5 Dec 2006 01:29:07 +0000 (01:29 +0000)]
LayoutTests:

        Reviewed by Adele.

        - test the part of http://bugs.webkit.org/show_bug.cgi?id=11628
          REGRESSION (r17597): Command-return in text fields doesn't open a new tab or window
          that can easily be tested from the DOM -- this only checks that
          simulated mouse events from clicking on a link have the key state
          from the Enter key keyboard event, which is one part of the fix
          for the bug above

        * fast/events/simulated-key-state-expected.txt: Added.
        * fast/events/simulated-key-state.html: Added.

WebCore:

        Reviewed by Adele.

        - fix another part of http://bugs.webkit.org/show_bug.cgi?id=11628
          REGRESSION (r17597): Command-return in text fields doesn't open a new tab or window

        This fixes command-return when the focus is on a link.
        Despite the title of the bug, Mitz wanted me to fix both, and I will not
        say no to him!

        Test: fast/events/simulated-key-state.html

        * dom/EventTargetNode.cpp:
        (WebCore::EventTargetNode::dispatchSimulatedMouseEvent): Instead of always passing
        false for all the key state in simulated mouse events, pass the state from the
        first underlying event in the chain that has key state; in the case in the bug,
        the keyboard event will be the underlying event itself and we'll propagate the
        alt key modifier to the mouse event, resulting in the effect we want. It's nice
        that JavaScript also gets to see the proper modifiers in the mouse event.

        * html/HTMLAnchorElement.cpp: (WebCore::HTMLAnchorElement::defaultEventHandler):
        Added code to pass in an underlying event to dispatchSimulatedClick. After looking
        at all the other callers, this seems to be the only one that needs to pass an
        event that is currently passing 0. Also removed the code that only simulated a
        click when the event has a PlatformKeyboardEvent -- no reason for that and it
        prevented me from writing a layout test for the fix.

        * dom/UIEventWithKeyState.h: Added findEventWithKeyState function that walks the
        underlyingEvent chain to find the first event that has key state. This already
        existed in WebKit, but I wanted to use it in dispatchSimulatedMouseEvent.
        * dom/UIEventWithKeyState.cpp: Added.

        * CMakeLists.txt: Added UIEventWithKeyState.cpp.
        * WebCore.vcproj/WebCore/WebCore.vcproj: Added UIEventWithKeyState.cpp.
        * WebCore.xcodeproj/project.pbxproj: Added UIEventWithKeyState.cpp.
        * WebCoreSources.bkl: Added UIEventWithKeyState.cpp.

        * WebCore.exp: Added findEventWithKeyState, used by WebKit.

WebKit:

        Reviewed by Adele.

        * WebCoreSupport/WebFrameLoaderClient.mm:
        (WebFrameLoaderClient::actionDictionary): Changed to use the new
        findEventWithKeyState function in WebCore instead of a local function
        in this file.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18012 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Darin.
kmccullo [Tue, 5 Dec 2006 00:49:16 +0000 (00:49 +0000)]
    Reviewed by Darin.

        - removed the guards for the "multiple forms submission" issue, which may not be
          an issue anymore and the guards prevent perfectly legitimate websites from
          working correctly.

        * bridge/mac/FrameMac.mm:
        (WebCore::FrameMac::setView):
        * bridge/mac/WebCoreAXObject.mm:
        (-[WebCoreAXObject accessibilityPerformAction:]):
        * bridge/win/FrameWin.cpp:
        (WebCore::FrameWin::keyPress):
        * config.h:
        * loader/FrameLoader.cpp:
        (WebCore::FrameLoader::submitForm):
        * loader/FrameLoader.h:
        * loader/mac/FrameLoaderMac.mm:
        (WebCore::FrameLoader::receivedMainResourceError):
        * loader/qt/FrameLoaderQt.cpp:
        (WebCore::FrameLoader::submitForm):
        * page/Frame.cpp:
        (WebCore::Frame::setView):
        * page/mac/EventHandlerMac.mm:
        (WebCore::EventHandler::keyEvent):
        (WebCore::EventHandler::mouseDown):
        * platform/qt/FrameQt.cpp:
        (WebCore::FrameQt::keyEvent):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18011 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Rolled out the WebDashboardBehaviorUseBackwardCompatibilityModeEnabled
ggaren [Tue, 5 Dec 2006 00:37:53 +0000 (00:37 +0000)]
    Rolled out the WebDashboardBehaviorUseBackwardCompatibilityModeEnabled
        part of my last checkin.

        We have to turn on support for backward compatibility mode to avoid Dashboard
        regressions in the short term.

        * WebView/WebView.mm:
        (-[WebView _setDashboardBehavior:to:]):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18010 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years agoLayoutTests:
ggaren [Mon, 4 Dec 2006 23:54:29 +0000 (23:54 +0000)]
LayoutTests:

        Reviewed by Darin Adler.

        Removed Dashboard quirk from expected results. Now that we have a Dashboard
        quirks mode, there's no reason to keep the old, bad behavior in the browser.

        * http/tests/xmlhttprequest/exceptions-expected.txt:
        * http/tests/xmlhttprequest/exceptions.html:

WebCore:

        Reviewed by Darin Adler.

        Added support for Dashboard backward compatibility mode.

        * html/CanvasRenderingContext2D.cpp:
        (WebCore::CanvasRenderingContext2D::stroke): Added support for old behavior
        of automatically clearing the stroke path buffer after a call to stroke().
        * html/HTMLCanvasElement.cpp: Added supoprt for old behavior of the canvas
        tag being self-closing.
        (WebCore::HTMLCanvasElement::endTagRequirement):
        (WebCore::HTMLCanvasElement::tagPriority):
        * html/HTMLCanvasElement.h:
        * html/HTMLParser.cpp: Ditto.
        (WebCore::HTMLParser::canvasCreateErrorCheck):
        * xml/xmlhttprequest.cpp: Added support for old behavior of silently ignoring
        a call to setRequestHeader() if it preceded a call to open() or followed a call
        to send().
        (WebCore::XMLHttpRequest::setRequestHeader):

WebKit:

        Reviewed by Darin Adler.

        Added SPI for enabling Dashboard backward compatibility mode. For now,
        we enable it unconditionally for Dashboard and Dashcode. Once they
        implement specific support for the backward compatibility mode behavior,
        we can change that.

        Set the default WebDashboardBehaviorUseBackwardCompatibilityModeEnabled
        to YES in order to turn this code on.

        * WebView/WebView.mm:
        (-[WebView _setDashboardBehavior:to:]):
        (-[WebView _dashboardBehavior:]):
        * WebView/WebViewPrivate.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18009 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years agoWebCore:
darin [Mon, 4 Dec 2006 23:43:17 +0000 (23:43 +0000)]
WebCore:

        Reviewed by Alice.

        * bridge/EditorClient.h: Removed "_web_" prefix from
        C++ userVisibleString member function. Alice will probably change
        this so it's not on the editor client any more later.

        * editing/Editor.h: Removed "_web_" prefix from
        C++ userVisibleString member function.
        * editing/Editor.cpp: Tweaked formatting a bit. Removed Mac-specific
        code from this file.

        * editing/mac/EditorMac.mm:
        (WebCore::Editor::newGeneralClipboard): Removed unnneded local variable.
        (WebCore::Editor::userVisibleString): Moved this function here.

        * platform/Pasteboard.h: Added some FIXMEs. Removed unneeded includes.
        Made Pasteboard noncopyable. Removed use of "protected" where we should
        be using "private". Removed s_generalPasteboard.
        * platform/mac/PasteboardMac.mm: Added some FIXMEs. Removed the
        s_generalPasteboard global. Removed the unused destructor. Updated call
        to userVisibleString for name change. Tweaked formatting.

WebKit:

        Reviewed by Alice.

        * WebCoreSupport/WebEditorClient.h: Removed "_web_" prefix from
        C++ userVisibleString member function.
        * WebCoreSupport/WebEditorClient.mm: (WebEditorClient::userVisibleString):
        Ditto.

        * WebView/WebView.mm: (-[WebView selectedFrame]): Removed extra return statement.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18008 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Oliver.
aliceli1 [Mon, 4 Dec 2006 23:30:19 +0000 (23:30 +0000)]
    Reviewed by Oliver.

        Moved some constants from EventHandlerMac.mm to EventHandler.cpp
        Added some platform-specific data members and functions.

        * page/EventHandler.cpp:
        * page/EventHandler.h:
        * page/mac/EventHandlerMac.mm:
        * platform/PlatformMouseEvent.h:
        (WebCore::):
        (WebCore::PlatformMouseEvent::timestamp):
        (WebCore::PlatformMouseEvent::activatedWebView):
        (WebCore::PlatformMouseEvent::type):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18007 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Darin, Geoff.
andersca [Mon, 4 Dec 2006 23:26:05 +0000 (23:26 +0000)]
    Reviewed by Darin, Geoff.

        Get rid of ResourceHandle::kill(), all it did was to balance out a ref() in ResourceHandle::start().
        We use RefPtrs to ResourceHandle instead.

        * loader/icon/IconLoader.cpp:
        (WebCore::IconLoader::~IconLoader):
        (WebCore::IconLoader::stopLoading):
        (WebCore::IconLoader::didReceiveResponse):
        * loader/loader.cpp:
        (WebCore::Loader::servePendingRequests):
        (WebCore::Loader::cancelRequests):
        (WebCore::Loader::jobForRequest):
        * loader/loader.h:
        * platform/network/ResourceHandle.cpp:
        * platform/network/ResourceHandle.h:
        * platform/network/mac/ResourceHandleMac.mm:
        (WebCore::ResourceHandle::start):
        (WebCore::ResourceHandle::finishJobAndHandle):
        (WebCore::ResourceHandle::reportError):
        * xml/xmlhttprequest.cpp:
        (WebCore::XMLHttpRequest::abort):
        (WebCore::XMLHttpRequest::didFinishLoading):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18006 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years agoBuild fix: set private attribute on ImageAnimationObserver.h so it is copied into...
bdash [Mon, 4 Dec 2006 23:14:04 +0000 (23:14 +0000)]
Build fix: set private attribute on ImageAnimationObserver.h so it is copied into the framework.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18005 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago2006-12-04 Oliver Hunt <oliver@apple.com>
oliver [Mon, 4 Dec 2006 22:32:43 +0000 (22:32 +0000)]
2006-12-04  Oliver Hunt  <oliver@apple.com>

        Build fix for non-SVG builds

        * bindings/js/JSSVGPoint.cpp:
        (WebCore::JSSVGPointProtoFunc::callAsFunction):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18004 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Beth.
darin [Mon, 4 Dec 2006 21:29:45 +0000 (21:29 +0000)]
    Reviewed by Beth.

        - fix http://bugs.webkit.org/show_bug.cgi?id=11632
          AKA <rdar://problem/4858866> REGRESSION (r17770): Overflow areas' scrollbars don't work

        No test case added at the moment, but Beth said she'd investigate
        adding one after the fact.

        * page/mac/EventHandlerMac.mm:
        (WebCore::EventHandler::passMousePressEventToScrollbar):
        Fix obvious-in-retrospect copy and paste error -- call
        passMouseDownEventToWidget instead of passWheelEventToWidget.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18001 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago2006-12-04 Don Gibson <dgibson77@gmail.com>
ap [Mon, 4 Dec 2006 19:37:15 +0000 (19:37 +0000)]
2006-12-04  Don Gibson  <dgibson77@gmail.com>

        Reviewed and landed by Alexey.

        http://bugs.webkit.org/show_bug.cgi?id=11738:
        Make link clicking work again on Windows.

WebCore:
        This re-implements a few functions that used to be part of FrameWin in
        their new loader-based locations, and copies a few things from the Mac
        and Qt event handling code that aren't strictly necessary but are
        pretty simple.

        * WebCore.vcproj/WebCore/WebCore.vcproj:
        * bridge/win/ChromeClientWin.h:
        * bridge/win/ContextMenuClientWin.h:
        * bridge/win/EditorClientWin.h:
        * bridge/win/FrameWin.cpp:
        (WebCore::FrameWin::client):
        * bridge/win/FrameWin.h:
        * loader/win/DocumentLoaderWin.cpp: Added.
        (WebCore::DocumentLoader::setTitle):
        * loader/win/FrameLoaderClientWin.cpp: Added.
        (WebCore::FrameLoaderClientWin::userAgent):
        * loader/win/FrameLoaderClientWin.h:
        * loader/win/FrameLoaderWin.cpp: Added.
        (WebCore::FrameLoader::urlSelected):
        (WebCore::FrameLoader::submitForm):
        (WebCore::FrameLoader::setTitle):
        * page/win/EventHandlerWin.cpp: Added.
        (WebCore::EventHandler::passMousePressEventToSubframe):
        (WebCore::EventHandler::passMouseMoveEventToSubframe):
        (WebCore::EventHandler::passMouseReleaseEventToSubframe):
        (WebCore::EventHandler::passWheelEventToSubframe):
        (WebCore::EventHandler::passMousePressEventToScrollbar):
        (WebCore::EventHandler::passWidgetMouseDownEventToWidget):
        * platform/win/TemporaryLinkStubs.cpp:
        (WebCore::EventHandler::tabsToLinks):
        (WebCore::EventHandler::tabsToAllControls):
        (WebCore::EventHandler::lastEventIsMouseUp):
        (WebCore::EventHandler::passSubframeEventToSubframe):
        (WebCore::EventHandler::passMouseDownEventToWidget):
        (WebCore::EventHandler::passWheelEventToWidget):
        (WebCore::FrameLoader::getHistoryLength):
        (WebCore::FrameLoader::historyURL):
        (WebCore::FrameLoader::createFrame):
        (WebCore::FrameLoaderClientWin::setTitle):

WebKit:
        The WebKit changes are to ignore WM_MOUSEMOVED messages when the mouse
        hasn't actually moved, which were preventing clicks from actually
        getting dispatched in many cases.  It's a peculiarity of Windows mouse
        handling that we receive these at all.

        * COM/WebView.cpp:
        (WebView::WebView):
        (WebView::mouseMoved):
        * COM/WebView.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@18000 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago2006-12-04 Don Gibson <dgibson77@gmail.com>
ap [Mon, 4 Dec 2006 18:49:18 +0000 (18:49 +0000)]
2006-12-04  Don Gibson  <dgibson77@gmail.com>

        Reviewed by Mitz.

        http://bugs.webkit.org/show_bug.cgi?id=11748:
        Windows build bustage.

        * WebCore.vcproj/WebCore/WebCore.vcproj:
        * platform/ContextMenuItem.h:
        * platform/win/TemporaryLinkStubs.cpp:
        (WebCore::ContextMenuItem::ContextMenuItem):
        (WebCore::ContextMenuItem::platformDescription):
        (WebCore::ContextMenuItem::action):
        (WebCore::ContextMenuItem::setAction):
        (WebCore::ContextMenuItem::title):
        (WebCore::ContextMenuItem::setTitle):
        (WebCore::ContextMenuItem::platformSubMenu):
        (WebCore::ContextMenuItem::setSubMenu):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17999 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Anders
sullivan [Mon, 4 Dec 2006 18:24:35 +0000 (18:24 +0000)]
    Reviewed by Anders

        Moved EditorMac.mm to its appropriate location

        * platform/mac/EditorMac.mm: Removed.
        * editing/mac/EditorMac.mm: Added

        * WebCore.xcodeproj/project.pbxproj:
        updated for this change

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17998 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Anders
sullivan [Mon, 4 Dec 2006 17:07:53 +0000 (17:07 +0000)]
    Reviewed by Anders

        - fixed <rdar://problem/4857833> REGRESSION: When ctrl-clicking on a misspelled word, "Ignore Spelling" and "Learn Spelling"
          menu items not displayed in the contextual menu

        * WebView/WebHTMLView.m:
        (-[WebHTMLView _isSelectionMisspelled]):
        We were computing isSelectionMisspelled by calling WebCore, but then ignoring the result and always
        returning NO. D'oh!

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17997 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by dhyatt.
rwlbuis [Mon, 4 Dec 2006 09:21:08 +0000 (09:21 +0000)]
    Reviewed by dhyatt.

        Patch by pmax.

        http://bugs.webkit.org/show_bug.cgi?id=3280
        With LEGEND element, align=right value is not supported
        http://bugs.webkit.org/show_bug.cgi?id=11544
        <legend> rendering doesn't take align into account

        Allow aligning for legends in both RTL and LTR mode.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17995 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago2006-12-03 Mark Rowe <bdash@webkit.org>
bdash [Mon, 4 Dec 2006 00:16:07 +0000 (00:16 +0000)]
2006-12-03  Mark Rowe  <bdash@webkit.org>

        Reviewed by Alexey.

        http://bugs.webkit.org/show_bug.cgi?id=11730
        Bug 11730: Meta HTTP Refresh that contains a fraction / decimal get ignored.

        * dom/Document.cpp:
        (WebCore::Document::processHttpEquiv): Parse the refresh interval as a double rather than an integer.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17994 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years agoReviewed by Oliver.
zimmermann [Sun, 3 Dec 2006 13:36:37 +0000 (13:36 +0000)]
Reviewed by Oliver.

Fix following bugs:
http://bugs.webkit.org/show_bug.cgi?id=11734
http://bugs.webkit.org/show_bug.cgi?id=11685

SVGPoint/SVGRect/SVGNumber were missing put() support.
SVGPoint.matrixTransform() was missing.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17993 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years agoReviewed by Dave.
zimmermann [Sun, 3 Dec 2006 12:19:50 +0000 (12:19 +0000)]
Reviewed by Dave.
Another missing piece in the platform/graphics move.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17992 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Oliver.
rwlbuis [Sun, 3 Dec 2006 12:02:26 +0000 (12:02 +0000)]
    Reviewed by Oliver.

        http://bugs.webkit.org/show_bug.cgi?id=11667
        SVG: method .getTransformToElement(elt) in SVGLocatable not implemented

        Implement getTransformToElement functionality. Introduce virtual
        baseclass SVGLocatable to allow one implementation of the functionality.
        Finally cleanup some code.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17991 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years agoReviewed by Rob.
zimmermann [Sun, 3 Dec 2006 11:55:12 +0000 (11:55 +0000)]
Reviewed by Rob.
Move some files around, which have been forgotton in the platform/graphics move.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17990 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years agoReviewed by Mitz.
zimmermann [Sun, 3 Dec 2006 11:39:10 +0000 (11:39 +0000)]
Reviewed by Mitz.
Fix non-svg build. (At least hope BuildBot doesn't moan anymore :-)

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17989 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Mitz.
ap [Sun, 3 Dec 2006 09:07:31 +0000 (09:07 +0000)]
    Reviewed by Mitz.

        This test used to be a pixel one, but without pixel results provided - converted to text.

        * http/tests/xmlhttprequest/frame-load-cancelled-abort-expected.txt:
        * http/tests/xmlhttprequest/frame-load-cancelled-abort.html:

        * http/tests/xmlhttprequest/resources/frame-load-to-cancel.html: Added a parameter to send()
        to make the test work in Firefox.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17988 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago Reviewed by Tim Omernick
sullivan [Sat, 2 Dec 2006 14:48:50 +0000 (14:48 +0000)]
    Reviewed by Tim Omernick

        Removed a couple of big chunks of duplicated code from the spelling and grammar stuff by merging
        the find-next-instance functions with the mark-all-instances functions.

        * bridge/mac/FrameMac.mm:
        (WebCore::findFirstMisspellingInRange):
        added markAll parameter, and reworked loop so that if markAll parameter is true, this function loops
        through the entire range and marks each misspelling
        (WebCore::findFirstGrammarDetailInRange):
        extracted from findFirstBadGrammarInRange; loops through the potentially-multiple details in a given
        ungrammatical phrase (e.g., multiple grammar errors in one sentence). Has a markAll parameter akin
        to the one in findFirstMisspellingInRange.
        (WebCore::findFirstBadGrammarInRange):
        added markAll parameter like the one in findFirstMisspellingInRange, and extracted findFirstGrammarDetailInRange
        (WebCore::FrameMac::advanceToNextMisspelling):
        pass "false" for new markAll parameters
        (WebCore::markAllMisspellingsInRange):
        now just calls findFirstMisspellingInRange with markAll = true, thus removing a big hunk of duplicated code
        (WebCore::markAllBadGrammarInRange):
        now just calls findFirstBadGrammarInRange with markAll = true, thus removing a big hunk of duplicated code

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17987 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago2006-12-02 Mitz Pettel <mitz@webkit.org>
ap [Sat, 2 Dec 2006 14:02:57 +0000 (14:02 +0000)]
2006-12-02  Mitz Pettel  <mitz@webkit.org>

        Reviewed by Hyatt.

        - fix http://bugs.webkit.org/show_bug.cgi?id=11672
          REGRESSION (r17068): Repro crash due to painting without layout

        Test: fast/dynamic/containing-block-change.html

        * rendering/RenderObject.cpp:
        (WebCore::RenderObject::setStyle): Changed the logic used
        to find absolutely positioned descendant's current containing block to
        match the changes made to containingBlock() in the fix for bug 9347.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17986 268f45cc-cd09-0410-ab3c-d52691b4dbfc

14 years ago2006-12-02 MorganL <morganl.webkit@yahoo.com>
ap [Sat, 2 Dec 2006 13:41:18 +0000 (13:41 +0000)]
2006-12-02  MorganL  <morganl.webkit@yahoo.com>

        Reviewed by Darin.

        http://bugs.webkit.org/show_bug.cgi?id=11709
        DeprecatedString::format is broken on Windows

        Use _vscprintf on Windows to compute the length of the buffer that
        vsnprintf would need.

        * platform/DeprecatedString.cpp:
        (WebCore::DeprecatedString::format):
        * platform/String.cpp:
        (WebCore::String::format):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17985 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years agoWebCore:
bdakin [Sat, 2 Dec 2006 02:35:12 +0000 (02:35 +0000)]
WebCore:
        Reviewed by Adam.

        Support for sub-menus in WebCore context menus. This also re-
        architects the ContextMenuItem class so that it is more like
        ContextMenu in that the class is now really just a wrapper for the
        platformDescription

        * WebCore.exp:
        * WebCore.xcodeproj/project.pbxproj:
        * page/ContextMenuController.cpp:
        (WebCore::ContextMenuController::contextMenuItemSelected): Add
        place-holders for new tags for the sub-menu items. I will flesh
        these out in a separate check-in.
        * platform/ContextMenu.cpp:
        (WebCore::createFontSubMenu):
        (WebCore::createSpellingAndGrammarSubMenu):
        (WebCore::createSpellingSubMenu):
        (WebCore::createSpeechSubMenu):
        (WebCore::createWritingDirectionSubMenu):
        (WebCore::ContextMenu::populate): Call the above functions to add
        the appropriate sub-menus to editing context menus.
        * platform/ContextMenu.h:
        * platform/ContextMenuItem.h:
        (WebCore::): New tags in the ContextMenuAction enumeration.
        (WebCore::ContextMenuItem::parentMenu):
        (WebCore::ContextMenuItem::setType):
        * platform/PlatformMenuDescription.h: Added. This defines
        PlatformMenuDesciption. It needs to be its own header because we
       have to include it from ContextMenu.h and ContextMenuItem.h
        * platform/mac/ContextMenuItemMac.mm: Lots of adjustments here to
        make this class basically just be a wrapper for NSMenuItem.
        (WebCore::ContextMenuItem::ContextMenuItem):
        (WebCore::ContextMenuItem::~ContextMenuItem):
        (WebCore::ContextMenuItem::platformDescription):
        (WebCore::ContextMenuItem::action):
        (WebCore::ContextMenuItem::title):
        (WebCore::ContextMenuItem::platformSubMenu):
        (WebCore::ContextMenuItem::setAction):
        (WebCore::ContextMenuItem::setTitle):
        (WebCore::ContextMenuItem::setSubMenu):
        * platform/mac/ContextMenuMac.mm:
        (WebCore::ContextMenu::ContextMenu):
        (WebCore::getNSMenuItem): Now we only have to get the
        platformDescription of the ContextMenuItem and then set its target
        and action.
        (WebCore::ContextMenu::itemCount):

WebKit:
        Reviewed by Adam.

        Changes to support sub-menus in WebCore ContextMenus.

        * WebCoreSupport/WebContextMenuClient.mm:
        (WebContextMenuClient::contextMenuItemSelected):
        ContextMenuItem::menu() is now called parentMenu()
        * WebView/WebUIDelegatePrivate.h: New not-yet-API tags.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17984 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years ago Reviewed by .
kmccullo [Sat, 2 Dec 2006 00:36:58 +0000 (00:36 +0000)]
    Reviewed by .

        - accidentally checked in with previous checkin

        * platform/qt/FrameQt.cpp:
        (WebCore::FrameQt::keyEvent):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17983 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years ago Reviewed by Adam.
kmccullo [Sat, 2 Dec 2006 00:23:49 +0000 (00:23 +0000)]
    Reviewed by Adam.

        - better solution to the ambiguous reference

        * platform/Widget.h:
        (WebCore::Widget::handleMouseMoveEvent):
        (WebCore::Widget::handleMouseReleaseEvent):
        * platform/qt/FrameQt.cpp:
        (WebCore::FrameQt::keyEvent):
        * platform/win/PlatformScrollBar.h:
        * platform/win/TemporaryLinkStubs.cpp:
        (WebCore::PlatformScrollbar::handleMouseMoveEvent):
        (WebCore::PlatformScrollbar::handleMouseReleaseEvent):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17982 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years agoLayoutTests:
justing [Fri, 1 Dec 2006 23:40:35 +0000 (23:40 +0000)]
LayoutTests:

        Reviewed by john

        <rdar://problem/4826940>
        Selection change performed even when delete delegate replies NO (11415)

        Removed unnecessary shouldChangeSelection calls;
        * editing/deleting/delete-at-start-or-end-expected.txt:
        * editing/deleting/delete-br-002-expected.txt:
        * editing/deleting/delete-br-004-expected.txt:
        * editing/deleting/delete-br-005-expected.txt:
        * editing/deleting/delete-br-006-expected.txt:
        * editing/deleting/delete-br-009-expected.txt:
        * editing/deleting/delete-br-010-expected.txt:
        * editing/deleting/delete-br-012-expected.txt:
        * editing/deleting/delete-hr-expected.txt:
        * editing/deleting/delete-tab-004-expected.txt:
        * editing/deleting/forward-delete-expected.txt:
        * editing/deleting/merge-into-empty-block-1-expected.txt:
        * editing/deleting/merge-into-empty-block-2-expected.txt:
        * editing/execCommand/format-block-expected.txt:
        * editing/execCommand/outdent-selection-expected.txt:
        * editing/inserting/editing-empty-divs-expected.txt:
        * editing/inserting/insert-3800346-fix-expected.txt:
        * editing/inserting/insert-br-004-expected.txt:
        * editing/inserting/insert-br-005-expected.txt:
        * editing/inserting/insert-br-006-expected.txt:
        * editing/inserting/insert-br-008-expected.txt:
        * editing/inserting/insert-div-006-expected.txt:
        * editing/inserting/insert-div-008-expected.txt:
        * editing/inserting/insert-div-010-expected.txt:
        * editing/inserting/insert-div-011-expected.txt:
        * editing/inserting/insert-div-013-expected.txt:
        * editing/inserting/insert-div-015-expected.txt:
        * editing/inserting/insert-div-019-expected.txt:
        * editing/inserting/insert-div-021-expected.txt:
        * editing/inserting/insert-paragraph-01-expected.txt:
        * editing/inserting/insert-paragraph-03-expected.txt:
        * editing/inserting/insert-tab-004-expected.txt:
        * editing/inserting/insert-text-with-newlines-expected.txt:
        * editing/inserting/line-break-expected.txt:
        * editing/pasteboard/3976872-expected.txt:
        * editing/pasteboard/paste-text-005-expected.txt:
        * editing/pasteboard/paste-text-006-expected.txt:
        * editing/pasteboard/paste-text-007-expected.txt:
        * editing/pasteboard/paste-text-010-expected.txt:
        * editing/pasteboard/paste-text-014-expected.txt:
        * editing/pasteboard/paste-text-016-expected.txt:
        * editing/pasteboard/quirks-mode-br-2-expected.txt:
        * editing/style/apple-style-editable-mix-expected.txt:
        * editing/style/block-style-001-expected.txt:
        * editing/style/block-style-002-expected.txt:
        * editing/style/block-style-003-expected.txt:
        * editing/style/block-style-006-expected.txt:
        * editing/style/create-block-for-style-005-expected.txt:
        * editing/style/create-block-for-style-006-expected.txt:
        * editing/style/create-block-for-style-008-expected.txt:
        * editing/style/relative-font-size-change-002-expected.txt:
        * editing/style/relative-font-size-change-003-expected.txt:
        * editing/style/relative-font-size-change-004-expected.txt:
        * editing/style/table-selection-expected.txt:

WebCore:

        Reviewed by john

        <rdar://problem/4826940>
        Selection change performed even when delete delegate replies NO (11415)

        No layout test for the bug fix, because there's no way to register a custom
        editing delegate from a layout test.  Layout tests are effected by the change
        to avoid sending unnecessary shouldChangeSelections, however.

        * editing/Editor.cpp:
        (WebCore::Editor::appliedEditing): Don't bother sending shouldChangeSelection
        if the editing operation didn't change the selection.  Still call
        setSelection though, because it does work in this case that's necessary,
        like clearing the typing style.
        (WebCore::Editor::unappliedEditing): Ditto.
        (WebCore::Editor::reappliedEditing): Ditto.
        * editing/TypingCommand.cpp:
        (WebCore::TypingCommand::deleteKeyPressed): Don't set the starting
        selection if the editing delegate returns NO from shouldDeleteRange.
        Notice we now call setStartingSelection in the case where
        the current selection was a range selection.  This is fine because
        it's a no-op (the starting selection is already the current selection).
        (WebCore::TypingCommand::forwardDeleteKeyPressed): Ditto.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17981 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years ago Reviewed by Darin
sullivan [Fri, 1 Dec 2006 23:32:56 +0000 (23:32 +0000)]
    Reviewed by Darin

        Move subrange helper function from spellchecking code to TextIterator

        * editing/TextIterator.h:
        added TextIterator::subrange
        * editing/TextIterator.cpp:
        (WebCore::CharacterIterator::advance):
        early return if count is <= 0; assert that it's not < 0
        (WebCore::TextIterator::subrange):
        new function, moved from FrameMac.mmm

        * bridge/mac/FrameMac.mm:
        moved subrange() function to TextIterator
        (WebCore::FrameMac::advanceToNextMisspelling):
        use TextIterator::subrange
        (WebCore::markAllMisspellingsInRange):
        ditto
        (WebCore::markAllBadGrammarInRange):
        ditto

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17980 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years agoWebCore:
darin [Fri, 1 Dec 2006 22:46:21 +0000 (22:46 +0000)]
WebCore:

        Reviewed by Mitz.

        - fix http://bugs.webkit.org/show_bug.cgi?id=11628
          REGRESSION (r17597): Command-return in native text fields doesn't open a new tab or window

        I couldn't think of an easy way to make a regression test for this, but maybe
        I'll get an idea later about how to do it.

        The main thing I did was add a concept of a DOM event having an "underlying event".
        That allows the DOM activate event to contain inside it the original keyboard event
        that triggered the form submission, and thus allows WebKit to see the modifier keys
        from that original event. The code that uses the underlying event is in WebKit, but
        the code to set it up is here in WebCore.

        - also do some clean-up to related event handling code

        * bindings/js/kjs_events.cpp: (KJS::DOMEvent::getValueProperty): Updated for the
        name change of cancelBubble.

        * dom/Event.h: Removed a useless comment. Fixed some whitespace and formatting.
        Renamed getCancelBubble to cancelBubble to match the DOM -- I suspect the old
        name predated the use of the m_ prefix on data members. Added the underlying event,
        and a getter and setter.
        * dom/Event.cpp:
        (WebCore::Event::setTarget): Updated to take a PassRefPtr.
        (WebCore::Event::setUnderlyingEvent): Added.

        * dom/EventTargetNode.h: Added an optional underlyingEvent parameter to
        dispatchUIEvent, one of the overloads of dispatchMouseEvent, and
        dispatchSimulatedMouseEvent. Added a new dispatchSimulatedClick function here that
        mostly replaces the click function in HTMLElement.
        * dom/EventTargetNode.cpp:
        (WebCore::EventTargetNode::dispatchGenericEvent): Updated for the name change
        of cancelBubble.
        (WebCore::EventTargetNode::dispatchUIEvent): Added an underlying event parameter,
        which gets attached to the UIEvent object after it's created.
        (WebCore::EventTargetNode::dispatchMouseEvent): Tweaked formatting and parameter
        name for the version that creates a mouse event for a real platform mouse event.
        Added an underlying event parameter to the main version, and attached it to all
        three of the events that can be dispatched.
        (WebCore::EventTargetNode::dispatchSimulatedMouseEvent): Added an underlying
        event parameter, passed it along to dispatchMouseEvent.
        (WebCore::EventTargetNode::dispatchSimulatedClick): Moved this here from HTMLElement
        and renamed it from click. Added an underlyingEvent parameter, and passed that along
        in all three of the calls to dispatchSimulatedMouseEvent.

        * bridge/mac/FrameMac.mm: (WebCore::FrameMac::shouldClose): Updated call to
        setTarget that no longer needs a get().
        * ksvg2/svg/SVGElement.cpp: (WebCore::SVGElement::sendSVGLoadEventIfPossible): Ditto.

        * html/HTMLAnchorElement.cpp:
        (WebCore::HTMLAnchorElement::defaultEventHandler): Converted a call to click
        to a call to dispatchSimulatedClick.
        (WebCore::HTMLAnchorElement::accessKeyAction): Ditto.
        * html/HTMLButtonElement.cpp:
        (WebCore::HTMLButtonElement::accessKeyAction): Ditto.
        * html/HTMLElement.h: Removed the parameters to click and made it non-virtual.
        We could move it down to the input and button elements, now that it's just
        a single function call, but it's also OK to just leave it here.
        * html/HTMLElement.cpp:
        (WebCore::HTMLElement::click): Removed the parameters and changed this to just
        call dispatchSimulatedClick. The real work is now in dispatchSimulatedClick.
        (WebCore::HTMLElement::accessKeyAction): Converted a call to click to a call to
        dispatchSimulatedClick.
        * html/HTMLFormElement.cpp:
        (WebCore::HTMLFormElement::submitClick): Ditto. But unlike accessKeyAction callers,
        pass the event along as the underlying event.
        * html/HTMLInputElement.h:
        * html/HTMLInputElement.cpp: Removed override of virtual click function. The
        special cases for the file control and hidden input elements aren't needed.
        (WebCore::HTMLInputElement::accessKeyAction): Converted a call to click to a call to
        dispatchSimulatedClick.
        (WebCore::HTMLInputElement::defaultEventHandler): Converted calls to click to calls to
        dispatchSimulatedClick, passing along the event as the underlying event.
        * html/HTMLLabelElement.cpp:
        (WebCore::HTMLLabelElement::defaultEventHandler): Converted a call to click to a call
        to dispatchSimulatedClick, passing the event along as the underlying event. Also
        changed the local variable for the element to a RefPtr since the code assumes it's
        still around after calling arbitrary JavaScript code.
        * html/HTMLSelectElement.cpp:
        (WebCore::HTMLSelectElement::accessKeyAction): Converted a call to click to a call to
        dispatchSimulatedClick.

        * rendering/RenderFileUploadControl.h:
        * rendering/RenderFileUploadControl.cpp: (WebCore::RenderFileUploadControl::click):
        Removed unneeded ignored parameter to the click function, and also made it non-virtual.

        * loader/NavigationAction.h: Removed unneeded includes.
        * loader/NavigationAction.cpp: Moved all the code here from NavigationActionMac.mm,
        since none of it is Mac-specific any more.
        * loader/mac/NavigationActionMac.mm: Removed.
        * WebCore.xcodeproj/project.pbxproj: Updated for removed file.

        * ksvg2/svg/SVGAElement.cpp: Removed an unnecessary include.

        * loader/FrameLoader.cpp: Added a newly-needed incluude.
        * loader/mac/DocumentLoaderMac.mm: Ditto.
        * loader/mac/FrameLoaderMac.mm: Ditto.
        * rendering/RenderWidget.cpp: Ditto.

WebKit:

        Reviewed by Mitz.

        - fix http://bugs.webkit.org/show_bug.cgi?id=11628
          REGRESSION (r17597): Command-return in native text fields doesn't open a new tab or window

        * WebCoreSupport/WebFrameLoaderClient.mm:
        (findKeyStateEvent): Added. Helper that finds the mouse or keyboard event in a chain
        of events and their underlying events.
        (findMouseEvent): Added. Same, but specifically for mouse events.
        (WebFrameLoaderClient::actionDictionary): Rewrote to use the above functions. This means we
        use the modifiers from the underlying events rather than just the one from the event itself.
        So if the event is a DOM activate event, we can still see the modifiers from the original
        keyboard event that triggered it. Has no effect if the event is already the right type or
        if there is no underlying event.

        * WebView/WebFrame.mm: Added a newly-needed include.

        * WebKit.xcodeproj/project.pbxproj: Xcode wants what it wants.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17976 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years ago Reviewed by Darin
sullivan [Fri, 1 Dec 2006 22:12:40 +0000 (22:12 +0000)]
    Reviewed by Darin

        - fixed <rdar://problem/4811175> Many false reports of bad grammar appear, caused by
          insufficient context passed to grammar checker

        * bridge/mac/FrameMac.mm:
        (WebCore::markAllMisspellingsInRange):
        new function, extracted from markMisspellings -- ignores grammar
        (WebCore::markAllBadGrammarInRange):
        new function, extracted from markMisspellings -- ignores spelling, and operates on
        appropriately-sized chunks of text
        (WebCore::FrameMac::markMisspellings):
        now calls markAllMisspellingsInRange and (optionally) markAllBadGrammarInRange rather
        than trying to interweave the spelling and grammar logic

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17968 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years agoRemoved stray conflict marker.
sullivan [Fri, 1 Dec 2006 21:31:50 +0000 (21:31 +0000)]
Removed stray conflict marker.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17967 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years ago Reviewed by Darin
sullivan [Fri, 1 Dec 2006 21:25:09 +0000 (21:25 +0000)]
    Reviewed by Darin

        With these changes, grammar checking works correctly for the one-by-one case.
        It still doesn't work correctly for the check-as-you-type case; I need to make these
        same kinds of changes in markMisspellings, and refactor to share more code between
        the two cases, but I wanted to get this working code in before modifying it further.

        The major change here is that advanceToNextMisspelling used to look at small chunks of
        text at a time, checking each one for both misspellings and questionable grammar. But
        grammar checking needs at least paragraph-sized chunks of text to have enough context
        to work correctly, so the old mechanism was causing many spurious complaints of bad
        grammar (e.g., almost every word seemed to be at the start of a sentence so the checker
        would complain about missing capitalization). So now the spell checker runs in the
        specified range first. Then the grammar checker runs on the same range (stopping at the
        next misspelling, if any), but expanded to paragraph-aligned boundaries.

        * bridge/mac/FrameMac.mm:
        (WebCore::findFirstMisspellingInRange):
        new function, extracted from advanceToNextMisspelling, and ignores grammar
        (WebCore::paragraphAlignedRangeForRange):
        new function, used by findNextBadGrammarInRange
        (WebCore::findFirstBadGrammarInRange):
        new function, extracted from advanceToNextMisspelling, and rewritten to use paragraph-aligned
        chunks, and ignores spelling
        (WebCore::subrange):
        new helper function, used by advanceToNextMisspelling
        (WebCore::FrameMac::advanceToNextMisspelling):
        now calls out to both findFirstMisspellingInRange and findFirstBadGrammarInRange separately
        instead of trying to interweave the spelling and grammar logic

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17966 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years ago Reviewed by Mitz.
rwlbuis [Fri, 1 Dec 2006 21:21:07 +0000 (21:21 +0000)]
    Reviewed by Mitz.

        http://bugs.webkit.org/show_bug.cgi?id=11732:
        Windows build bustage.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17965 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years ago Reviewed by Adam.
thatcher [Fri, 1 Dec 2006 18:44:41 +0000 (18:44 +0000)]
    Reviewed by Adam.

        <rdar://problem/4841432> 9A312: iWeb crashes on launch; _WebReportError missing from WebKit

        Added back WebReportAssertionFailure and WebReportError for apps that still need these symbols.

        * Misc/OldWebAssertions.c: Added.
        (WebReportAssertionFailure):
        (WebReportError):
        * WebKit.LP64.exp: added the new symbols, and sorted the file
        * WebKit.exp: added the new symbols, and sorted the file
        * WebKit.xcodeproj/project.pbxproj:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17962 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years agoCorrecting the copyright date since these are new files.
thatcher [Fri, 1 Dec 2006 18:34:33 +0000 (18:34 +0000)]
Correcting the copyright date since these are new files.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17961 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years ago2006-11-30 Steve Falkenburg <sfalken@apple.com>
sfalken [Fri, 1 Dec 2006 05:42:19 +0000 (05:42 +0000)]
2006-11-30  Steve Falkenburg  <sfalken@apple.com>

        Reviewed by Oliver.

        Move WTF from JavaScriptCore project into a new WTF project.

        * JavaScriptCore.vcproj/JavaScriptCore.sln: Add WTF.vcproj to sln
        * JavaScriptCore.vcproj/JavaScriptCore/JavaScriptCore.vcproj: Remove WTF source files
        * JavaScriptCore.vcproj/WTF/WTF.vcproj: Added.
        * JavaScriptCore.vcproj/testkjs/testkjs.vcproj: Add dependency on WTF.lib

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17959 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years agoWebCore:
ggaren [Fri, 1 Dec 2006 04:15:19 +0000 (04:15 +0000)]
WebCore:

        Rubber Stamped by Anders Carlsson.

        Global rename of Document::focusNode to Document::focusedNode. 'focusNode'
        suggested a command, and conflicted with a different meaning for 'focusNode'
        in the Mozilla selection API.

WebKit:

        Rubber Stamped by Anders Carlsson.

        Global rename of Document::focusNode to Document::focusedNode. 'focusNode'
        suggested a command, and conflicted with a different meaning for 'focusNode'
        in the Mozilla selection API.

        * WebView/WebHTMLView.m:
        (-[NSArray clearFocus]):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17958 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years agoLayoutTests:
sullivan [Fri, 1 Dec 2006 00:55:56 +0000 (00:55 +0000)]
LayoutTests:

        Reviewed by Justin

        * editing/execCommand/create-list-from-range-selection-expected.checksum:
        * editing/execCommand/create-list-from-range-selection-expected.png:
        * editing/execCommand/create-list-from-range-selection-expected.txt:
        * editing/execCommand/create-list-from-range-selection.html:
        This test's results were broken by using rangeCompliantEquivalent at
        appropriate places in CompositeEditCommand.cpp::moveParagraphs(), presumably
        by revealing a different bug. Justin is going to look into this; for now I've
        updated the result so that it won't appear to fail for others.

        * editing/execCommand/create-list-with-hr-expected.checksum:
        * editing/execCommand/create-list-with-hr-expected.png:
        * editing/execCommand/create-list-with-hr-expected.txt:
        * editing/execCommand/create-list-with-hr.html:
        This test's results were improved by using rangeCompliantEquivalent at
        appropriate places in CompositeEditCommand.cpp::moveParagraphs() -- it used
        to create an extra <div>, and now it does not.

WebCore:

        Reviewed by Justin

        With Darin, fixed a problem in the Range constructors found while implementing grammar checking.
        That revealed another problem in the layout tests involving bad parameters passed to the Range
        constructors.

        With these fixes in place, one layout test (editing/execCommand/create-list-from-range-selection.html)
        no longer works as intended. This is apparently due to yet another bug being flushed out somewhere.
        I'm going to update the results for that test and file a separate radar about it, which Justin will
        investigate.

        * dom/Position.h:
        removed equivalentRangeCompliantPosition(), which was declared but not implemented or called.

        * dom/Range.cpp:
        (WebCore::Range::Range):
        Call setStart and setEnd in the two Range constructors that take parameters, rather than just
        directly setting the instance variables. This makes Range perform the boundary checks and
        compensations that the DOM spec requires.

        * editing/CompositeEditCommand.cpp:
        (WebCore::CompositeEditCommand::moveParagraphs):
        Use rangeCompliantEquivalent() on "editing-style" Positions before creating Ranges from them.

        * editing/TextIterator.cpp:
        (WebCore::TextIterator::TextIterator):
        Assert that the boundary points of the range are valid.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17955 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years ago Reviewed by Mitz.
thatcher [Fri, 1 Dec 2006 00:14:17 +0000 (00:14 +0000)]
    Reviewed by Mitz.

        Bug 10698: Scroll wheel causes inspector to shift up
        http://bugs.webkit.org/show_bug.cgi?id=10698

        Remove size attribute from the tree popup as a workaround for
        http://bugs.webkit.org/show_bug.cgi?id=11362 Bug 11362: Native popup with size="1" wraps options

        * WebInspector/webInspector/inspector.css:
        * WebInspector/webInspector/inspector.html:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17954 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years ago Reviewed by Tim H.
thatcher [Fri, 1 Dec 2006 00:11:18 +0000 (00:11 +0000)]
    Reviewed by Tim H.

        Move web inspector style markup to javascript to fix http://bugs.webkit.org/show_bug.cgi?id=6724
        Bug 6724: Text copied from Web Inspector is different from actual text

        * WebInspector/webInspector/inspector.css:
        * WebInspector/webInspector/inspector.js:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17953 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years agoRemoving the conflict marker.
thatcher [Fri, 1 Dec 2006 00:03:50 +0000 (00:03 +0000)]
Removing the conflict marker.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17952 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years ago2006-11-30 Lou Amadio <lamadio@apple.com>
lamadio [Thu, 30 Nov 2006 22:29:32 +0000 (22:29 +0000)]
2006-11-30  Lou Amadio  <lamadio@apple.com>

        Reviewed by Dave Hyatt
        Cleaned up generated files.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17949 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years agoWebCore:
aroben [Thu, 30 Nov 2006 22:07:17 +0000 (22:07 +0000)]
WebCore:

        Reviewed by Beth.

        Store ContextMenu's NSMutableArray inside a RetainPtr so that we
        will retain/release it correctly.

        * WebCore.exp:
        * platform/ContextMenu.cpp:
        (WebCore::ContextMenu::populate): Added a FIXME.
        * platform/ContextMenu.h:
        * platform/mac/ContextMenuMac.mm:
        (WebCore::ContextMenu::ContextMenu):
        (WebCore::ContextMenu::~ContextMenu):
        (WebCore::getNSMenuItem):
        (WebCore::ContextMenu::appendItem):
        (WebCore::ContextMenu::itemCount):
        (WebCore::ContextMenu::insertItem):
        (WebCore::ContextMenu::setPlatformDescription):
        (WebCore::ContextMenu::platformDescription):

WebKit:

        Reviewed by Beth.

        Put code in place to use WebCore context menus when they are turned
        on.

        * WebView/WebHTMLView.m:
        (-[NSArray menuForEvent:]):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17948 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years agoReviewed by Eric. Rubber stamped by Oliver.
zimmermann [Thu, 30 Nov 2006 21:47:57 +0000 (21:47 +0000)]
Reviewed by Eric. Rubber stamped by Oliver.

Fixes: http://bugs.webkit.org/show_bug.cgi?id=10383
This is the final patch after the long "die kcanvas" journey.

All old kcanvas code is gone now, and properly integrated within
WebCore (stuff like GraphicsContext changes etc.). It shares
the platform/ design concept: no subclassing, but instead
implementing parts of the classes/methods per-platform.

This commit removes the last pieces: KRenderingDevice & KRenderingDeviceContext.
This layer was just obsolete, given the powerful GraphicsContext API we have
since quite a while now. All the ugly pushContext/popContext stuff is gone now.

The naming issues Cg vs. CG will be fixed in one shot, when moving the whole
platform/graphics/svg directory down into ksvg2/graphics - as discussed with Darin.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17947 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years agoJavaScriptCore:
ggaren [Thu, 30 Nov 2006 21:06:14 +0000 (21:06 +0000)]
JavaScriptCore:

        Reviewed by Beth Dakin.

        Fixed up garbage collection at window close time.

        * kjs/interpreter.cpp:
        (KJS::Interpreter::~Interpreter): Garbage collect here, since
        destroying the interpreter frees the global object and
        therefore creates a lot of garbage.

WebCore:

        Reviewed by Beth Dakin.

        Fixed up garbage collection at window close time.

        * bindings/js/kjs_proxy.cpp: Don't garbage collect in the KJSProxy
        destructor, since the global object hasn't been freed yet.
        * bindings/js/kjs_proxy.h:
        * loader/FrameLoader.cpp:
        (WebCore::FrameLoader::detachFromParent): Made this function cross-
        platform.
        * loader/FrameLoader.h:
        * loader/mac/FrameLoaderMac.mm:
        (WebCore::FrameLoader::setTitle): Moved this function to FrameLoaderMac,
        since it's Mac-only.
        (WebCore::FrameLoader::closeBridge):
        * page/Page.cpp:
        (WebCore::Page::~Page): Don't garbage collect in the Page destructor,
        since the Interpreter destructor will do it for us.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17945 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years ago Reviewed by Tim's rubberstamp
beidson [Thu, 30 Nov 2006 19:23:01 +0000 (19:23 +0000)]
    Reviewed by Tim's rubberstamp

        Amazingly, DocumentLoader.h survived all this time without a header guard...

        * loader/DocumentLoader.h:  Added header guard

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17940 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years ago Reviewed by Brady and Eric.
thatcher [Thu, 30 Nov 2006 17:37:47 +0000 (17:37 +0000)]
    Reviewed by Brady and Eric.

        XMLHttpRequest fails in a page loaded with WebFrame's loadHTMLString: or loadData:
        http://bugs.webkit.org/show_bug.cgi?id=11723

        Allow cross-domain XMLHTTPRequest for applewebdata URLs. No automated way to test,
        tested in Safari's debug Snippet Editor.

        * xml/xmlhttprequest.cpp:
        (WebCore::XMLHttpRequest::urlMatchesDocumentDomain):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17939 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years ago Reviewed by Brady.
andersca [Thu, 30 Nov 2006 03:26:15 +0000 (03:26 +0000)]
    Reviewed by Brady.

        Get rid of PlatformResponse, the platform specific response object is stored inside of
        the ResourceResponse object now. This also gets rid of receivedResponse in ResourceHandleClient.

        * bridge/mac/WebCoreFrameBridge.mm:
        (-[WebCoreFrameBridge getData:andResponse:forURL:]):
        (-[WebCoreFrameBridge getAllResourceDatas:andResponses:]):
        * loader/CachedResource.cpp:
        (WebCore::CachedResource::CachedResource):
        (WebCore::CachedResource::~CachedResource):
        * loader/CachedResource.h:
        (WebCore::CachedResource::response):
        * loader/loader.cpp:
        * loader/loader.h:
        * loader/mac/ImageDocumentMac.mm:
        (WebCore::finishImageLoad):
        * loader/mac/LoaderFunctionsMac.mm:
        (WebCore::CheckCacheObjectStatus):
        * loader/mac/SubresourceLoaderMac.mm:
        (WebCore::SubresourceLoader::didReceiveResponse):
        * platform/network/ResourceHandle.h:
        * platform/network/ResourceResponse.h:
        (WebCore::ResourceResponse::nsURLResponse):
        (WebCore::ResourceResponse::cfURLResponse):
        * platform/network/mac/ResourceHandleMac.mm:
        (WebCore::ResourceHandle::didReceiveResponse):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17937 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years agoLayoutTests:
justing [Thu, 30 Nov 2006 02:54:19 +0000 (02:54 +0000)]
LayoutTests:

        Reviewed by sullivan

        <rdar://problem/4845371>
        In Mail, a crash occurs at WebCore::Node::traverseNextNode() when cutting selected text from a HTML message

        * editing/deleting/4845371-expected.checksum: Added.
        * editing/deleting/4845371-expected.png: Added.
        * editing/deleting/4845371-expected.txt: Added.
        * editing/deleting/4845371.html: Added.

WebCore:

        Reviewed by sullivan

        <rdar://problem/4845371>
        In Mail, a crash occurs at WebCore::Node::traverseNextNode() when cutting selected text from a HTML message

        * editing/DeleteSelectionCommand.cpp:
        (WebCore::DeleteSelectionCommand::initializeStartEnd): The start/end were
        being inflated even when they were the start/end of a partially selected
        special element.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17936 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years agoBuild fix: ResourceRequestMac.h was removed in r17911.
bdash [Thu, 30 Nov 2006 02:01:24 +0000 (02:01 +0000)]
Build fix:  ResourceRequestMac.h was removed in r17911.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17935 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years ago Reviewed by Oliver.
thatcher [Thu, 30 Nov 2006 00:59:37 +0000 (00:59 +0000)]
    Reviewed by Oliver.

        Keep preferences separate from the rest of the client, making sure we are using expected preference values.
        This lets the inspector work when plugins are disabled for the WebView.

        * WebInspector/WebInspector.m:
        (-[NSWindow window]):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17933 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years ago Reviewed by Oliver.
andersca [Wed, 29 Nov 2006 22:42:37 +0000 (22:42 +0000)]
    Reviewed by Oliver.

        Fix fast/dom/xmlhttprequest-get layout test failure.

        * platform/network/mac/ResourceResponseMac.mm:
        Initialize the status code to 0 for non-http responses.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17932 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years ago Reviewed by Anders Carlsson.
ggaren [Wed, 29 Nov 2006 22:14:22 +0000 (22:14 +0000)]
    Reviewed by Anders Carlsson.

        Fixed http://bugs.webkit.org/show_bug.cgi?id=11712
        REGRESSION: Crash when clicking JS link on crateandbarrel.com (window.open("http[...]"))

        This was an accidental commit by Anders.

        Chrome can't use the FrameView at window.open time, because it doesn't
        exist yet.

        * page/Chrome.cpp:
        (WebCore::Chrome::pageRect):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17931 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years ago Reviewed by Mitz Pettel.
ggaren [Wed, 29 Nov 2006 21:58:41 +0000 (21:58 +0000)]
    Reviewed by Mitz Pettel.

        Fixed http://bugs.webkit.org/show_bug.cgi?id=11710
        REGRESSION (r17906): Crash in WebCore::FrameMac

        Added null checks for EditorClient, since it can be NULL when the page
        has been destroyed. Removed external access to EditorClient, since it's
        an implementation detail of the Editor.

        No test case because this crash depends on window tear-down. Layout tests
        pass.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17930 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years ago Reviewed by Tim.
andersca [Wed, 29 Nov 2006 18:47:11 +0000 (18:47 +0000)]
    Reviewed by Tim.

        Add back methods in WebCoreStatistics that are still used by Tiger Safari.

        * Misc/WebCoreStatistics.h:
        * Misc/WebCoreStatistics.m:
        (+[WebCoreStatistics emptyCache]):
        (+[WebCoreStatistics setCacheDisabled:]):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17925 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years ago Fix build.
andersca [Wed, 29 Nov 2006 18:38:17 +0000 (18:38 +0000)]
    Fix build.

        * platform/network/mac/ResourceHandleMac.mm:
        (WebCore::ResourceHandle::receivedResponse):
        Fix tyop.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17923 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years ago Reviewed by Darin.
andersca [Wed, 29 Nov 2006 18:29:08 +0000 (18:29 +0000)]
    Reviewed by Darin.

        Have ResourceResponse hold on to the platform object and do lazy
        initialization of the data members.

        * WebCore.xcodeproj/project.pbxproj:
        * loader/mac/FrameLoaderMac.mm:
        (WebCore::FrameLoader::loadResourceSynchronously):
        * platform/network/ResourceRequest.cpp:
        (WebCore::ResourceRequest::updatePlatformRequest):
        (WebCore::ResourceRequest::updateResourceRequest):
        * platform/network/ResourceResponse.cpp: Added.
        (WebCore::ResourceResponse::url):
        (WebCore::ResourceResponse::mimeType):
        (WebCore::ResourceResponse::expectedContentLength):
        (WebCore::ResourceResponse::textEncodingName):
        (WebCore::ResourceResponse::suggestedFilename):
        (WebCore::ResourceResponse::httpStatusCode):
        (WebCore::ResourceResponse::setHTTPStatusCode):
        (WebCore::ResourceResponse::httpStatusText):
        (WebCore::ResourceResponse::setHTTPStatusText):
        (WebCore::ResourceResponse::httpHeaderField):
        (WebCore::ResourceResponse::httpHeaderFields):
        (WebCore::ResourceResponse::setExpirationDate):
        (WebCore::ResourceResponse::expirationDate):
        (WebCore::ResourceResponse::setLastModifiedDate):
        (WebCore::ResourceResponse::lastModifiedDate):
        (WebCore::ResourceResponse::updateResourceResponse):
        * platform/network/ResourceResponse.h:
        (WebCore::ResourceResponse::ResourceResponse):
        (WebCore::ResourceResponse::isMultipart):
        * platform/network/mac/ResourceHandleMac.mm:
        (WebCore::ResourceHandle::receivedResponse):
        (WebCore::ResourceHandle::willSendRequest):
        * platform/network/mac/ResourceResponseMac.h: Removed.
        * platform/network/mac/ResourceResponseMac.mm:
        (-[NSURLResponse WebCore]):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17921 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years agoWebCore:
aliceli1 [Wed, 29 Nov 2006 07:25:53 +0000 (07:25 +0000)]
WebCore:

        Reviewed by Maciej.

        A fix for a couple failing layout tests involving copy/cut in iframes.

        * bridge/EditorClient.h:
        Add frame parameter to dataForArchivedSelectionInFrame instead of
        just getting the webview's selectedFrame.

        * platform/mac/PasteboardMac.mm:
        (Pasteboard::writeSelection):
        Pass in the frame

WebKit:

        Reviewed by Maciej.

        A fix for a couple failing layout tests involving copy/cut in iframes.

        * WebCoreSupport/WebEditorClient.h:
        * WebCoreSupport/WebEditorClient.mm:
        (WebEditorClient::dataForArchivedSelection):
        Use the frame parameter instead of using the webview's selectedFrame.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17920 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years ago Reviewed by Geoffff.
bdakin [Wed, 29 Nov 2006 06:42:26 +0000 (06:42 +0000)]
    Reviewed by Geoffff.

        Fix for http://bugs.webkit.org/show_bug.cgi?id=11691 REGRESSION
        (r17399, r17511): WebElementDictionary no longer returns nil
        NSStrings

        String's NSString* operator converts null Strings to empty
        NSStrings for compatibility with AppKit. We need to work around
        that here.

        * Misc/WebElementDictionary.m:
        (NSStringOrNil):
        (-[WebElementDictionary _altDisplayString]):
        (-[WebElementDictionary _spellingToolTip]):
        (-[WebElementDictionary _title]):
        (-[WebElementDictionary _titleDisplayString]):
        (-[WebElementDictionary _textContent]):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17919 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years agoWebCore:
ggaren [Wed, 29 Nov 2006 06:11:14 +0000 (06:11 +0000)]
WebCore:

        Reviewed by Beth Dakin.

        Fixed <rdar://problem/4844855> Should clarify when to create clients in
        the WebCore client API

        All clients must now be supplied as constructor arguments. This clarifies
        when you need to create clients, and also guarantees that objects can't
        (for the most part) be in a clientless state.

        Layout tests pass. No leaks reported.

        * bridge/mac/WebCoreFrameBridge.mm: I had to move some initialization up into
        WebKit to resolve circular dependencies at init time.

WebKit:

        Reviewed by Beth Dakin.

        Fixed <rdar://problem/4844855> Should clarify when to create clients in
        the WebCore client API

        All clients must now be supplied as constructor arguments. This clarifies
        when you need to create clients, and also guarantees that objects can't
        (for the most part) be in a clientless state.

        Layout tests pass. No leaks reported.

        * WebCoreSupport/WebFrameBridge.mm: Shuffled around initialization and changed
        some arguments to resolve ciruclar dependencies at init time.
        (-[WebFrame _initWithWebFrameView:webView:bridge:]): We no longer call setClient
        here, because the client is set up at construction time.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17918 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years ago Reviewed by Ada.
aroben [Wed, 29 Nov 2006 04:19:21 +0000 (04:19 +0000)]
    Reviewed by Ada.

        Add platform-specific constructor/destructor to ContextMenu so we can
        properly retain/release the platform menu description.

        * platform/ContextMenu.h:
        (WebCore::ContextMenu::platformDescription):
        * platform/mac/ContextMenuMac.mm:
        (WebCore::ContextMenu::ContextMenu):
        (WebCore::ContextMenu::~ContextMenu):
        (WebCore::getNSMenuItem):
        (WebCore::ContextMenu::appendItem):
        (WebCore::ContextMenu::itemCount):
        (WebCore::ContextMenu::insertItem):
        (WebCore::ContextMenu::setPlatformDescription):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17917 268f45cc-cd09-0410-ab3c-d52691b4dbfc

15 years ago Build fix.
aroben [Wed, 29 Nov 2006 01:51:39 +0000 (01:51 +0000)]
    Build fix.

        * platform/network/mac/ResourceRequestMac.mm:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@17913 268f45cc-cd09-0410-ab3c-d52691b4dbfc