1. 17 Nov, 2006 1 commit
    • thatcher's avatar
      Reviewed by Harrison. · 3d53764a
      thatcher authored
              <rdar://problem/4796730> table deletion elements are serialized out if they are visible when innerHTML or a Web Archive is made
      
              Disable the delete button controller when cloning nodes, Mail does this before saving a draft.
      
              * dom/ContainerNode.cpp:
              (WebCore::ContainerNode::cloneChildNodes):
              * editing/markup.cpp:
              (WebCore::createFragmentFromNodes):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@17833 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      3d53764a
  2. 13 Oct, 2006 1 commit
    • ggaren's avatar
      LayoutTests: · 31614e2f
      ggaren authored
              Tests for accessing renderer-dependent properties from a javascript: URL.
              
              * fast/frames/frame-js-url-clientWidth-expected.txt: Added.
              * fast/frames/frame-js-url-clientWidth.html: Added.
              * fast/frames/iframe-js-url-clientWidth-expected.txt: Added.
              * fast/frames/iframe-js-url-clientWidth.html: Added.
      
      WebCore:
      
              Reviewed by Darin, John.
      
              - Merged more frame and iframe code
              - Fixed a bug where iframes returned incorrect values for renderer-dependent 
              properties during javascript: loads because they didn't have renderers at 
              load time
              
              PLT insists this is a small performance win. Don't believe its lies.
      
              * bindings/js/kjs_html.cpp:
              (KJS::JSHTMLElement::frameGetter): Renamed frameWidth and frameHeight to
              width and height, for consistency with the rest of the DOM.
              * dom/ContainerNode.cpp:
              (WebCore::ContainerNode::queuePostAttachCallback): Added a post-attach callback
              queue that gets drained after the render tree is fully constructed. Currently,
              this is only used for frame loading.
              (WebCore::ContainerNode::attach):
              * dom/ContainerNode.h:
              * html/HTMLFrameElement.cpp:
              (WebCore::HTMLFrameElement::insertedIntoDocument): Removed frame loading from
              attach() because loading iframes during attach() causes a crash. 
              Moved frame loading logic into insertedIntoDocument(). That's a more 
              logical place for it because  document insertion is what 
              triggers frame loading. Made frame loading a post-attach callback, instead
              of an immediate action, to fix the incorrect values bug.
              (WebCore::HTMLFrameElement::attach): Added setWidget call that used to be
              in HTMLIFrameElement::attach. IFRAME requires this call. FRAME will soon 
              require this call, once I remove the call from WebKit.
              (WebCore::HTMLFrameElement::setLocation):
              (WebCore::HTMLFrameElement::width):
              (WebCore::HTMLFrameElement::height):
              * html/HTMLFrameElement.h: Made openURL non-virtual to avoid the unnecessary
              killing of puppies.
              * html/HTMLIFrameElement.cpp: Merged code into HTMLFrameElement
              (WebCore::HTMLIFrameElement::rendererIsNeeded):
              (WebCore::HTMLIFrameElement::createRenderer):
              (WebCore::HTMLIFrameElement::insertedIntoDocument):
              (WebCore::HTMLIFrameElement::removedFromDocument):
              (WebCore::HTMLIFrameElement::attach):
              * page/FrameView.h: Removed unused method.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@17040 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      31614e2f
  3. 03 Aug, 2006 1 commit
    • weinig's avatar
      JavaScriptCore: · f18aae37
      weinig authored
              Reviewed by Darin.
      
              - patch for http://bugzilla.opendarwin.org/show_bug.cgi?id=10176
                Make WebCore compile with -Wundef
      
                * Adds -Wundef flag to Xcode project
                * Converts #ifs to #ifdef and #ifndefs where needed.
                * Added #define YYMAXDEPTH 10000 in kjs/grammar.y
                  to fix a warning from within Bison.
      
              * JavaScriptCore.xcodeproj/project.pbxproj:
              * bindings/jni/jni_jsobject.cpp:
              (JavaJSObject::getSlot):
              (JavaJSObject::setSlot):
              * bindings/npapi.h:
              * bindings/objc/objc_class.mm:
              (KJS::Bindings::ObjcClass::methodsNamed):
              (KJS::Bindings::ObjcClass::fieldNamed):
              * bindings/objc/objc_instance.mm:
              (ObjcInstance::invokeMethod):
              * bindings/objc/objc_runtime.mm:
              (ObjcMethod::getMethodSignature):
              (ObjcField::name):
              (ObjcField::type):
              * kjs/grammar.y:
              * kjs/identifier.h:
      
      JavaScriptGlue:
      
              Reviewed by Darin.
      
              - patch for http://bugzilla.opendarwin.org/show_bug.cgi?id=10176
                Make WebCore compile with -Wundef
      
                * Adds -Wundef flag to Xcode project
      
              * JavaScriptGlue.xcodeproj/project.pbxproj:
      
      WebCore:
      
              Reviewed by Darin.
      
              - patch for http://bugzilla.opendarwin.org/show_bug.cgi?id=10176
                Make WebCore compile with -Wundef
      
                * Adds -Wundef flag to Xcode project
                * Converts #ifs to #ifdef and #ifndefs where needed.
                * Replaces #ifdef WIN32 with #if PLATFORM(WIN_OS) or PLATFORM(WIN)
                  (and in one instance in config.h with #if !COMPILER(MSVC))
                * Added #define YYMAXDEPTH 10000 in XPathGrammar.y and CSSGrammar.y
                  to fix a warning from within Bison.
                * Cleaned up style a little in surrounding code.
      
              * WebCore.xcodeproj/project.pbxproj:
              * bridge/mac/WebCoreAXObject.mm:
              (-[WebCoreAXObject doAXTextMarkerRangeForUnorderedTextMarkers:]):
              * config.h:
              * css/CSSGrammar.y:
              * css/MediaFeatureNames.cpp:
              * css/MediaFeatureNames.h:
              * css/cssparser.cpp:
              * dom/ContainerNode.cpp:
              (WebCore::ContainerNode::setActive):
              * dom/Element.cpp:
              (WebCore::Element::attach):
              * dom/Element.h:
              * dom/EventNames.cpp:
              * dom/EventNames.h:
              * dom/NamedAttrMap.h:
              * dom/Position.cpp:
              * dom/QualifiedName.cpp:
              * dom/QualifiedName.h:
              * dom/Range.h:
              * dom/XMLTokenizer.cpp:
              (WebCore::XMLTokenizer::error):
              * html/HTMLTokenizer.cpp:
              (WebCore::HTMLTokenizer::scriptHandler):
              (WebCore::HTMLTokenizer::scriptExecution):
              (WebCore::HTMLTokenizer::parseTag):
              (WebCore::HTMLTokenizer::continueProcessing):
              (WebCore::HTMLTokenizer::write):
              (WebCore::HTMLTokenizer::timerFired):
              (WebCore::HTMLTokenizer::notifyFinished):
              * kcanvas/device/quartz/KCanvasFilterQuartz.h:
              * kcanvas/device/quartz/KRenderingDeviceQuartz.h:
              * ksvg2/css/SVGRenderStyle.h:
              * ksvg2/css/SVGRenderStyleDefs.h:
              * ksvg2/scripts/make_names.pl:
              * loader/CachedResource.h:
              * loader/LoaderFunctions.h:
              * loader/loader.h:
              * page/Frame.cpp:
              * page/FrameTree.cpp:
              * page/FrameView.cpp:
              (WebCore::FrameView::clear):
              (WebCore::FrameView::layout):
              (WebCore::FrameView::layoutTimerFired):
              (WebCore::FrameView::scheduleRelayout):
              (WebCore::FrameView::unscheduleRelayout):
              * platform/AtomicString.cpp:
              * platform/AtomicString.h:
              * platform/Cursor.h:
              * platform/DeprecatedArray.h:
              * platform/DeprecatedString.cpp:
              (WebCore::allocateHandle):
              (WebCore::initializeHandleNodeBlock):
              (WebCore::freeHandle):
              * platform/FloatPoint.h:
              * platform/FloatRect.h:
              * platform/FloatSize.h:
              * platform/GraphicsContext.h:
              * platform/Image.h:
              * platform/IntPoint.h:
              * platform/IntRect.h:
              (WebCore::IntRect::inflateX):
              (WebCore::IntRect::inflateY):
              * platform/IntSize.h:
              * platform/PlatformKeyboardEvent.h:
              * platform/PlatformMouseEvent.h:
              * platform/PlatformString.h:
              * platform/ResourceLoader.h:
              * platform/ResourceLoaderInternal.h:
              (WebCore::ResourceLoaderInternal::ResourceLoaderInternal):
              * platform/ScrollView.h:
              * platform/StaticConstructors.h:
              * platform/StreamingTextDecoderICU.cpp:
              (WebCore::StreamingTextDecoderICU::convert):
              * platform/StringImpl.h:
              * platform/Widget.h:
              * platform/mac/BlockExceptions.mm:
              * platform/mac/ColorMac.mm:
              (+[WebCoreControlTintObserver WebCore]):
              * platform/mac/FloatPointMac.mm:
              * platform/mac/FloatRectMac.mm:
              * platform/mac/FloatSizeMac.mm:
              * platform/mac/FontMac.mm:
              * platform/mac/GraphicsContextMac.mm:
              (WebCore::GraphicsContext::drawFocusRing):
              * platform/mac/IntPointMac.mm:
              * platform/mac/IntRectMac.mm:
              * platform/mac/IntSizeMac.mm:
              * platform/mac/WebCoreSystemInterface.h:
              * rendering/RenderBlock.h:
              * rendering/RenderTableCell.h:
              * rendering/bidi.cpp:
              (WebCore::appendRun):
              (WebCore::RenderBlock::layoutInlineChildren):
              * xml/XSLTProcessor.cpp:
              (WebCore::parseErrorFunc):
              * xpath/impl/XPathGrammar.y:
      
      WebKit:
      
              Reviewed by Darin.
      
              - patch for http://bugzilla.opendarwin.org/show_bug.cgi?id=10176
                Make WebCore compile with -Wundef
      
                * Adds -Wundef flag to Xcode project
                * Converts #ifs to #ifdef and #ifndefs where needed.
      
              * Carbon/CarbonUtils.m:
              * Carbon/CarbonWindowAdapter.m:
              * Carbon/HIViewAdapter.m:
              (+[NSView bindHIViewToNSView:nsView:]):
              * Carbon/HIWebView.m:
              (HIWebViewEventHandler):
              * Misc/WebFileDatabase.m:
              (UniqueFilePathForKey):
              * Misc/WebNSWindowExtras.m:
              (swizzleInstanceMethod):
              * Misc/WebTypesInternal.h:
              * Plugins/WebNetscapeDeprecatedFunctions.c:
              * Plugins/WebNetscapeDeprecatedFunctions.h:
              * Plugins/WebNetscapePluginPackage.h:
              * Plugins/WebNetscapePluginPackage.m:
              (-[WebNetscapePluginPackage unloadWithoutShutdown]):
              (-[WebNetscapePluginPackage load]):
              * WebKit.xcodeproj/project.pbxproj:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@15781 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      f18aae37
  4. 05 Jul, 2006 1 commit
    • andersca's avatar
      WebCore: · 3a434621
      andersca authored
      2006-07-05  Anders Carlsson  <acarlsson@apple.com>
      
              Reviewed by Maciej.
      
              http://bugzilla.opendarwin.org/show_bug.cgi?id=3581
              iFrames set to display:none are Missing from frames array
      
              * bridge/mac/FrameMac.h:
              * bridge/mac/FrameMac.mm:
              (WebCore::FrameMac::FrameMac):
              (WebCore::FrameMac::createFrame):
              * bridge/mac/WebCoreFrameBridge.h:
              * bridge/mac/WebCoreFrameBridge.mm:
              (-[WebCoreFrameBridge initSubframeWithOwnerElement:]):
              (-[WebCoreFrameBridge installInFrame:]):
              Modify to pass the owner element instead of the owner renderer.        
      
              * dom/ContainerNode.cpp:
              (WebCore::ContainerNode::insertBefore):
              (WebCore::ContainerNode::replaceChild):
              (WebCore::ContainerNode::appendChild):
              Dispatch the node inserted events before attaching the nodes. This is what the
              tokenizer does.
              
              * html/HTMLFrameElement.cpp:
              (WebCore::HTMLFrameElement::openURL):
              (WebCore::HTMLFrameElement::attach):
              Pass the element to requestFrame.
              
              (WebCore::HTMLFrameElement::setLocation):
              Don't call attach/detach on an iframe.
      
              * html/HTMLIFrameElement.cpp:
              (WebCore::HTMLIFrameElement::insertedIntoDocument):
              Load the frame here (using openURL).
              
              (WebCore::HTMLIFrameElement::removedFromDocument):
              Call frameDetached.
              
              (WebCore::HTMLIFrameElement::attach):
              If there's a renderer, attach the content frame to it.
              
              (WebCore::HTMLIFrameElement::detach):
              Reset the renderer's frame.
              
              (WebCore::HTMLIFrameElement::openURL):
              Modify to request the frame.
              
              * html/HTMLIFrameElement.h:
              Add detach.
              
              * page/Frame.cpp:
              (WebCore::parentFromOwnerElement):
              (WebCore::Frame::Frame):
              (WebCore::Frame::~Frame):
              (WebCore::Frame::requestFrame):
              (WebCore::Frame::requestObject):
              (WebCore::Frame::loadSubframe):
              (WebCore::Frame::ownerElement):
              (WebCore::Frame::ownerRenderer):
              (WebCore::Frame::disconnectOwnerElement):
              * page/Frame.h:
              * page/FramePrivate.h:
              (WebCore::FramePrivate::FramePrivate):        
              * rendering/RenderPart.cpp:
              (WebCore::RenderPart::setFrame):
              Modify to keep an owner element around instead of the renderer. 
              
              * rendering/RenderPartObject.cpp:
              (WebCore::RenderPartObject::updateWidget):
              Don't do anything for iframes.
      
      WebKit:
      
      2006-07-05  Anders Carlsson  <acarlsson@apple.com>
      
              Reviewed by Maciej.
      
              http://bugzilla.opendarwin.org/show_bug.cgi?id=3581
              iFrames set to display:none are Missing from frames array
              
              * WebCoreSupport/WebFrameBridge.m:
              (-[WebFrameBridge initSubframeWithOwnerElement:frameName:view:]):
              (-[WebFrameBridge createChildFrameNamed:withURL:referrer:ownerElement:allowsScrolling:marginWidth:marginHeight:]):
              Modify to pass the owner element instead of the owner renderer.
              
              * WebView/WebHTMLView.m:
              (-[WebHTMLView _topHTMLView]):
              Remove assertion, it's not valid anymore.
      
      LayoutTests:
      
      2006-07-05  Anders Carlsson  <acarlsson@apple.com>
      
              Reviewed by Maciej.
      
              http://bugzilla.opendarwin.org/show_bug.cgi?id=3581
              iFrames set to display:none are Missing from frames array
      
              * fast/events/mouseover-mouseout2-expected.txt:
              * fast/events/mouseover-mouseout2.html:
              Update expected result. Since we now keep the frame around, the mouseout event is 
              now dispatched to the element in the frame.
      
              * fast/events/onloadFrameCrash-expected.checksum:
              * fast/events/onloadFrameCrash-expected.png:
              * fast/events/onloadFrameCrash-expected.txt:
              This does hide the frame now.
              
              * fast/frames/iframe-display-none-expected.txt: Added.
              * fast/frames/iframe-display-none.html: Added.
              * fast/frames/resources/iframe-display-none-child.html: Added.
              New test that tests JS interaction with frames.
              
              * fast/frames/iframe-double-attach-expected.txt: Added.
              * fast/frames/iframe-double-attach.html: Added.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@15170 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      3a434621
  5. 19 Jun, 2006 1 commit
  6. 12 May, 2006 1 commit
    • eseidel's avatar
      2006-05-12 Eric Seidel <eseidel@apple.com> · e619f1c8
      eseidel authored
              Reviewed by beth.
      
              Split out render_line.* into separate files (one per class).
      
              * WebCore.xcodeproj/project.pbxproj:
              * dom/ContainerNode.cpp:
              * rendering/EllipsisBox.cpp: Added.
              * rendering/EllipsisBox.h: Added.
              (WebCore::EllipsisBox::EllipsisBox):
              * rendering/InlineBox.cpp: Added.
              * rendering/InlineBox.h: Added.
              (WebCore::InlineBox::InlineBox):
              (WebCore::InlineBox::~InlineBox):
              (WebCore::InlineBox::bottomOverflow):
              (WebCore::InlineBox::rightOverflow):
              * rendering/InlineFlowBox.cpp: Added.
              (WebCore::InlineFlowBox::placeBoxesHorizontally):
              * rendering/InlineFlowBox.h: Added.
              * rendering/InlineRunBox.h: Added.
              (WebCore::InlineRunBox::InlineRunBox):
              (WebCore::InlineRunBox::paintBackgroundAndBorder):
              (WebCore::InlineRunBox::paintDecorations):
              * rendering/InlineTextBox.h:
              * rendering/RenderBlock.h:
              * rendering/RenderFlow.h:
              * rendering/RenderReplaced.cpp:
              * rendering/RootInlineBox.cpp: Added.
              * rendering/RootInlineBox.h: Added.
              (WebCore::RootInlineBox::RootInlineBox):
              * rendering/render_line.h: Removed.
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@14343 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      e619f1c8
  7. 25 Apr, 2006 1 commit
    • eseidel's avatar
      2006-04-25 Eric Seidel <eseidel@apple.com> · 12c2b125
      eseidel authored
              Reviewed by ggaren.
      
              Fixes for our 3rd and 5th most common crashtracers:
              <rdar://problem/4233435> CrashTracer: 2698 crashes in Safari at com.apple.WebCore: khtml::RenderBlock::addChildToFlow + 156
              <rdar://problem/4129744> [REGRESSION]CrashTracer: ..400 crashes at com.apple.WebCore: DOM::NodeImpl::createRendererIfNeeded + 44
      
              Test case landed on trunk but not on branch.
      
              * khtml/xml/dom_docimpl.cpp:
              (DocumentImpl::setFocusNode): use m_inDetach bool copied from trunk
              * khtml/xml/dom_nodeimpl.cpp:
              (NodeImpl::NodeImpl):
              (NodeImpl::detach): set m_inDetach
              (NodeImpl::createRendererIfNeeded):
              (NodeBaseImpl::removeChildren): remove node from tree before calling detach.
              * khtml/xml/dom_nodeimpl.h:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@14054 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      12c2b125
  8. 24 Apr, 2006 1 commit
  9. 19 Apr, 2006 1 commit
    • adele's avatar
      LayoutTests: · 6c464a17
      adele authored
              Tests for change to make readonly text fields have dimmed borders.
      
              * fast/forms/input-appearance-readonly-expected.checksum:
              * fast/forms/input-appearance-readonly-expected.png:
              * fast/forms/input-readonly-dimmed-expected.checksum: Added.
              * fast/forms/input-readonly-dimmed-expected.png: Added.
              * fast/forms/input-readonly-dimmed-expected.txt: Added.
              * fast/forms/input-readonly-dimmed.html: Added.
      
      WebCore:
      
       2006-04-19  Adele Peterson  <adele@apple.com>
       
               Reviewed by Beth.
       
               Fix to make readonly text fields have dimmed borders to match AppKit behavior.
       
               Test: fast/forms/input-readonly-dimmed.html
       
               * dom/Node.h: (WebCore::Node::isReadOnlyControl): Changed from const version of isReadOnly.
               * dom/Node.cpp:
               (WebCore::Node::isReadOnlyNode): Changed from isReadOnly.
               (WebCore::Node::setNodeValue): Uses isReadOnlyNode instead of isReadOnly.
               (WebCore::Node::checkSetPrefix): ditto.
               (WebCore::Node::checkAddChild): ditto.
               * dom/Attr.cpp: (WebCore::Attr::setValue): ditto.
               * dom/CharacterData.cpp:
               (WebCore::CharacterData::setData): ditto.
               (WebCore::CharacterData::appendData): ditto.
               (WebCore::CharacterData::checkCharDataOperation): ditto.
               * dom/ContainerNode.cpp: (WebCore::ContainerNode::removeChild): ditto.
               * dom/Element.cpp: (WebCore::Element::setAttribute): ditto.
               * dom/NamedAttrMap.cpp:
               (WebCore::NamedAttrMap::setNamedItem): ditto.
               (WebCore::NamedAttrMap::removeNamedItem): ditto.
               * dom/NamedAttrMap.h: (WebCore::NamedAttrMap::isReadOnlyNode): ditto.
               * dom/NamedNodeMap.h: (WebCore::NamedNodeMap::isReadOnlyNode): ditto.
               * dom/Range.cpp:
               (WebCore::Range::checkDeleteExtract): ditto.
               (WebCore::Range::containedByReadOnly): ditto.
               * dom/Text.cpp: (WebCore::Text::splitText): ditto.
               * dom/dom_xmlimpl.cpp: (WebCore::ProcessingInstruction::setData): ditto.
       
               * bindings/js/kjs_html.cpp:
               (KJS::JSHTMLElement::inputGetter): Uses isReadOnlyControl instead of isReadOnly.
               (KJS::JSHTMLElement::textAreaGetter): ditto.
               * bindings/objc/DOMHTML.mm: (-[DOMHTMLInputElement readOnly]): ditto.
               * rendering/render_form.cpp:
               (WebCore::RenderLineEdit::updateFromElement): ditto.
               (WebCore::RenderTextArea::updateFromElement): ditto.
               * rendering/RenderTextField.cpp:
               (WebCore::RenderTextField::createDivStyle): ditto.
               (WebCore::RenderTextField::updateFromElement): ditto.
       
               * html/HTMLGenericFormElement.cpp: (WebCore::HTMLGenericFormElement::parseMappedAttribute): 
                 When readonly attribute changes, update the theme so the control will repaint.
               * html/HTMLGenericFormElement.h: (WebCore::HTMLGenericFormElement::isReadOnlyControl): Renamed from readOnly.
               * html/HTMLInputElement.h: Removed isReadOnly, since isReadOnlyControl now exists on HTMLGenericFormElement.
               * rendering/RenderTheme.cpp: (WebCore::RenderTheme::isReadOnlyControl): Renamed from isReadOnly.
               * rendering/RenderTheme.h: (WebCore::): Added ReadOnlyState to ControlState enum.
               * rendering/RenderThemeMac.h: Removed NSTextFieldCell since it was only being used to store the enabled state.
                 Removed setTextFieldState since it was updating the enabled state of the cell, which is only used in one place.
               * rendering/RenderThemeMac.mm:
               (WebCore::RenderThemeMac::RenderThemeMac): No longer initialized the NSTextFieldCell.
               (WebCore::RenderThemeMac::adjustRepaintRect): No longer calls setTextFieldState.
               (WebCore::RenderThemeMac::paintTextField): Uses the enabled state and the readonly state to determine whether to draw
                a dimmed version of the aqua border.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@13973 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      6c464a17
  10. 11 Apr, 2006 1 commit
    • darin's avatar
      JavaScriptCore: · 36d1136a
      darin authored
              Rubber-stamped by John Sullivan.
      
              - switched from a shell script to a makefile for generated files
              - removed lots of unneeded includes
              - added new Forward.h and HashForward.h headers that allow compiling with
                fewer unneeded templates
      
              * DerivedSources.make: Added.
              * generate-derived-sources: Removed.
              * JavaScriptCore.xcodeproj/project.pbxproj: Added new files, changed to use
              DerivedSources.make.
      
              * kxmlcore/Forward.h: Added.
              * kxmlcore/HashForward.h: Added.
      
              * kxmlcore/HashCountedSet.h: Include HashForward for default args.
              * kxmlcore/HashMap.h: Ditto.
              * kxmlcore/HashSet.h: Ditto.
      
              * kjs/object.h:
              * kjs/object.cpp:
              Moved KJS_MAX_STACK into the .cpp file.
      
              * bindings/NP_jsobject.cpp:
              * bindings/c/c_instance.h:
              * bindings/jni/jni_class.h:
              * bindings/jni/jni_runtime.h:
              * bindings/jni/jni_utility.h:
              * bindings/objc/WebScriptObject.mm:
              * bindings/objc/WebScriptObjectPrivate.h:
              * bindings/objc/objc_class.h:
              * bindings/objc/objc_class.mm:
              * bindings/objc/objc_instance.h:
              * bindings/objc/objc_instance.mm:
              * bindings/objc/objc_runtime.mm:
              * bindings/objc/objc_utility.mm:
              * bindings/runtime.h:
              * bindings/runtime_array.cpp:
              * bindings/runtime_array.h:
              * bindings/runtime_method.cpp:
              * bindings/runtime_method.h:
              * bindings/runtime_object.cpp:
              * bindings/runtime_root.h:
              * kjs/JSImmediate.cpp:
              * kjs/Parser.h:
              * kjs/array_object.cpp:
              * kjs/array_object.h:
              * kjs/bool_object.cpp:
              * kjs/bool_object.h:
              * kjs/collector.h:
              * kjs/context.h:
              * kjs/debugger.cpp:
              * kjs/error_object.h:
              * kjs/function_object.h:
              * kjs/internal.h:
              * kjs/lexer.cpp:
              * kjs/math_object.cpp:
              * kjs/math_object.h:
              * kjs/nodes.cpp:
              * kjs/nodes.h:
              * kjs/number_object.cpp:
              * kjs/number_object.h:
              * kjs/object_object.cpp:
              * kjs/operations.cpp:
              * kjs/protected_reference.h:
              * kjs/reference.h:
              * kjs/reference_list.h:
              * kjs/regexp_object.h:
              * kjs/string_object.cpp:
              * kjs/string_object.h:
              * kjs/testkjs.cpp:
              * kjs/value.cpp:
              * kjs/value.h:
              * kxmlcore/HashTable.h:
              * kxmlcore/ListRefPtr.h:
              * kxmlcore/TCPageMap.h:
              * kxmlcore/Vector.h:
              Removed unneeded header includes.
      
      JavaScriptGlue:
      
              Rubber-stamped by John Sullivan.
      
              - added forwarding headers for the new Forward.h and HashForward.h files
      
              * kxmlcore/Forward.h: Added.
              * kxmlcore/HashForward.h: Added.
      
      WebCore:
      
              Rubber-stamped by John Sullivan (except for pbxproj change).
      
              - updated to use the new Forward.h and HashForward.h headers
              - moved the showTree debugging functions out of the WebCore
                namespace so they are easier to call from gdb, and renamed
                the showTree member functions so they don't get in the way;
                now you can do "call showTree(x)" in gdb and it just works
              - removed a lot of unneeded includes
      
              * WebCore.xcodeproj/project.pbxproj: Fixed a lot of paths that
              were not relative to the enclosing group.
      
              * ForwardingHeaders/kxmlcore/Forward.h: Added.
              * ForwardingHeaders/kxmlcore/HashForward.h: Added.
              * bindings/js/JSCanvasRenderingContext2DBase.cpp:
              * bindings/js/JSXMLHttpRequest.cpp:
              * bindings/js/JSXMLHttpRequest.h:
              * bindings/js/JSXSLTProcessor.h:
              * bindings/js/kjs_binding.h:
              * bindings/js/kjs_dom.cpp:
              * bindings/js/kjs_dom.h:
              * bindings/js/kjs_events.cpp:
              * bindings/js/kjs_events.h:
              * bindings/js/kjs_html.cpp:
              * bindings/js/kjs_navigator.cpp:
              * bindings/js/kjs_navigator.h:
              * bindings/js/kjs_proxy.cpp:
              * bindings/js/kjs_traversal.h:
              * bindings/js/kjs_window.cpp:
              * bindings/js/kjs_window.h:
              * bindings/objc/DOM.mm:
              * bindings/objc/DOMCSS.mm:
              * bindings/objc/DOMCore.h:
              * bindings/objc/DOMEvents.mm:
              * bindings/objc/DOMHTML.mm:
              * bindings/objc/DOMImplementationFront.h:
              * bindings/objc/DOMInternal.mm:
              * bindings/objc/DOMUtility.mm:
              * bindings/objc/DOMViews.mm:
              * bridge/BrowserExtension.h:
              * bridge/mac/BrowserExtensionMac.mm:
              * bridge/mac/FrameMac.h:
              * bridge/mac/FrameMac.mm:
              * bridge/mac/WebCoreFrameBridge.mm:
              * bridge/mac/WebCoreFrameNamespaces.mm:
              * bridge/mac/WebCoreJavaScript.mm:
              * bridge/win/PageWin.cpp:
              * css/CSSComputedStyleDeclaration.cpp:
              * css/css_base.h:
              * css/css_ruleimpl.h:
              * css/css_valueimpl.cpp:
              * css/cssparser.cpp:
              * css/cssparser.h:
              * css/cssstyleselector.cpp:
              * css/cssstyleselector.h:
              * dom/AbstractView.h:
              * dom/AtomicStringList.h:
              * dom/Attribute.cpp:
              * dom/Attribute.h:
              * dom/Comment.cpp:
              * dom/ContainerNode.cpp:
              * dom/DOMImplementation.cpp:
              * dom/DOMImplementation.h:
              * dom/Document.cpp:
              * dom/Document.h:
              * dom/Element.h:
              * dom/EventTargetNode.cpp:
              (WebCore::EventTargetNode::dump):
              (WebCore::forbidEventDispatch):
              (WebCore::allowEventDispatch):
              (WebCore::eventDispatchForbidden):
              * dom/EventTargetNode.h:
              (WebCore::EventTargetNode::postDispatchEventHandler):
              * dom/NamedAttrMap.h:
              * dom/Node.cpp:
              (WebCore::Node::showNode):
              (WebCore::Node::showTree):
              (WebCore::Node::showTreeAndMark):
              (showTree):
              * dom/Node.h:
              * dom/NodeList.cpp:
              * dom/NodeList.h:
              * dom/Position.cpp:
              (showTree):
              * dom/Position.h:
              * dom/Range.cpp:
              * dom/Range.h:
              * dom/StyledElement.cpp:
              * dom/StyledElement.h:
              * dom/dom2_eventsimpl.cpp:
              * dom/dom2_eventsimpl.h:
              * dom/dom2_traversalimpl.h:
              * dom/dom_xmlimpl.cpp:
              * dom/xml_tokenizer.cpp:
              * dom/xml_tokenizer.h:
              * editing/AppendNodeCommand.cpp:
              * editing/ApplyStyleCommand.cpp:
              * editing/ApplyStyleCommand.h:
              * editing/BreakBlockquoteCommand.cpp:
              * editing/CompositeEditCommand.cpp:
              * editing/CreateLinkCommand.cpp:
              * editing/DeleteFromTextNodeCommand.cpp:
              * editing/DeleteFromTextNodeCommand.h:
              * editing/DeleteSelectionCommand.cpp:
              * editing/EditCommand.cpp:
              * editing/EditCommand.h:
              * editing/HTMLInterchange.cpp:
              * editing/InsertIntoTextNodeCommand.cpp:
              * editing/InsertIntoTextNodeCommand.h:
              * editing/InsertLineBreakCommand.cpp:
              * editing/InsertNodeBeforeCommand.cpp:
              * editing/InsertParagraphSeparatorCommand.cpp:
              * editing/InsertTextCommand.cpp:
              * editing/JSEditor.cpp:
              * editing/JoinTextNodesCommand.cpp:
              * editing/MergeIdenticalElementsCommand.cpp:
              * editing/ModifySelectionListLevelCommand.cpp:
              * editing/MoveSelectionCommand.cpp:
              * editing/RebalanceWhitespaceCommand.h:
              * editing/RemoveCSSPropertyCommand.h:
              * editing/ReplaceSelectionCommand.cpp:
              * editing/ReplaceSelectionCommand.h:
              * editing/Selection.cpp:
              (WebCore::Selection::formatForDebugger):
              (WebCore::Selection::showTree):
              (showTree):
              * editing/Selection.h:
              * editing/SelectionController.cpp:
              (WebCore::SelectionController::formatForDebugger):
              (WebCore::SelectionController::showTree):
              (showTree):
              * editing/SelectionController.h:
              * editing/TextIterator.cpp:
              * editing/TextIterator.h:
              * editing/TypingCommand.cpp:
              * editing/TypingCommand.h:
              * editing/UnlinkCommand.cpp:
              * editing/VisiblePosition.cpp:
              (WebCore::isEqualIgnoringAffinity):
              (WebCore::VisiblePosition::formatForDebugger):
              (WebCore::VisiblePosition::showTree):
              (showTree):
              * editing/VisiblePosition.h:
              (WebCore::VisiblePosition::VisiblePosition):
              (WebCore::operator==):
              * editing/WrapContentsInDummySpanCommand.cpp:
              * editing/htmlediting.h:
              * editing/markup.cpp:
              * editing/markup.h:
              (WebCore::):
              * editing/visible_units.cpp:
              * html/CanvasGradient.cpp:
              * html/CanvasRenderingContext2D.h:
              * html/CanvasStyle.cpp:
              * html/CanvasStyle.h:
              * html/FormDataList.cpp:
              * html/FormDataList.h:
              * html/HTMLCollection.cpp:
              * html/HTMLCollection.h:
              * html/HTMLDocument.cpp:
              * html/HTMLDocument.h:
              * html/HTMLElement.cpp:
              * html/HTMLElementFactory.cpp:
              * html/HTMLElementFactory.h:
              * html/HTMLFormCollection.cpp:
              * html/HTMLFormElement.cpp:
              * html/HTMLFormElement.h:
              * html/HTMLInputElement.cpp:
              * html/HTMLParser.cpp:
              * html/HTMLSelectElement.cpp:
              * html/HTMLSelectElement.h:
              * html/HTMLTokenizer.cpp:
              * html/HTMLTokenizer.h:
              * html/html_baseimpl.cpp:
              * html/html_headimpl.h:
              * kcanvas/KCanvasCreator.cpp:
              * kcanvas/KCanvasFilters.h:
              * kcanvas/KCanvasPath.h:
              * kcanvas/KCanvasResources.h:
              * kcanvas/KCanvasTreeDebug.cpp:
              * kcanvas/RenderPath.cpp:
              * kcanvas/RenderPath.h:
              * kcanvas/device/KRenderingDevice.h:
              * kcanvas/device/KRenderingPaintServerGradient.h:
              * kcanvas/device/KRenderingPaintServerPattern.h:
              * kcanvas/device/KRenderingPaintServerSolid.h:
              * kcanvas/device/quartz/KCanvasFilterQuartz.mm:
              * kcanvas/device/quartz/KCanvasMaskerQuartz.h:
              * kcanvas/device/quartz/KCanvasResourcesQuartz.h:
              * kcanvas/device/quartz/KCanvasResourcesQuartz.mm:
              * kcanvas/device/quartz/KRenderingPaintServerQuartz.h:
              * khtml/misc/decoder.cpp:
              * khtml/misc/decoder.h:
              * khtml/xsl/XSLStyleSheet.cpp:
              * khtml/xsl/XSLTProcessor.cpp:
              * khtml/xsl/XSLTProcessor.h:
              * ksvg2/css/SVGRenderStyle.h:
              * ksvg2/ecma/GlobalObject.cpp:
              * ksvg2/misc/KCanvasRenderingStyle.h:
              * ksvg2/misc/SVGDocumentExtensions.h:
              * ksvg2/svg/SVGAngle.h:
              * ksvg2/svg/SVGAnimateColorElement.h:
              * ksvg2/svg/SVGAnimatedColor.h:
              * ksvg2/svg/SVGAnimatedLengthList.h:
              * ksvg2/svg/SVGAnimatedNumberList.h:
              * ksvg2/svg/SVGAnimatedString.h:
              * ksvg2/svg/SVGAnimatedTransformList.h:
              * ksvg2/svg/SVGAnimationElement.h:
              * ksvg2/svg/SVGColor.h:
              * ksvg2/svg/SVGCursorElement.h:
              * ksvg2/svg/SVGHelper.h:
              * ksvg2/svg/SVGLength.h:
              * ksvg2/svg/SVGList.h:
              * ksvg2/svg/SVGPaint.h:
              * ksvg2/svg/SVGPathSeg.h:
              * ksvg2/svg/SVGPatternElement.h:
              * ksvg2/svg/SVGSVGElement.cpp:
              * ksvg2/svg/SVGSVGElement.h:
              * ksvg2/svg/SVGStringList.h:
              * ksvg2/svg/SVGTransform.h:
              * kwq/AccessibilityObjectCache.mm:
              * kwq/ClipboardMac.mm:
              * kwq/JavaAppletWidget.mm:
              * kwq/KWQComboBox.mm:
              * kwq/KWQEditCommand.mm:
              * kwq/KWQFileButton.mm:
              * kwq/KWQKHTMLSettings.h:
              * kwq/KWQKSSLKeyGen.mm:
              * kwq/KWQLoader.mm:
              * kwq/KWQPageState.mm:
              * kwq/KWQTextEdit.mm:
              * kwq/RegularExpression.h:
              * kwq/RenderTreeAsText.cpp:
              * kwq/RenderTreeAsText.h:
              * kwq/WebCoreAXObject.mm:
              * loader/Cache.cpp:
              * loader/Cache.h:
              * loader/CachedCSSStyleSheet.cpp:
              * loader/CachedObject.h:
              * loader/CachedScript.cpp:
              * loader/CachedXBLDocument.cpp:
              * loader/CachedXBLDocument.h:
              * loader/CachedXSLStyleSheet.cpp:
              * loader/CachedXSLStyleSheet.h:
              * loader/DocLoader.cpp:
              * page/Frame.cpp:
              * page/Frame.h:
              * page/FramePrivate.h:
              * page/FrameTree.cpp:
              * page/FrameTree.h:
              * page/FrameView.cpp:
              * page/FrameView.h:
              * page/Page.cpp:
              * page/Page.h:
              * page/Plugin.h:
              (WebCore::Plugin::Plugin):
              (WebCore::Plugin::view):
              * platform/Color.cpp:
              * platform/FloatRect.h:
              * platform/Font.cpp:
              * platform/Font.h:
              * platform/FontFamily.cpp:
              * platform/GraphicsContext.cpp:
              * platform/Image.cpp:
              * platform/Image.h:
              * platform/IntRect.h:
              * platform/KURL.cpp:
              * platform/KURL.h:
              * platform/SegmentedString.h:
              * platform/Shared.h:
              * platform/StreamingTextDecoder.cpp:
              * platform/StringImpl.cpp:
              * platform/StringImpl.h:
              * platform/TextEncoding.h:
              * platform/Timer.cpp:
              * platform/Timer.h:
              * platform/TransferJob.cpp:
              * platform/TransferJob.h:
              * platform/TransferJobInternal.h:
              * platform/cairo/GraphicsContextCairo.cpp:
              * platform/cairo/ImageCairo.cpp:
              * platform/cairo/ImageSourceCairo.cpp:
              * platform/image-decoders/gif/GIFImageReader.cpp:
              * platform/image-decoders/jpeg/JPEGImageDecoder.cpp:
              * platform/mac/FontFamilyMac.mm:
              * platform/mac/FontMac.mm:
              * platform/mac/ImageMac.mm:
              * platform/mac/TextEncodingMac.cpp:
              * platform/mac/TransferJobMac.mm:
              * platform/win/FontPlatformDataWin.cpp:
              * platform/win/TransferJobWin.cpp:
              * rendering/RenderBlock.cpp:
              * rendering/RenderBlock.h:
              * rendering/RenderBox.cpp:
              * rendering/RenderBox.h:
              * rendering/RenderCanvas.cpp:
              * rendering/RenderCanvas.h:
              * rendering/RenderContainer.cpp:
              * rendering/RenderFlexibleBox.h:
              * rendering/RenderFlow.cpp:
              * rendering/RenderFlow.h:
              * rendering/RenderImage.cpp:
              * rendering/RenderImage.h:
              * rendering/RenderLayer.cpp:
              * rendering/RenderLayer.h:
              * rendering/RenderObject.cpp:
              (showTree):
              * rendering/RenderObject.h:
              * rendering/RenderTableCell.h:
              * rendering/RenderTableSection.h:
              * rendering/RenderText.cpp:
              * rendering/RenderText.h:
              * rendering/RenderTextField.cpp:
              * rendering/RenderTextFragment.h:
              * rendering/RenderTheme.h:
              * rendering/RenderThemeMac.mm:
              * rendering/RenderThemeWin.cpp:
              * rendering/bidi.cpp:
              * rendering/render_form.h:
              * rendering/render_line.cpp:
              (showTree):
              * rendering/render_line.h:
              * rendering/render_list.cpp:
              * rendering/render_replaced.cpp:
              * rendering/render_replaced.h:
              * rendering/render_style.cpp:
              * rendering/render_style.h:
              * xml/xmlhttprequest.h:
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@13821 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      36d1136a
  11. 28 Mar, 2006 1 commit
    • ggaren's avatar
      Reviewed by Beth. · aa01dc00
      ggaren authored
              - Global replace of getDocument() with document(). Darin suggested this
              in his review of my EventTargetNode patch. It matches the style of
              methods like ownerDocument().
      
              - Changed getDocument() to document(); changed data member document to
              m_document; changed stack variable document to doc.
      
              * bindings/objc/DOM.mm:
              (-[DOMNode ownerDocument]):
              (-[DOMNode KJS::Bindings::]):
              (-[DOMElement _getURLAttribute:]):
              * bindings/objc/DOMHTML.mm:
              (-[DOMHTMLElement titleDisplayString]):
              (-[DOMHTMLInputElement altDisplayString]):
              (-[DOMHTMLAnchorElement blur]):
              (-[DOMHTMLAnchorElement focus]):
              (-[DOMHTMLImageElement altDisplayString]):
              (-[DOMHTMLAppletElement altDisplayString]):
              (-[DOMHTMLAreaElement altDisplayString]):
              * bindings/objc/DOMInternal.mm:
              (-[WebScriptObject _initializeScriptDOMNodeImp]):
              * bridge/mac/FrameMac.mm:
              (WebCore::FrameMac::attributedString):
              * bridge/mac/FrameViewMac.mm:
              (WebCore::FrameView::updateDashboardRegions):
              * bridge/mac/WebCoreFrameBridge.mm:
              (-[WebCoreFrameBridge initSubframeWithRenderer:]):
              (-[WebCoreFrameBridge setSelectedDOMRange:affinity:closeTyping:]):
              (-[WebCoreFrameBridge smartDeleteRangeForProposedRange:]):
              * css/CSSComputedStyleDeclaration.cpp:
              (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
              * css/css_base.cpp:
              (WebCore::StyleBase::baseURL):
              * css/css_stylesheetimpl.cpp:
              (WebCore::CSSStyleSheet::CSSStyleSheet):
              * css/cssstyleselector.cpp:
              (WebCore::CSSStyleSelector::initForStyleResolve):
              (WebCore::CSSStyleSelector::canShareStyleWithElement):
              (WebCore::CSSStyleSelector::locateSharedStyle):
              (WebCore::CSSStyleSelector::createStyleForElement):
              (WebCore::CSSStyleSelector::createPseudoStyleForElement):
              (WebCore::CSSStyleSelector::adjustRenderStyle):
              (WebCore::CSSStyleSelector::styleRulesForElement):
              (WebCore::CSSStyleSelector::checkOneSelector):
              (WebCore::CSSStyleSelector::applyProperty):
              (WebCore::CSSStyleSelector::mapBackgroundImage):
              (WebCore::CSSStyleSelector::getColorFromPrimitiveValue):
              * dom/AbstractView.cpp:
              (WebCore::AbstractView::AbstractView):
              * dom/CDATASection.cpp:
              (WebCore::CDATASection::cloneNode):
              (WebCore::CDATASection::createNew):
              * dom/CharacterData.cpp:
              (WebCore::CharacterData::setData):
              (WebCore::CharacterData::insertData):
              (WebCore::CharacterData::deleteData):
              (WebCore::CharacterData::replaceData):
              (WebCore::CharacterData::dispatchModifiedEvent):
              * dom/Comment.cpp:
              (WebCore::Comment::cloneNode):
              * dom/ContainerNode.cpp:
              (WebCore::ContainerNode::insertBefore):
              (WebCore::ContainerNode::replaceChild):
              (WebCore::ContainerNode::removeChild):
              (WebCore::ContainerNode::appendChild):
              (WebCore::ContainerNode::addChild):
              (WebCore::ContainerNode::getUpperLeftCorner):
              (WebCore::dispatchChildInsertionEvents):
              (WebCore::dispatchChildRemovalEvents):
              * dom/DOMImplementation.cpp:
              (WebCore::DOMImplementation::createDocument):
              * dom/Document.cpp:
              (WebCore::Document::Document):
              (WebCore::Document::~Document):
              (WebCore::Document::createDocumentFragment):
              (WebCore::Document::adoptNode):
              (WebCore::Document::createElementNS):
              (WebCore::Document::nodeAbsIndex):
              (WebCore::Document::setFocusNode):
              (WebCore::Document::topDocument):
              * dom/DocumentFragment.cpp:
              (WebCore::DocumentFragment::cloneNode):
              * dom/EventTargetNode.cpp:
              (WebCore::EventTargetNode::~EventTargetNode):
              (WebCore::EventTargetNode::insertedIntoDocument):
              (WebCore::EventTargetNode::removedFromDocument):
              (WebCore::EventTargetNode::addEventListener):
              (WebCore::EventTargetNode::removeEventListener):
              (WebCore::EventTargetNode::dispatchGenericEvent):
              (WebCore::EventTargetNode::dispatchEvent):
              (WebCore::EventTargetNode::dispatchSubtreeModifiedEvent):
              (WebCore::EventTargetNode::dispatchWindowEvent):
              (WebCore::EventTargetNode::dispatchUIEvent):
              (WebCore::EventTargetNode::dispatchKeyEvent):
              (WebCore::EventTargetNode::dispatchMouseEvent):
              (WebCore::EventTargetNode::dispatchWheelEvent):
              (WebCore::EventTargetNode::removeHTMLEventListener):
              * dom/Node.cpp:
              (WebCore::Node::Node):
              (WebCore::Node::setDocument):
              (WebCore::Node::setChanged):
              (WebCore::Node::checkSetPrefix):
              (WebCore::Node::checkAddChild):
              (WebCore::Node::attach):
              (WebCore::Node::detach):
              (WebCore::Node::createRendererIfNeeded):
              (WebCore::Node::rendererIsNeeded):
              (WebCore::Node::getElementsByTagNameNS):
              (WebCore::Node::ownerDocument):
              (WebCore::Node::setTextContent):
              * dom/Node.h:
              (WebCore::Node::document):
              (WebCore::Node::inDocument):
              * dom/NodeList.cpp:
              (WebCore::NodeList::itemById):
              * dom/Position.cpp:
              (WebCore::Position::documentElement):
              * dom/Range.cpp:
              (WebCore::Range::commonAncestorContainer):
              (WebCore::Range::setStart):
              (WebCore::Range::setEnd):
              (WebCore::Range::compareBoundaryPoints):
              (WebCore::Range::insertNode):
              (WebCore::Range::text):
              (WebCore::Range::setStartAfter):
              (WebCore::Range::setEndBefore):
              (WebCore::Range::setEndAfter):
              (WebCore::Range::surroundContents):
              (WebCore::Range::setStartBefore):
              (WebCore::rangeOfContents):
              * dom/Text.cpp:
              (WebCore::Text::cloneNode):
              (WebCore::Text::createNew):
              * dom/dom2_eventsimpl.cpp:
              (WebCore::MouseRelatedEvent::receivedTarget):
              * dom/dom2_traversalimpl.cpp:
              (WebCore::NodeIterator::NodeIterator):
              * dom/dom_elementimpl.cpp:
              (WebCore::Attribute::createAttrIfNeeded):
              (WebCore::Attr::createTextChild):
              (WebCore::Attr::setValue):
              (WebCore::Attr::cloneNode):
              (WebCore::Element::cloneNode):
              (WebCore::inHTMLDocument):
              (WebCore::Element::setAttribute):
              (WebCore::Element::setAttributeMap):
              (WebCore::Element::createStyleForRenderer):
              (WebCore::Element::createRenderer):
              (WebCore::Element::recalcStyle):
              (WebCore::Element::dispatchAttrRemovalEvent):
              (WebCore::Element::dispatchAttrAdditionEvent):
              (WebCore::Element::updateId):
              (WebCore::Element::removeAttributeNode):
              (WebCore::Element::focus):
              (WebCore::Element::blur):
              (WebCore::NamedAttrMap::setNamedItem):
              (WebCore::NamedMappedAttrMap::parseClassAttribute):
              (WebCore::StyledElement::createInlineStyleDecl):
              (WebCore::StyledElement::parseMappedAttribute):
              (WebCore::StyledElement::createMappedDecl):
              * dom/dom_xmlimpl.cpp:
              (WebCore::EntityReference::cloneNode):
              (WebCore::ProcessingInstruction::cloneNode):
              (WebCore::ProcessingInstruction::checkStyleSheet):
              (WebCore::ProcessingInstruction::sheetLoaded):
              (WebCore::ProcessingInstruction::setStyleSheet):
              * dom/xml_tokenizer.cpp:
              (WebCore::XMLTokenizer::XMLTokenizer):
              * editing/ReplaceSelectionCommand.cpp:
              (WebCore::ReplacementFragment::ReplacementFragment):
              (WebCore::ReplaceSelectionCommand::fixupNodeStyles):
              (WebCore::styleForNode):
              * editing/Selection.cpp:
              (WebCore::Selection::toRange):
              * editing/SelectionController.cpp:
              (WebCore::SelectionController::~SelectionController):
              (WebCore::SelectionController::setSelection):
              (WebCore::SelectionController::xPosForVerticalArrowNavigation):
              (WebCore::SelectionController::frame):
              (WebCore::SelectionController::layout):
              (WebCore::SelectionController::needsCaretRepaint):
              * editing/TextIterator.cpp:
              (WebCore::TextIterator::range):
              (WebCore::SimplifiedBackwardsTextIterator::range):
              * editing/VisiblePosition.cpp:
              (WebCore::VisiblePosition::init):
              (WebCore::makeRange):
              * editing/markup.cpp:
              (WebCore::startMarkup):
              (WebCore::shouldSelfClose):
              (WebCore::markup):
              (WebCore::createMarkup):
              * editing/visible_units.cpp:
              (WebCore::previousBoundary):
              (WebCore::nextBoundary):
              (WebCore::previousLinePosition):
              (WebCore::nextLinePosition):
              (WebCore::inSameDocument):
              * html/HTMLCollection.cpp:
              (WebCore::HTMLCollection::HTMLCollection):
              (WebCore::HTMLCollection::resetCollectionInfo):
              * html/HTMLElement.cpp:
              (WebCore::HTMLElement::nodeName):
              (WebCore::HTMLElement::cloneNode):
              (WebCore::HTMLElement::innerText):
              (WebCore::HTMLElement::createContextualFragment):
              (WebCore::HTMLElement::setInnerText):
              (WebCore::HTMLElement::setOuterText):
              (WebCore::HTMLElement::isContentEditable):
              (WebCore::HTMLElement::contentEditable):
              (WebCore::HTMLElement::toString):
              (WebCore::HTMLElement::childAllowed):
              (WebCore::HTMLElement::setHTMLEventListener):
              * html/HTMLFormElement.cpp:
              (WebCore::HTMLFormElement::formWouldHaveSecureSubmission):
              (WebCore::HTMLFormElement::attach):
              (WebCore::HTMLFormElement::insertedIntoDocument):
              (WebCore::HTMLFormElement::removedFromDocument):
              (WebCore::HTMLFormElement::formData):
              (WebCore::HTMLFormElement::prepareSubmit):
              (WebCore::HTMLFormElement::submit):
              (WebCore::HTMLFormElement::reset):
              (WebCore::HTMLFormElement::parseMappedAttribute):
              (WebCore::HTMLFormElement::registerFormElement):
              (WebCore::HTMLFormElement::removeFormElement):
              * html/HTMLGenericFormElement.cpp:
              (WebCore::HTMLGenericFormElement::attach):
              (WebCore::HTMLGenericFormElement::insertedIntoTree):
              (WebCore::HTMLGenericFormElement::isKeyboardFocusable):
              * html/HTMLInputElement.cpp:
              (WebCore::HTMLInputElement::~HTMLInputElement):
              (WebCore::HTMLInputElement::isKeyboardFocusable):
              (WebCore::HTMLInputElement::focus):
              (WebCore::HTMLInputElement::setInputType):
              (WebCore::HTMLInputElement::parseMappedAttribute):
              (WebCore::HTMLInputElement::attach):
              (WebCore::HTMLInputElement::setChecked):
              (WebCore::HTMLInputElement::preDispatchEventHandler):
              (WebCore::HTMLInputElement::defaultEventHandler):
              (WebCore::HTMLInputElement::src):
              * html/HTMLKeygenElement.cpp:
              (WebCore::HTMLKeygenElement::appendFormData):
              * html/HTMLLabelElement.cpp:
              (WebCore::HTMLLabelElement::formElement):
              * html/HTMLOptionElement.cpp:
              (WebCore::HTMLOptionElement::text):
              (WebCore::HTMLOptionElement::setText):
              * html/HTMLParser.cpp:
              (WebCore::HTMLParser::HTMLParser):
              * html/HTMLSelectElement.cpp:
              (WebCore::HTMLSelectElement::~HTMLSelectElement):
              * html/HTMLTextAreaElement.cpp:
              (WebCore::HTMLTextAreaElement::~HTMLTextAreaElement):
              (WebCore::HTMLTextAreaElement::setDefaultValue):
              * html/HTMLTokenizer.cpp:
              (WebCore::HTMLTokenizer::HTMLTokenizer):
              * html/html_baseimpl.cpp:
              (WebCore::HTMLBodyElement::createLinkDecl):
              (WebCore::HTMLBodyElement::mapToEntry):
              (WebCore::HTMLBodyElement::parseMappedAttribute):
              (WebCore::HTMLBodyElement::insertedIntoDocument):
              (WebCore::HTMLFrameElement::isURLAllowed):
              (WebCore::HTMLFrameElement::openURL):
              (WebCore::HTMLFrameElement::attach):
              (WebCore::HTMLFrameElement::close):
              (WebCore::HTMLFrameElement::contentFrame):
              (WebCore::HTMLFrameElement::frameWidth):
              (WebCore::HTMLFrameElement::frameHeight):
              (WebCore::HTMLFrameSetElement::parseMappedAttribute):
              (WebCore::HTMLIFrameElement::parseMappedAttribute):
              (WebCore::HTMLIFrameElement::insertedIntoDocument):
              (WebCore::HTMLIFrameElement::removedFromDocument):
              (WebCore::HTMLIFrameElement::attach):
              (WebCore::HTMLIFrameElement::src):
              * html/html_blockimpl.cpp:
              (WebCore::HTMLParagraphElement::checkDTD):
              * html/html_headimpl.cpp:
              (WebCore::HTMLBaseElement::removedFromDocument):
              (WebCore::HTMLBaseElement::process):
              (WebCore::HTMLLinkElement::setDisabledState):
              (WebCore::HTMLLinkElement::parseMappedAttribute):
              (WebCore::HTMLLinkElement::process):
              (WebCore::HTMLLinkElement::setStyleSheet):
              (WebCore::HTMLLinkElement::sheetLoaded):
              (WebCore::HTMLLinkElement::href):
              (WebCore::HTMLMetaElement::process):
              (WebCore::HTMLScriptElement::childrenChanged):
              (WebCore::HTMLScriptElement::parseMappedAttribute):
              (WebCore::HTMLScriptElement::insertedIntoDocument):
              (WebCore::HTMLScriptElement::evaluateScript):
              (WebCore::HTMLScriptElement::setText):
              (WebCore::HTMLScriptElement::src):
              (WebCore::HTMLStyleElement::insertedIntoDocument):
              (WebCore::HTMLStyleElement::removedFromDocument):
              (WebCore::HTMLStyleElement::childrenChanged):
              (WebCore::HTMLStyleElement::sheetLoaded):
              (WebCore::HTMLTitleElement::insertedIntoDocument):
              (WebCore::HTMLTitleElement::removedFromDocument):
              (WebCore::HTMLTitleElement::childrenChanged):
              (WebCore::HTMLTitleElement::setText):
              * html/html_imageimpl.cpp:
              (WebCore::HTMLImageLoader::~HTMLImageLoader):
              (WebCore::HTMLImageLoader::updateFromElement):
              (WebCore::HTMLImageLoader::notifyFinished):
              (WebCore::HTMLImageElement::parseMappedAttribute):
              (WebCore::HTMLImageElement::insertedIntoDocument):
              (WebCore::HTMLImageElement::removedFromDocument):
              (WebCore::HTMLImageElement::width):
              (WebCore::HTMLImageElement::height):
              (WebCore::HTMLImageElement::src):
              (WebCore::HTMLMapElement::~HTMLMapElement):
              (WebCore::HTMLMapElement::parseMappedAttribute):
              (WebCore::HTMLAreaElement::href):
              * html/html_inlineimpl.cpp:
              (WebCore::HTMLAnchorElement::isKeyboardFocusable):
              (WebCore::HTMLAnchorElement::defaultEventHandler):
              (WebCore::HTMLAnchorElement::href):
              (WebCore::HTMLAnchorElement::blur):
              (WebCore::HTMLAnchorElement::focus):
              * html/html_objectimpl.cpp:
              (WebCore::HTMLAppletElement::parseMappedAttribute):
              (WebCore::HTMLAppletElement::insertedIntoDocument):
              (WebCore::HTMLAppletElement::removedFromDocument):
              (WebCore::HTMLAppletElement::createRenderer):
              (WebCore::HTMLAppletElement::getAppletInstance):
              (WebCore::HTMLEmbedElement::getEmbedInstance):
              (WebCore::HTMLEmbedElement::parseMappedAttribute):
              (WebCore::HTMLEmbedElement::rendererIsNeeded):
              (WebCore::HTMLEmbedElement::insertedIntoDocument):
              (WebCore::HTMLEmbedElement::removedFromDocument):
              (WebCore::HTMLObjectElement::getObjectInstance):
              (WebCore::HTMLObjectElement::parseMappedAttribute):
              (WebCore::HTMLObjectElement::rendererIsNeeded):
              (WebCore::HTMLObjectElement::insertedIntoDocument):
              (WebCore::HTMLObjectElement::removedFromDocument):
              (WebCore::HTMLObjectElement::updateDocNamedItem):
              (WebCore::HTMLParamElement::parseMappedAttribute):
              * html/html_tableimpl.cpp:
              (WebCore::HTMLTableElement::createTHead):
              (WebCore::HTMLTableElement::createTFoot):
              (WebCore::HTMLTableElement::createCaption):
              (WebCore::HTMLTableElement::insertRow):
              (WebCore::HTMLTableElement::addChild):
              (WebCore::HTMLTableElement::mapToEntry):
              (WebCore::HTMLTableElement::parseMappedAttribute):
              (WebCore::HTMLTableElement::additionalAttributeStyleDecl):
              (WebCore::HTMLTableElement::getSharedCellDecl):
              (WebCore::HTMLTablePartElement::mapToEntry):
              (WebCore::HTMLTablePartElement::parseMappedAttribute):
              (WebCore::HTMLTableSectionElement::insertRow):
              (WebCore::HTMLTableRowElement::insertCell):
              * khtml/ecma/kjs_dom.cpp:
              (KJS::DOMNode::~DOMNode):
              (KJS::DOMNode::mark):
              (KJS::DOMElement::getValueProperty):
              (KJS::DOMElementProtoFunc::callAsFunction):
              (KJS::checkNodeSecurity):
              (KJS::toJS):
              * khtml/ecma/kjs_html.cpp:
              (KJS::JSHTMLElement::implementsCall):
              (KJS::JSHTMLElement::bodyGetter):
              (KJS::JSHTMLElement::anchorGetter):
              (KJS::JSHTMLElement::getValueProperty):
              (KJS::JSHTMLElement::bodySetter):
              * khtml/ecma/kjs_traversal.cpp:
              (KJS::JSNodeFilterCondition::acceptNode):
              * khtml/ecma/kjs_views.cpp:
              (KJS::DOMAbstractViewProtoFunc::callAsFunction):
              * khtml/xbl/xbl_binding.cpp:
              (XBL::XBLBindingChain::failed):
              (XBL::m_nextBinding):
              (XBL::XBLBinding::setXBLDocument):
              * khtml/xbl/xbl_protobinding.cpp:
              (XBL::XBLPrototypeBinding::document):
              * khtml/xsl/XSLStyleSheet.cpp:
              (WebCore::XSLStyleSheet::XSLStyleSheet):
              * khtml/xsl/XSLTProcessor.cpp:
              (WebCore::XSLTProcessor::createDocumentFromSource):
              (WebCore::xmlDocPtrFromNode):
              (WebCore::XSLTProcessor::transformToString):
              * ksvg2/svg/SVGAElement.cpp:
              (SVGAElement::defaultEventHandler):
              * ksvg2/svg/SVGAnimateColorElement.cpp:
              (SVGAnimateColorElement::handleTimerEvent):
              * ksvg2/svg/SVGAnimateElement.cpp:
              (SVGAnimateElement::handleTimerEvent):
              * ksvg2/svg/SVGAnimateTransformElement.cpp:
              (SVGAnimateTransformElement::handleTimerEvent):
              * ksvg2/svg/SVGAnimationElement.cpp:
              (SVGAnimationElement::closeRenderer):
              * ksvg2/svg/SVGClipPathElement.cpp:
              (SVGClipPathElement::canvasResource):
              * ksvg2/svg/SVGElement.cpp:
              (WebCore::SVGElement::addSVGEventListener):
              * ksvg2/svg/SVGGradientElement.cpp:
              (SVGGradientElement::rebuildStops):
              * ksvg2/svg/SVGHelper.cpp:
              (SVGHelper::PercentageOfViewport):
              * ksvg2/svg/SVGLinearGradientElement.cpp:
              (SVGLinearGradientElement::buildGradient):
              * ksvg2/svg/SVGPatternElement.cpp:
              (WebCore::SVGPatternElement::fillAttributesFromReferencePattern):
              * ksvg2/svg/SVGRadialGradientElement.cpp:
              (WebCore::SVGRadialGradientElement::buildGradient):
              * ksvg2/svg/SVGSVGElement.cpp:
              (WebCore::SVGSVGElement::setCurrentScale):
              (WebCore::SVGSVGElement::addSVGWindowEventListner):
              * ksvg2/svg/SVGSetElement.cpp:
              (SVGSetElement::handleTimerEvent):
              * ksvg2/svg/SVGStyleElement.cpp:
              (SVGStyleElement::childrenChanged):
              * ksvg2/svg/SVGStyledElement.cpp:
              (WebCore::SVGStyledElement::canvas):
              * ksvg2/svg/SVGTitleElement.cpp:
              (WebCore::SVGTitleElement::closeRenderer):
              (WebCore::SVGTitleElement::insertedIntoDocument):
              (WebCore::SVGTitleElement::removedFromDocument):
              (WebCore::SVGTitleElement::childrenChanged):
              * ksvg2/svg/SVGUseElement.cpp:
              (SVGUseElement::closeRenderer):
              * kwq/WebCoreAXObject.mm:
              (-[WebCoreAXObject accessibilityPerformAction:]):
              (-[WebCoreAXObject accessibilityAttributeValue:]):
              * page/Frame.cpp:
              (WebCore::parentFromOwnerRenderer):
              (WebCore::Frame::frameForNode):
              (WebCore::Frame::clearDocumentFocus):
              * page/FrameView.cpp:
              (WebCore::FrameView::dispatchMouseEvent):
              * rendering/RenderBox.cpp:
              (WebCore::RenderBox::setStyle):
              * rendering/RenderCanvas.cpp:
              (WebCore::RenderCanvas::RenderCanvas):
              (WebCore::RenderCanvas::paintBoxDecorations):
              (WebCore::RenderCanvas::repaintViewRectangle):
              * rendering/RenderImage.cpp:
              (WebCore::RenderImage::imageMap):
              * rendering/RenderLayer.cpp:
              (WebCore::RenderLayer::setHasHorizontalScrollbar):
              (WebCore::RenderLayer::setHasVerticalScrollbar):
              * rendering/RenderObject.cpp:
              (WebCore::RenderObject::createObject):
              (WebCore::RenderObject::RenderObject):
              (WebCore::RenderObject::isRoot):
              (WebCore::RenderObject::backslashAsCurrencySymbol):
              * rendering/RenderObject.h:
              (WebCore::RenderObject::document):
              * rendering/RenderTheme.cpp:
              (WebCore::RenderTheme::isFocused):
              * rendering/render_applet.cpp:
              (WebCore::RenderApplet::createWidgetIfNecessary):
              * rendering/render_replaced.cpp:
              (WebCore::RenderWidget::RenderWidget):
              (WebCore::RenderWidget::focusIn):
              (WebCore::RenderWidget::focusOut):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@13543 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      aa01dc00
  12. 19 Mar, 2006 1 commit
  13. 17 Mar, 2006 2 commits
    • ggaren's avatar
      LayoutTests: · 42e58c6d
      ggaren authored
              Reviewed by Darin.
      
              * fast/dom/prototype-chain-expected.txt: Updated to reflect new
              prototype chain.
      
      WebCore:
      
              Reviewed by Darin.
      
              - Fixed some crashes in event dispatch and settled the question of 
              when getDocument() can return NULL, removing superfluous NULL checks.
      
              I promise to check in a test case soon, but I need to land this before
              the global rename happens, and I left the test file on my other machine.
      
              Here's what I did:
      
              (1) Removed NULL checks for getDocument() in cases where we know it
              should not return NULL (which turned out to be all but one). Replaced 
              with ASSERT inside getDocument(). Tested to ensure there was no 
              regression @ albertsons.com.
      
              (2) Added the EventTargetNode class, which represents Nodes that
              implement the DOM EventTarget interface. Discussed this design with
              Maciej and Hyatt. The previous dsign -- assuming that all Nodes were 
              EventTargets -- made it possible to crash WebKit by, for example, 
              dispatching a mouse event to a documentType node that was not 
              associated with a document.
      
              (3) Reflected (2) into the JS bindings and touched JSDOMCore.cpp to 
              force a re-build.
      
              (4) Using classInfo checking, strengthened type constraints on 
              JavaScript method dispatch so that you can't finagle JavaScript into, 
              for example, invoking a document-dependent method belonging to a
              node type that's guaranteed to have a document on a node type that may
              not have one. 
      
              (5) Pushed some IE-specific JS bindings that depend on a node having a 
              document down from DOMNode to DOMElement. (An element always has a 
              document.) Tested that Firefox's behavior matched. Confirmed with MSDN.
      
              (6) Updated Objc bindigns to throw an exception if you try to use
              the event interface on a node that doesn't support it. Discussed this
              design with Maciej and TimH.
      
              (7) Consolidated repeated documentElement-finding code in the Position 
              class into the Position::documentElement() method. Did the same for
              repeated top-level document finding and DocumentImpl::topDocument().
              
              * WebCore+SVG/KDOMHeaders.h:
              * WebCore.xcodeproj/project.pbxproj:
              * bindings/js/JSDOMCore.cpp:
              * bindings/objc/DOM.mm:
              (-[DOMNode addEventListener:::]):
              (-[DOMNode removeEventListener:::]):
              (-[DOMNode dispatchEvent:]):
              (-[DOMNode KJS::Bindings::]):
              * bridge/mac/MacFrame.mm:
              (WebCore::MacFrame::keyEvent):
              (WebCore::MacFrame::dispatchCPPEvent):
              * bridge/mac/WebCoreFrameBridge.mm:
              (-[WebCoreFrameBridge setSelectedDOMRange:affinity:closeTyping:]):
              (-[WebCoreFrameBridge smartDeleteRangeForProposedRange:]):
              * css/css_base.cpp:
              (WebCore::StyleBaseImpl::baseURL):
              * css/css_computedstyle.cpp:
              (WebCore::CSSComputedStyleDeclarationImpl::getPropertyCSSValue):
              * css/css_valueimpl.cpp:
              (WebCore::CSSMutableStyleDeclarationImpl::removeProperty):
              (WebCore::CSSMutableStyleDeclarationImpl::setProperty):
              * css/cssstyleselector.cpp:
              (WebCore::CSSStyleSelector::applyProperty):
              * dom/Attr.idl:
              * dom/CharacterData.idl:
              * dom/CharacterDataImpl.cpp:
              (WebCore::CharacterDataImpl::CharacterDataImpl):
              (WebCore::CharacterDataImpl::rendererIsNeeded):
              (WebCore::CharacterDataImpl::dump):
              * dom/CharacterDataImpl.h:
              * dom/ContainerNodeImpl.cpp:
              (WebCore::ContainerNodeImpl::ContainerNodeImpl):
              (WebCore::ContainerNodeImpl::removeChild):
              (WebCore::ContainerNodeImpl::attach):
              (WebCore::ContainerNodeImpl::detach):
              (WebCore::ContainerNodeImpl::insertedIntoDocument):
              (WebCore::ContainerNodeImpl::removedFromDocument):
              (WebCore::ContainerNodeImpl::insertedIntoTree):
              (WebCore::ContainerNodeImpl::removedFromTree):
              (WebCore::ContainerNodeImpl::setFocus):
              (WebCore::ContainerNodeImpl::setActive):
              (WebCore::ContainerNodeImpl::setHovered):
              (WebCore::dispatchChildInsertionEvents):
              (WebCore::dispatchChildRemovalEvents):
              * dom/ContainerNodeImpl.h:
              * dom/DOMImplementationImpl.cpp:
              (WebCore::DOMImplementationImpl::createDocument):
              * dom/DocumentImpl.cpp:
              (WebCore::DocumentImpl::removeAllEventListenersFromAllNodes):
              (WebCore::DocumentImpl::removeAllDisconnectedNodeEventListeners):
              (WebCore::DocumentImpl::getAccObjectCache):
              (WebCore::DocumentImpl::setFocusNode):
              (WebCore::DocumentImpl::topDocument):
              * dom/Element.idl:
              * dom/EventTargetNodeImpl.cpp: Added.
              (WebCore::EventTargetNodeImpl::EventTargetNodeImpl):
              (WebCore::EventTargetNodeImpl::~EventTargetNodeImpl):
              (WebCore::EventTargetNodeImpl::insertedIntoDocument):
              (WebCore::EventTargetNodeImpl::removedFromDocument):
              (WebCore::EventTargetNodeImpl::addEventListener):
              (WebCore::EventTargetNodeImpl::removeEventListener):
              (WebCore::EventTargetNodeImpl::removeAllEventListeners):
              (WebCore::EventTargetNodeImpl::handleLocalEvents):
              (WebCore::EventTargetNodeImpl::dispatchGenericEvent):
              (WebCore::EventTargetNodeImpl::dispatchEvent):
              (WebCore::EventTargetNodeImpl::dispatchSubtreeModifiedEvent):
              (WebCore::EventTargetNodeImpl::dispatchWindowEvent):
              (WebCore::EventTargetNodeImpl::dispatchUIEvent):
              (WebCore::EventTargetNodeImpl::dispatchKeyEvent):
              (WebCore::EventTargetNodeImpl::dispatchMouseEvent):
              (WebCore::EventTargetNodeImpl::dispatchSimulatedMouseEvent):
              (WebCore::EventTargetNodeImpl::dispatchWheelEvent):
              (WebCore::EventTargetNodeImpl::dispatchHTMLEvent):
              (WebCore::EventTargetNodeImpl::removeHTMLEventListener):
              (WebCore::EventTargetNodeImpl::setHTMLEventListener):
              (WebCore::EventTargetNodeImpl::getHTMLEventListener):
              (WebCore::EventTargetNodeImpl::disabled):
              (WebCore::EventTargetNodeImpl::defaultEventHandler):
              (WebCore::EventTargetNodeImpl::dump):
              * dom/EventTargetNodeImpl.h: Added.
              (WebCore::EventTargetNodeImpl::isEventTargetNode):
              (WebCore::EventTargetNodeImpl::preDispatchEventHandler):
              (WebCore::EventTargetNodeImpl::postDispatchEventHandler):
              (WebCore::EventTarget):
              (WebCore::forbidEventDispatch):
              (WebCore::allowEventDispatch):
              (WebCore::eventDispatchForbidden):
              * dom/NodeImpl.cpp:
              (WebCore::NodeImpl::NodeImpl):
              (WebCore::NodeImpl::~NodeImpl):
              (WebCore::NodeImpl::dump):
              (WebCore::NodeImpl::detach):
              (WebCore::NodeImpl::insertedIntoDocument):
              (WebCore::NodeImpl::removedFromDocument):
              * dom/NodeImpl.h:
              (WebCore::NodeImpl::isEventTargetNode):
              (WebCore::NodeImpl::isLink):
              (WebCore::NodeImpl::getDocument):
              (WebCore::NodeImpl::inDocument):
              * dom/dom2_eventsimpl.cpp:
              (WebCore::MouseRelatedEventImpl::receivedTarget):
              * dom/dom2_rangeimpl.cpp:
              (WebCore::RangeImpl::commonAncestorContainer):
              * dom/dom_elementimpl.cpp:
              (WebCore::inHTMLDocument):
              (WebCore::ElementImpl::focus):
              (WebCore::ElementImpl::blur):
              (WebCore::StyledElementImpl::parseMappedAttribute):
              * dom/dom_position.cpp:
              (WebCore::Position::documentElement):
              * dom/dom_position.h:
              * editing/ReplaceSelectionCommand.cpp:
              (WebCore::computeAndStoreNodeDesiredStyle):
              * editing/SelectionController.cpp:
              (WebCore::SelectionController::needsCaretRepaint):
              * editing/visible_units.cpp:
              (WebCore::previousBoundary):
              (WebCore::nextBoundary):
              (WebCore::previousLinePosition):
              (WebCore::nextLinePosition):
              (WebCore::startOfDocument):
              (WebCore::endOfDocument):
              * khtml/ecma/kjs_dom.cpp:
              (KJS::DOMNode::mark):
              (KJS::DOMNode::getValueProperty):
              (KJS::DOMNode::putValueProperty):
              (KJS::DOMNodeProtoFunc::callAsFunction):
              (KJS::DOMEventTargetNode::DOMEventTargetNode):
              (KJS::DOMEventTargetNode::getOwnPropertySlot):
              (KJS::DOMEventTargetNode::getValueProperty):
              (KJS::DOMEventTargetNode::put):
              (KJS::DOMEventTargetNode::putValueProperty):
              (KJS::DOMEventTargetNode::setListener):
              (KJS::DOMEventTargetNode::getListener):
              (KJS::DOMEventTargetNode::pushEventHandlerScope):
              (KJS::DOMEventTargetNodeProtoFunc::callAsFunction):
              (KJS::):
              (KJS::DOMDocument::DOMDocument):
              (KJS::DOMDocument::getOwnPropertySlot):
              (KJS::DOMDocument::put):
              (KJS::DOMDocument::putValueProperty):
              (KJS::DOMDocumentProtoFunc::callAsFunction):
              (KJS::DOMElement::DOMElement):
              (KJS::DOMElement::getValueProperty):
              (KJS::DOMElement::put):
              (KJS::DOMElement::putValueProperty):
              (KJS::DOMElement::getOwnPropertySlot):
              (KJS::DOMElementProtoFunc::callAsFunction):
              (KJS::checkNodeSecurity):
              * khtml/ecma/kjs_dom.h:
              (KJS::DOMNode::):
              (KJS::DOMEventTargetNode::):
              (KJS::DOMElement::):
              * khtml/ecma/kjs_events.cpp:
              (KJS::JSLazyEventListener::parseCode):
              (KJS::getNodeEventListener):
              * khtml/ecma/kjs_html.cpp:
              (KJS::HTMLElement::bodyGetter):
              (KJS::HTMLElement::anchorGetter):
              (KJS::HTMLElement::getValueProperty):
              (KJS::HTMLElement::bodySetter):
              * khtml/ecma/kjs_views.cpp:
              (KJS::DOMAbstractViewProtoFunc::callAsFunction):
              * khtml/html/HTMLFormElementImpl.cpp:
              (WebCore::HTMLFormElementImpl::registerFormElement):
              (WebCore::HTMLFormElementImpl::removeFormElement):
              * khtml/html/HTMLGenericFormElementImpl.cpp:
              (WebCore::HTMLGenericFormElementImpl::insertedIntoTree):
              * khtml/html/HTMLInputElementImpl.cpp:
              (WebCore::HTMLInputElementImpl::~HTMLInputElementImpl):
              (WebCore::HTMLInputElementImpl::focus):
              * khtml/html/HTMLOptionElementImpl.cpp:
              (WebCore::HTMLOptionElementImpl::text):
              * khtml/html/HTMLSelectElementImpl.cpp:
              (WebCore::HTMLSelectElementImpl::~HTMLSelectElementImpl):
              * khtml/html/HTMLTextAreaElementImpl.cpp:
              (WebCore::HTMLTextAreaElementImpl::~HTMLTextAreaElementImpl):
              * khtml/html/html_baseimpl.cpp:
              (WebCore::HTMLBodyElementImpl::insertedIntoDocument):
              (WebCore::HTMLFrameElementImpl::isURLAllowed):
              (WebCore::HTMLFrameElementImpl::openURL):
              (WebCore::HTMLFrameElementImpl::frameWidth):
              (WebCore::HTMLFrameElementImpl::frameHeight):
              * khtml/html/html_imageimpl.cpp:
              (WebCore::HTMLImageLoader::~HTMLImageLoader):
              (WebCore::HTMLImageLoader::updateFromElement):
              (WebCore::HTMLImageLoader::notifyFinished):
              (WebCore::HTMLImageElementImpl::width):
              (WebCore::HTMLImageElementImpl::height):
              (WebCore::HTMLMapElementImpl::~HTMLMapElementImpl):
              * khtml/html/html_inlineimpl.cpp:
              (WebCore::HTMLAnchorElementImpl::defaultEventHandler):
              * khtml/html/htmltokenizer.cpp:
              (WebCore::HTMLTokenizer::notifyFinished):
              * ksvg2/svg/SVGAnimateColorElementImpl.cpp:
              (SVGAnimateColorElementImpl::handleTimerEvent):
              * ksvg2/svg/SVGAnimateElementImpl.cpp:
              (SVGAnimateElementImpl::handleTimerEvent):
              * ksvg2/svg/SVGAnimateTransformElementImpl.cpp:
              (SVGAnimateTransformElementImpl::handleTimerEvent):
              * ksvg2/svg/SVGAnimationElementImpl.cpp:
              (SVGAnimationElementImpl::closeRenderer):
              * ksvg2/svg/SVGDOMImplementationImpl.cpp:
              * ksvg2/svg/SVGDocumentImpl.cpp:
              (WebCore::SVGDocumentImpl::dispatchRecursiveEvent):
              * ksvg2/svg/SVGDocumentImpl.h:
              * ksvg2/svg/SVGImageElementImpl.cpp:
              * ksvg2/svg/SVGSetElementImpl.cpp:
              (SVGSetElementImpl::handleTimerEvent):
              * kwq/KWQAccObject.mm:
              (-[KWQAccObject mouseButtonListener]):
              (-[KWQAccObject accessibilityPerformAction:]):
              * kwq/KWQTextArea.mm:
              (-[KWQTextAreaTextView dispatchHTMLEvent:]):
              * page/Frame.cpp:
              (WebCore::dispatchKHTMLEditableContentChanged):
              * page/FrameView.cpp:
              (WebCore::FrameView::dispatchDragEvent):
              (WebCore::FrameView::dispatchMouseEvent):
              (WebCore::FrameView::viewportWheelEvent):
              * rendering/render_layer.cpp:
              (WebCore::RenderLayer::scrollToOffset):
              * rendering/render_object.cpp:
              (WebCore::RenderObject::shouldSelect):
              (WebCore::RenderObject::backslashAsCurrencySymbol):
              * rendering/render_replaced.cpp:
              (WebCore::RenderWidget::sendConsumedMouseUp):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@13369 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      42e58c6d
    • hyatt's avatar
      Give table rows and sections accurate dimensions. Fix absolutePosition · d866e595
      hyatt authored
              to work for table cells properly.  Add an absolutePositionForContent method
              to make sure callers that want to deal with the content of a cell handle
              the cell's extra space correctly.
      
              Reviewed by darin
      
              Existing layout tests cover this change.
      
              * bridge/mac/WebCoreFrameBridge.mm:
              (-[WebCoreFrameBridge copyRenderNode:copier:]):
              * dom/ContainerNodeImpl.cpp:
              (WebCore::ContainerNodeImpl::getUpperLeftCorner):
              (WebCore::ContainerNodeImpl::getLowerRightCorner):
              * dom/NodeImpl.cpp:
              (WebCore::NodeImpl::getRect):
              * editing/SelectionController.cpp:
              (WebCore::SelectionController::layout):
              (WebCore::SelectionController::caretRect):
              * editing/visible_units.cpp:
              (WebCore::previousLinePosition):
              (WebCore::nextLinePosition):
              * khtml/html/HTMLInputElementImpl.cpp:
              (WebCore::HTMLInputElementImpl::defaultEventHandler):
              * kwq/KWQRenderTreeDebug.cpp:
              (operator<<):
              * rendering/RenderBlock.cpp:
              (WebCore::RenderBlock::selectionGapRects):
              (WebCore::RenderBlock::positionForCoordinates):
              * rendering/RenderContainer.cpp:
              (WebCore::RenderContainer::positionForCoordinates):
              (WebCore::RenderContainer::lineBoxRects):
              * rendering/RenderTableCell.cpp:
              (WebCore::RenderTableCell::computeAbsoluteRepaintRect):
              (WebCore::RenderTableCell::absolutePosition):
              * rendering/RenderTableRow.cpp:
              (WebCore::RenderTableRow::addChild):
              (WebCore::RenderTableRow::getAbsoluteRepaintRect):
              (WebCore::RenderTableRow::nodeAtPoint):
              * rendering/RenderTableRow.h:
              * rendering/RenderTableSection.cpp:
              (WebCore::RenderTableSection::ensureRows):
              (WebCore::RenderTableSection::addCell):
              (WebCore::RenderTableSection::layoutRows):
              (WebCore::RenderTableSection::recalcCells):
              (WebCore::RenderTableSection::nodeAtPoint):
              * rendering/RenderTableSection.h:
              * rendering/RenderText.cpp:
              (WebCore::RenderText::lineBoxRects):
              (WebCore::RenderText::positionForCoordinates):
              (WebCore::RenderText::caretRect):
              (WebCore::RenderText::posOfChar):
              (WebCore::RenderText::selectionRect):
              * rendering/render_box.cpp:
              (WebCore::RenderBox::absolutePosition):
              (WebCore::RenderBox::caretRect):
              * rendering/render_br.cpp:
              (WebCore::RenderBR::caretRect):
              * rendering/render_canvas.h:
              * rendering/render_flow.cpp:
              (WebCore::RenderFlow::caretRect):
              * rendering/render_frames.cpp:
              (WebCore::RenderPart::updateWidgetPosition):
              * rendering/render_layer.cpp:
              (WebCore::RenderLayer::updateLayerPosition):
              * rendering/render_object.cpp:
              (WebCore::RenderObject::absoluteRects):
              (WebCore::RenderObject::absoluteBoundingBoxRect):
              (WebCore::RenderObject::absolutePosition):
              * rendering/render_object.h:
              (WebCore::RenderObject::absolutePositionForContent):
              (WebCore::RenderObject::offsetHeight):
              * rendering/render_replaced.cpp:
              (WebCore::RenderWidget::updateWidgetPosition):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@13346 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      d866e595
  14. 06 Mar, 2006 1 commit
    • darin's avatar
      Reviewed by Maciej. · 8d1badc7
      darin authored
              - moved all the remnants of the public C++ DOM API out of khtml/dom
              - changed from "int" to "ExceptionCode" for DOM exceptions
              - removed unused CSS_HTML_RELATIVE
              - changed offsetInCharacters to be a member function of NodeImpl
              - changed DOM functions that take a NodeType to use NodeType instead of
                unsigned short for clarity (will still be unsigned short in bindings)
              - changed exception constants so they can be used directly in the
                implementation code (added in the offsets for different types of exceptions)
              - replaced the eventListenerType function with an isHTMLEventListener function
              - got rid of EventListenerEvent, which is a synonym for EventImpl*
              - eliminated handleEventImpl, whish is now the same as handleEvent
      
              - did other preparation for the "remove Impl suffix" renaming
                (tested by using a script that does the renaming)
      
              * khtml/dom/css_rule.h: Removed.
              * khtml/dom/css_stylesheet.h: Removed.
              * khtml/dom/css_value.h: Removed.
              * khtml/dom/dom2_events.cpp: Removed.
              * khtml/dom/dom2_events.h: Removed.
              * khtml/dom/dom2_range.h: Removed.
              * khtml/dom/dom2_traversal.cpp: Removed.
              * khtml/dom/dom2_traversal.h: Removed.
              * khtml/dom/dom_exception.h: Removed.
              * khtml/dom/dom_node.h: Removed.
      
              * dom/EventListener.h: Added.
              * dom/ExceptionCode.h: Added.
      
              * WebCore+SVG/kdom.h: Removed NodeType and ExceptionCodes
              * WebCore+SVG/kdomevents.h: Removed.
      
              * WebCore.xcodeproj/project.pbxproj: Updated for file changes.
              * WebCore.xcodeproj/project.pbxproj: Updated for file changes.
      
              * bindings/scripts/CodeGeneratorJS.pm: Removed unneeded DOM:: prefix. Updated file
              names and exception prefix for changes in DOM exceptions.
      
              * bindings/js/JSDOMCore.cpp: Touched to cause auto-generated code to be
              recompiled. We need to get this fixed!
              * bindings/js/JSDOMEvents.cpp: Ditto.
      
              * dom/Attr.idl:
              * dom/CharacterData.idl:
              * dom/DOMImplementation.idl:
              * dom/DocumentType.idl:
              * dom/Element.idl:
              * dom/Entity.idl:
              * dom/MutationEvent.idl:
              * dom/Notation.idl:
              * dom/ProcessingInstruction.idl:
              * dom/Text.idl:
              * dom/WheelEvent.idl:
              Touched all IDL files so that changes in CodeGeneratorJS.pm would take effect.
              Added license headers.
      
              * bindings/objc/DOM.mm: Fixed garbled license agreement. Updated includes.
              Changed from a single "using namespace WebCore" to individual using statements
              because of the imminent conflict between DOMImplementation in Objective C
              and WebCore::DOMImplementation (currently has an Impl suffix). Added a typedef
              for WebCore::DOMImplementationImpl. Changed to use ExceptionCode instead of int.
      
              * bindings/objc/DOMCSS.h: Removed DOMCSSException and the special CSS exception
              codes. This is a feature of DOM Level 1 only. In DOM Level 2 these were eliminated
              and use basic DOM exception codes instead. We might have to do something for binary
              compatibility eventually, but perhaps not.
      
              * bindings/objc/DOMCSS.mm:
              * bindings/objc/DOMEvents.mm:
              * bindings/objc/DOMEventsInternal.h:
              * bindings/objc/DOMHTML.mm:
              * bindings/objc/DOMHTMLInternal.h:
              * bindings/objc/DOMViews.mm:
              * bindings/objc/DOMViewsInternal.h:
              Fixed garbled license agreements.
              Changed to use ExceptionCode instead of int and name the variable "ec".
      
              * bindings/objc/DOMInternal.h: Changed addDOMWrapperImpl to take NSObject* instead
              of id. This helps with overload resolution when addDOMWrapperImpl is renamed to be
              addDOMWrapper. Changed ALLOW_DOM_CAST to always use "class" in from of the type name
              of the WebCore class. This helps work around what seems like a bug in namespace support
              in Objective-C mode, although the bug only happens after the "remove Impl" renaming.
              * bindings/objc/DOMInternal.mm:
              (getDOMWrapperImpl): Changed to use HashMap.
              (addDOMWrapperImpl): Ditto.
              (removeDOMWrapper): Ditto.
              (raiseDOMException): Update to use new names for exception number ranges.
      
              * bridge/mac/WebCoreFrameBridge.mm:
              * khtml/ecma/xmlserializer.cpp:
              * kwq/KWQAccObject.mm:
              Removed unneeded includes.
      
              * css/css_ruleimpl.h: Moved "rule type" into this header.
      
              * dom/CommentImpl.h:
              * dom/CommentImpl.cpp: (WebCore::CommentImpl::offsetInCharacters): Added. Returns true.
      
              * khtml/ecma/XSLTProcessor.cpp: (KJS::XSLTProcessorProtoFunc::callAsFunction):
              Changed this around so we don't have a local variable named docImpl.
      
              * khtml/ecma/kjs_binding.cpp: (KJS::setDOMException): Updated for new form of exception
              constants.
      
              * khtml/ecma/kjs_events.h:
              * khtml/ecma/kjs_events.cpp:
              (KJS::JSAbstractEventListener::handleEvent): Changed to no longer use EventListenerEvent.
              (KJS::JSAbstractEventListener::isHTMLEventListener): Added.
      
              * rendering/RenderTextField.h: Updated includes. Tweaked the code formatting of
              InputMutationListener. (Might be unnecessary since this class might be deleted soon.)
      
              * bridge/mac/MacFrame.mm:
              * css/css_computedstyle.cpp:
              * css/css_computedstyle.h:
              * css/css_ruleimpl.cpp:
              * css/css_stylesheetimpl.cpp:
              * css/css_stylesheetimpl.h:
              * css/css_valueimpl.cpp:
              * css/css_valueimpl.cpp:
              * css/css_valueimpl.h:
              * css/css_valueimpl.h:
              * css/cssparser.cpp:
              * css/cssstyleselector.cpp:
              * dom/CDATASectionImpl.cpp:
              * dom/CDATASectionImpl.h:
              * dom/CharacterDataImpl.cpp:
              * dom/CharacterDataImpl.h:
              * dom/ContainerNodeImpl.cpp:
              * dom/DOMImplementationImpl.cpp:
              * dom/DocumentFragmentImpl.cpp:
              * dom/DocumentFragmentImpl.h:
              * dom/DocumentImpl.cpp:
              * dom/DocumentImpl.h:
              * dom/DocumentTypeImpl.cpp:
              * dom/DocumentTypeImpl.h:
              * dom/NamedNodeMapImpl.h:
              * dom/NodeImpl.cpp:
              * dom/NodeImpl.h:
              * dom/NodeListImpl.cpp:
              * dom/TextImpl.cpp:
              * dom/TextImpl.h:
              * dom/dom2_eventsimpl.cpp:
              * dom/dom2_eventsimpl.h:
              * dom/dom2_rangeimpl.cpp:
              * dom/dom2_rangeimpl.h:
              * dom/dom2_traversalimpl.cpp:
              * dom/dom2_traversalimpl.h:
              * dom/dom_elementimpl.cpp:
              * dom/dom_elementimpl.h:
              * dom/dom_position.cpp:
              * dom/dom_xmlimpl.cpp:
              * dom/dom_xmlimpl.h:
              * dom/xml_tokenizer.cpp:
              * editing/AppendNodeCommand.cpp:
              * editing/ApplyStyleCommand.cpp:
              * editing/CompositeEditCommand.cpp:
              * editing/DeleteFromTextNodeCommand.cpp:
              * editing/InsertIntoTextNodeCommand.cpp:
              * editing/InsertLineBreakCommand.cpp:
              * editing/InsertNodeBeforeCommand.cpp:
              * editing/InsertParagraphSeparatorCommand.cpp:
              * editing/JoinTextNodesCommand.cpp:
              * editing/MergeIdenticalElementsCommand.cpp:
              * editing/RemoveNodeAttributeCommand.cpp:
              * editing/RemoveNodeCommand.cpp:
              * editing/ReplaceSelectionCommand.cpp:
              * editing/Selection.cpp:
              * editing/SelectionController.cpp:
              * editing/SelectionController.h:
              * editing/SetNodeAttributeCommand.cpp:
              * editing/SplitElementCommand.cpp:
              * editing/SplitTextNodeCommand.cpp:
              * editing/VisiblePosition.cpp:
              * editing/WrapContentsInDummySpanCommand.cpp:
              * editing/htmlediting.cpp:
              * editing/markup.cpp:
              * editing/visible_text.cpp:
              * khtml/ecma/kjs_binding.h:
              * khtml/ecma/kjs_css.cpp:
              * khtml/ecma/kjs_dom.cpp:
              * khtml/ecma/kjs_html.cpp:
              * khtml/ecma/kjs_range.cpp:
              * khtml/ecma/kjs_traversal.cpp:
              * khtml/ecma/kjs_traversal.h:
              * khtml/ecma/kjs_window.cpp:
              * khtml/html/HTMLElementImpl.cpp:
              * khtml/html/HTMLOptionElementImpl.cpp:
              * khtml/html/HTMLOptionElementImpl.h:
              * khtml/html/HTMLOptionsCollectionImpl.cpp:
              * khtml/html/HTMLSelectElementImpl.cpp:
              * khtml/html/HTMLTextAreaElementImpl.cpp:
              * khtml/html/html_documentimpl.cpp:
              * khtml/html/html_documentimpl.h:
              * khtml/html/html_headimpl.cpp:
              * khtml/html/html_tableimpl.cpp:
              * khtml/html/html_tableimpl.h:
              * khtml/html/htmlparser.cpp:
              * khtml/xbl/xbl_tokenizer.cpp:
              * khtml/xsl/xsl_stylesheetimpl.cpp:
              * ksvg2/misc/SVGDocumentExtensions.cpp:
              * ksvg2/svg/SVGAnimationElementImpl.cpp:
              * ksvg2/svg/SVGDOMImplementationImpl.cpp:
              * ksvg2/svg/SVGDOMImplementationImpl.h:
              * ksvg2/svg/SVGDocumentImpl.cpp:
              * ksvg2/svg/SVGDocumentImpl.h:
              * ksvg2/svg/SVGElementImpl.cpp:
              * ksvg2/svg/SVGLengthImpl.cpp:
              * ksvg2/svg/SVGLocatableImpl.cpp:
              * ksvg2/svg/SVGPolyElementImpl.cpp:
              * ksvg2/svg/SVGSVGElementImpl.cpp:
              * ksvg2/svg/SVGStyleElementImpl.cpp:
              * ksvg2/svg/SVGStyleElementImpl.h:
              * ksvg2/svg/SVGUseElementImpl.cpp:
              * page/Frame.cpp:
              * page/FrameView.cpp:
              * rendering/render_object.cpp:
              * xml/xmlhttprequest.cpp:
              Changed to use ExceptionCode instead of int and name the variable "ec".
              Also updated use of exception codes and other constants to get them from
              their new locations.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@13167 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      8d1badc7
  15. 09 Feb, 2006 2 commits
    • darin's avatar
      Reviewed by Eric and Geoff. · 7191dd12
      darin authored
              - changed basic DOM mutation calls to assert that "this"
                is not floating, then added more uses of RefPtr to prevent the
                assertion from firing (at least during my testing and layout tests)
      
              - removed use of PassRefPtr as the type of a local variable; after talking
                with Maciej and Eric, this type of use is now "deprecated"
      
              * bindings/js/JSDOMCore.cpp: Touched this file to get things to build.
      
              * bindings/objc/DOM.mm:
              (-[DOMRange extractContents]):
              (-[DOMRange cloneContents]):
              (-[DOMRange cloneRange]):
              * khtml/ecma/kjs_range.cpp:
              (KJS::DOMRange::getValueProperty):
              (KJS::DOMRangeProtoFunc::callAsFunction):
              * khtml/editing/Selection.cpp:
              (WebCore::Selection::toRange):
              * bridge/mac/WebCoreFrameBridge.mm:
              (-[WebCoreFrameBridge documentFragmentWithMarkupString:baseURLString:]):
              * dom/ContainerNodeImpl.cpp:
              (WebCore::ContainerNodeImpl::insertBefore):
              (WebCore::ContainerNodeImpl::replaceChild):
              (WebCore::ContainerNodeImpl::removeChild):
              (WebCore::ContainerNodeImpl::appendChild):
              * dom/DocPtr.h: Removed uses of NULL and unused deprecated functions.
              * dom/dom2_rangeimpl.h:
              * dom/dom2_rangeimpl.cpp:
              (WebCore::RangeImpl::RangeImpl):
              (WebCore::RangeImpl::startContainer):
              (WebCore::RangeImpl::endContainer):
              (WebCore::RangeImpl::commonAncestorContainer):
              (WebCore::RangeImpl::setStart):
              (WebCore::RangeImpl::setEnd):
              (WebCore::RangeImpl::collapse):
              (WebCore::RangeImpl::compareBoundaryPoints):
              (WebCore::RangeImpl::boundaryPointsValid):
              (WebCore::RangeImpl::processContents):
              (WebCore::RangeImpl::extractContents):
              (WebCore::RangeImpl::cloneContents):
              (WebCore::RangeImpl::insertNode):
              (WebCore::RangeImpl::createContextualFragment):
              (WebCore::RangeImpl::detach):
              (WebCore::RangeImpl::cloneRange):
              (WebCore::RangeImpl::selectNodeContents):
              (WebCore::RangeImpl::surroundContents):
              (WebCore::RangeImpl::containedByReadOnly):
              (WebCore::RangeImpl::startPosition):
              (WebCore::RangeImpl::endPosition):
              (WebCore::RangeImpl::startNode):
              (WebCore::RangeImpl::editingStartPosition):
              (WebCore::rangeOfContents):
              * dom/dom_elementimpl.h:
              * dom/dom_elementimpl.cpp:
              (WebCore::AttrImpl::AttrImpl):
              (WebCore::AttrImpl::~AttrImpl):
              (WebCore::AttrImpl::setValue):
              (WebCore::AttrImpl::childTypeAllowed):
              (WebCore::AttrImpl::childrenChanged):
              (WebCore::ElementImpl::removeAttributeNode):
              (WebCore::NamedAttrMapImpl::clearAttributes):
              (WebCore::CSSMappedAttributeDeclarationImpl::~CSSMappedAttributeDeclarationImpl):
              (WebCore::MappedAttributeImpl::clone):
              * dom/DocumentFragmentImpl.cpp:
              (DOM::DocumentFragmentImpl::cloneNode):
              * dom/dom_xmlimpl.cpp:
              (WebCore::EntityReferenceImpl::cloneNode):
              (WebCore::ProcessingInstructionImpl::ProcessingInstructionImpl):
              (WebCore::ProcessingInstructionImpl::checkStyleSheet):
              (WebCore::ProcessingInstructionImpl::setStyleSheet):
              * dom/dom_position.cpp:
              * khtml/editing/break_blockquote_command.cpp:
              (WebCore::BreakBlockquoteCommand::doApply):
              * khtml/editing/composite_edit_command.cpp:
              (WebCore::CompositeEditCommand::appendBlockPlaceholder):
              (WebCore::CompositeEditCommand::insertBlockPlaceholder):
              (WebCore::CompositeEditCommand::moveParagraphContentsToNewBlockIfNecessary):
              (WebCore::createBlockPlaceholderElement):
              * khtml/editing/delete_selection_command.cpp:
              (WebCore::DeleteSelectionCommand::insertPlaceholderForAncestorBlockContent):
              (WebCore::DeleteSelectionCommand::moveNodesAfterNode):
              * khtml/editing/html_interchange.cpp:
              * khtml/editing/htmlediting.cpp:
              (WebCore::rebalanceWhitespaceInTextNode):
              (WebCore::nonBreakingSpaceString):
              (WebCore::createDefaultParagraphElement):
              (WebCore::createBreakElement):
              (WebCore::createTabSpanElement):
              * khtml/editing/insert_line_break_command.cpp:
              (khtml::InsertLineBreakCommand::doApply):
              * khtml/editing/insert_paragraph_separator_command.cpp:
              (WebCore::InsertParagraphSeparatorCommand::doApply):
              * khtml/editing/insert_paragraph_separator_command.h:
              * khtml/editing/insert_text_command.cpp:
              (khtml::InsertTextCommand::insertTab):
              * khtml/editing/markup.cpp:
              (khtml::createFragmentFromMarkup):
              (khtml::createParagraphContentsFromString):
              (khtml::createFragmentFromText):
              (khtml::createFragmentFromNodeList):
              * khtml/editing/rebalance_whitespace_command.cpp:
              * khtml/editing/replace_selection_command.cpp:
              (WebCore::ReplacementFragment::ReplacementFragment):
              (WebCore::ReplacementFragment::insertFragmentForTestRendering):
              (WebCore::ReplaceSelectionCommand::doApply):
              * khtml/editing/visible_text.cpp:
              (khtml::CharacterIterator::range):
              (khtml::findPlainText):
              * khtml/html/HTMLElementImpl.cpp:
              (WebCore::HTMLElementImpl::cloneNode):
              * khtml/html/htmlparser.cpp:
              (HTMLParser::handleResidualStyleCloseTagAcrossBlocks):
              * ksvg2/svg/SVGTransformableImpl.cpp:
              (SVGTransformableImpl::parseTransformAttribute):
              * ksvg2/svg/SVGUseElementImpl.cpp:
              (SVGUseElementImpl::closeRenderer):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@12725 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      7191dd12
    • mjs's avatar
      Rubber-stamped by Hyatt. · b1742373
      mjs authored
              
              - moved khtml/xml to dom
      
              * dom: moved from khtml/xml
              * WebCore.xcodeproj/project.pbxproj: Updated for new file locations.
              * WebCore+SVG/KDOMHeaders.h: Updated for new header locations.
              * dom/dom2_rangeimpl.cpp: ditto
              * dom/dom2_traversalimpl.cpp: ditto
              * dom/dom_textimpl.cpp: ditto
              * dom/dom_xmlimpl.cpp: ditto
              * khtml/dom/dom2_events.cpp: ditto
              * khtml/ecma/kjs_binding.cpp: ditto
              * khtml/ecma/kjs_dom.cpp: ditto
              * khtml/ecma/kjs_events.cpp: ditto
              * khtml/ecma/kjs_html.cpp: ditto
              * khtml/ecma/kjs_range.cpp: ditto
              * khtml/ecma/kjs_views.cpp: ditto
              * khtml/editing/Selection.cpp: ditto
              * khtml/editing/SelectionController.cpp: ditto
              * khtml/editing/delete_from_text_node_command.cpp: ditto
              * khtml/editing/edit_command.cpp: ditto
              * khtml/editing/insert_into_text_node_command.cpp: ditto
              * khtml/editing/insert_line_break_command.cpp: ditto
              * khtml/editing/insert_paragraph_separator_command.cpp: ditto
              * khtml/editing/insert_text_command.cpp: ditto
              * khtml/editing/join_text_nodes_command.cpp: ditto
              * khtml/editing/markup.cpp: ditto
              * khtml/editing/merge_identical_elements_command.cpp: ditto
              * khtml/editing/rebalance_whitespace_command.cpp: ditto
              * khtml/editing/remove_node_attribute_command.cpp: ditto
              * khtml/editing/set_node_attribute_command.cpp: ditto
              * khtml/editing/split_element_command.cpp: ditto
              * khtml/editing/split_text_node_command.cpp: ditto
              * khtml/editing/split_text_node_containing_element.cpp: ditto
              * khtml/editing/visible_position.cpp: ditto
              * khtml/editing/visible_position.h: ditto
              * khtml/editing/visible_text.cpp: ditto
              * khtml/editing/visible_text.h: ditto
              * khtml/editing/visible_units.cpp: ditto
              * khtml/editing/wrap_contents_in_dummy_span_command.cpp: ditto
              * khtml/html/HTMLElementImpl.h: ditto
              * khtml/html/html_documentimpl.cpp: ditto
              * khtml/html/html_headimpl.cpp: ditto
              * khtml/xbl/xbl_binding_manager.cpp: ditto
              * khtml/xbl/xbl_tokenizer.cpp: ditto
              * khtml/xbl/xbl_tokenizer.h: ditto
              * ksvg2/svg/SVGAElementImpl.cpp: ditto
              * rendering/InlineTextBox.cpp: ditto
              * rendering/RenderContainer.cpp: ditto
              * rendering/RenderText.h: ditto
              * rendering/RenderTextField.cpp: ditto
              * rendering/render_frames.cpp: ditto
              * rendering/render_layer.cpp: ditto
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@12715 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      b1742373
  16. 04 Feb, 2006 1 commit
    • mjs's avatar
      Reviewed by Darin. · f1622377
      mjs authored
              - Just return bool from DOM child mutation methods instead of the node
              http://bugzilla.opendarwin.org/show_bug.cgi?id=7076
      
              * bindings/objc/DOM.mm:
              (-[DOMNode insertBefore::]):
              (-[DOMNode replaceChild::]):
              (-[DOMNode removeChild:]):
              (-[DOMNode appendChild:]):
              * khtml/ecma/kjs_dom.cpp:
              (KJS::DOMNodeProtoFunc::callAsFunction):
              * khtml/html/HTMLOptGroupElementImpl.cpp:
              (WebCore::HTMLOptGroupElementImpl::insertBefore):
              (WebCore::HTMLOptGroupElementImpl::replaceChild):
              (WebCore::HTMLOptGroupElementImpl::removeChild):
              (WebCore::HTMLOptGroupElementImpl::appendChild):
              * khtml/html/HTMLOptGroupElementImpl.h:
              * khtml/html/HTMLSelectElementImpl.cpp:
              (WebCore::HTMLSelectElementImpl::insertBefore):
              (WebCore::HTMLSelectElementImpl::replaceChild):
              (WebCore::HTMLSelectElementImpl::removeChild):
              (WebCore::HTMLSelectElementImpl::appendChild):
              * khtml/html/HTMLSelectElementImpl.h:
              * khtml/html/HTMLTextAreaElementImpl.cpp:
              (WebCore::HTMLTextAreaElementImpl::setDefaultValue):
              * khtml/html/html_tableimpl.cpp:
              (WebCore::HTMLTableElementImpl::createTFoot):
              * khtml/xml/ContainerNodeImpl.cpp:
              (WebCore::ContainerNodeImpl::insertBefore):
              (WebCore::ContainerNodeImpl::replaceChild):
              (WebCore::ContainerNodeImpl::removeChild):
              (WebCore::ContainerNodeImpl::appendChild):
              * khtml/xml/ContainerNodeImpl.h:
              * khtml/xml/NodeImpl.cpp:
              (WebCore::NodeImpl::insertBefore):
              (WebCore::NodeImpl::replaceChild):
              (WebCore::NodeImpl::removeChild):
              (WebCore::NodeImpl::appendChild):
              * khtml/xml/NodeImpl.h:
              * khtml/xml/xml_tokenizer.cpp:
              (WebCore::XMLTokenizer::insertErrorMessageBlock):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@12568 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      f1622377
  17. 31 Jan, 2006 1 commit
    • vicki's avatar
      Reviewed by Geoff. · 0cde5129
      vicki authored
              - fix <rdar://problem/4426668> REGRESSION: sometimes URLs with named anchors in a
              page don't jump to proper location in document (6916). Added test cases for this
              fix and past link jumping bug fixes.
      
              * khtml/xml/ContainerNodeImpl.cpp:
              (WebCore::ContainerNodeImpl::getUpperLeftCorner): Traverse up the parent node chain
              until you find one that has a sibling.
              * manual-tests/linkjump-1.html: Added a note here - the bug for this test case is
              still broken in TOT.
              * manual-tests/linkjump-2.html: Added. Renamed scrollToAnchor.html, to group it with the
              rest of the link jumping tests.
              * manual-tests/linkjump-3.html: Added. Test case for this bug, <rdar://problem/4426668>.
              * manual-tests/linkjump-4.html: Added. Test case for past fix, <rdar://problem/4247537>.
              * manual-tests/linkjump-5.html: Added. Test case for past fix, <rdar://problem/4256060>.
              * manual-tests/scrollToAnchor.html: Removed.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@12504 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      0cde5129
  18. 25 Jan, 2006 1 commit
    • harrison's avatar
      Reviewed by Justin. · dec5e09b
      harrison authored
              <rdar://problem/3907635> copy/paste of list item text moves list item up one <LI>
              <rdar://problem/3907647> Enhance list editing: return inserts <li></li>
              <rdar://problem/4060158> deleting selection within table deletes more than intended
              <rdar://problem/4061232> Deleting a list can delete unselected content
              <rdar://problem/4062212> after pasting in contents of web.apple.com, typing before start adds to table instead of before table
              <rdar://problem/4064437> After copy/paste from bugweb cannot go back to entering text at left side of page
              <rdar://problem/4259845> Table editing in design mode is broken
              <rdar://problem/4287667> Insertion point goes before table instead of inside first cell
              <rdar://problem/4345749> Editing HTML - Enter at end of <LI> inserts uneditable blank <LI>
              <rdar://problem/4345794> HTML editing: Enter at end of last <LI> does not add new <LI>
              <rdar://problem/4345825> HTML Editing: editing first <LI> element removes first <LI> and more
              <rdar://problem/4345835> HTML editing: editing last <LI> removes everything within <BODY>
              <rdar://problem/4345879> HTML editing: editing first <TD> moves data out of table
      
              ...also added showTree() static functions because switch to gcc 4.0 makes calling instance methods unreliable
      
              - numerous small changes to handle empty list items
              - fix numeric list marker updating when adding/deleting list items
              - start to decompose "special element" handling, replacing it with appropriate handling of the different
                kinds of special elements in various situations, rather than giving a blanket treatment.  I will do more
                of this in subsequent checkins.
              - numerous small editing/selection changes to handle VisiblePosition at table offset childNodeCount()
              - simplify and fix equivalentRangeCompliantPosition, rename it to rangeCompliantEquivalent and make it static
              - some minor reformatting to current standards
              - the comments in the list below are for changes not covered by the above comments
              
              * khtml/editing/Selection.cpp:
              (WebCore::Selection::toRange):
              (WebCore::Selection::validate):
              * khtml/editing/SelectionController.cpp:
              (WebCore::SelectionController::modifyExtendingLeftBackward):
              - character selection backward from after table selects the table
              (WebCore::showTree):
              * khtml/editing/composite_edit_command.cpp:
              (WebCore::CompositeEditCommand::removeFullySelectedNode):
              - make sure empty cell has some height
              (WebCore::CompositeEditCommand::positionOutsideTabSpan):
              - check for !isTabSpanTextNode() to make calling this function easier
              (WebCore::CompositeEditCommand::addBlockPlaceholderIfNeeded):
              * khtml/editing/delete_selection_command.cpp:
              (WebCore::positionBeforePossibleContainingSpecialElement):
              (WebCore::positionAfterPossibleContainingSpecialElement):
              (WebCore::DeleteSelectionCommand::initializeStartEnd):
              - new.  more consistent handling of special element boundaries.
              (WebCore::DeleteSelectionCommand::initializePositionData):
              (WebCore::DeleteSelectionCommand::handleGeneralDelete):
              - handle childless block (e.g. empty table cell)
              - allow merging across list items
              (WebCore::DeleteSelectionCommand::moveNodesAfterNode):
              - use new isEmpty() method for renderers, to handle empty list items
              * khtml/editing/delete_selection_command.h:
              * khtml/editing/htmlediting.cpp:
              (WebCore::isAtomicNode):
              (WebCore::editingIgnoresContent):
              - new.  smarter check than isReplaced()
              (WebCore::rangeCompliantEquivalent):
              (WebCore::maxDeepOffset):
              (WebCore::isFirstVisiblePositionInSpecialElement):
              (WebCore::positionBeforeContainingSpecialElement):
              (WebCore::isLastVisiblePositionInSpecialElement):
              (WebCore::positionAfterContainingSpecialElement):
              (WebCore::positionOutsideContainingSpecialElement):
              (WebCore::positionBeforeNode):
              (WebCore::positionAfterNode):
              (WebCore::isListElement):
              (WebCore::isTableElement):
              (WebCore::isFirstVisiblePositionAfterTableElement):
              (WebCore::positionBeforePrecedingTableElement):
              (WebCore::positionAvoidingSpecialElementBoundary):
              * khtml/editing/htmlediting.h:
              * khtml/editing/insert_line_break_command.cpp:
              (khtml::InsertLineBreakCommand::doApply):
              * khtml/editing/insert_paragraph_separator_command.cpp:
              (khtml::InsertParagraphSeparatorCommand::doApply):
              * khtml/editing/insert_text_command.cpp:
              (khtml::InsertTextCommand::prepareForTextInsertion):
              (khtml::InsertTextCommand::input):
              * khtml/editing/replace_selection_command.cpp:
              (WebCore::isMailPasteAsQuotationNode):
              (WebCore::ReplacementFragment::countRenderedBlocks):
              (WebCore::ReplaceSelectionCommand::doApply):
              - allow for fact that fragments have no VisiblePositions
              * khtml/editing/visible_position.cpp:
              (khtml::VisiblePosition::isCandidate):
              (khtml::showTree):
              (khtml::makeRange):
              (khtml::setStart):
              (khtml::setEnd):
              * khtml/editing/visible_position.h:
              * khtml/editing/visible_units.cpp:
              (khtml::previousBoundary):
              (khtml::nextBoundary):
              (khtml::startOfLine):
              - allow for fact that renderers for list markers and other generated content
                have no corresponding NodeImpl.
              (khtml::endOfLine):
              - ditto
              (khtml::nextLinePosition):
              (khtml::startOfParagraph):
              (khtml::endOfParagraph):
              * khtml/xml/ContainerNodeImpl.cpp:
              (WebCore::ContainerNodeImpl::getUpperLeftCorner):
              (WebCore::ContainerNodeImpl::childNode):
              * khtml/xml/ContainerNodeImpl.h:
              * khtml/xml/NodeImpl.cpp:
              (WebCore::NodeImpl::childNode):
              (WebCore::NodeImpl::traversePreviousNode):
              (WebCore::NodeImpl::nextEditable):
              (WebCore::showTree):
              * khtml/xml/NodeImpl.h:
              * khtml/xml/dom_position.cpp:
              (DOM::Position::upstream):
              (DOM::Position::downstream):
              (DOM::Position::inRenderedContent):
              (DOM::showTree):
              * khtml/xml/dom_position.h:
              * rendering/render_canvas.cpp:
              (RenderCanvas::selectionRect):
              * rendering/render_list.cpp:
              (RenderListItem::calcListValue):
              (RenderListItem::isEmpty):
              (getParentOfFirstLineBox):
              (RenderListItem::resetMarkerValue):
              (RenderListItem::updateMarkerLocation):
              * rendering/render_list.h:
              (khtml::RenderListMarker::isListMarker):
              * rendering/render_object.cpp:
              (WebCore::RenderObject::nextRenderer):
              (WebCore::RenderObject::previousRenderer):
              (WebCore::showTree):
              * rendering/render_object.h:
              (WebCore::RenderObject::getBaselineOfLastLineBox):
              (WebCore::RenderObject::isEmpty):
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@12358 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      dec5e09b
  19. 24 Jan, 2006 3 commits
    • darin's avatar
      Reviewed by Eric. · f69b9576
      darin authored
              - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6782
                REGRESSION: replaceChild broken when node to replace is first (TinyMCE test app broken)
      
              - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6784
                REGRESSION: 25 layout tests failing (basic DOM operations)
      
              * khtml/xml/ContainerNodeImpl.cpp:
              (WebCore::ContainerNodeImpl::insertBefore): Change one place that hands off ownership of
              as PassRefPtr that causes us to almost always return 0. Fix test that would screw up when
              both "prev" and "refChild->previousSibling()" were 0.
              (WebCore::ContainerNodeImpl::appendChild): Changed a nearly-identical place handing off
              ownership as above.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@12343 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      f69b9576
    • darin's avatar
      Reviewed by John Sullivan. · 71e27498
      darin authored
              - http://bugzilla.opendarwin.org/show_bug.cgi?id=6750
                replace QDateTime with a simpler platform abstraction
      
              * ForwardingHeaders/qdatetime.h: Removed.
              * kwq/KWQDateTime.cpp: Removed.
              * kwq/KWQDateTime.h: Removed.
      
              * platform/SystemTime.h: Added.
              * platform/mac/SystemTime.cpp: (WebCore::currentTime): Added.
              * platform/win: Added.
              * platform/win/SystemTime.cpp: (WebCore::currentTime): Added.
      
              * WebCore.vcproj/WebCore/WebCore.vcproj: Added new files, removed old.
              * WebCore.xcodeproj/project.pbxproj: Ditto.
      
              * css/css_base.h: Removed include of <qdatetime.h>.
              * css/cssstyleselector.cpp: Ditto.
      
              * khtml/html/htmltokenizer.h:
              * khtml/html/htmltokenizer.cpp: Convert tabs to spaces.
              (WebCore::HTMLTokenizer::continueProcessing): Change parameter from QTime to double.
              Use currentTime() instead of QTime::elapsed().
              (WebCore::HTMLTokenizer::write): Use currentTime() instead of QTime::elapsed().
      
              * config.h: Added HAVE_FUNC_USLEEP for now, not sure this is really a
              good way to handle this.
              * khtml/xml/ContainerNodeImpl.cpp: (WebCore::ContainerNodeImpl::setActive):
              Use currentTime() instead of QTime::elapsed(). Use HAVE_FUNC_USLEEP for the if.
      
              * khtml/xml/DocumentImpl.h:
              * khtml/xml/DocumentImpl.cpp:
              (WebCore::DocumentImpl::DocumentImpl): Use currentTime() instead of QTime::elapsed().
              (WebCore::DocumentImpl::implicitClose): Ditto.
              (WebCore::DocumentImpl::minimumLayoutDelay): Ditto.
              (WebCore::DocumentImpl::elapsedTime): Ditto.
      
              * khtml/xml/dom2_eventsimpl.cpp: (WebCore::EventImpl::EventImpl): Use currentTime()
              instead of local function called currentTimeStamp().
      
              * khtml/xml/xml_tokenizer.h: Removed declaration of class QTime.
      
              * ksvg2/misc/KSVGTimeScheduler.h:
              * ksvg2/misc/KSVGTimeScheduler.cpp:
              (KSVG::TimeScheduler::TimeScheduler): Use currentTime instead of QTime::elapsed.
              (KSVG::TimeScheduler::startAnimations): Ditto.
              (KSVG::TimeScheduler::toggleAnimations): Ditto.
              (KSVG::TimeScheduler::elapsed): Ditto.
      
              * page/Frame.cpp: (Frame::clear): Removed unused m_parsetime.
              * page/FramePrivate.h: Ditto.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@12341 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      71e27498
    • darin's avatar
      Reviewed by Justin. · dd3670b0
      darin authored
              - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6753
                REGRESSION (r12282-12292): Crash loading TinyMCE test app
      
              * khtml/xml/ContainerNodeImpl.h: Remove some internals that don't need
              to be member functions.
              * khtml/xml/ContainerNodeImpl.cpp:
              (WebCore::ContainerNodeImpl::insertBefore): Improved algorithm to keep
              refs to more things so that we don't end up with a dangling pointer (fixes
              the crash) and so that we do not crash if someone modifies the tree inside
              a DOM mutation event handler (theoretical only at this point, needs test
              cases).
              (WebCore::ContainerNodeImpl::replaceChild): Ditto.
              (WebCore::willRemoveChild): Changed from member function to free function.
              (WebCore::ContainerNodeImpl::removeChild): Fix potential problem if the
              mutation event handler moves the node into a different parent.
              (WebCore::ContainerNodeImpl::appendChild): Made changes like those in
              insertBefore above.
              (WebCore::dispatchChildInsertionEvents): Changed from member function to
              free function. Tightened up handling of some edge cases.
              (WebCore::dispatchChildRemovalEvents): Ditto.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@12338 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      dd3670b0
  20. 23 Jan, 2006 1 commit
    • darin's avatar
      Reviewed by John Sullivan. · 4e051a01
      darin authored
              - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=6617
                REGRESSION: Crash in cloneChildNodes when clicking element
      
              Test: fast/dom/clone-node-form-elements-with-attr.html
      
              Changed cloneNode and some other functions to return PassRefPtr.
              Also made m_render private and changed its name to m_renderer.
      
              * bindings/objc/DOM.mm: (-[DOMNode cloneNode:]): Add call to get() needed
              now that cloneNode returns a PassRefPtr.
      
              * khtml/editing/break_blockquote_command.cpp:
              (WebCore::BreakBlockquoteCommand::doApply):
              * khtml/editing/insert_paragraph_separator_command.cpp:
              (khtml::InsertParagraphSeparatorCommand::doApply):
              * khtml/editing/split_element_command.cpp:
              (khtml::SplitElementCommand::doApply):
              * khtml/html/htmlparser.cpp:
              (HTMLParser::handleResidualStyleCloseTagAcrossBlocks):
              (HTMLParser::reopenResidualStyleTags):
              * khtml/xml/dom2_rangeimpl.cpp: (DOM::RangeImpl::processContents):
              * ksvg2/svg/SVGUseElementImpl.cpp: (SVGUseElementImpl::closeRenderer):
              Use RefPtr and PassRefPtr as appropriate, since the result of cloneNode
              is now a referenced object in a PassRefPtr rather than a floating one and
              so needs to be kept referenced until used.
      
              * khtml/html/HTMLElementImpl.h:
              * khtml/html/HTMLElementImpl.cpp:
              (WebCore::HTMLElementImpl::cloneNode): Changed to return a PassRefPtr.
              (WebCore::HTMLElementImpl::children): Ditto.
              * khtml/xml/DocumentFragmentImpl.h:
              * khtml/xml/DocumentFragmentImpl.cpp:
              (DOM::DocumentFragmentImpl::cloneNode): Changed to return a PassRefPtr.
              * khtml/xml/DocumentImpl.h:
              * khtml/xml/DocumentTypeImpl.h:
              * khtml/xml/DocumentTypeImpl.cpp:
              (DOM::DocumentTypeImpl::cloneNode): Changed to return a PassRefPtr.
              * khtml/xml/NamedNodeMapImpl.h:
              (WebCore::NamedNodeMapImpl::getNamedItem): Changed to return PassRefPtr.
              (WebCore::NamedNodeMapImpl::removeNamedItem): Ditto.
              (WebCore::NamedNodeMapImpl::setNamedItemNS): Ditto.
      
              * khtml/html/HTMLGenericFormElementImpl.cpp:
              (WebCore::HTMLGenericFormElementImpl::attach): Use renderer() instead of
              getting at m_render directly.
              (WebCore::HTMLGenericFormElementImpl::recalcStyle): Ditto.
              (WebCore::HTMLGenericFormElementImpl::isFocusable): Ditto.
              (WebCore::HTMLGenericFormElementImpl::isKeyboardFocusable): Ditto.
              (WebCore::HTMLGenericFormElementImpl::isMouseFocusable): Ditto.
              * khtml/html/HTMLInputElementImpl.cpp:
              (WebCore::HTMLInputElementImpl::selectionStart): Ditto.
              (WebCore::HTMLInputElementImpl::selectionEnd): Ditto.
              (WebCore::HTMLInputElementImpl::setSelectionStart): Ditto.
              (WebCore::HTMLInputElementImpl::setSelectionEnd): Ditto.
              (WebCore::HTMLInputElementImpl::select): Ditto.
              (WebCore::HTMLInputElementImpl::setSelectionRange): Ditto.
              (WebCore::HTMLInputElementImpl::parseMappedAttribute): Ditto.
              (WebCore::HTMLInputElementImpl::setValue): Ditto.
              (WebCore::HTMLInputElementImpl::defaultEventHandler): Ditto.
              * khtml/html/HTMLSelectElementImpl.cpp:
              (WebCore::HTMLSelectElementImpl::recalcStyle): Ditto.
              (WebCore::HTMLSelectElementImpl::setRecalcListItems): Ditto.
              (WebCore::HTMLSelectElementImpl::reset): Ditto.
              (WebCore::HTMLSelectElementImpl::notifyOptionSelected): Ditto.
              (WebCore::HTMLSelectElementImpl::defaultEventHandler): Ditto.
              * khtml/html/HTMLTextAreaElementImpl.cpp:
              (WebCore::HTMLTextAreaElementImpl::selectionStart): Ditto.
              (WebCore::HTMLTextAreaElementImpl::selectionEnd): Ditto.
              (WebCore::HTMLTextAreaElementImpl::setSelectionStart): Ditto.
              (WebCore::HTMLTextAreaElementImpl::setSelectionEnd): Ditto.
              (WebCore::HTMLTextAreaElementImpl::select): Ditto.
              (WebCore::HTMLTextAreaElementImpl::setSelectionRange): Ditto.
              (WebCore::HTMLTextAreaElementImpl::updateValue): Ditto.
              (WebCore::HTMLTextAreaElementImpl::setValue): Ditto.
              * khtml/html/html_baseimpl.cpp:
              (WebCore::HTMLFrameElementImpl::updateForNewURL): Ditto.
              (WebCore::HTMLFrameElementImpl::openURL): Ditto.
              (WebCore::HTMLFrameElementImpl::attach): Ditto.
              (WebCore::HTMLFrameElementImpl::close): Ditto.
              (WebCore::HTMLFrameElementImpl::willRemove): Ditto.
              (WebCore::HTMLFrameElementImpl::isFocusable): Ditto.
              (WebCore::HTMLFrameElementImpl::setFocus): Ditto.
              (WebCore::HTMLFrameElementImpl::frameWidth): Ditto.
              (WebCore::HTMLFrameElementImpl::frameHeight): Ditto.
              (WebCore::HTMLFrameSetElementImpl::defaultEventHandler): Ditto.
              (WebCore::HTMLFrameSetElementImpl::recalcStyle): Ditto.
              (WebCore::HTMLIFrameElementImpl::attach): Ditto.
              (WebCore::HTMLIFrameElementImpl::recalcStyle): Ditto.
              * khtml/html/html_imageimpl.cpp:
              (WebCore::HTMLImageElementImpl::parseMappedAttribute): Ditto.
              (WebCore::HTMLImageElementImpl::width): Ditto.
              (WebCore::HTMLImageElementImpl::height): Ditto.
              * khtml/html/html_inlineimpl.cpp:
              (WebCore::HTMLAnchorElementImpl::isFocusable): Ditto.
              * khtml/html/html_listimpl.cpp:
              (DOM::HTMLLIElementImpl::parseMappedAttribute): Ditto.
              (DOM::HTMLLIElementImpl::attach): Ditto.
              * khtml/html/html_objectimpl.cpp:
              (WebCore::HTMLAppletElementImpl::getAppletInstance): Ditto.
              (WebCore::HTMLAppletElementImpl::closeRenderer): Ditto.
              (WebCore::HTMLEmbedElementImpl::getEmbedInstance): Ditto.
              (WebCore::HTMLEmbedElementImpl::attach): Ditto.
              (WebCore::HTMLObjectElementImpl::getObjectInstance): Ditto.
              (WebCore::HTMLObjectElementImpl::parseMappedAttribute): Ditto.
              (WebCore::HTMLObjectElementImpl::attach): Ditto.
              (WebCore::HTMLObjectElementImpl::detach): Ditto.
              (WebCore::HTMLObjectElementImpl::recalcStyle): Ditto.
              * khtml/html/html_tableimpl.cpp:
              (WebCore::HTMLTableElementImpl::parseMappedAttribute): Ditto.
              (WebCore::HTMLTableElementImpl::attach): Ditto.
              * khtml/xml/ContainerNodeImpl.cpp:
              (WebCore::ContainerNodeImpl::getUpperLeftCorner): Ditto.
              (WebCore::ContainerNodeImpl::getLowerRightCorner): Ditto.
              (WebCore::ContainerNodeImpl::setActive): Ditto.
              (WebCore::ContainerNodeImpl::setHovered): Ditto.
              * khtml/xml/DocumentImpl.cpp:
              (WebCore::DocumentImpl::~DocumentImpl): Ditto.
              (WebCore::DocumentImpl::elementFromPoint): Ditto.
              (WebCore::DocumentImpl::recalcStyle): Ditto.
              (WebCore::DocumentImpl::attach): Ditto.
              (WebCore::DocumentImpl::restoreRenderer): Ditto.
              (WebCore::DocumentImpl::detach): Ditto.
              (WebCore::DocumentImpl::setVisuallyOrdered): Ditto.
              (WebCore::DocumentImpl::updateSelection): Ditto.
              (WebCore::DocumentImpl::prepareMouseEvent): Ditto.
              (WebCore::DocumentImpl::cloneNode): Changed to return PassRefPtr.
              (WebCore::DocumentImpl::recalcStyleSelector): Use renderer() instead
              of getting at m_render directly.
              (WebCore::DocumentImpl::setInPageCache): Ditto.
      
              * khtml/xml/NodeImpl.h:
              * khtml/xml/NodeImpl.cpp:
              (WebCore::NodeImpl::NodeImpl): Changed m_render to m_renderer.
              (WebCore::NodeImpl::~NodeImpl): Changed use of m_render to renderer().
              (WebCore::NodeImpl::getRect): Ditto.
              (WebCore::NodeImpl::attach): Ditto.
              (WebCore::NodeImpl::detach): Ditto.
              (WebCore::NodeImpl::createRendererIfNeeded): Ditto.
              (WebCore::NodeImpl::getElementsByTagName): Changed to return PassRefPtr.
              (WebCore::NodeImpl::getElementsByTagNameNS): Ditto.
      
              * khtml/xml/dom_elementimpl.h:
              * khtml/xml/dom_elementimpl.cpp:
              (WebCore::AttrImpl::cloneNode): Changed to return PassRefPtr.
              (WebCore::ElementImpl::cloneNode): Ditto.
              (WebCore::ElementImpl::scrollIntoView): Use renderer() instead of m_render.
              (WebCore::ElementImpl::scrollIntoViewIfNeeded): Ditto.
              (WebCore::ElementImpl::recalcStyle): Ditto.
              (WebCore::ElementImpl::setAttributeNode): Changed to return PassRefPtr.
              (WebCore::ElementImpl::removeAttributeNode): Ditto.
              (WebCore::NamedAttrMapImpl::removeNamedItemNS): Ditto.
              (WebCore::NamedAttrMapImpl::setNamedItem): Ditto.
              (WebCore::NamedAttrMapImpl::removeNamedItem): Ditto.
              (DOM::ElementImpl::setAttributeNodeNS): Ditto.
      
              * khtml/xml/dom_textimpl.h:
              * khtml/xml/dom_textimpl.cpp:
              (CharacterDataImpl::setData): Changed use of m_render to renderer().
              (CharacterDataImpl::appendData): Ditto.
              (CharacterDataImpl::insertData): Ditto.
              (CharacterDataImpl::deleteData): Ditto.
              (CharacterDataImpl::replaceData): Ditto.
              (CommentImpl::cloneNode): Changed to return PassRefPtr.
              (TextImpl::splitText): Changed use of m_render to renderer().
              (TextImpl::cloneNode): Changed to return PassRefPtr.
              (TextImpl::recalcStyle): Changed use of m_render to renderer().
              (CDATASectionImpl::cloneNode): Changed to return PassRefPtr.
      
              * khtml/xml/dom_xmlimpl.h:
              * khtml/xml/dom_xmlimpl.cpp:
              (DOM::EntityImpl::cloneNode): Changed to return PassRefPtr.
              (DOM::EntityReferenceImpl::cloneNode): Ditto.
              (DOM::NotationImpl::cloneNode): Ditto.
              (DOM::ProcessingInstructionImpl::cloneNode): Ditto.
      
              - removed unused code
      
              * khtml/html/html_documentimpl.cpp: Removed unused slotHistoryChanged function.
              * khtml/html/html_documentimpl.h: Ditto.
              * kwq/KWQObject.cpp: (QObject::connect): Removed special case for
              slotHistoryChanged, no longer used.
      
              - fixed storage leak
      
              * bridge/mac/MacFrame.mm: (MacFrame::~MacFrame): Delete window widget.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@12313 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      4e051a01
  21. 22 Jan, 2006 1 commit
    • darin's avatar
      Reviewed by Anders. · d545cb4f
      darin authored
              - http://bugzilla.opendarwin.org/show_bug.cgi?id=6705
                use PassRefPtr in more of the basic DOM operations
      
              Once we do the same with cloneNode, I believe we'll fix one of our P1 bugs,
              but cloneNode was a little too much to do without doing this first pass.
      
              * khtml/xml/NodeImpl.cpp:
              (WebCore::NodeImpl::childNodes): Updated for parameter changes.
              (WebCore::NodeImpl::insertBefore): Ditto.
              (WebCore::NodeImpl::replaceChild): Ditto.
              (WebCore::NodeImpl::removeChild): Ditto.
              (WebCore::NodeImpl::appendChild): Ditto.
              (WebCore::NodeImpl::addChild): Ditto.
              (WebCore::NodeImpl::addEventListener): Ditto.
              (WebCore::NodeImpl::setHTMLEventListener): Ditto.
              (WebCore::NodeImpl::isDefaultNamespace): Updated for changed name of ancestorElement.
              (WebCore::NodeImpl::lookupPrefix): Ditto.
              (WebCore::NodeImpl::lookupNamespaceURI): Ditto.
              (WebCore::NodeImpl::lookupNamespacePrefix): Ditto.
              (WebCore::NodeImpl::ancestorElement): Changed name from getAncestorElement.
              * khtml/xml/NodeImpl.h: Changed most functions where it makes sense to take and return
              PassRefPtr instead of raw pointers. Even non-obvious cases like appendChild, where the
              return value has to be PassRefPtr only because it might be removed when the JavaScript
              triggered by the DOM mutation event runs (normally, there's no need to return an "owning"
              pointer because the tree now owns the newly-inserted node). Made the ancestorElement
              function private.
      
              * khtml/xml/ContainerNodeImpl.cpp:
              (WebCore::ContainerNodeImpl::ContainerNodeImpl): Updated for changes from
              _first to m_firstChild and _last to m_lastChild.
              (WebCore::ContainerNodeImpl::removeAllChildren): Ditto.
              (WebCore::ContainerNodeImpl::firstChild): Ditto.
              (WebCore::ContainerNodeImpl::lastChild): Ditto.
              (WebCore::ContainerNodeImpl::insertBefore): Updated for parameter changes.
              (WebCore::ContainerNodeImpl::replaceChild): Ditto.
              (WebCore::ContainerNodeImpl::willRemove): Updated for m_lastChild.
              (WebCore::ContainerNodeImpl::removeChild): Updated for parameter changes.
              (WebCore::ContainerNodeImpl::removeChildren): Updated for m_first/lastChild.
              (WebCore::ContainerNodeImpl::appendChild): Updated for parameter changes.
              (WebCore::ContainerNodeImpl::hasChildNodes): Updated for m_firstChild.
              (WebCore::ContainerNodeImpl::addChild): Updated for parameter changes.
              (WebCore::ContainerNodeImpl::attach): Updated for m_firstChild.
              (WebCore::ContainerNodeImpl::detach): Ditto.
              (WebCore::ContainerNodeImpl::insertedIntoDocument): Ditto.
              (WebCore::ContainerNodeImpl::removedFromDocument): Ditto.
              (WebCore::ContainerNodeImpl::insertedIntoTree): Ditto.
              (WebCore::ContainerNodeImpl::removedFromTree): Ditto.
              * khtml/xml/ContainerNodeImpl.h: Removed unused checkSameDocument and checkIsChild.
              Made more things private, updated parameters for NodeImpl functions.
      
              * khtml/html/HTMLSelectElementImpl.cpp:
              (DOM::HTMLSelectElementImpl::insertBefore): Ditto.
              (DOM::HTMLSelectElementImpl::replaceChild): Ditto.
              (DOM::HTMLSelectElementImpl::removeChild): Ditto.
              (DOM::HTMLSelectElementImpl::appendChild): Ditto.
              (DOM::HTMLSelectElementImpl::addChild): Ditto.
              * khtml/html/HTMLSelectElementImpl.h: Ditto.
      
              * khtml/html/HTMLOptGroupElementImpl.cpp:
              (WebCore::HTMLOptGroupElementImpl::insertBefore): Updated for parameter type change.
              Also changed to look at return value, not exception code, to check for success.
              (WebCore::HTMLOptGroupElementImpl::replaceChild): Ditto.
              (WebCore::HTMLOptGroupElementImpl::removeChild): Ditto.
              (WebCore::HTMLOptGroupElementImpl::appendChild): Ditto.
              (WebCore::HTMLOptGroupElementImpl::addChild): Ditto.
              * khtml/html/HTMLOptGroupElementImpl.h: Ditto.
      
              * WebCore+SVG/kdom.h: Renamed enum from ExceptionCode to ExceptionCodes
              to avoid conflict with a typedef ExceptionCode I added.
      
              * bindings/objc/DOM.mm:
              (-[DOMNode insertBefore::]): Added get() call since return value is a PassRefPtr.
              (-[DOMNode replaceChild::]): Ditto.
              (-[DOMNode removeChild:]): Ditto.
              (-[DOMNode appendChild:]): Ditto.
      
              * khtml/ecma/kjs_dom.h: Changed getDOMNode to take PassRefPtr.
              * khtml/ecma/kjs_dom.cpp: (KJS::getDOMNode): Changed to take PassRefPtr.
      
              * khtml/html/HTMLElementImpl.cpp: Added dom2_events.h include, now needed.
              Re-sorted includes.
              * ksvg2/svg/SVGElementImpl.cpp: Ditto.
      
              * khtml/html/html_documentimpl.cpp: (WebCore::HTMLDocumentImpl::documentElement):
              Changed access to now-private data member _first to equivalent inline function
              fastFirstChild().
              * khtml/xml/DocumentImpl.cpp: (WebCore::DocumentImpl::recalcStyle): Ditto.
              * khtml/xml/dom_elementimpl.cpp: (WebCore::ElementImpl::recalcStyle): Ditto.
      
              * khtml/html/html_tableimpl.cpp:
              (WebCore::HTMLTableElementImpl::setCaption): Updated to work with new replaceChild
              that returns PassRefPtr.
              (WebCore::HTMLTableElementImpl::setTHead): Ditto.
              (WebCore::HTMLTableElementImpl::setTFoot): Ditto.
              (WebCore::HTMLTableElementImpl::setTBody): Ditto.
              (WebCore::HTMLTableElementImpl::addChild): Updated for parameter type change.
              (WebCore::HTMLTableSectionElementImpl::addChild): Ditto.
              (WebCore::HTMLTableRowElementImpl::addChild): Ditto.
              * khtml/html/html_tableimpl.h: Ditto.
      
              * khtml/html/htmlparser.cpp: (HTMLParser::handleResidualStyleCloseTagAcrossBlocks):
              Removed an unneeded explicit call to removeChild. appendChild already takes care of
              removing the child from its own location. This avoids the fact that removeChild was
              removing the parent, the only thing keeping the node alive. This is sort of the
              "flip side" of our removeChild leaks -- code that depended on the behavior that
              caused the leaks.
      
              * khtml/xml/xml_tokenizer.cpp: (WebCore::XMLTokenizer::startElementNs):
              Removed unneeded isHTMLElement() calls from before the "qualified name" change.
      
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@12287 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      d545cb4f
  22. 14 Jan, 2006 1 commit
    • eseidel's avatar
      2006-01-14 Eric Seidel <eseidel@apple.com> · e03393aa
      eseidel authored
              Reviewed by NOBODY (OOPS!).
      
              break classes in dom_nodeimpl.* into separate files (one per class)
              http://bugzilla.opendarwin.org/show_bug.cgi?id=6543
      
              * ForwardingHeaders/kdom/core/NodeImpl.h: Removed.
              * WebCore.xcodeproj/project.pbxproj:
              * bridge/mac/MacFrame.h:
              * bridge/mac/WebCoreFrameBridge.mm:
              * khtml/css/css_base.h:
              * khtml/css/css_stylesheetimpl.cpp:
              * khtml/css/css_valueimpl.cpp:
              * khtml/css/css_valueimpl.h:
              * khtml/ecma/kjs_binding.cpp:
              * khtml/ecma/kjs_dom.cpp:
              * khtml/ecma/kjs_dom.h:
              * khtml/ecma/kjs_events.cpp:
              * khtml/ecma/kjs_html.cpp:
              * khtml/ecma/kjs_traversal.cpp:
              * khtml/editing/SelectionController.cpp:
              * khtml/editing/append_node_command.cpp:
              * khtml/editing/htmlediting.cpp:
              * khtml/editing/htmlediting.h:
              * khtml/editing/insert_node_before_command.cpp:
              * khtml/editing/remove_node_attribute_command.h:
              * khtml/editing/remove_node_command.cpp:
              * khtml/editing/remove_node_preserving_children_command.cpp:
              * khtml/editing/set_node_attribute_command.h:
              * khtml/editing/visible_position.cpp:
              * khtml/editing/visible_text.cpp:
              * khtml/html/HTMLOptionElementImpl.cpp:
              * khtml/html/html_headimpl.cpp:
              * khtml/html/htmlparser.cpp:
              * khtml/khtml_events.cpp:
              * khtml/rendering/render_block.cpp:
              * khtml/rendering/render_box.cpp:
              * khtml/rendering/render_flow.cpp:
              * khtml/rendering/render_frames.h:
              * khtml/rendering/render_line.cpp:
              * khtml/rendering/render_object.h:
              * khtml/xml/ChildNodeListImpl.cpp: Added.
              * khtml/xml/ChildNodeListImpl.h: Added.
              * khtml/xml/ContainerNodeImpl.cpp: Added.
              (DOM::ContainerNodeImpl::removeAllChildren):
              (DOM::ContainerNodeImpl::checkSameDocument):
              (DOM::ContainerNodeImpl::getRect):
              (DOM::ContainerNodeImpl::dispatchChildRemovalEvents):
              * khtml/xml/ContainerNodeImpl.h: Added.
              * khtml/xml/DocumentFragmentImpl.cpp:
              * khtml/xml/DocumentFragmentImpl.h:
              * khtml/xml/DocumentImpl.cpp:
              * khtml/xml/DocumentImpl.h:
              (DOM::DocumentImpl::setTextColor):
              * khtml/xml/DocumentTypeImpl.cpp:
              * khtml/xml/DocumentTypeImpl.h:
              * khtml/xml/NameNodeListImpl.cpp: Added.
              * khtml/xml/NameNodeListImpl.h: Added.
              * khtml/xml/NamedNodeMapImpl.h: Added.
              (DOM::NamedNodeMapImpl::NamedNodeMapImpl):
              (DOM::NamedNodeMapImpl::~NamedNodeMapImpl):
              * khtml/xml/NodeImpl.cpp: Added.
              (DOM::TagNodeListImpl::TagNodeListImpl):
              (DOM::TagNodeListImpl::length):
              (DOM::TagNodeListImpl::item):
              (DOM::TagNodeListImpl::nodeMatches):
              (DOM::NodeImpl::getRect):
              * khtml/xml/NodeImpl.h: Added.
              * khtml/xml/NodeListImpl.cpp: Added.
              * khtml/xml/NodeListImpl.h: Added.
              * khtml/xml/dom2_eventsimpl.h:
              * khtml/xml/dom_elementimpl.h:
              * khtml/xml/dom_nodeimpl.cpp: Removed.
              * khtml/xml/dom_nodeimpl.h: Removed.
              * khtml/xml/dom_position.cpp:
              * khtml/xml/dom_textimpl.h:
              * khtml/xml/dom_xmlimpl.cpp:
              * khtml/xml/dom_xmlimpl.h:
              * khtml/xml/xml_tokenizer.cpp:
              * khtml/xsl/xsl_stylesheetimpl.cpp:
              * khtml/xsl/xslt_processorimpl.h:
              * ksvg2/svg/SVGURIReferenceImpl.cpp:
              * kwq/DOM.mm:
              * kwq/DOMHTML.mm:
              * kwq/DOMUtility.mm:
              * kwq/KWQClipboard.h:
              * page/FrameView.cpp:
      
      
      git-svn-id: http://svn.webkit.org/repository/webkit/trunk@12087 268f45cc-cd09-0410-ab3c-d52691b4dbfc
      e03393aa