17 years agotop level:
darin [Tue, 3 May 2005 01:17:08 +0000 (01:17 +0000)]
top level:

        - move to Xcode native targets and stop checking in generated files

        * configure.in: Removed gperf and yacc sections, and all the makefile paths for subdirectories
        of JavaScriptCore and WebCore, since those directories no longer have makefiles.


        - move to Xcode native targets and stop checking in generated files

        * CommitLogEditor/CommitLogEditor.pbproj/project.pbxproj: Updated to use native targets.
        * CommitLogEditor/Info.plist: Added. Native targets use a separate file for this.

        * HotSpotFinder/HotSpotFinder.pbproj/project.pbxproj: Updated to use native targets.
        * HotSpotFinder/Info.plist: Added. Native targets use a separate file for this.


        - move to Xcode native targets and stop checking in generated files

        * JavaScriptCore.pbproj/project.pbxproj: Updated to use native targets and generate all the generated
        files, so we don't have to check them in any more.
        * Info.plist: Added. Native targets use a separate file for this.

        * Makefile.am: Removed pcre and kjs SUBDIRS. Also removed code that deleted the embedded copy of this
        framework, since we haven't been embedding it for some time.

        * kjs/grammar_wrapper.cpp: Added. Shell used to compile grammar.cpp since we can't add a generated file
        easily to the list of files to be compiled.

        * kjs/.cvsignore: Removed.
        * kjs/Makefile.am: Removed.
        * kjs/array_object.lut.h: Removed.
        * kjs/date_object.lut.h: Removed.
        * kjs/grammar.cpp: Removed.
        * kjs/grammar.cpp.h: Removed.
        * kjs/grammar.h: Removed.
        * kjs/lexer.lut.h: Removed.
        * kjs/math_object.lut.h: Removed.
        * kjs/number_object.lut.h: Removed.
        * kjs/string_object.lut.h: Removed.
        * pcre/.cvsignore: Removed.
        * pcre/Makefile.am: Removed.
        * pcre/chartables.c: Removed.


        - move to Xcode native targets and stop checking in generated files

        * WebCore.pbproj/project.pbxproj: Updated to use native targets and generate all the generated
        files, so we don't have to check them in any more.
        * Info.plist: Added. Native targets use a separate file for this.

        * Makefile.am: Removed rule to generate WebCore-combined.exp since this is now handled by the
        Xcode project. Removed the code to remove the embedded copy of the framework since we don't
        do that any more. Removed timestamp cleaning rules since we don't use those any more.

        * WebCore-tests.exp: Removed symbols that aren't really needed. The native target gives an
        error when you mention a nonexistent symbol, so we can't have them any more.

        * khtml/css/parser_wrapper.cpp: Added. Shell used to compile parser.cpp since we can't add
        a generated file easily to the list of files to be compiled.

        * .cvsignore: Removed various timestamp files.

        * WebCore-combined.exp: Removed.
        * force-clean-timestamp: Removed.
        * force-js-clean-timestamp: Removed.
        * khtml/.cvsignore: Removed.
        * khtml/Makefile.am: Removed.
        * khtml/css/.cvsignore: Removed.
        * khtml/css/Makefile.am: Removed.
        * khtml/css/cssproperties.c: Removed.
        * khtml/css/cssproperties.h: Removed.
        * khtml/css/cssvalues.c: Removed.
        * khtml/css/cssvalues.h: Removed.
        * khtml/css/parser.cpp: Removed.
        * khtml/css/parser.h: Removed.
        * khtml/css/tokenizer.cpp: Removed.
        * khtml/ecma/.cvsignore: Removed.
        * khtml/ecma/Makefile.am: Removed.
        * khtml/ecma/kjs_css.lut.h: Removed.
        * khtml/ecma/kjs_dom.lut.h: Removed.
        * khtml/ecma/kjs_events.lut.h: Removed.
        * khtml/ecma/kjs_html.lut.h: Removed.
        * khtml/ecma/kjs_navigator.lut.h: Removed.
        * khtml/ecma/kjs_range.lut.h: Removed.
        * khtml/ecma/kjs_traversal.lut.h: Removed.
        * khtml/ecma/kjs_views.lut.h: Removed.
        * khtml/ecma/kjs_window.lut.h: Removed.
        * khtml/ecma/xmlhttprequest.lut.h: Removed.
        * khtml/ecma/xmlserializer.lut.h: Removed.
        * khtml/html/.cvsignore: Removed.
        * khtml/html/Makefile.am: Removed.
        * khtml/html/doctypes.cpp: Removed.
        * khtml/html/kentities.c: Removed.
        * khtml/misc/.cvsignore: Removed.
        * khtml/misc/Makefile.am: Removed.
        * khtml/misc/htmlattrs.c: Removed.
        * khtml/misc/htmlattrs.h: Removed.
        * khtml/misc/htmltags.c: Removed.
        * khtml/misc/htmltags.h: Removed.
        * kwq/.cvsignore: Removed.
        * kwq/KWQCharsetData.c: Removed.
        * kwq/KWQColorData.c: Removed.
        * kwq/Makefile.am: Removed.


        - move to Xcode native targets and stop checking in generated files

        * WebKit.pbproj/project.pbxproj: Updated to use native targets and generate all the generated
        files, so we don't have to check them in any more.
        * Info.plist: Added. Native targets use a separate file for this.

        * Plugins.subproj/npapi.m: Fixed import statement to get npapi.h from <WebKit/> rather than current directory.

        * Makefile.am: Removed timestamp cleaning rules since we don't use it any more.

        * .cvsignore: Removed various timestamp files.

        * DOM.subproj/DOM-compat.h: Removed.
        * DOM.subproj/DOM.h: Removed.
        * DOM.subproj/DOMCSS.h: Removed.
        * DOM.subproj/DOMCore.h: Removed.
        * DOM.subproj/DOMEvents.h: Removed.
        * DOM.subproj/DOMExtensions.h: Removed.
        * DOM.subproj/DOMHTML.h: Removed.
        * DOM.subproj/DOMPrivate.h: Removed.
        * DOM.subproj/DOMRange.h: Removed.
        * DOM.subproj/DOMStylesheets.h: Removed.
        * DOM.subproj/DOMTraversal.h: Removed.
        * DOM.subproj/DOMViews.h: Removed.
        * Plugins.subproj/WebScriptObject.h: Removed.
        * Plugins.subproj/npapi.h: Removed.
        * Plugins.subproj/npruntime.h: Removed.
        * copy-webcore-files-to-webkit: Removed.
        * embed-frameworks.sh: Removed.
        * force-clean-timestamp: Removed.


        - move to Xcode native targets and stop checking in generated files

        * WebBrowser.pbproj/project.pbxproj: Updated to use native target.
        * Info.plist: Added. Native targets use a separate file for this.

        * .cvsignore: Took out .DS_Store, since that's always ignored server-wide.

        * English.lproj/.cvsignore: Removed.
        * Preferences.subproj/.cvsignore: Removed.
        * Resources/.cvsignore: Removed.
        * Resources/Images/.cvsignore: Removed.


        - move to Xcode native targets and stop checking in generated files

        * Blot/Blot.xcode/project.pbxproj: Updated to use a native target.

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

17 years agoFix layout test paths.
darin [Mon, 2 May 2005 23:05:29 +0000 (23:05 +0000)]
Fix layout test paths.

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

17 years ago Reviewed by Vicki.
darin [Mon, 2 May 2005 18:39:16 +0000 (18:39 +0000)]
    Reviewed by Vicki.
        Added two layout tests for regression testing.

        - redid frameElement (fix for 4091082 below)

        The first version lacked a security check, and was also broken.

        * khtml/ecma/kjs_window.cpp:
        (frameElement): Refactored into separate function; added isSafeScript check.
        (Window::get): Call the new frameElement function.

        * fast/frames/frameElement-frame.html: Added.
        * fast/frames/frameElement-frame-expected.txt: Added.
        * fast/frames/frameElement-iframe.html: Added.
        * fast/frames/frameElement-iframe-expected.txt: Added.
        * fast/frames/resources/frameElement-contents.html: Added.

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

17 years ago Reviewed by Vicki.
harrison [Mon, 2 May 2005 17:11:26 +0000 (17:11 +0000)]
    Reviewed by Vicki.

        Fix isStartOfEditableContent and isEndOfEditableContent to return actual, rather than inverted, answers.
        No Radar.  Found this when trying to use isEndOfEditableContent() in some new code.

        * khtml/editing/visible_units.cpp:
        Flip expressions.

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

17 years ago Reviewed by David Harrison.
darin [Fri, 29 Apr 2005 22:34:24 +0000 (22:34 +0000)]
    Reviewed by David Harrison.

        * khtml/xml/dom_nodeimpl.cpp: (NodeImpl::displayNode): Turn newlines into \n for better dumping.

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

17 years ago Reviewed by Darin.
harrison [Fri, 29 Apr 2005 20:13:42 +0000 (20:13 +0000)]
    Reviewed by Darin.

        <rdar://problem/4083333> When deleting link at end of sentence, entire sentence gets deleted

        * khtml/editing/htmlediting.cpp:
        Work around bug #4103339 (whose real fix is somewhat risky), so this fix can get into a software update.

        Add isAncestor check when comparing m_downstreamEnd.node() and m_startNode.

        * layout-tests/editing/deleting/delete-4083333-fix-expected.txt: Added.
        * layout-tests/editing/deleting/delete-4083333-fix.html: Added.

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

17 years ago Reviewed by Dave Harrison.
darin [Fri, 29 Apr 2005 19:10:13 +0000 (19:10 +0000)]
    Reviewed by Dave Harrison.

        - changed layout tests to dump more minimal information about caret and selection

        * kwq/KWQRenderTreeDebug.cpp:
        (nodePosition): Changed name; now does position relative to document.
        (writeSelection): Removed upstream/downstream code and changed format slightly.

        * layout-tests/editing/*-expected.txt: Regenerated in new format.

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

17 years ago Reviewed by Chris Blumenberg.
darin [Fri, 29 Apr 2005 17:28:54 +0000 (17:28 +0000)]
    Reviewed by Chris Blumenberg.
        Added two layout tests for regression testing.

        - fixed <rdar://problem/4097849> REGRESSION (162-163): importNode creates non-HTML elements, thus style attributes (and some others) don't work

        * khtml/xml/dom_docimpl.cpp:
        (DocumentImpl::importNode): Reorganized and partly rewrote this. The change that fixes the bug at
        hand is to explicitly use XHTML_NAMESPACE for HTML elements, since the old way of getting the namespace
        will return the null string for HTML elements, and createElementNS will not create an HTML element
        if passed a null string for the namespace.
        (DocumentImpl::processHttpEquiv): Removed some bogus getDocument() calls -- no need to call getDocument()
        in a document object.
        (DocumentImpl::attrName): Ditto.
        (DocumentImpl::tagName): Ditto.
        (DocumentImpl::setFocusNode): Ditto.

        * khtml/html/html_elementimpl.cpp: (HTMLElementImpl::cloneNode): Moved the actual cloning here
        from ElementImpl::cloneNode, because XMLElementImpl already had its own version, and in here
        we can use createHTMLElement, which will work properly even in an XML document, and is also slightly
        more efficient.

        * khtml/xml/dom_nodeimpl.h: Added a namespaceURI method function to go along with localName.
        * khtml/xml/dom_nodeimpl.cpp: (NodeImpl::namespaceURI): Added. Returns null string to be consistent
        with localName (only works on certain types of elements as documented).
        * khtml/xml/dom_elementimpl.h: Removed ElementImpl::cloneNode (see above). Added an override of
        namespaceURI for XMLElementImpl.
        * khtml/xml/dom_elementimpl.cpp: (XMLElementImpl::namespaceURI): Added. Returns the namespace
        (consistent with localName).

        * layout-tests/fast/dom/importNodeHTML.html: Added. Tests both importNode and cloneNode (for comparison).
        * layout-tests/fast/dom/importNodeHTML-expected.txt: Added.
        * layout-tests/fast/dom/importNodeXML.xhtml: Added. XML version of the same test as above. Tests a different
        code path, so useful to have.
        * layout-tests/fast/dom/importNodeXML-expected.txt: Added.

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

17 years ago Reviewed by Maciej.
darin [Fri, 29 Apr 2005 01:13:11 +0000 (01:13 +0000)]
    Reviewed by Maciej.

        - fixed problems preventing us from compiling with gcc 4.0

        * WebKit.pbproj/project.pbxproj: Removed -fobjc-exceptions because I can't figure out an easy
        way to pass it only when compiling Objective-C/C++. Removed -Wmissing-prototypes from
        WARNING_CPLUSPLUSFLAGS since it's now a C-only warning.

        * History.subproj/WebHistoryItem.m: (-[WebHistoryItem pageCache]): Changed return type
        to match the declaration.
        * WebCoreSupport.subproj/WebBridge.m: (-[WebBridge _retrieveKeyboardUIModeFromPreferences:]):
        Fixed a BOOL that should have been a Boolean.
        * WebCoreSupport.subproj/WebTextRenderer.m: Removed redundant copy of ROUND_TO_INT, also in
        a WebCore header.
        (-[WebTextRenderer _computeWidthForSpace]): Had to add cast because of difference in type of
        (pathFromFont): Added a cast to convert UInt8 * to char *.
        * WebView.subproj/WebFrameView.m:
        (-[WebFrameView _setDocumentView:]): Fixed parameter type to match the declaration.
        (-[WebFrameView documentView]): Fixed return type to match the declaration.
        * WebView.subproj/WebHTMLView.m:
        (-[WebHTMLView _startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]):
        Initialized a variable to quiet an incorrect gcc 4.0 uninitialized variable warning.
        (-[WebHTMLView deleteToMark:]): Switched from @try style to NS_DURING style of exception handler
        because we can't pass -fobjc-exceptions just to Objective-C at the moment (see above).
        (-[WebHTMLView selectToMark:]): Ditto.
        (-[WebHTMLView swapWithMark:]): Ditto.

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

17 years ago Reviewed by Dave Harrison.
darin [Fri, 29 Apr 2005 00:31:01 +0000 (00:31 +0000)]
    Reviewed by Dave Harrison.

        - fixed problems preventing us from compiling with gcc 4.0

        * WebCore.pbproj/project.pbxproj: Removed -fobjc-exceptions because I can't figure out an easy
        way to pass it only when compiling Objective-C/C++. Removed -Wmissing-prototypes from
        WARNING_CPLUSPLUSFLAGS since it's now a C-only warning.

        * khtml/css/parser.y: Changed some rules that were using a float to pass around an enum to use an
        int instead to avoid a warning.
        * khtml/css/parser.cpp: Regenerated.
        * khtml/css/parser.h: Regenerated.

        * khtml/ecma/kjs_dom.cpp: (DOMTextProtoFunc::tryCall): Rearranged a return statement to avoid an incorrect
        * khtml/ecma/kjs_html.cpp: (KJS::Context2DFunction::tryCall): Initialized a couple of variables to avoid
        an incorrect warning.
        * khtml/ecma/kjs_proxy.cpp: (KJSProxyImpl::evaluate): Rearranged how we exit from the function to avoid
        an incorret warning.
        * khtml/editing/selection.cpp: (khtml::Selection::debugPosition): Changed some %d to %ld where the
        parameters where long ints.
        * khtml/editing/visible_position.cpp: (khtml::VisiblePosition::debugPosition): Ditto.
        * khtml/xml/dom_position.cpp: (DOM::Position::debugPosition): Ditto.
        * kwq/DOMEvents.mm: (-[DOMMouseEvent initMouseEvent:::::::::::::::]): Rearranged code to avoid a cast
        that was causing an incorrect warning.
        * kwq/DOMUtility.mm:
        (createObjCDOMNode): Broke out as a separate function.
        (KJS::ScriptInterpreter::createObjcInstanceForValue): Rearranged code to avoid a namespace collision with
        KJS::DOMNode and the Objective-C DOMNode class.
        * kwq/KWQFileButton.mm: Made fields of KWQFileButtonAdapter public to avoid an error, new to gcc 4.0,
        about accessing protected Objective-C fields.
        * kwq/KWQKHTMLPart.mm:
        (KWQKHTMLPart::matchLabelsAgainstElement): Rearranged a return statement to avoid an incorrect warning.
        (KWQKHTMLPart::imageFromRect): Rearranged how this function does its exception handling to avoid a
        "may be clobbered" warning.
        * kwq/KWQKJavaAppletWidget.mm: Fixed incorrect import that said "KHTMLView.h" instead of "khtmlview.h".
        * kwq/KWQObject.mm: Made fields of KWQObjectTimerTarget public to avoid an error, new to gcc 4.0,
        about accessing protected Objective-C fields.
        * kwq/WebCoreBridge.mm: (partHasSelection): Used [bridge part] instead of getting directly at instance
        variable to avoid an error, new to gcc 4.0, about accessing protected Objective-C fields.

        * WebCore-combined.exp: Regenerated.
        * WebCore-tests.exp: Added some additional symbols needed by the tests under gcc 4.0.

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

17 years ago Reviewed by Dave Harrison.
darin [Fri, 29 Apr 2005 00:22:55 +0000 (00:22 +0000)]
    Reviewed by Dave Harrison.

        - fixed problems preventing us from compiling with gcc 4.0

        * JavaScriptCore.pbproj/project.pbxproj: Removed -Wmissing-prototypes from
        WARNING_CPLUSPLUSFLAGS since it's now a C-only warning.

        * bindings/jni/jni_jsobject.cpp:
        (JSObject::getSlot): Changed some %d to %ld where the parameters where long ints.
        (JSObject::setSlot): Ditto.
        * bindings/jni/jni_utility.cpp:
        (KJS::Bindings::getJavaVM): Ditto.
        (KJS::Bindings::getJNIEnv): Ditto.
        * bindings/objc/objc_utility.mm: Fixed include of <JavascriptCore/internal.h> that needed the
        letter "S" capitalized.
        * kjs/bool_object.cpp: (BooleanProtoFuncImp::call): Rearranged how this function returns to
        avoid incorrect gcc 4.0 warning.
        * kjs/collector.cpp: (KJS::Collector::markStackObjectsConservatively): Changed code to check
        the alignment of the passed-in pointers to only require pointer-level alignment, not 8-byte alignment.
        Prevents a crash on garbage collect when compiled with gcc 4.0.
        * kjs/nodes.cpp:
        (WhileNode::execute): Added a redundant return after an infinite loop to work around incorrect gcc 4.0 warning.
        (ForNode::execute): Ditto.
        (SwitchNode::execute):Rearranged how this function returns to avoid incorrect gcc 4.0 warning.
        (LabelNode::execute): Ditto.
        * kjs/string_object.cpp: (replace): Ditto.

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

17 years agoFix ChangeLog
darin [Fri, 29 Apr 2005 00:07:23 +0000 (00:07 +0000)]
Fix ChangeLog

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

17 years ago * WebCore.pbproj/project.pbxproj: Add back the main_thread_malloc files,...
darin [Fri, 29 Apr 2005 00:07:03 +0000 (00:07 +0000)]
    * WebCore.pbproj/project.pbxproj: Add back the main_thread_malloc files, rolled out by accident.

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

17 years ago Rolling out fix for <rdar://problem/4097849> because the following layout...
adele [Thu, 28 Apr 2005 01:04:59 +0000 (01:04 +0000)]
    Rolling out fix for <rdar://problem/4097849> because the following layout tests were failing:


        * khtml/html/html_documentimpl.cpp:
        * khtml/html/html_documentimpl.h:
        * khtml/html/html_elementimpl.cpp:
        * khtml/xml/dom_docimpl.cpp:
        * khtml/xml/dom_docimpl.h:

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

17 years agoone more tweak
vicki [Thu, 28 Apr 2005 01:03:24 +0000 (01:03 +0000)]
one more tweak

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

17 years agoWebCore-413.1
vicki [Thu, 28 Apr 2005 00:06:31 +0000 (00:06 +0000)]

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

17 years ago Reviewed by Darin.
sullivan [Wed, 27 Apr 2005 21:34:35 +0000 (21:34 +0000)]
    Reviewed by Darin.

        Experimental prototype of user-resizable textareas. All the new code is guarded by
        #if ALLOW_RESIZING_TEXTAREAS, which is false unless you remove a comment and rebuild.

        This code allows you to press near the bottom-right corner of any textarea and drag
        to resize the textarea on the page. It works correctly with textareas in left-aligned
        or centered blocks, but is weird in right-aligned blocks. It also does something
        sensible if the width is specified as a % (in that case, you can resize vertically only).
        The user-created-size survives resizing the window and survives the back/forward cache.
        It does not survive reloading the page.

        This complete-lack-of-affordance UI is obviously not shippable, but this proof of concept
        code could lead to a real user feature.

        * kwq/KWQTextArea.mm:
        (-[KWQTextArea getNumColumns:andNumRows:forSize:]):
        new method that determines cols and rows for a given textarea frame size
        (-[KWQTextAreaTextView _trackResizeFromMouseDown:]):
        new method that tracks a drag and does a live resize-and-relayout
        (-[KWQTextAreaTextView mouseDown:]):
        if the mouse down is in the bottom-right corner, call _trackResizeFromMouseDown:

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

17 years ago Reviewed by Adele.
sullivan [Wed, 27 Apr 2005 21:32:26 +0000 (21:32 +0000)]
    Reviewed by Adele.

        - fixed problem with mouse wheel patch where alt and shift keys were switched

        * khtml/xml/dom2_eventsimpl.h:
        use the order cntl, alt, shift, meta in KeyboardEventImpl constructors to match
        superclass. This isn't necessary to fix the bug, but is better for clarity.

        * khtml/xml/dom2_eventsimpl.cpp:
        switch parameter order to match superclass. Then pass the parameters to superclass's
        constructor in the right order.
        Pass parameters to superclass's constructor in the right order.

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

17 years ago Reviewed by Dave Harrison.
sullivan [Wed, 27 Apr 2005 17:59:15 +0000 (17:59 +0000)]
    Reviewed by Dave Harrison.

        - fixed <rdar://problem/3547489> pop-up window blocking preference and
        menu item can easily get out of sync.

        * WebView.subproj/WebPreferences.m:
        (-[WebPreferences _setStringValue:forKey:]):
        save local value before setting value in NSUserDefaults, so clients reacting to NSUserDefaults
        change notification but calling back on WebPreferences API will see the updated value.
        (-[WebPreferences _setIntegerValue:forKey:]):
        (-[WebPreferences _setBoolValue:forKey:]):

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

17 years ago Fixed by Darin, reviewed by me.
adele [Wed, 27 Apr 2005 05:52:08 +0000 (05:52 +0000)]
    Fixed by Darin, reviewed by me.

        Fix for <rdar://problem/4084029> designMode doesn't allow editing when iframe src = "" or = about:blank

        This change will add an HTML element for empty documents.  Now that there will be an HTMLDocument in this case,
        a body will also be created (see rdar://problem/3758785). This was preventing frames with empty documents from
        being editable.

        * khtml/html/htmlparser.cpp: (KHTMLParser::finished):

        Updated these tests to expect the HTML and BODY elements
        * layout-tests/fast/flexbox/016-expected.txt:
        * layout-tests/fast/frames/001-expected.txt:
        * layout-tests/fast/frames/002-expected.txt:
        * layout-tests/fast/frames/contentWindow_Frame-expected.txt:
        * layout-tests/fast/frames/contentWindow_iFrame-expected.txt:
        * layout-tests/fast/frames/empty-frame-src-expected.txt:

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

17 years agoJavaScriptCore:
rjw [Wed, 27 Apr 2005 01:03:57 +0000 (01:03 +0000)]
Fixed <rdar://problem/4098713> Scripting API is incompatible with Mozilla

We were incompatible with Mozilla's implementation of the scripting APIs in
two ways:

Their NPN_SetException has the following signature:

            void NPN_SetException(NPObject *npobj, const NPUTF8 *message);

ours has:

            void NPN_SetException (NPObject * npobj, const NPString *message);

Also, they expect the string returned from NPN_UTF8FromIdentifier() to be freed by caller.
We do not.

I changed both behaviors to match Mozilla.

        Reviewed by Chris.

        * bindings/NP_jsobject.cpp:
        * bindings/npruntime.cpp:
        * bindings/npruntime.h:
        * bindings/npruntime_impl.h:

Fixed <rdar://problem/4098713> Scripting API is incompatible with Mozilla

        Reviewed by Chris.

        * Plugins.subproj/npfunctions.h:
        * Plugins.subproj/npruntime.h:

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

17 years agoJavaScriptCore:
mjs [Wed, 27 Apr 2005 00:18:14 +0000 (00:18 +0000)]

        Reviewed by Chris.

<rdar://problem/4092136> reproducible crash in KJS::kjs_fast_realloc loading maps.google.com

* kjs/string_object.cpp:
        (StringObjectFuncImp::call): Allocate adopted ustring buffer properly.


        New test case for <rdar://problem/4092136> reproducible crash in KJS::kjs_fast_realloc loading maps.google.com

        * layout-tests/fast/js/string-from-char-code-expected.txt: Added.
        * layout-tests/fast/js/string-from-char-code.html: Added.

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

17 years agoWebCore:
darin [Tue, 26 Apr 2005 23:36:34 +0000 (23:36 +0000)]

        Reviewed by John.

        - fixed <rdar://problem/3655817> please add support for mouse wheel events and the onmousewheel handler

        Loose ends:

            - need to test behavior of Windows IE with horizontal scroll wheeling; we currently send a distinct event
              for that relatively obscure case, which means the event handlers won't fire at all; might be incorrect
            - overflow scrolling is done after all DOM event handling, but ideally should be done in the overflowing
              element's default event handler; not important in practice
            - frame scrolling is done after all DOM event handling, but probably should be done in a default event handler;
              not sure about this, but it's probably not important in practice and definitely not required

        - JavaScript

        * khtml/ecma/kjs_events.h: Added DOMWheelEvent.
        * khtml/ecma/kjs_events.cpp:
        (KJS::getDOMEvent): Added a case for wheel event. To be forward looking, I use the event's impl pointer
        instead of a C++ DOM wrapper. Eventually it will all work this way.
        (offsetFromTarget): Added. Factored out code to compute offsetX/Y for an event.
        (DOMMouseEvent::getValueProperty): Changed to call offsetFromTarget for offsetX/Y.
        (DOMWheelEvent::DOMWheelEvent): Added.
        (DOMWheelEvent::tryGet): Added.
        (DOMWheelEvent::getValueProperty): Added.
        (DOMWheelEventProtoFunc::tryCall): Added. Nothing at the moment, but might get contents later.

        * khtml/ecma/kjs_dom.h: Added OnMouseWheel to the enum with the list of properties.
        * khtml/ecma/kjs_dom.cpp: Added onmousewheel as a property of DOM nodes.
        (DOMNode::getValueProperty): Return the mouse wheel event handler.
        (DOMNode::putValue): Set the mouse wheel event handler.

        * khtml/ecma/kjs_window.cpp: Added onmousewheel as a property of the window.
        (Window::get): Return the mouse wheel event handler.
        (Window::put): Set the mouse wheel event handler.

        * khtml/ecma/kjs_window.h: Added OnWindowMouseWheel to the enum with the list of properties.
        (Other properties distinguish the window handler by lower-casing the initial letter, way too subtle,
        so I did this one a good way.)

        * khtml/dom/dom2_events.h: Made the constructors for Event and UIEvent public. There's no good reason
        for them to be private, and I had to use the UIEvent one in the JavaScript implementation.

        - DOM

        * khtml/xml/dom2_eventsimpl.h: Added events for mouse wheel and horizontal mouse wheel.
        Added isWheelEvent function to EventImpl.
        (DOM::UIEventWithKeyStateImpl): Added. Base class shared by mouse, wheel, and keyboard events.
        (DOM::MouseRelatedEventImpl): Added. Base class shared by mouse and wheel events.
        (DOM::WheelEventImpl): Added.

        * khtml/xml/dom2_eventsimpl.cpp: Added "mousewheel" to list of event names and a placeholder for
        the horizontal mouse wheel.
        (EventImpl::isWheelEvent): Added. Returns false.
        (MouseRelatedEventImpl::MouseRelatedEventImpl): Added. Factored out what's shared between mouse
        events and wheel events to avoid duplicated code.
        (MouseRelatedEventImpl::computeLayerPos): Moved to MouseRelatedWheelEventImpl.
        (MouseEventImpl::MouseEventImpl): Changed since MouseRelatedWheelEventImpl is now the base class
        so we can share more code with wheel events.
        (KeyboardEventImpl::KeyboardEventImpl): Changed since UIEventWithKeyStateImpl is now the base class
        so we can share more code with mouse and wheel events.
        (WheelEventImpl::WheelEventImpl): Added.
        (WheelEventImpl::isWheelEvent): Added. Returns true.

        * khtml/misc/htmlattrs.in: Added "onmousewheel" attribute name.
        * khtml/html/html_elementimpl.cpp: (HTMLElementImpl::parseHTMLAttribute): Added parsing of the
        "onmousewheel" atribute, consistent with other event handler attributes.

        - event handling

        * kwq/WebCoreBridge.h: Renamed scrollOverflowWithScrollWheelEvent to sendScrollWheelEvent.
        * kwq/WebCoreBridge.mm: (-[WebCoreBridge sendScrollWheelEvent:]): Renamed.

        * kwq/KWQEvent.h: Added Wheel as an event type value.
        (QWheelEvent::QWheelEvent): Added.
        * kwq/KWQEvent.mm:
        (positionForEvent): Updated to know that wheel events have valid positions in them.
        (orientationForEvent): Added.
        (deltaForEvent): Added.
        (QWheelEvent::QWheelEvent): Added.

        * kwq/KWQKHTMLPart.h: Renamed scrollOverflowWithScrollWheelEvent to wheelEvent.
        * kwq/KWQKHTMLPart.mm: (KWQKHTMLPart::wheelEvent): Renamed and added code to construct a QWheelEvent
        and send it along to KHTMLView::viewportWheelEvent, consistent with how mouse events work.

        * khtml/khtmlview.cpp: (KHTMLView::viewportWheelEvent): Do a hit test to figure out which node to
        send the event to, and then call dispatchWheelEvent.

        * khtml/xml/dom_nodeimpl.h: Added dispatchWheelEvent.
        * khtml/xml/dom_nodeimpl.cpp: (NodeImpl::dispatchWheelEvent): Added.

        - generated files

        * khtml/ecma/kjs_dom.lut.h: Regenerated.
        * khtml/ecma/kjs_events.lut.h: Regenerated.
        * khtml/ecma/kjs_window.lut.h: Regenerated.
        * khtml/misc/htmlattrs.c: Regenerated.
        * khtml/misc/htmlattrs.h: Regenerated.


        Reviewed by John.

        - fixed <rdar://problem/3655817> please add support for mouse wheel events and the onmousewheel handler

        * WebView.subproj/WebHTMLView.m: (-[WebHTMLView scrollWheel:]): Call sendScrollWheelEvent: method
        instead of the old scrollOverflowWithScrollWheelEvent: (just a name change).

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

17 years ago Reviewed by Darin, Maciej.
harrison [Tue, 26 Apr 2005 22:39:33 +0000 (22:39 +0000)]
    Reviewed by Darin, Maciej.

        <rdar://problem/4075576> Deleting text in new message borks content

        Fixed by removing the methods that attempted to preserve the position.  The idea
        of preserving position is a very recent one, and turned out to not actually address
        the problem it was intended to fix (see below).  Further, is unclear how the position
        could be preserved in a form that could be properly used later on.   Therefore,
        removing the code to work like before is the preferred alternative for this software
        update.  I've written <rdar://problem/4099839> to cover the bug that position
        preservation was supposed to fix (but did not).  Added layout tests for
        both this bug and 4099839.  Also, updated existing tests with correct expected results
        (delete-at-paragraph-boundaries-003 and 004).

        * khtml/editing/htmlediting.cpp:
        * khtml/editing/htmlediting.h:
        * layout-tests/editing/deleting/delete-at-paragraph-boundaries-003-expected.txt:
        * layout-tests/editing/deleting/delete-at-paragraph-boundaries-004-expected.txt:
        * layout-tests/editing/deleting/delete-at-paragraph-boundaries-007-expected.txt: Added.
        * layout-tests/editing/deleting/delete-at-paragraph-boundaries-007.html: Added.
        * layout-tests/editing/deleting/delete-at-paragraph-boundaries-008-expected.txt: Added.
        * layout-tests/editing/deleting/delete-at-paragraph-boundaries-008.html: Added.
        * layout-tests/editing/deleting/delete-at-paragraph-boundaries-009-expected.txt: Added.
        * layout-tests/editing/deleting/delete-at-paragraph-boundaries-009.html: Added.
        * layout-tests/editing/deleting/delete-at-paragraph-boundaries-010-expected.txt: Added.
        * layout-tests/editing/deleting/delete-at-paragraph-boundaries-010.html: Added.

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

17 years ago - fixed development builds
darin [Tue, 26 Apr 2005 21:20:28 +0000 (21:20 +0000)]
    - fixed development builds

        * khtml/misc/main_thread_malloc.h: Use inlines instead of macros for allocation functions.

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

17 years ago Fix for 4097842, changing 1st line of a url that wraps doesn't update the second...
hyatt [Tue, 26 Apr 2005 21:12:02 +0000 (21:12 +0000)]
Fix for 4097842, changing 1st line of a url that wraps doesn't update the second line.  Make sure to
update line break info for the last dirty line so that when a clean line tries to figure out where it
started, it will get an accurate position taking into account the updated string.  By doing this, the code
will be able to properly distinguish between the old and new positions and not accidentally assume they are
the same.

        Reviewed by darin

        * khtml/rendering/render_text.cpp:

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

17 years ago Reviewed by Maciej.
darin [Tue, 26 Apr 2005 21:02:08 +0000 (21:02 +0000)]
    Reviewed by Maciej.

        - fixed <rdar://problem/4098826> Bezier curves broken in new Safari canvas object (last two parameters parsed incorrectly)

        * khtml/ecma/kjs_html.cpp: (KJS::Context2DFunction::tryCall): Fixed incorrect argument indices.
        Thanks to Brian Campbell who figured out what was wrong.

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

17 years ago Reviewed by Darin.
mjs [Tue, 26 Apr 2005 18:46:04 +0000 (18:46 +0000)]
    Reviewed by Darin.

- use single-threaded malloc in places where malloc is hot for an
8% speed improvement on cvs-base

        * ForwardingHeaders/misc/fast_malloc.h: Added.
        * WebCore.pbproj/project.pbxproj:
        * khtml/css/css_base.h:
        * khtml/css/css_ruleimpl.h:
        * khtml/css/css_valueimpl.h:
        * khtml/css/cssstyleselector.h:
        * khtml/misc/arena.cpp:
        * khtml/misc/main_thread_malloc.cpp: Added.
        * khtml/misc/main_thread_malloc.h: Added.
        * khtml/rendering/render_style.h:
        * khtml/xml/dom2_eventsimpl.h:
        * khtml/xml/dom2_rangeimpl.h:
        * khtml/xml/dom2_traversalimpl.h:
        * khtml/xml/dom2_viewsimpl.h:
        * khtml/xml/dom_docimpl.h:
        * khtml/xml/dom_elementimpl.cpp:
        * khtml/xml/dom_elementimpl.h:
        * khtml/xml/dom_nodeimpl.h:
        * khtml/xml/dom_stringimpl.h:
        * kwq/KWQFontFamily.h:
        * kwq/KWQListImpl.mm:
        * kwq/KWQString.h:
        * kwq/KWQString.mm:

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

17 years ago Reviewed by Dave Harrison.
sullivan [Mon, 25 Apr 2005 23:35:14 +0000 (23:35 +0000)]
    Reviewed by Dave Harrison.

        - fixed <rdar://problem/4098731> [DOMHTMLTextAreaElement cols] returns wrong value (usually zero)

        * kwq/DOMHTML.mm:
        (-[DOMHTMLTextAreaElement cols]):
        use ATTR_COLS instead of ATTR_ACCESSKEY (D'oh!)
        (-[DOMHTMLTextAreaElement setCols:]):
        fixed whitespace

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

17 years agoJavaScriptCore-412.1
vicki [Mon, 25 Apr 2005 18:37:06 +0000 (18:37 +0000)]

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

17 years ago Reviewed by John.
darin [Mon, 25 Apr 2005 15:55:02 +0000 (15:55 +0000)]
    Reviewed by John.

        - fixed <rdar://problem/4097849> REGRESSION (162-163): importNode creates non-HTML elements, thus style attributes (and some others) don't work

        * khtml/xml/dom_docimpl.h: Add virtual functions HTMLElementNamespace and isHTMLNamespace.
        * khtml/xml/dom_docimpl.cpp:
        (DocumentImpl::importNode): Rearranged this function and fixed the following problems: 1) made sure to ref node while attributes are
        being set on it so it doesn't get destroyed; 2) fixed code to get namespace from the element we are importing to use the IDs from
        the source document, not the destination document; 3) removed unneeded getDocument() call which just returns this; 4) fixed error
        handling for cases where an exception happens while processing the children.
        (DocumentImpl::HTMLElementNamespace): Added. Returns XHTML_NAMESPACE.
        (DocumentImpl::isHTMLNamespace): Added. Returns true for any namespace that matches XHTML_NAMESPACE (case insensitive).
        (DocumentImpl::createElementNS): Changed to call isHTMLNamespace, which will cause it to accept the null namespace in an HTML document.
        This is the change that fixes the bug. Also fixed the code path to do a little less wasteful work in the non-XHTML case.
        (DocumentImpl::createHTMLElement): Pass in HTMLElementNamespace() rather than 0 to tagId.
        (DocumentImpl::attrId): Use isHTMLNamespace instead of allowing the null namespace explicitly.
        (DocumentImpl::tagId): Ditto.

        * khtml/html/html_documentimpl.h: Add overrides for HTMLElementNamespace and isHTMLNamespace.
        * khtml/html/html_documentimpl.cpp:
        (HTMLDocumentImpl::HTMLElementNamespace): Added. Returns 0 so we use the null string for HTML elements inside HTML documents (as before).
        (HTMLDocumentImpl::isHTMLNamespace): Added. Allows 0, and then calls base class to check for the actual XHTML namespace. Thus, we allow
        both no namespace at all and the XHTML namespace inside HTML documents.

        * khtml/html/html_elementimpl.cpp: (HTMLElementImpl::namespaceURI): Changed to call HTMLElementNamespace rather than checking
        isHTMLDocument. Same result as before, but better division of responsibilities.

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

17 years ago Reviewed by John.
darin [Mon, 25 Apr 2005 15:43:10 +0000 (15:43 +0000)]
    Reviewed by John.

        - fixed <rdar://problem/4091956> JavaScript drop handlers don't receive more than one dropped item

        * kwq/KWQClipboard.mm:
        (cocoaTypeFromMIMEType): Remove some use of compare -- less efficient than a simpler "==" check.
        Fixed non-GC-safe code to use KWQCFAutorelease instead.
        (MIMETypeFromCocoaType): Use fromCFString instead of fromNSString to avoid a cast.
        (KWQClipboard::getData): Rearrange so that we'll use filenames if both filenames and a URL are present, since
        filenames can accomodate multiple items. Fix bug where we'd return multiple filenames when the type requested
        is "URL". Fixed loop that computed the count over and over again for the loop termination condition. Check
        that the data for NSFilenamesPboardType is an NSArray instead of assuming it is.
        (KWQClipboard::setData): Use isEqualToString: instead of == when comparing types.

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

17 years ago Fix for 4096878, drop shadow effect not displayed correctly on tbray.org/ongoing...
hyatt [Sat, 23 Apr 2005 00:42:00 +0000 (00:42 +0000)]
Fix for 4096878, drop shadow effect not displayed correctly on tbray.org/ongoing/.  Block minmaxwidth was
broken when negative margins were used and did not properly decrease the max width.

        Reviewed by Maciej

        * khtml/rendering/render_block.cpp:
        * layout-tests/fast/block/float/034-expected.txt: Added.
        * layout-tests/fast/block/float/034.html: Added.
        * layout-tests/fast/block/float/035-expected.txt: Added.
* layout-tests/fast/block/float/035.html: Added.

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

17 years ago Remove some dead code from css_valueimpl. It wasn't used at all.
hyatt [Sat, 23 Apr 2005 00:08:30 +0000 (00:08 +0000)]
    Remove some dead code from css_valueimpl.  It wasn't used at all.

        * khtml/css/css_valueimpl.cpp:
        * khtml/css/css_valueimpl.h:

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

17 years ago Reviewed by Maciej.
darin [Fri, 22 Apr 2005 21:53:58 +0000 (21:53 +0000)]
    Reviewed by Maciej.

        * kjs/ustring.cpp: (KJS::UString::UTF8String): Fix off-by-one error in surrogate pair logic.

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

17 years ago * khtml/ecma/kjs_html.h: Removed unnecessary bogus class name qualifiers.
darin [Fri, 22 Apr 2005 21:19:58 +0000 (21:19 +0000)]
    * khtml/ecma/kjs_html.h: Removed unnecessary bogus class name qualifiers.

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

17 years ago Fix for 4096681, fix regression in how the list-style property is parsed. It no...
hyatt [Fri, 22 Apr 2005 18:12:16 +0000 (18:12 +0000)]
Fix for 4096681, fix regression in how the list-style property is parsed.  It no longer parses when it hits
a url in the property value list now, because the list pointer did not get advanced.  This fixes alistapart.com.

        Reviewed by john

        * khtml/css/cssparser.cpp:
        * layout-tests/fast/lists/009-expected.txt: Added.
        * layout-tests/fast/lists/009.html: Added.
        * layout-tests/fast/lists/resources/listmark.gif: Added.

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

17 years ago Reviewed by John.
darin [Fri, 22 Apr 2005 16:48:44 +0000 (16:48 +0000)]
    Reviewed by John.

        - fixed <rdar://problem/4090046> JavaScript throw statement causes parse error when no semicolon is present

        * kjs/grammar.y: Added an additional rule for throw like the ones we have for all the other semicolon rules.
        Not sure why we missed this one earlier.

        * kjs/grammar.cpp: Regenerated.

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

17 years ago Reviewed by John.
darin [Fri, 22 Apr 2005 16:30:28 +0000 (16:30 +0000)]
    Reviewed by John.

        - fixed <rdar://problem/4091082> Google Suggest no longer works due to lack of "frameElement"

        * khtml/ecma/kjs_window.h: Added FrameElement.
        * khtml/ecma/kjs_window.cpp: (Window::get): Added "frameElement".
        * khtml/ecma/kjs_window.lut.h: Regenerated.

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

17 years ago Reviewed by John.
darin [Fri, 22 Apr 2005 16:29:51 +0000 (16:29 +0000)]
    Reviewed by John.

        - a small editing-related code cleanup

        * khtml/rendering/render_text.h: Added positionForOffset and made offsetForPosition const.
        * khtml/rendering/render_text.cpp:
        (InlineTextBox::offsetForPosition): Made const.
        (InlineTextBox::positionForOffset): Added. Moved code here from caretRect.
        (RenderText::caretRect): Call positionForOffset instead of doing the work here.

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

17 years ago Fix for 4095839, wrong background image used on flechtwerk.de. Make sure that the...
hyatt [Thu, 21 Apr 2005 20:55:15 +0000 (20:55 +0000)]
Fix for 4095839, wrong background image used on flechtwerk.de.  Make sure that the global mapped
attribute cache hashed background attributes into per-document buckets.

        * khtml/html/html_baseimpl.cpp:
        * khtml/html/html_elementimpl.h:
        * khtml/html/html_tableimpl.cpp:
        * khtml/xml/dom_docimpl.cpp:
        * khtml/xml/dom_docimpl.h:

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

17 years ago - layout test for 4065447, outerHTML on images
vicki [Thu, 21 Apr 2005 16:07:43 +0000 (16:07 +0000)]
- layout test for 4065447, outerHTML on images

        * layout-tests/fast/dynamic/outerHTML-img-expected.txt: Added.
        * layout-tests/fast/dynamic/outerHTML-img.html: Added.

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

17 years ago Reviewed by hyatt.
vicki [Thu, 21 Apr 2005 16:02:24 +0000 (16:02 +0000)]
    Reviewed by hyatt.

- fixed <rdar://problem/4065447> support outerHTML on IMG elements

        * khtml/html/html_elementimpl.cpp:

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

17 years ago Reviewed by Maciej.
darin [Wed, 20 Apr 2005 10:14:35 +0000 (10:14 +0000)]
    Reviewed by Maciej.

        - speedups, total 12% on JavaScript iBench

        I ran the benchmark under Shark and followed its advice a lot, mainly.

        * kjs/collector.cpp:
        (KJS::Collector::allocate): Take out special case for 0; costing speed but unexercised.
        Use numLiveObjectsAtLastCollect instead of numAllocationsSinceLastCollect so we don't
        have to bump it each time we call allocate. Put numLiveObjects into a local variable to
        cut down on global variable accesses. Make "next" cell pointer be a byte offset rather
        than a pointer so we don't need a special case for NULL. Allow freeList to point to some
        bogus item when the entire block is full rather than going out of our way to make it
        point to NULL.
        (KJS::Collector::markProtectedObjects): Get table size and pointer into locals outside
        the loop to avoid re-loading them over and over again.
        (KJS::Collector::collect): Put numLiveObjects into a local variable to cut down on global
        variable accesses. Make "next" cell pointer be a byte offset as above. Put numLiveObjects
        into a local variable to cut down on global variable accesses. Set numLiveObjectsAtLastCollect
        rather than numAllocationsSinceLastCollect.
        (KJS::Collector::numReferencedObjects): Get table size and pointer into locals outside
        the loop to avoid re-loading them over and over again.
        (KJS::Collector::rootObjectClasses): Ditto.

        * kjs/internal.h: Make Value be a friend of NumberImp so it can construct number objects
        directly, avoiding the conversion from Number to Value.

        * kjs/internal.cpp: (StringImp::toObject): Don't use Object::dynamicCast, because we know
        the thing is an object and we don't want to do all the extra work; just cast directly.

        * kjs/list.cpp: (KJS::List::List): Construct valueRefCount in a way that avoids the need for
        a branch -- in the hot case this just meant avoiding checking a variable we just set to false.

        * kjs/lookup.cpp: (keysMatch): Marked this inline.

        * kjs/nodes.cpp: Disabled KJS_BREAKPOINT, to avoid calling hitStatement all the time.
        (BooleanNode::evaluate): Make a Value directly, rather than making a Boolean which is converted
        into a Value.
        (NumberNode::evaluate): Ditto.
        (StringNode::evaluate): Ditto.
        (ArrayNode::evaluate): Ditto.
        (FunctionCallNode::evaluate): Use new inline baseIfMutable to avoid unnecessary getBase function.
        Also just use a pointer for func, rather than an Object.
        (PostfixNode::evaluate): Change code so that it doesn't make an excess Number, and so that it
        passes a "known to be integer" boolean in, often avoiding a conversion from floating point to
        integer and back.
        (DeleteNode::evaluate): Make a Value directly.
        (TypeOfNode::evaluate): Use new inline baseIfMutable and make Value directly.
        (PrefixNode::evaluate): Change code so that it doesn't make an excess Number, and so that it
        passes a "known to be integer" boolean in, often avoiding a conversion from floating point to
        integer and back.
        (UnaryPlusNode::evaluate): Make a Value directly.
        (NegateNode::evaluate): Change code so that it doesn't make an excess Number, and so that it
        passes a "known to be integer" boolean in, often avoiding a conversion from floating point to
        integer and back.
        (BitwiseNotNode::evaluate): Make a Value directly.
        (LogicalNotNode::evaluate): Ditto.
        (ShiftNode::evaluate): Don't convert to a double before making a Value.
        (RelationalNode::evaluate): Make a Value directly.
        (EqualNode::evaluate): Ditto.
        (BitOperNode::evaluate): Ditto.
        (AssignNode::evaluate): Make a Value directly. Change code so that it passes a "known to be integer"
        boolean in, often avoiding a conversion from floating point to integer and back.
        (VarDeclNode::evaluate): Make a Value directly.
        (ForNode::execute): Remove unused local variable.

        * kjs/operations.h:
        (KJS::isNaN): Inlined.
        (KJS::isInf): Ditto.
        (KJS::isPosInf): Ditto.
        (KJS::isNegInf): Ditto.

        * kjs/operations.cpp: Change isNaN, isInf, isPosInf, and isNegInf to be inlines.
        (KJS::equal): Rewrite to avoid creating values and recursing back into the function.
        (KJS::relation): Rearranged code so that we don't need explicit isNaN checks.
        (KJS::add): Changed code to make Value directly, and so that it passes a "known to be integer"
        boolean in, often avoiding a conversion from floating point to integer and back.
        (KJS::mult): Ditto.

        * kjs/property_map.cpp:
        (KJS::PropertyMap::~PropertyMap): Get size and entries pointer outside loop to avoid
        re-getting them inside the loop.
        (KJS::PropertyMap::clear): Ditto. Clear value pointer in addition to key, so we can just
        look at the value pointer in the mark function.
        (KJS::PropertyMap::get): Get sizeMask and entries pointer outside loop to avoid
        re-getting them inside the loop.
        (KJS::PropertyMap::put): Ditto.
        (KJS::PropertyMap::insert): Ditto.
        (KJS::PropertyMap::remove): Ditto.
        (KJS::PropertyMap::mark): Get size and entries pointer outside loop to avoid
        re-getting them inside the loop. Don't bother checking key for 0, since we already have
        to check value for 0. (Also had to change clear() to set value to 0.)
        (KJS::PropertyMap::addEnumerablesToReferenceList): Get size and entries pointer outside
        loop to avoid re-getting them inside the loop.
        (KJS::PropertyMap::addSparseArrayPropertiesToReferenceList): Ditto.
        (KJS::PropertyMap::save): Ditto.

        - other changes

        * kjs/protected_values.h: Remove unneeded class name qualifiers.

        * kjs/reference.h:
        (KJS::Reference::baseIfMutable): New inline function: replaces isMutable().
        (KJS::Reference::Reference): Inlined.
        * kjs/reference.cpp:
        (KJS::Reference::getValue): Rewrite to not use getBase.
        (KJS::Reference::putValue): Ditto.
        (KJS::Reference::deleteValue): Dittol

        * kjs/simple_number.h:
        (KJS::SimpleNumber::integerFits): Added. For use when the parameter is known to be integral.

        * kjs/string_object.cpp: (StringProtoFuncImp::call): Create the number without first converting
        to double in various cases that involve integers.

        * kjs/ustring.h:
        (KJS::UString::attach): Inlined.
        (KJS::UString::release): Inlined.
        * kjs/ustring.cpp:
        (KJS::UString::find): Get first character outside the loop instead of re-fetching it each time.

        * kjs/value.cpp:
        (Value::Value): Added overloads for all the various specific types of values, so you don't have
        to convert from, say, Number to Value, just to create one.
        (Number::Number): Added an overload that takes a boolean to indicate the number is already
        known to be an integer.

        * kjs/value.h: Added more Value constructors, added a version of toNumber that returns
        a boolean to indicate if the number is known to be an integer (because it was a "simple number").
        (KJS::ValueImp::marked): Inlined.
        (KJS::ValueImp::dispatchType): Inlined.
        (KJS::ValueImp::dispatchToPrimitive): Inlined.
        (KJS::ValueImp::dispatchToBoolean): Inlined.
        (KJS::ValueImp::dispatchToNumber): Inlined.
        (KJS::ValueImp::dispatchToString): Inlined.
        (KJS::ValueImp::dispatchToUInt32): Inlined.

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

17 years ago Reviewed by Hyatt.
darin [Tue, 19 Apr 2005 01:17:53 +0000 (01:17 +0000)]
    Reviewed by Hyatt.

        - fixed <rdar://problem/4092614> REGRESSION (Tiger): progressively loaded background images "scroll around" instead of just appearing

        * WebCoreSupport.subproj/WebImageData.m:
        (-[WebImageData _imageSourceOptions]): Moved a global inside this function, since it's only used here.
        (-[WebImageData _cacheImages:allImages:]): Fixed a sizeof that was getting the size of the wrong thing.
        (-[WebImageData _isSizeAvailable]): Used calloc in a more consistent way.
        (drawPattern): Removed an unneeded cast.
        (-[WebImageData tileInRect:fromPoint:context:]): Here's the actual bug fix. Don't use the image size
        when deciding whether the image needs to be tiled as a pattern nor when creating the pattern: in both
        cases, use the tile size. The old way was wrong, and the new way works perfectly. Also removed uneeded
        error message when the image is not yet loaded enough to create a CGImageRef for it -- it's fine to
        draw nothing in that case.

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

17 years ago Fix min-height so that when it resolves to auto it does not use the box's intrinsic...
hyatt [Mon, 18 Apr 2005 20:57:04 +0000 (20:57 +0000)]
Fix min-height so that when it resolves to auto it does not use the box's intrinsic height.

        * khtml/rendering/render_box.cpp:

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

17 years agoFix layout test.
hyatt [Mon, 18 Apr 2005 20:56:04 +0000 (20:56 +0000)]
Fix layout test.

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

17 years ago Back out fix for 4032346, since it is causing garbled image content on many...
hyatt [Mon, 18 Apr 2005 18:12:42 +0000 (18:12 +0000)]
    Back out fix for 4032346, since it is causing garbled image content on many sites.

The bug tracking the fix is 4069093.


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

17 years ago Fix the smile in the Acid2 test. Floats should not grow to contain other floats...
hyatt [Mon, 18 Apr 2005 11:07:34 +0000 (11:07 +0000)]
Fix the smile in the Acid2 test.  Floats should not grow to contain other floats unless height is auto.  Otherwise
the float should use the specified height.

Also fix row 14 of the Acid2 test.  Although ambiguous, just modify the table cell baseline alignment code to align
to the bottom of the cell's content height if no suitable baseline could be found.

        * khtml/rendering/render_block.cpp:
        * khtml/rendering/render_block.h:
        * khtml/rendering/render_table.cpp:

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

17 years ago Make sure empty tables honor CSS-specified heights when they have no rows or section...
hyatt [Fri, 15 Apr 2005 22:00:16 +0000 (22:00 +0000)]
Make sure empty tables honor CSS-specified heights when they have no rows or sections.  This is done only
in strict mode, since it is not compatible with WinIE.

        * khtml/rendering/render_table.cpp:

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

17 years agoUpdate layout tests for Tiger.
hyatt [Fri, 15 Apr 2005 21:45:54 +0000 (21:45 +0000)]
Update layout tests for Tiger.

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

17 years ago Fix for row 13 of the Acid2 test. Change HTML comment parsing in strict mode to...
hyatt [Fri, 15 Apr 2005 20:36:16 +0000 (20:36 +0000)]
Fix for row 13 of the Acid2 test.  Change HTML comment parsing in strict mode to do proper SGML parsing,
checking for pairs of -- and only being willing to close the comment if every -- is paired up.

        * khtml/html/htmltokenizer.cpp:

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

17 years ago Reviewed by Richard.
mjs [Fri, 15 Apr 2005 16:45:20 +0000 (16:45 +0000)]
    Reviewed by Richard.

- use custom single-threaded malloc for all non-GC JavaScriptCore
allocations, for a 9.1% speedup on JavaScript iBench

* khtml/ecma/kjs_binding.cpp:
        * khtml/ecma/kjs_proxy.cpp:

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

17 years ago Fix the six pixel gap between rows nine and ten of the Acid2 test. Make sure that...
hyatt [Fri, 15 Apr 2005 10:53:59 +0000 (10:53 +0000)]
Fix the six pixel gap between rows nine and ten of the Acid2 test.  Make sure that percentage heights that
resolve to auto are properly treated as though they have auto height by the self-collapsing block check (as per
section 8.3.1, paragraph 7 of the CSS2.1 spec).

        * khtml/rendering/render_block.cpp:

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

17 years agoFix a mistake in render_box.cpp.
hyatt [Fri, 15 Apr 2005 10:51:49 +0000 (10:51 +0000)]
Fix a mistake in render_box.cpp.

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

17 years agoAdd bulletproof null check to previous check-in
hyatt [Fri, 15 Apr 2005 10:05:57 +0000 (10:05 +0000)]
Add bulletproof null check to previous check-in

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

17 years ago The Acid2 test and the reference rendering both make use of overflow:hidden on the...
hyatt [Fri, 15 Apr 2005 09:52:42 +0000 (09:52 +0000)]
The Acid2 test and the reference rendering both make use of overflow:hidden on the <html> element.  Turns out
the CSS2.1 wording for this behavior has been revised (based off WinIE/Mozilla behavior).  Change our behavior
to match and make <html> overflow apply to the viewport.

        * khtml/khtmlview.cpp:
        * khtml/khtmlview.h:
        * khtml/rendering/render_box.cpp:

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

17 years ago - make fast_malloc.h a private header, not project
mjs [Fri, 15 Apr 2005 01:30:37 +0000 (01:30 +0000)]
    - make fast_malloc.h a private header, not project

        * JavaScriptCore.pbproj/project.pbxproj:

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

17 years ago Reviewed by Richard.
mjs [Fri, 15 Apr 2005 01:26:26 +0000 (01:26 +0000)]
    Reviewed by Richard.

<rdar://problem/4089734> JavaScript iBench can be sped up ~10% with custom allocator

- use custom single-threaded malloc for all non-GC JavaScriptCore
allocations, for a 9.1% speedup on JavaScript iBench

        * JavaScriptCore.pbproj/project.pbxproj:
        * kjs/collector.cpp:
        (KJS::Collector::allocate): Use dlmalloc to allocate the collector blocks.
        (KJS::Collector::collect): And dlfree to free it.
        * kjs/fast_malloc.cpp: Added, just the standard dlmalloc here.
        * kjs/fast_malloc.h: Added. Declarations for the functions. Also added a handy
macro to give a class custom operator new/delete
        * kjs/identifier.cpp:
        (KJS::Identifier::add): Use dlmalloc/dlfree.
        * kjs/nodes.h: make nodes KJS_FAST_ALLOCATED.
        * kjs/property_map.cpp:
        (KJS::PropertyMap::~PropertyMap): Use dlmalloc/dlfree.
        (KJS::PropertyMap::rehash): ditto
        * kjs/scope_chain.h:
        * kjs/ustring.cpp:
        (KJS::UString::Rep::createCopying): New named constructor that copies a passed-in
buffer, to hide allocation details from webcore.
        (KJS::UString::UString): use createCopying when appropriate.
        (KJS::UString::Rep::destroy): Use dlmalloc/dlfree.
        (KJS::UString::expandedSize): likewise
        (KJS::UString::expandCapacity): likewise
        (KJS::UString::expandPreCapacity): likewise
        (KJS::UString::spliceSubstringsWithSeparators): likewise
        (KJS::UString::append): likewise
        (KJS::UString::operator=): likewise
        (KJS::UString::detach): likewise
        * kjs/ustring.h: make UString and UString::Rep KJS_FAST_ALLOCATED.

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

17 years ago 3258403 and 3258402 can now be fixed. min/max-width/height support is now complete...
hyatt [Thu, 14 Apr 2005 18:33:54 +0000 (18:33 +0000)]
3258403 and 3258402 can now be fixed.  min/max-width/height support is now complete.  This patch makes them
work for positioned elements and enables us to pass row one of the Acid2 test.

        * khtml/rendering/render_box.cpp:
        * khtml/rendering/render_box.h:

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

17 years ago Reviewed by Chris.
sullivan [Thu, 14 Apr 2005 17:19:50 +0000 (17:19 +0000)]
    Reviewed by Chris.

        * WebView.subproj/WebBaseResourceHandleDelegate.m:
        (-[WebBaseResourceHandleDelegate connection:willCacheResponse:]):
        Beefed up assertion that's been bugging me and Chris to include
        the two troublemaking values.

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

17 years ago Working on the Acid2 test, Row 1.
hyatt [Tue, 12 Apr 2005 22:49:41 +0000 (22:49 +0000)]
Working on the Acid2 test, Row 1.

Improve checkChild for the DTD so that it knows what mode a document is in.  This allows it to adhere more
strictly to the actual DTD in strict mode and almost strict mode.

Change the <table>-inside-<p> check so that <table> is disallowed inside <p> in
strict mode and almost strict mode.  This matches Firefox behavior, which allows <table>
inside <p> only in quirks mode.

        * khtml/html/dtd.cpp:
        * khtml/html/dtd.h:
        * khtml/html/htmlparser.cpp:
        * khtml/html/htmltokenizer.cpp:
        * khtml/xml/dom_elementimpl.cpp:

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

17 years ago Reviewed by Maciej.
vicki [Tue, 12 Apr 2005 22:37:18 +0000 (22:37 +0000)]
    Reviewed by Maciej.

- fixed <rdar://problem/3760895> Request for including an implementation of the elementFromPoint function

        * khtml/dom/dom_doc.cpp:
        * khtml/dom/dom_doc.h:
        * khtml/ecma/kjs_dom.cpp:
        * khtml/ecma/kjs_dom.h:
        * khtml/ecma/kjs_dom.lut.h:
        * khtml/xml/dom_docimpl.cpp:
        * khtml/xml/dom_docimpl.h:

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

17 years ago Reviewed by John.
mjs [Tue, 12 Apr 2005 22:18:35 +0000 (22:18 +0000)]
    Reviewed by John.

<rdar://problem/4086819> Avoid using protect count hash table so much for 5.6% JS iBench speedup

- Avoid using protected values hash for the two most common cases
- Bump up ListImp high water mark, new testing shows 508 ListImps are
created during JS iBench.

Net result is a 5.6% speedup on JavaScript iBench

        * kjs/collector.cpp:
        (KJS::Collector::collect): mark protected lists as appropriate.
        * kjs/context.h:
        * kjs/list.cpp:
        (KJS::ListImp::markValues): Moved implementation from List::markValues
        (KJS::List::markProtectedLists): Implemented - scan pool and overflow
        (KJS::allocateListImp): link lists outside the pool into a separate
doubly linked list to be able to mark protected lists
        (KJS::deallocateListImp): do the corresponding delinking
        (KJS::List::derefValues): do nothing in conservative GC mode
        (KJS::List::refValues): do nothing in conservative GC mode
        (KJS::List::markValues): call ListImp version
        * kjs/list.h:

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

17 years ago Beginning of work to support the Acid2 CSS test put forward by the Web Standards...
hyatt [Tue, 12 Apr 2005 22:11:45 +0000 (22:11 +0000)]
Beginning of work to support the Acid2 CSS test put forward by the Web Standards Project.  Fix
our handling of the rel attribute on <link> elements to do a proper tokenization so that stylesheets
can be recognized even when other keywords are present in the rel attribute.

        * khtml/html/html_headimpl.cpp:
        * khtml/html/html_headimpl.h:

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

17 years agoLeft out an #import in previous checkin.
sullivan [Tue, 12 Apr 2005 15:56:17 +0000 (15:56 +0000)]
Left out an #import in previous checkin.

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

17 years ago - fixed these two bugs (I also fixed these on the experimental-ui-branch)
sullivan [Tue, 12 Apr 2005 15:53:17 +0000 (15:53 +0000)]
    - fixed these two bugs (I also fixed these on the experimental-ui-branch)
        <rdar://problem/3154293> Find Next should not scroll page if the next target is already visible
        <rdar://problem/3121828> scrollToVisible on find cuts off the left part of the view due to needless horiz. scroll

        Reviewed by Chris.

        * kwq/KWQKHTMLPart.mm:
        Trey had written code to address these issues, but left it commented out due to other
        problems. The other problems no longer occur, so I uncommented Trey's code, and then
        discovered that I could make it behave more like TextEdit with many fewer lines of

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

17 years ago Reviewed by Dave Hyatt.
harrison [Sat, 9 Apr 2005 00:05:24 +0000 (00:05 +0000)]
    Reviewed by Dave Hyatt.

        <rdar://problem/4084106> Remove NSAccessibilityForegroundColorTextAttributeWrapper

        * kwq/KWQAccObject.mm:
        Use NSAccessibilityForegroundColorTextAttribute directly.

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

17 years ago Fix for 4077106, make sure that mouse wheeling in overflow sections uses 40 rather...
hyatt [Tue, 5 Apr 2005 23:41:18 +0000 (23:41 +0000)]
Fix for 4077106, make sure that mouse wheeling in overflow sections uses 40 rather than 10 as the base line

        Reviewed by darin

        * khtml/rendering/render_layer.cpp:
        * kwq/KWQScrollBar.mm:

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

17 years ago Fix for 4077106, wheel scroll amount smaller in Tiger. All along wheeling should...
hyatt [Tue, 5 Apr 2005 23:38:25 +0000 (23:38 +0000)]
Fix for 4077106, wheel scroll amount smaller in Tiger.  All along wheeling should have been 4x the default
line height of 10 (just as arrow keys did).  Scroll arrows should have done this too for scroll views (they did
already for overflow sections).  This patch puts the override into the scrollview itself, and removes the
multipliers in the private frame methods.

        Reviewed by darin

        * WebView.subproj/WebFrameView.m:
        (-[WebFrameView _verticalKeyboardScrollDistance]):
        (-[WebFrameView initWithFrame:]):
        (-[WebFrameView _horizontalKeyboardScrollDistance]):

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

17 years ago Reviewed by Maciej.
vicki [Tue, 5 Apr 2005 06:01:45 +0000 (06:01 +0000)]
    Reviewed by Maciej.

- fixed <rdar://problem/3871669> no focus or blur methods on HTML button elements

        * khtml/dom/html_form.cpp:
        * khtml/dom/html_form.h:
        * khtml/ecma/kjs_html.cpp:
        * khtml/ecma/kjs_html.h:
        * khtml/ecma/kjs_html.lut.h:
        * khtml/html/html_formimpl.cpp:
        * khtml/html/html_formimpl.h:

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

17 years agoWebKit-312.1 stamp for <rdar://problem/4070729>
vicki [Fri, 1 Apr 2005 20:42:27 +0000 (20:42 +0000)]
WebKit-312.1 stamp for <rdar://problem/4070729>

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

17 years ago Fixed: <rdar://problem/4070729> REGRESSION (125-311, Panther-only?): Safari crashes...
cblu [Fri, 1 Apr 2005 01:07:16 +0000 (01:07 +0000)]
Fixed: <rdar://problem/4070729> REGRESSION (125-311, Panther-only?): Safari crashes while reloading "My eBay" page

        Reviewed by rjw.

        * WebView.subproj/WebBaseResourceHandleDelegate.m:
        (-[WebBaseResourceHandleDelegate resourceData]): retain and autorelease resourceData since releaseResources (which releases resourceData) may be called before the caller of this method has an opporuntity to retain the returned data

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

17 years agoversioning for SUPanWheat WebCore submission, WebCore-315
vicki [Tue, 29 Mar 2005 19:47:40 +0000 (19:47 +0000)]
versioning for SUPanWheat WebCore submission, WebCore-315

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

17 years agoversioning for WebCore-415
vicki [Mon, 28 Mar 2005 23:21:25 +0000 (23:21 +0000)]
versioning for WebCore-415

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

17 years ago Reviewed by Darin.
harrison [Mon, 28 Mar 2005 21:46:39 +0000 (21:46 +0000)]
    Reviewed by Darin.

        <rdar://problem/4069161> REGRESSION (8A416-8A419): Safari crash bringing up context menu for non-HTML content in a frame

        * kwq/KWQAccObject.mm:
        (-[KWQAccObject rendererForView:]):
        Nil-check node variable instead of rechecking document variable.

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

17 years agoversioning for WebCore-413
vicki [Mon, 28 Mar 2005 02:15:42 +0000 (02:15 +0000)]
versioning for WebCore-413

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

17 years ago Reviewed by me, fix by Kida-san.
darin [Mon, 28 Mar 2005 01:50:25 +0000 (01:50 +0000)]
    Reviewed by me, fix by Kida-san.

        - fixed <rdar://problem/4067474> 8A424: Safari immediately quit by Cmd+Ctrll+'D'

        * kwq/WebCoreBridge.mm: (-[WebCoreBridge convertToNSRange:DOM::]):
        Added nil check.

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

17 years agoversioning for tip of tree, Safari 2.0 (412+)
vicki [Fri, 25 Mar 2005 00:14:21 +0000 (00:14 +0000)]
versioning for tip of tree, Safari 2.0 (412+)

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

17 years agoversioning for SUPanWheat, Safari 1.3 (312)
vicki [Fri, 25 Mar 2005 00:05:23 +0000 (00:05 +0000)]
versioning for SUPanWheat, Safari 1.3 (312)

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

17 years agoSafari-412 stamp
vicki [Thu, 24 Mar 2005 23:59:26 +0000 (23:59 +0000)]
Safari-412 stamp

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

17 years ago Fixed <rdar://problem/4052683> After adding/removing stocks from Stocks Widget,...
rjw [Thu, 24 Mar 2005 22:58:01 +0000 (22:58 +0000)]
Fixed <rdar://problem/4052683> After adding/removing stocks from Stocks Widget, stock areas went blank

The request was being collected before firing it's load handler.
We now gc protect the request while it's loading.

        Reviewed by Maciej.

        * khtml/ecma/xmlhttprequest.cpp:

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

17 years agoversioning for TOT, Safari 2.0 (411+)
vicki [Thu, 24 Mar 2005 03:39:23 +0000 (03:39 +0000)]
versioning for TOT, Safari 2.0 (411+)

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

17 years agoversioning for SUPanWheat, Safari 1.3 (311)
vicki [Thu, 24 Mar 2005 03:31:34 +0000 (03:31 +0000)]
versioning for SUPanWheat, Safari 1.3 (311)

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

17 years agoSafari-411 stamp
vicki [Thu, 24 Mar 2005 03:24:08 +0000 (03:24 +0000)]
Safari-411 stamp

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

17 years ago Use Patti Yeh's hack to determine the appropriate rectangle
rjw [Thu, 24 Mar 2005 03:03:02 +0000 (03:03 +0000)]
Use Patti Yeh's hack to determine the appropriate rectangle
to place the "associated word" window.
If there is no marked text firstRectForCharacterRange: will
use the selected range to determine the returned rectangle,
ignoring the input range.  This is the fix from
4029491 that I previously backed out.

        Reviewed by Vicki.

        * WebView.subproj/WebHTMLView.m:
        (-[WebHTMLView firstRectForCharacterRange:]):

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

17 years ago Further fix for 4053515.
rjw [Thu, 24 Mar 2005 01:47:25 +0000 (01:47 +0000)]
Further fix for 4053515.

Covered cases where text position doesn't lie inside a
text node.

        Reviewed by Richard.

        * khtml/editing/visible_text.cpp:

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

17 years ago Fixed <rdar://problem/4062490> REGRESSION (WebKit-408): no subresources reported...
rjw [Wed, 23 Mar 2005 23:55:41 +0000 (23:55 +0000)]
Fixed <rdar://problem/4062490> REGRESSION (WebKit-408): no subresources reported in Activity window after going back at hrweb.apple.com

Stop collecting subresource responses after the document
had loaded, not after it has been opened.

        Reviewed by Chris.

        * WebView.subproj/WebFrame.m:
        (-[WebFrame _setState:]):
        (-[WebFrame _opened]):

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

17 years agoWebKit:
mjs [Wed, 23 Mar 2005 22:09:34 +0000 (22:09 +0000)]

        Reviewed by Darin.

<rdar://problem/4051145> The QuickTime Cocoa plug-in needs an SPI that it can call to check for URL policy

        * Plugins.subproj/WebPluginContainerCheck.h: Added.
        * Plugins.subproj/WebPluginContainerCheck.m: Added this new helper class to encapsulate
an async plugin navigation check.
        (+[WebPluginContainerCheck checkWithRequest:target:resultObject:selector:controller:]): Convenience allocator that gives autoreleased value.
        (-[WebPluginContainerCheck initWithRequest:target:resultObject:selector:controller:]): Initializer.
        (-[WebPluginContainerCheck finalize]): Just assert that we're done, it would
be bad to deallocate this object while request is still outstanding.
        (-[WebPluginContainerCheck dealloc]): Ditto.
        (-[WebPluginContainerCheck _continueWithPolicy:]): Method to continue after async
policy check.
        (-[WebPluginContainerCheck _isDisallowedFileLoad]): Do "file: URL from remote content"
        (-[WebPluginContainerCheck _actionInformationWithURL:]): Helper to make action
        (-[WebPluginContainerCheck _askPolicyDelegate]): Call policy delegate to let
the app decide if this load is allowed.
        (-[WebPluginContainerCheck start]): Start the check.
        (-[WebPluginContainerCheck cancel]): Cancel a check in progress.
        * Plugins.subproj/WebPluginController.h:
        * Plugins.subproj/WebPluginController.m:
        (-[WebPluginController initWithDocumentView:]): Initialize new _checksInProgress field.
        (-[WebPluginController _webPluginContainerCancelCheckIfAllowedToLoadRequest:]): Implement
this new SPI method.
        (-[WebPluginController _cancelOutstandingChecks]): New helper to make sure to cancel
all outstanding requests when destroying all plugins.
        (-[WebPluginController destroyAllPlugins]): Call above helper.
        (-[WebPluginController _webPluginContainerCheckIfAllowedToLoadRequest:inFrame:resultObject:selector:]): Implement this new plug-in SPI method.
        (-[WebPluginController bridge]): New helper method.
        (-[WebPluginController webView]): New helper method.
        * WebView.subproj/WebPolicyDelegatePrivate.h: Add new navigation
type WebNavigationTypePlugInRequest.
        * WebKit.pbproj/project.pbxproj: Add new files.
        * WebView.subproj/WebDefaultPolicyDelegate.m:
        (-[WebDefaultPolicyDelegate webView:decidePolicyForNavigationAction:request:frame:decisionListener:]): Don't open externally on a plug-in request.


        Reviewed by Darin.

<rdar://problem/4051145> The QuickTime Cocoa plug-in needs an SPI that it can call to check for URL policy

* BrowserWebController.m:
        (-[BrowserWebView decidePolicyForAction:request:frame:newFrameName:decisionListener:]): In
case this is a plugin load request, accept it early to avoid throwing up UI or
causing external loads.

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

17 years agoWebCore:
rjw [Wed, 23 Mar 2005 19:49:41 +0000 (19:49 +0000)]
Fixed <rdar://problem/4053515> REGRESSION (Mail): Kotoeri input method reconversion does not work in WebViews

We now use actual document NSRanges to represent both marked text
ranges and selection ranges.

        Reviewed by Ken.

        * khtml/editing/visible_text.cpp:
        * khtml/editing/visible_text.h:
        * kwq/WebCoreBridge.h:
        * kwq/WebCoreBridge.mm:
        (-[WebCoreBridge convertToNSRange:DOM::]):
        (-[WebCoreBridge DOM::convertToDOMRange:]):
        (-[WebCoreBridge selectNSRange:]):
        (-[WebCoreBridge markedTextDOMRange]):
        (-[WebCoreBridge markedTextNSRange]):

Fixed <rdar://problem/4053515> REGRESSION (Mail): Kotoeri input method reconversion does not work in WebViews

We now use actual document NSRanges to represent both marked text
ranges and selection ranges.

        Reviewed by Ken Kocienda.

        * WebView.subproj/WebHTMLView.m:
        (-[WebHTMLView validAttributesForMarkedText]):
        (-[WebHTMLView firstRectForCharacterRange:]):
        (-[WebHTMLView selectedRange]):
        (-[WebHTMLView markedRange]):
        (-[WebHTMLView _selectMarkedText]):
        (-[WebHTMLView setMarkedText:selectedRange:]):

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

17 years ago Reviewed by Vicki.
kdecker [Wed, 23 Mar 2005 02:42:58 +0000 (02:42 +0000)]
    Reviewed by Vicki.

Fixed <rdar://problem/4062336> REGRESSION (406-407): HTML submenus not working at hrweb.apple.com after going back

Rolled out the fix for <rdar://problem/4041374> REGRESSION (185-186): unload handlers (at least those added with addEventListener) are broken

We clearly need a better solution to 4041374. We can't indiscriminately remove event listeners in closeURL() after-all. Since event listeners are registered in a <script> tag, which is evaluated and executed at page load time, this becomes a problem since we don't reevaluate a page's <script> that is in the back/forward cache.  Thus once you leave the page, the listeners are gone for good.  This is the problem.

        * khtml/khtml_part.cpp:
        * khtml/xml/dom_docimpl.cpp:

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

17 years ago - roll the fix for <rdar://problem/4060266> back in, since its
vicki [Wed, 23 Mar 2005 02:03:04 +0000 (02:03 +0000)]
    - roll the fix for <rdar://problem/4060266> back in, since its
now approved by CCC (and move the Safari-410 release marker)

        * khtml/editing/visible_text.cpp:

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

17 years agoversioning for TOT, Safari 2.0 (410+)
vicki [Wed, 23 Mar 2005 01:50:41 +0000 (01:50 +0000)]
versioning for TOT, Safari 2.0 (410+)

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

17 years agoversioning for SUPanWheat, Safari 1.3 (310)
vicki [Wed, 23 Mar 2005 01:45:20 +0000 (01:45 +0000)]
versioning for SUPanWheat, Safari 1.3 (310)

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

17 years agoSafari-410 stamp
vicki [Wed, 23 Mar 2005 01:39:37 +0000 (01:39 +0000)]
Safari-410 stamp

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

17 years ago - roll out the fix for <rdar://problem/4060266> since it was denied by CCC
vicki [Wed, 23 Mar 2005 01:32:40 +0000 (01:32 +0000)]
- roll out the fix for <rdar://problem/4060266> since it was denied by CCC

        * khtml/editing/visible_text.cpp:

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

17 years ago Reviewed by Darin.
harrison [Tue, 22 Mar 2005 22:12:55 +0000 (22:12 +0000)]
    Reviewed by Darin.

        <rdar://problem/4060266> Double-clicking in Dictionary.app doesn't work for some words (coming just after style change)

        * khtml/editing/visible_text.cpp:
        Complete the check of whether to emit space for collapsed space.

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

17 years ago Reviewed by John.
harrison [Tue, 22 Mar 2005 17:59:24 +0000 (17:59 +0000)]
    Reviewed by John.

        <rdar://problem/4061443> REGRESSION (8A420-8A421): Pasting in the Stickies widget is broken again

        * khtml/editing/htmlediting.cpp:
        Return unchanged Position rather than a null or non-editable one.

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

17 years ago * English.lproj/StringsNotToBeLocalized.txt: Updated for recent changes.
darin [Tue, 22 Mar 2005 13:10:41 +0000 (13:10 +0000)]
    * English.lproj/StringsNotToBeLocalized.txt: Updated for recent changes.

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

17 years agoVersioning for TOT, Safari 2.0 (409+).
vicki [Mon, 21 Mar 2005 03:18:51 +0000 (03:18 +0000)]
Versioning for TOT, Safari 2.0 (409+).
The tree is open!

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