darin [Wed, 11 May 2005 02:10:10 +0000 (02:10 +0000)]
Reviewed by Dave Hyatt.
No new layout tests needed.
- remove all remaining uses of QMIN/QMAX and KMIN/KMAX.
* kwq/KWQDef.h: Remove the macros.
Remove all use of the macros (and fix a few compile errors by changing the types of
some integer and floating point constants).
* khtml/css/cssparser.cpp:
(CSSParser::parseColorFromValue):
* khtml/css/cssstyleselector.cpp:
(khtml::CSSStyleSelector::getComputedSizeFromSpecifiedSize):
* khtml/html/html_elementimpl.cpp:
(HTMLElementImpl::addHTMLColor):
* khtml/html/html_formimpl.cpp:
(DOM::HTMLSelectElementImpl::parseHTMLAttribute):
* khtml/html/htmltokenizer.cpp:
(khtml::HTMLTokenizer::parseComment):
* khtml/rendering/render_block.cpp:
(khtml::RenderBlock::nearestFloatBottom):
(khtml::RenderBlock::calcMinMaxWidth):
* khtml/rendering/render_flow.cpp:
(RenderFlow::paintOutlineForLine):
* khtml/rendering/render_form.cpp:
(RenderLineEdit::calcMinMaxWidth):
(RenderFieldset::layoutLegend):
(RenderFileButton::calcMinMaxWidth):
(RenderSelect::layout):
(RenderTextArea::calcMinMaxWidth):
* khtml/rendering/render_object.cpp:
(RenderObject::drawBorder):
* khtml/rendering/render_replaced.cpp:
(RenderWidget::resizeWidget):
* khtml/rendering/render_table.cpp:
(RenderTableSection::layoutRows):
* khtml/rendering/table_layout.cpp:
(AutoTableLayout::recalcColumn):
(AutoTableLayout::calcEffectiveWidth):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9157
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Wed, 11 May 2005 00:58:29 +0000 (00:58 +0000)]
Reviewed by Chris Blumenberg.
- next pass of moving code from C++ DOM wrappers into the DOM impl. classes
(this step adds still more member functions missing from the DOM impl. and
changes some of the C++ and Objective-C DOM to call the new ones; also
changes various places that use the C++ DOM to use the DOM impl. instead)
* khtml/css/css_computedstyle.cpp:
(DOM::CSSComputedStyleDeclarationImpl::getPropertyCSSValue):
* khtml/css/css_computedstyle.h:
* khtml/css/css_stylesheetimpl.cpp:
(CSSStyleSheetImpl::cssRules):
* khtml/css/css_stylesheetimpl.h:
* khtml/css/css_valueimpl.cpp:
(DOM::CSSStyleDeclarationImpl::getPropertyCSSValue):
(DOM::CSSStyleDeclarationImpl::getPropertyValue):
(DOM::CSSStyleDeclarationImpl::getPropertyPriority):
(DOM::CSSStyleDeclarationImpl::setProperty):
(DOM::CSSStyleDeclarationImpl::removeProperty):
(DOM::CSSMutableStyleDeclarationImpl::getPropertyValue):
(DOM::CSSPrimitiveValueImpl::CSSPrimitiveValueImpl):
(DOM::operator==):
(DOM::CSSStyleDeclarationImpl::propertyID):
* khtml/css/css_valueimpl.h:
(DOM::CSSValueImpl::setCssText):
(DOM::CSSPrimitiveValueImpl::getDashboardRegionValue):
* khtml/dom/css_rule.cpp:
* khtml/dom/css_rule.h:
* khtml/dom/css_stylesheet.h:
(DOM::CSSException::):
* khtml/dom/css_value.cpp:
(DOM::CSSStyleDeclaration::getPropertyValue):
(DOM::CSSStyleDeclaration::getPropertyCSSValue):
(DOM::CSSStyleDeclaration::removeProperty):
(DOM::CSSStyleDeclaration::getPropertyPriority):
(DOM::CSSStyleDeclaration::setProperty):
* khtml/dom/css_value.h:
* khtml/dom/dom2_events.cpp:
(EventListener::handleEvent):
* khtml/dom/dom2_events.h:
* khtml/dom/dom2_traversal.h:
* khtml/dom/dom_doc.cpp:
(DOM::DOMImplementation::createHTMLDocument):
(DOM::DOMImplementation::createCSSStyleSheet):
(DOM::Document::doctype):
(DOM::Document::createAttribute):
(DOM::Document::createAttributeNS):
(DOM::Document::queryCommandValue):
(DOM::Document::handle):
* khtml/dom/dom_doc.h:
* khtml/dom/dom_element.cpp:
(Attr::name):
(Attr::value):
(Element::getAttribute):
(Element::setAttribute):
(Element::removeAttribute):
(Element::getAttributeNode):
(Element::setAttributeNode):
(Element::removeAttributeNode):
(Element::getElementsByTagName):
(Element::getElementsByTagNameNS):
(Element::getAttributeNS):
(Element::setAttributeNS):
(Element::removeAttributeNS):
(Element::getAttributeNodeNS):
(Element::setAttributeNodeNS):
(Element::hasAttribute):
(Element::hasAttributeNS):
(Element::style):
* khtml/dom/dom_exception.h:
* khtml/dom/dom_misc.cpp:
(DOM::DomShared::deleteMe):
* khtml/dom/dom_misc.h:
(DOM::DomShared::deleteMe):
* khtml/dom/dom_node.cpp:
(NamedNodeMap::getNamedItemNS):
(NamedNodeMap::setNamedItemNS):
(NamedNodeMap::removeNamedItemNS):
(Node::ownerDocument):
(Node::hasAttributes):
(Node::isSupported):
(Node::addEventListener):
(Node::removeEventListener):
* khtml/dom/dom_node.h:
* khtml/dom/html_document.cpp:
(HTMLDocument::setTitle):
(HTMLDocument::completeURL):
(HTMLDocument::getElementsByName):
* khtml/dom/html_element.cpp:
(HTMLElement::setInnerHTML):
(HTMLElement::setInnerText):
(HTMLElement::setOuterHTML):
(HTMLElement::setOuterText):
* khtml/dom/html_form.cpp:
(HTMLLabelElement::form):
(HTMLSelectElement::setValue):
(HTMLSelectElement::options):
(HTMLOptionElement::setValue):
* khtml/dom/html_inline.cpp:
(HTMLAnchorElement::accessKey):
(HTMLAnchorElement::setAccessKey):
(HTMLAnchorElement::charset):
(HTMLAnchorElement::setCharset):
(HTMLAnchorElement::coords):
(HTMLAnchorElement::setCoords):
(HTMLAnchorElement::href):
(HTMLAnchorElement::setHref):
(HTMLAnchorElement::hreflang):
(HTMLAnchorElement::setHreflang):
(HTMLAnchorElement::name):
(HTMLAnchorElement::setName):
(HTMLAnchorElement::rel):
(HTMLAnchorElement::setRel):
(HTMLAnchorElement::rev):
(HTMLAnchorElement::setRev):
(HTMLAnchorElement::shape):
(HTMLAnchorElement::setShape):
(HTMLAnchorElement::tabIndex):
(HTMLAnchorElement::setTabIndex):
(HTMLAnchorElement::target):
(HTMLAnchorElement::setTarget):
(HTMLAnchorElement::type):
(HTMLAnchorElement::setType):
(HTMLAnchorElement::blur):
(HTMLAnchorElement::focus):
(HTMLBRElement::clear):
(HTMLBRElement::setClear):
(HTMLFontElement::color):
(HTMLFontElement::setColor):
(HTMLFontElement::face):
(HTMLFontElement::setFace):
(HTMLFontElement::size):
(HTMLFontElement::setSize):
(HTMLModElement::cite):
(HTMLModElement::setCite):
(HTMLModElement::dateTime):
(HTMLModElement::setDateTime):
(HTMLQuoteElement::cite):
(HTMLQuoteElement::setCite):
* khtml/dom/html_misc.cpp:
(HTMLCollection::HTMLCollection):
(HTMLCollection::base):
(HTMLCollection::namedItems):
* khtml/dom/html_misc.h:
* khtml/editing/htmlediting.cpp:
* khtml/editing/selection.cpp:
* khtml/html/html_documentimpl.cpp:
(DOM::HTMLDocumentImpl::determineParseMode):
(DOM::HTMLDocumentImpl::doctype):
* khtml/html/html_documentimpl.h:
* khtml/html/html_elementimpl.cpp:
(HTMLElementImpl::setInnerHTML):
(HTMLElementImpl::setOuterHTML):
(HTMLElementImpl::setInnerText):
(HTMLElementImpl::setOuterText):
(HTMLElementImpl::style):
(HTMLElementImpl::idDOM):
(HTMLElementImpl::setId):
(HTMLElementImpl::title):
(HTMLElementImpl::setTitle):
(HTMLElementImpl::lang):
(HTMLElementImpl::setLang):
(HTMLElementImpl::dir):
(HTMLElementImpl::setDir):
(HTMLElementImpl::className):
(HTMLElementImpl::setClassName):
(HTMLElementImpl::children):
(HTMLGenericElementImpl::HTMLGenericElementImpl):
(HTMLGenericElementImpl::id):
* khtml/html/html_elementimpl.h:
(DOM::HTMLElementImpl::isGenericFormElement):
* khtml/html/html_formimpl.cpp:
(DOM::HTMLFormElementImpl::parseEnctype):
(DOM::HTMLFormElementImpl::parseHTMLAttribute):
(DOM::HTMLFormElementImpl::elements):
(DOM::HTMLFormElementImpl::name):
(DOM::HTMLFormElementImpl::setName):
(DOM::HTMLFormElementImpl::acceptCharset):
(DOM::HTMLFormElementImpl::setAcceptCharset):
(DOM::HTMLFormElementImpl::action):
(DOM::HTMLFormElementImpl::setAction):
(DOM::HTMLFormElementImpl::setEnctype):
(DOM::HTMLFormElementImpl::method):
(DOM::HTMLFormElementImpl::setMethod):
(DOM::HTMLFormElementImpl::target):
(DOM::HTMLFormElementImpl::setTarget):
(DOM::HTMLGenericFormElementImpl::HTMLGenericFormElementImpl):
(DOM::HTMLGenericFormElementImpl::~HTMLGenericFormElementImpl):
(DOM::HTMLGenericFormElementImpl::parseHTMLAttribute):
(DOM::HTMLGenericFormElementImpl::name):
(DOM::HTMLGenericFormElementImpl::setName):
(DOM::HTMLGenericFormElementImpl::setOverrideName):
(DOM::HTMLGenericFormElementImpl::setDisabled):
(DOM::HTMLGenericFormElementImpl::setReadOnly):
(DOM::HTMLGenericFormElementImpl::tabIndex):
(DOM::HTMLGenericFormElementImpl::setTabIndex):
(DOM::HTMLButtonElementImpl::accessKey):
(DOM::HTMLButtonElementImpl::setAccessKey):
(DOM::HTMLButtonElementImpl::value):
(DOM::HTMLButtonElementImpl::setValue):
(DOM::HTMLInputElementImpl::HTMLInputElementImpl):
(DOM::HTMLInputElementImpl::parseHTMLAttribute):
(DOM::HTMLInputElementImpl::defaultValue):
(DOM::HTMLInputElementImpl::setDefaultValue):
(DOM::HTMLInputElementImpl::defaultChecked):
(DOM::HTMLInputElementImpl::setDefaultChecked):
(DOM::HTMLInputElementImpl::accept):
(DOM::HTMLInputElementImpl::setAccept):
(DOM::HTMLInputElementImpl::accessKey):
(DOM::HTMLInputElementImpl::setAccessKey):
(DOM::HTMLInputElementImpl::align):
(DOM::HTMLInputElementImpl::setAlign):
(DOM::HTMLInputElementImpl::alt):
(DOM::HTMLInputElementImpl::setAlt):
(DOM::HTMLInputElementImpl::setMaxLength):
(DOM::HTMLInputElementImpl::sizeDOM):
(DOM::HTMLInputElementImpl::setSize):
(DOM::HTMLInputElementImpl::src):
(DOM::HTMLInputElementImpl::setSrc):
(DOM::HTMLInputElementImpl::useMap):
(DOM::HTMLInputElementImpl::setUseMap):
(DOM::HTMLLabelElementImpl::form):
(DOM::HTMLLabelElementImpl::accessKey):
(DOM::HTMLLabelElementImpl::setAccessKey):
(DOM::HTMLLabelElementImpl::htmlFor):
(DOM::HTMLLabelElementImpl::setHtmlFor):
(DOM::HTMLLegendElementImpl::accessKey):
(DOM::HTMLLegendElementImpl::setAccessKey):
(DOM::HTMLLegendElementImpl::align):
(DOM::HTMLLegendElementImpl::setAlign):
(DOM::HTMLSelectElementImpl::setValue):
(DOM::HTMLSelectElementImpl::optionsHTMLCollection):
(DOM::HTMLSelectElementImpl::setMultiple):
(DOM::HTMLSelectElementImpl::setSize):
(DOM::HTMLOptGroupElementImpl::label):
(DOM::HTMLOptGroupElementImpl::setLabel):
(DOM::HTMLOptionElementImpl::setText):
(DOM::HTMLOptionElementImpl::setIndex):
(DOM::HTMLOptionElementImpl::setValue):
(DOM::HTMLOptionElementImpl::defaultSelected):
(DOM::HTMLOptionElementImpl::setDefaultSelected):
(DOM::HTMLOptionElementImpl::label):
(DOM::HTMLOptionElementImpl::setLabel):
(DOM::HTMLTextAreaElementImpl::accessKey):
(DOM::HTMLTextAreaElementImpl::setAccessKey):
(DOM::HTMLTextAreaElementImpl::setCols):
(DOM::HTMLTextAreaElementImpl::setRows):
(DOM::HTMLIsIndexElementImpl::HTMLIsIndexElementImpl):
(DOM::HTMLIsIndexElementImpl::parseHTMLAttribute):
(DOM::HTMLIsIndexElementImpl::prompt):
(DOM::HTMLIsIndexElementImpl::setPrompt):
* khtml/html/html_formimpl.h:
* khtml/html/html_headimpl.cpp:
(HTMLBaseElementImpl::setHref):
(HTMLBaseElementImpl::setTarget):
(HTMLLinkElementImpl::disabled):
(HTMLLinkElementImpl::setDisabled):
(HTMLLinkElementImpl::charset):
(HTMLLinkElementImpl::setCharset):
(HTMLLinkElementImpl::href):
(HTMLLinkElementImpl::setHref):
(HTMLLinkElementImpl::hreflang):
(HTMLLinkElementImpl::setHreflang):
(HTMLLinkElementImpl::media):
(HTMLLinkElementImpl::setMedia):
(HTMLLinkElementImpl::rel):
(HTMLLinkElementImpl::setRel):
(HTMLLinkElementImpl::rev):
(HTMLLinkElementImpl::setRev):
(HTMLLinkElementImpl::target):
(HTMLLinkElementImpl::setTarget):
(HTMLLinkElementImpl::type):
(HTMLLinkElementImpl::setType):
(HTMLMetaElementImpl::content):
(HTMLMetaElementImpl::setContent):
(HTMLMetaElementImpl::httpEquiv):
(HTMLMetaElementImpl::setHttpEquiv):
(HTMLMetaElementImpl::name):
(HTMLMetaElementImpl::setName):
(HTMLMetaElementImpl::scheme):
(HTMLMetaElementImpl::setScheme):
(HTMLScriptElementImpl::id):
(HTMLScriptElementImpl::isURLAttribute):
(HTMLScriptElementImpl::insertedIntoDocument):
(HTMLScriptElementImpl::notifyFinished):
(HTMLScriptElementImpl::text):
(HTMLScriptElementImpl::setText):
(HTMLScriptElementImpl::htmlFor):
(HTMLScriptElementImpl::setHtmlFor):
(HTMLScriptElementImpl::event):
(HTMLScriptElementImpl::setEvent):
(HTMLScriptElementImpl::charset):
(HTMLScriptElementImpl::setCharset):
(HTMLScriptElementImpl::defer):
(HTMLScriptElementImpl::setDefer):
(HTMLScriptElementImpl::src):
(HTMLScriptElementImpl::setSrc):
(HTMLScriptElementImpl::type):
(HTMLScriptElementImpl::setType):
(HTMLStyleElementImpl::disabled):
(HTMLStyleElementImpl::setDisabled):
(HTMLStyleElementImpl::media):
(HTMLStyleElementImpl::setMedia):
(HTMLStyleElementImpl::type):
(HTMLStyleElementImpl::setType):
(HTMLTitleElementImpl::insertedIntoDocument):
(HTMLTitleElementImpl::childrenChanged):
(HTMLTitleElementImpl::text):
(HTMLTitleElementImpl::setText):
* khtml/html/html_headimpl.h:
* khtml/html/html_miscimpl.cpp:
(DOM::HTMLBaseFontElementImpl::id):
(DOM::HTMLBaseFontElementImpl::color):
(DOM::HTMLBaseFontElementImpl::setColor):
(DOM::HTMLBaseFontElementImpl::face):
(DOM::HTMLBaseFontElementImpl::setFace):
(DOM::HTMLBaseFontElementImpl::size):
(DOM::HTMLBaseFontElementImpl::setSize):
(DOM::HTMLCollectionImpl::HTMLCollectionImpl):
(DOM::HTMLCollectionImpl::~HTMLCollectionImpl):
(DOM::HTMLCollectionImpl::resetCollectionInfo):
(DOM::HTMLCollectionImpl::traverseNextItem):
(DOM::HTMLCollectionImpl::calcLength):
(DOM::HTMLCollectionImpl::item):
(DOM::HTMLCollectionImpl::namedItem):
(DOM::HTMLCollectionImpl::updateNameCache):
(DOM::HTMLCollectionImpl::namedItems):
(DOM::HTMLCollectionImpl::nextNamedItem):
(DOM::HTMLFormCollectionImpl::HTMLFormCollectionImpl):
(DOM::HTMLFormCollectionImpl::calcLength):
(DOM::HTMLFormCollectionImpl::item):
(DOM::HTMLFormCollectionImpl::getNamedFormItem):
(DOM::HTMLFormCollectionImpl::nextNamedItemInternal):
(DOM::HTMLFormCollectionImpl::namedItem):
(DOM::HTMLFormCollectionImpl::updateNameCache):
* khtml/html/html_miscimpl.h:
(DOM::HTMLCollectionImpl::base):
* khtml/html/htmlparser.cpp:
(KHTMLParser::parseToken):
(KHTMLParser::insertNode):
* khtml/html/htmltokenizer.cpp:
(khtml::HTMLTokenizer::scriptExecution):
* khtml/khtml_events.cpp:
(khtml::MouseEvent::MouseEvent):
(khtml::MouseEvent::offset):
* khtml/khtml_events.h:
(khtml::MouseEvent::innerNode):
(khtml::MousePressEvent::MousePressEvent):
(khtml::MouseDoubleClickEvent::MouseDoubleClickEvent):
(khtml::MouseMoveEvent::MouseMoveEvent):
(khtml::MouseReleaseEvent::MouseReleaseEvent):
* khtml/khtml_part.cpp:
(KHTMLPart::closeURL):
(KHTMLPart::executeScript):
(KHTMLPart::scheduleScript):
(KHTMLPart::executeScheduledScript):
(KHTMLPart::clear):
(KHTMLPart::selectClosestWordFromMouseEvent):
(KHTMLPart::handleMousePressEventDoubleClick):
(KHTMLPart::handleMousePressEventTripleClick):
(KHTMLPart::handleMousePressEventSingleClick):
(KHTMLPart::khtmlMousePressEvent):
(KHTMLPart::handleMouseMoveEventDrag):
(KHTMLPart::handleMouseMoveEventOver):
(KHTMLPart::handleMouseMoveEventSelection):
(KHTMLPart::khtmlMouseReleaseEvent):
(KHTMLPart::selectionHasStyle):
(KHTMLPart::selectionStartHasStyle):
* khtml/khtml_part.h:
* khtml/khtmlpart_p.h:
* khtml/khtmlview.cpp:
(KHTMLViewPrivate::reset):
(KHTMLView::viewportMousePressEvent):
(KHTMLView::viewportMouseDoubleClickEvent):
(KHTMLView::contentsContextMenuEvent):
(KHTMLView::updateDragAndDrop):
(KHTMLView::cancelDragAndDrop):
(KHTMLView::performDragAndDrop):
(KHTMLView::focusNextPrevNode):
* kwq/DOM-CSS.mm:
(-[DOMCSSStyleSheet cssRules]):
(-[DOMCSSStyleDeclaration getPropertyValue:]):
(-[DOMCSSStyleDeclaration getPropertyCSSValue:]):
(-[DOMCSSStyleDeclaration removeProperty:]):
(-[DOMCSSStyleDeclaration getPropertyPriority:]):
(-[DOMCSSStyleDeclaration setProperty:::]):
(-[DOMCSSValue setCssText:]):
* kwq/DOMCSS.h:
* kwq/DOMHTML.mm:
(-[DOMHTMLElement setInnerHTML:]):
(-[DOMHTMLElement setOuterHTML:]):
(-[DOMHTMLElement setInnerText:]):
(-[DOMHTMLElement setOuterText:]):
(-[DOMHTMLSelectElement setLength:]):
(-[DOMHTMLTableSectionElement insertRow:]):
* kwq/DOMInternal.h:
* kwq/DOMInternal.mm:
(raiseDOMException):
(-[WebScriptObject _initializeScriptDOMNodeImp]):
* kwq/DOMUtility.mm:
(KJS::ScriptInterpreter::createObjcInstanceForValue):
* kwq/KWQAccObject.mm:
(-[KWQAccObject accessibilityAttributeValue:]):
* kwq/KWQKHTMLPart.h:
* kwq/KWQKHTMLPart.mm:
(KWQKHTMLPart::KWQKHTMLPart):
(KWQKHTMLPart::advanceToNextMisspelling):
(KWQKHTMLPart::scrollOverflow):
(KWQKHTMLPart::paint):
(KWQKHTMLPart::openURLFromPageCache):
(KWQKHTMLPart::khtmlMousePressEvent):
(KWQKHTMLPart::passWidgetMouseDownEventToWidget):
(KWQKHTMLPart::dispatchDragSrcEvent):
(KWQKHTMLPart::eventMayStartDrag):
(KWQKHTMLPart::khtmlMouseMoveEvent):
(KWQKHTMLPart::dragSourceEndedAt):
(KWQKHTMLPart::mouseDown):
(KWQKHTMLPart::sendContextMenuEvent):
(listParent):
(isTextFirstInListItem):
(KWQKHTMLPart::attributedString):
(KWQKHTMLPart::snapshotDragImage):
(KWQKHTMLPart::mousePressNode):
* kwq/WebCoreBridge.mm:
(updateRenderingForBindings):
(-[WebCoreBridge _documentTypeString]):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9156
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mjs [Tue, 10 May 2005 22:25:04 +0000 (22:25 +0000)]
Reviewed by John.
- rename hasAnchor method to isLink
* khtml/css/cssstyleselector.cpp:
(khtml::checkPseudoState):
(khtml::CSSStyleSelector::canShareStyleWithElement):
(khtml::CSSStyleSelector::styleForElement):
(khtml::CSSStyleSelector::checkOneSelector):
* khtml/editing/htmlediting.cpp:
(khtml::isSpecialElement):
* khtml/html/html_imageimpl.cpp:
(HTMLImageElementImpl::parseHTMLAttribute):
* khtml/html/html_inlineimpl.cpp:
(DOM::HTMLAnchorElementImpl::isFocusable):
(DOM::HTMLAnchorElementImpl::defaultEventHandler):
(DOM::HTMLAnchorElementImpl::parseHTMLAttribute):
* khtml/rendering/render_flexbox.cpp:
(khtml::RenderFlexibleBox::layoutVerticalBox):
* khtml/rendering/render_layer.cpp:
(RenderLayer::hitTest):
* khtml/rendering/render_object.cpp:
(RenderObject::information):
* khtml/xml/dom_nodeimpl.cpp:
(NodeImpl::NodeImpl):
* khtml/xml/dom_nodeimpl.h:
(DOM::NodeImpl::isLink):
* kwq/KWQAccObject.mm:
(-[KWQAccObject anchorElement]):
(-[KWQAccObject addChildrenToArray:]):
(-[KWQAccObject role]):
(-[KWQAccObject title]):
(-[KWQAccObject accessibilityIsIgnored]):
(-[KWQAccObject accessibilityAttributeNames]):
(-[KWQAccObject accessibilityAttributeValue:]):
* kwq/KWQKHTMLPart.mm:
(KWQKHTMLPart::khtmlMouseMoveEvent):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9155
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mjs [Tue, 10 May 2005 22:24:09 +0000 (22:24 +0000)]
Reviewed by John.
- remove init hint argument from VisiblePosition
* khtml/editing/visible_position.cpp:
(khtml::VisiblePosition::VisiblePosition):
(khtml::VisiblePosition::init):
* khtml/editing/visible_position.h:
* khtml/editing/visible_units.cpp:
(khtml::previousBoundary):
(khtml::nextBoundary):
* khtml/xml/dom_docimpl.cpp:
(DocumentImpl::updateSelection):
* kwq/KWQKHTMLPart.mm:
(KWQKHTMLPart::styleForSelectionStart):
* kwq/WebCoreBridge.mm:
(-[WebCoreBridge setSelectedDOMRange:affinity:closeTyping:]):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9154
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Tue, 10 May 2005 21:59:15 +0000 (21:59 +0000)]
Reviewed by David Harrison.
- next pass of moving code from C++ DOM wrappers into the DOM impl. classes
(this step adds more member functions missing from the DOM impl. and
changes some of the Objective-C DOM to call the new ones; also changes some
parameter types in the DOM impl.)
* khtml/dom/dom2_events.cpp:
(UIEvent::initUIEvent):
(MouseEvent::initMouseEvent):
(MutationEvent::initMutationEvent):
(KeyboardEvent::initKeyboardEvent):
* khtml/dom/dom_doc.cpp:
(DOM::DOMImplementation::createDocument):
(DOM::Document::getElementsByTagName):
(DOM::Document::getElementsByTagNameNS):
* khtml/dom/dom_element.cpp:
(Element::removeAttributeNode):
(Element::getElementsByTagName):
(Element::getElementsByTagNameNS):
(Element::setAttributeNodeNS):
* khtml/dom/dom_node.cpp:
(NamedNodeMap::setNamedItemNS):
(NamedNodeMap::removeNamedItemNS):
* khtml/ecma/kjs_binding.cpp:
* khtml/ecma/kjs_events.cpp:
(ClipboardProtoFunc::tryCall):
* khtml/editing/jsediting.cpp:
* khtml/khtml_part.cpp:
(KHTMLPart::applyEditingStyleToBodyElement):
(KHTMLPart::removeEditingStyleFromBodyElement):
* khtml/khtmlview.cpp:
(KHTMLView::viewportMousePressEvent):
(KHTMLView::viewportMouseDoubleClickEvent):
(KHTMLView::viewportMouseMoveEvent):
(KHTMLView::viewportMouseReleaseEvent):
(KHTMLView::updateDragAndDrop):
(KHTMLView::dispatchMouseEvent):
* khtml/misc/shared.h:
(khtml::SharedPtr::reset):
(khtml::::operator):
(khtml::static_pointer_cast):
(khtml::const_pointer_cast):
* khtml/xml/dom2_eventsimpl.cpp:
(UIEventImpl::initUIEvent):
(UIEventImpl::keyCode):
(UIEventImpl::charCode):
(UIEventImpl::layerX):
(UIEventImpl::layerY):
(UIEventImpl::pageX):
(UIEventImpl::pageY):
(UIEventImpl::which):
(MouseRelatedEventImpl::pageX):
(MouseRelatedEventImpl::pageY):
(MouseEventImpl::initMouseEvent):
(MouseEventImpl::which):
(KeyboardEventImpl::initKeyboardEvent):
(KeyboardEventImpl::which):
(MutationEventImpl::MutationEventImpl):
(MutationEventImpl::initMutationEvent):
* khtml/xml/dom2_eventsimpl.h:
(DOM::MutationEventImpl::relatedNode):
* khtml/xml/dom2_rangeimpl.h:
* khtml/xml/dom2_traversalimpl.cpp:
(DOM::NodeFilterImpl::acceptNode):
* khtml/xml/dom2_traversalimpl.h:
* khtml/xml/dom_docimpl.cpp:
(DOMImplementationImpl::createDocument):
(DOMImplementationImpl::createCSSStyleSheet):
(DOMImplementationImpl::createHTMLDocument):
(DocumentImpl::createAttribute):
(DocumentImpl::createHTMLElement):
(DocumentImpl::getOverrideStyle):
(DocumentImpl::defaultEventHandler):
(DocumentImpl::completeURL):
(DocumentImpl::topDocument):
(DocumentImpl::createAttributeNS):
(DocumentImpl::images):
(DocumentImpl::applets):
(DocumentImpl::embeds):
(DocumentImpl::objects):
(DocumentImpl::links):
(DocumentImpl::forms):
(DocumentImpl::anchors):
(DocumentImpl::all):
(DocumentImpl::nameableItems):
(DocumentImpl::getElementsByName):
* khtml/xml/dom_docimpl.h:
(DOM::DocumentImpl::realDocType):
(DOM::DocumentImpl::createAttribute):
* khtml/xml/dom_elementimpl.cpp:
(AttrImpl::nodeName):
(AttrImpl::nodeValue):
(AttrImpl::name):
(AttrImpl::value):
(ElementImpl::attributes):
(ElementImpl::isURLAttribute):
(ElementImpl::setAttributeNode):
(ElementImpl::removeAttributeNode):
(ElementImpl::setAttributeNS):
(ElementImpl::removeAttributeNS):
(ElementImpl::getAttributeNodeNS):
(ElementImpl::hasAttributeNS):
(ElementImpl::style):
(XMLElementImpl::cloneNode):
(NamedAttrMapImpl::setNamedItem):
(NamedAttrMapImpl::removeNamedItem):
* khtml/xml/dom_elementimpl.h:
(DOM::ElementImpl::hasAttribute):
(DOM::ElementImpl::getAttribute):
(DOM::ElementImpl::setAttribute):
(DOM::ElementImpl::removeAttribute):
(DOM::ElementImpl::getAttributeNode):
(DOM::ElementImpl::setAttributeNodeNS):
* khtml/xml/dom_nodeimpl.cpp:
(NodeImpl::handleLocalEvents):
(NodeImpl::isAncestor):
(NodeImpl::addEventListener):
(NodeImpl::removeEventListener):
(NodeImpl::getElementsByTagNameNS):
(NodeImpl::isSupported):
(NodeImpl::ownerDocument):
(NodeImpl::hasAttributes):
(NodeImpl::attributes):
(ContainerNodeImpl::removeChildren):
(NamedNodeMapImpl::~NamedNodeMapImpl):
(NamedNodeMapImpl::getNamedItemNS):
(NamedNodeMapImpl::removeNamedItemNS):
* khtml/xml/dom_nodeimpl.h:
(DOM::NodeImpl::getElementsByTagName):
(DOM::NamedNodeMapImpl::NamedNodeMapImpl):
(DOM::NamedNodeMapImpl::getNamedItem):
(DOM::NamedNodeMapImpl::removeNamedItem):
(DOM::NamedNodeMapImpl::setNamedItemNS):
(DOM::NamedNodeMapImpl::isReadOnly):
* khtml/xml/dom_textimpl.h:
* khtml/xml/dom_xmlimpl.h:
* kwq/DOM.mm:
(-[DOMNode isSupported::]):
(-[DOMNode namespaceURI]):
(-[DOMNode hasAttributes]):
(-[DOMNamedNodeMap getNamedItem:]):
(-[DOMNamedNodeMap setNamedItem:]):
(-[DOMNamedNodeMap removeNamedItem:]):
(-[DOMNamedNodeMap getNamedItemNS::]):
(-[DOMNamedNodeMap setNamedItemNS:]):
(-[DOMNamedNodeMap removeNamedItemNS::]):
(-[DOMImplementation createDocument:::]):
(-[DOMImplementation createCSSStyleSheet::]):
(-[DOMDocument createAttribute:]):
(-[DOMDocument getElementsByTagName:]):
(-[DOMDocument createAttributeNS::]):
(-[DOMDocument getElementsByTagNameNS::]):
(-[DOMElement setAttribute::]):
(-[DOMElement removeAttribute:]):
(-[DOMElement getAttributeNode:]):
(-[DOMElement setAttributeNode:]):
(-[DOMElement removeAttributeNode:]):
(-[DOMElement getElementsByTagName:]):
(-[DOMElement getAttributeNS::]):
(-[DOMElement setAttributeNS:::]):
(-[DOMElement removeAttributeNS::]):
(-[DOMElement getAttributeNodeNS::]):
(-[DOMElement setAttributeNodeNS:]):
(-[DOMElement getElementsByTagNameNS::]):
(-[DOMElement hasAttribute:]):
(-[DOMElement hasAttributeNS::]):
(-[DOMElement style]):
(-[DOMDocumentType _documentTypeImpl]):
(ObjCNodeFilterCondition::acceptNode):
* kwq/DOMEvents.mm:
(-[DOMMutationEvent relatedNode]):
* kwq/KWQClipboard.h:
* kwq/KWQClipboard.mm:
(KWQClipboard::KWQClipboard):
(KWQClipboard::setDragImage):
(KWQClipboard::dragImageElement):
(KWQClipboard::setDragImageElement):
(KWQClipboard::dragNSImage):
* kwq/KWQKHTMLPart.mm:
(KWQKHTMLPart::khtmlMouseMoveEvent):
(KWQKHTMLPart::passSubframeEventToSubframe):
(KWQKHTMLPart::sendContextMenuEvent):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9153
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
sullivan [Tue, 10 May 2005 20:27:17 +0000 (20:27 +0000)]
WebKit:
Reviewed by Kevin.
- WebKit support for <rdar://problem/
3795701> Menu item/keyboard shortcut to
restore text zoom to normal
* WebView.subproj/WebView.m:
(-[WebView validateUserInterfaceItem:]):
validate makeTextStandardSize by calling canMakeTextStandardSize
(-[WebView canMakeTextStandardSize]):
new method, returns YES unless text size multiplier is currently 1
(-[WebView makeTextStandardSize:]):
new method, sets text size multiplier to 1
* WebView.subproj/WebViewPrivate.h:
add makeTextStandardSize: and canMakeTextStandardSize to pending public category
WebBrowser:
Reviewed by Chris.
- fixed <rdar://problem/
3795701> Menu item/keyboard shortcut to restore text zoom to normal
* BrowserDocument.h: added -makeTextStandardSize:
* BrowserDocument.m:
(-[BrowserDocument makeTextStandardSize:]):
call through to webview
(-[BrowserDocument validateUserInterfaceItem:]):
call through to webview
* BrowserWebController.m:
(-[BrowserWebView canMakeTextStandardSize]):
new method, special case bookmarks view, as with other text size methods
(-[BrowserWebView makeTextStandardSize:]):
new method, bail out if canMakeTextStandardSize fails, as with other text size methods
* BrowserWindowController.h: added -makeTextStandardSize:
* BrowserWindowController.m:
(-[BrowserWindowController validateUserInterfaceItem:]):
call through to webview
(-[BrowserWindowController makeTextStandardSize:]):
ditto
* English.lproj/MainMenu.nib:
Added Make Text Normal Size menu item with keyboard equivalent of command-0, in
between Make Text Bigger and Make Text Smaller
* HTMLSourceDocument.m:
(-[HTMLSourceDocument canMakeTextStandardSize]):
new method, imitates WebView code
(-[HTMLSourceDocument makeTextStandardSize:]):
ditto
(-[HTMLSourceDocument validateUserInterfaceItem:]):
validate new method
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9152
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Tue, 10 May 2005 18:42:04 +0000 (18:42 +0000)]
Reviewed by David Harrison.
- first pass of moving code from C++ DOM wrappers into the DOM impl. classes
(this step mostly adds member functions missing from the DOM impl.; later steps
will change the C++, JavaScript, and ObjC wrappers to call these functions)
* khtml/css/parser.y:
* khtml/css/css_ruleimpl.cpp:
(CSSRuleListImpl::CSSRuleListImpl):
* khtml/css/css_ruleimpl.h:
(DOM::CSSRuleListImpl::CSSRuleListImpl):
* khtml/html/html_baseimpl.cpp:
(HTMLBodyElementImpl::aLink):
(HTMLBodyElementImpl::setALink):
(HTMLBodyElementImpl::background):
(HTMLBodyElementImpl::setBackground):
(HTMLBodyElementImpl::bgColor):
(HTMLBodyElementImpl::setBgColor):
(HTMLBodyElementImpl::link):
(HTMLBodyElementImpl::setLink):
(HTMLBodyElementImpl::text):
(HTMLBodyElementImpl::setText):
(HTMLBodyElementImpl::vLink):
(HTMLBodyElementImpl::setVLink):
(HTMLFrameElementImpl::HTMLFrameElementImpl):
(HTMLFrameElementImpl::updateForNewURL):
(HTMLFrameElementImpl::openURL):
(HTMLFrameElementImpl::parseHTMLAttribute):
(HTMLFrameElementImpl::rendererIsNeeded):
(HTMLFrameElementImpl::attach):
(HTMLFrameElementImpl::detach):
(HTMLFrameElementImpl::setLocation):
(HTMLFrameElementImpl::contentPart):
(HTMLFrameElementImpl::frameBorder):
(HTMLFrameElementImpl::setFrameBorder):
(HTMLFrameElementImpl::longDesc):
(HTMLFrameElementImpl::setLongDesc):
(HTMLFrameElementImpl::marginHeight):
(HTMLFrameElementImpl::setMarginHeight):
(HTMLFrameElementImpl::marginWidth):
(HTMLFrameElementImpl::setMarginWidth):
(HTMLFrameElementImpl::name):
(HTMLFrameElementImpl::setName):
(HTMLFrameElementImpl::setNoResize):
(HTMLFrameElementImpl::scrolling):
(HTMLFrameElementImpl::setScrolling):
(HTMLFrameElementImpl::src):
(HTMLFrameElementImpl::setSrc):
(HTMLFrameSetElementImpl::parseHTMLAttribute):
(HTMLFrameSetElementImpl::cols):
(HTMLFrameSetElementImpl::setCols):
(HTMLFrameSetElementImpl::rows):
(HTMLFrameSetElementImpl::setRows):
(HTMLHeadElementImpl::profile):
(HTMLHeadElementImpl::setProfile):
(HTMLHtmlElementImpl::version):
(HTMLHtmlElementImpl::setVersion):
(HTMLIFrameElementImpl::HTMLIFrameElementImpl):
(HTMLIFrameElementImpl::rendererIsNeeded):
(HTMLIFrameElementImpl::attach):
(HTMLIFrameElementImpl::isURLAttribute):
(HTMLIFrameElementImpl::align):
(HTMLIFrameElementImpl::setAlign):
(HTMLIFrameElementImpl::height):
(HTMLIFrameElementImpl::setHeight):
(HTMLIFrameElementImpl::src):
(HTMLIFrameElementImpl::width):
(HTMLIFrameElementImpl::setWidth):
* khtml/html/html_baseimpl.h:
(DOM::HTMLFrameElementImpl::noResize):
(DOM::HTMLFrameElementImpl::scrollingMode):
(DOM::HTMLFrameElementImpl::getMarginWidth):
(DOM::HTMLFrameElementImpl::getMarginHeight):
* khtml/html/html_blockimpl.cpp:
(HTMLBlockquoteElementImpl::cite):
(HTMLBlockquoteElementImpl::setCite):
(HTMLDivElementImpl::align):
(HTMLDivElementImpl::setAlign):
(HTMLHRElementImpl::align):
(HTMLHRElementImpl::setAlign):
(HTMLHRElementImpl::noShade):
(HTMLHRElementImpl::setNoShade):
(HTMLHRElementImpl::size):
(HTMLHRElementImpl::setSize):
(HTMLHRElementImpl::width):
(HTMLHRElementImpl::setWidth):
(HTMLHeadingElementImpl::align):
(HTMLHeadingElementImpl::setAlign):
(HTMLParagraphElementImpl::align):
(HTMLParagraphElementImpl::setAlign):
(HTMLPreElementImpl::width):
(HTMLPreElementImpl::setWidth):
* khtml/html/html_blockimpl.h:
* khtml/html/html_imageimpl.cpp:
(HTMLImageElementImpl::name):
(HTMLImageElementImpl::setName):
(HTMLImageElementImpl::align):
(HTMLImageElementImpl::setAlign):
(HTMLImageElementImpl::alt):
(HTMLImageElementImpl::setAlt):
(HTMLImageElementImpl::border):
(HTMLImageElementImpl::setBorder):
(HTMLImageElementImpl::setHeight):
(HTMLImageElementImpl::hspace):
(HTMLImageElementImpl::setHspace):
(HTMLImageElementImpl::isMap):
(HTMLImageElementImpl::setIsMap):
(HTMLImageElementImpl::longDesc):
(HTMLImageElementImpl::setLongDesc):
(HTMLImageElementImpl::src):
(HTMLImageElementImpl::setSrc):
(HTMLImageElementImpl::useMap):
(HTMLImageElementImpl::setUseMap):
(HTMLImageElementImpl::vspace):
(HTMLImageElementImpl::setVspace):
(HTMLImageElementImpl::setWidth):
(HTMLImageElementImpl::x):
(HTMLImageElementImpl::y):
(HTMLMapElementImpl::parseHTMLAttribute):
(HTMLMapElementImpl::areas):
(HTMLMapElementImpl::name):
(HTMLMapElementImpl::setName):
(HTMLAreaElementImpl::HTMLAreaElementImpl):
(HTMLAreaElementImpl::parseHTMLAttribute):
(HTMLAreaElementImpl::getRegion):
(HTMLAreaElementImpl::accessKey):
(HTMLAreaElementImpl::setAccessKey):
(HTMLAreaElementImpl::alt):
(HTMLAreaElementImpl::setAlt):
(HTMLAreaElementImpl::coords):
(HTMLAreaElementImpl::setCoords):
(HTMLAreaElementImpl::href):
(HTMLAreaElementImpl::setHref):
(HTMLAreaElementImpl::noHref):
(HTMLAreaElementImpl::setNoHref):
(HTMLAreaElementImpl::shape):
(HTMLAreaElementImpl::setShape):
(HTMLAreaElementImpl::tabIndex):
(HTMLAreaElementImpl::setTabIndex):
(HTMLAreaElementImpl::target):
(HTMLAreaElementImpl::setTarget):
* khtml/html/html_imageimpl.h:
(DOM::HTMLImageElementImpl::pixmap):
(DOM::HTMLAreaElementImpl::isDefault):
(DOM::HTMLMapElementImpl::getName):
* khtml/html/html_inlineimpl.cpp:
(DOM::HTMLAnchorElementImpl::accessKey):
(DOM::HTMLAnchorElementImpl::setAccessKey):
(DOM::HTMLAnchorElementImpl::charset):
(DOM::HTMLAnchorElementImpl::setCharset):
(DOM::HTMLAnchorElementImpl::coords):
(DOM::HTMLAnchorElementImpl::setCoords):
(DOM::HTMLAnchorElementImpl::href):
(DOM::HTMLAnchorElementImpl::setHref):
(DOM::HTMLAnchorElementImpl::hreflang):
(DOM::HTMLAnchorElementImpl::setHreflang):
(DOM::HTMLAnchorElementImpl::name):
(DOM::HTMLAnchorElementImpl::setName):
(DOM::HTMLAnchorElementImpl::rel):
(DOM::HTMLAnchorElementImpl::setRel):
(DOM::HTMLAnchorElementImpl::rev):
(DOM::HTMLAnchorElementImpl::setRev):
(DOM::HTMLAnchorElementImpl::shape):
(DOM::HTMLAnchorElementImpl::setShape):
(DOM::HTMLAnchorElementImpl::tabIndex):
(DOM::HTMLAnchorElementImpl::setTabIndex):
(DOM::HTMLAnchorElementImpl::target):
(DOM::HTMLAnchorElementImpl::setTarget):
(DOM::HTMLAnchorElementImpl::type):
(DOM::HTMLAnchorElementImpl::setType):
(DOM::HTMLAnchorElementImpl::blur):
(DOM::HTMLAnchorElementImpl::focus):
(DOM::HTMLBRElementImpl::clear):
(DOM::HTMLBRElementImpl::setClear):
(DOM::HTMLFontElementImpl::parseHTMLAttribute):
(DOM::HTMLFontElementImpl::color):
(DOM::HTMLFontElementImpl::setColor):
(DOM::HTMLFontElementImpl::face):
(DOM::HTMLFontElementImpl::setFace):
(DOM::HTMLFontElementImpl::size):
(DOM::HTMLFontElementImpl::setSize):
(DOM::HTMLModElementImpl::HTMLModElementImpl):
(DOM::HTMLModElementImpl::cite):
(DOM::HTMLModElementImpl::setCite):
(DOM::HTMLModElementImpl::dateTime):
(DOM::HTMLModElementImpl::setDateTime):
(DOM::HTMLQuoteElementImpl::HTMLQuoteElementImpl):
(DOM::HTMLQuoteElementImpl::id):
(DOM::HTMLQuoteElementImpl::cite):
(DOM::HTMLQuoteElementImpl::setCite):
* khtml/html/html_inlineimpl.h:
* khtml/html/html_listimpl.cpp:
(DOM::HTMLUListElementImpl::compact):
(DOM::HTMLUListElementImpl::setCompact):
(DOM::HTMLUListElementImpl::type):
(DOM::HTMLUListElementImpl::setType):
(DOM::HTMLDirectoryElementImpl::compact):
(DOM::HTMLDirectoryElementImpl::setCompact):
(DOM::HTMLMenuElementImpl::compact):
(DOM::HTMLMenuElementImpl::setCompact):
(DOM::HTMLOListElementImpl::compact):
(DOM::HTMLOListElementImpl::setCompact):
(DOM::HTMLOListElementImpl::setStart):
(DOM::HTMLOListElementImpl::type):
(DOM::HTMLOListElementImpl::setType):
(DOM::HTMLLIElementImpl::type):
(DOM::HTMLLIElementImpl::setType):
(DOM::HTMLLIElementImpl::value):
(DOM::HTMLLIElementImpl::setValue):
(DOM::HTMLDListElementImpl::compact):
(DOM::HTMLDListElementImpl::setCompact):
* khtml/html/html_listimpl.h:
(DOM::HTMLUListElementImpl::start):
(DOM::HTMLDirectoryElementImpl::HTMLDirectoryElementImpl):
(DOM::HTMLMenuElementImpl::HTMLMenuElementImpl):
(DOM::HTMLOListElementImpl::HTMLOListElementImpl):
(DOM::HTMLOListElementImpl::start):
* khtml/html/html_objectimpl.cpp:
(DOM::HTMLAppletElementImpl::align):
(DOM::HTMLAppletElementImpl::setAlign):
(DOM::HTMLAppletElementImpl::alt):
(DOM::HTMLAppletElementImpl::setAlt):
(DOM::HTMLAppletElementImpl::archive):
(DOM::HTMLAppletElementImpl::setArchive):
(DOM::HTMLAppletElementImpl::code):
(DOM::HTMLAppletElementImpl::setCode):
(DOM::HTMLAppletElementImpl::codeBase):
(DOM::HTMLAppletElementImpl::setCodeBase):
(DOM::HTMLAppletElementImpl::height):
(DOM::HTMLAppletElementImpl::setHeight):
(DOM::HTMLAppletElementImpl::hspace):
(DOM::HTMLAppletElementImpl::setHspace):
(DOM::HTMLAppletElementImpl::name):
(DOM::HTMLAppletElementImpl::setName):
(DOM::HTMLAppletElementImpl::object):
(DOM::HTMLAppletElementImpl::setObject):
(DOM::HTMLAppletElementImpl::vspace):
(DOM::HTMLAppletElementImpl::setVspace):
(DOM::HTMLAppletElementImpl::width):
(DOM::HTMLAppletElementImpl::setWidth):
(DOM::HTMLObjectElementImpl::code):
(DOM::HTMLObjectElementImpl::setCode):
(DOM::HTMLObjectElementImpl::align):
(DOM::HTMLObjectElementImpl::setAlign):
(DOM::HTMLObjectElementImpl::archive):
(DOM::HTMLObjectElementImpl::setArchive):
(DOM::HTMLObjectElementImpl::border):
(DOM::HTMLObjectElementImpl::setBorder):
(DOM::HTMLObjectElementImpl::codeBase):
(DOM::HTMLObjectElementImpl::setCodeBase):
(DOM::HTMLObjectElementImpl::codeType):
(DOM::HTMLObjectElementImpl::setCodeType):
(DOM::HTMLObjectElementImpl::data):
(DOM::HTMLObjectElementImpl::setData):
(DOM::HTMLObjectElementImpl::declare):
(DOM::HTMLObjectElementImpl::setDeclare):
(DOM::HTMLObjectElementImpl::height):
(DOM::HTMLObjectElementImpl::setHeight):
(DOM::HTMLObjectElementImpl::hspace):
(DOM::HTMLObjectElementImpl::setHspace):
(DOM::HTMLObjectElementImpl::name):
(DOM::HTMLObjectElementImpl::setName):
(DOM::HTMLObjectElementImpl::standby):
(DOM::HTMLObjectElementImpl::setStandby):
(DOM::HTMLObjectElementImpl::tabIndex):
(DOM::HTMLObjectElementImpl::setTabIndex):
(DOM::HTMLObjectElementImpl::type):
(DOM::HTMLObjectElementImpl::setType):
(DOM::HTMLObjectElementImpl::useMap):
(DOM::HTMLObjectElementImpl::setUseMap):
(DOM::HTMLObjectElementImpl::vspace):
(DOM::HTMLObjectElementImpl::setVspace):
(DOM::HTMLObjectElementImpl::width):
(DOM::HTMLObjectElementImpl::setWidth):
(DOM::HTMLParamElementImpl::isURLAttribute):
(DOM::HTMLParamElementImpl::setName):
(DOM::HTMLParamElementImpl::type):
(DOM::HTMLParamElementImpl::setType):
(DOM::HTMLParamElementImpl::setValue):
(DOM::HTMLParamElementImpl::valueType):
(DOM::HTMLParamElementImpl::setValueType):
* khtml/html/html_objectimpl.h:
(DOM::HTMLParamElementImpl::name):
(DOM::HTMLParamElementImpl::value):
* khtml/html/html_tableimpl.cpp:
(DOM::HTMLTableElementImpl::rows):
(DOM::HTMLTableElementImpl::tBodies):
(DOM::HTMLTableElementImpl::align):
(DOM::HTMLTableElementImpl::setAlign):
(DOM::HTMLTableElementImpl::bgColor):
(DOM::HTMLTableElementImpl::setBgColor):
(DOM::HTMLTableElementImpl::border):
(DOM::HTMLTableElementImpl::setBorder):
(DOM::HTMLTableElementImpl::cellPadding):
(DOM::HTMLTableElementImpl::setCellPadding):
(DOM::HTMLTableElementImpl::cellSpacing):
(DOM::HTMLTableElementImpl::setCellSpacing):
(DOM::HTMLTableElementImpl::frame):
(DOM::HTMLTableElementImpl::setFrame):
(DOM::HTMLTableElementImpl::rules):
(DOM::HTMLTableElementImpl::setRules):
(DOM::HTMLTableElementImpl::summary):
(DOM::HTMLTableElementImpl::setSummary):
(DOM::HTMLTableElementImpl::width):
(DOM::HTMLTableElementImpl::setWidth):
(DOM::HTMLTableSectionElementImpl::align):
(DOM::HTMLTableSectionElementImpl::setAlign):
(DOM::HTMLTableSectionElementImpl::ch):
(DOM::HTMLTableSectionElementImpl::setCh):
(DOM::HTMLTableSectionElementImpl::chOff):
(DOM::HTMLTableSectionElementImpl::setChOff):
(DOM::HTMLTableSectionElementImpl::vAlign):
(DOM::HTMLTableSectionElementImpl::setVAlign):
(DOM::HTMLTableSectionElementImpl::rows):
(DOM::HTMLTableRowElementImpl::cells):
(DOM::HTMLTableRowElementImpl::setCells):
(DOM::HTMLTableRowElementImpl::align):
(DOM::HTMLTableRowElementImpl::setAlign):
(DOM::HTMLTableRowElementImpl::bgColor):
(DOM::HTMLTableRowElementImpl::setBgColor):
(DOM::HTMLTableRowElementImpl::ch):
(DOM::HTMLTableRowElementImpl::setCh):
(DOM::HTMLTableRowElementImpl::chOff):
(DOM::HTMLTableRowElementImpl::setChOff):
(DOM::HTMLTableRowElementImpl::vAlign):
(DOM::HTMLTableRowElementImpl::setVAlign):
(DOM::HTMLTableCellElementImpl::abbr):
(DOM::HTMLTableCellElementImpl::setAbbr):
(DOM::HTMLTableCellElementImpl::align):
(DOM::HTMLTableCellElementImpl::setAlign):
(DOM::HTMLTableCellElementImpl::axis):
(DOM::HTMLTableCellElementImpl::setAxis):
(DOM::HTMLTableCellElementImpl::bgColor):
(DOM::HTMLTableCellElementImpl::setBgColor):
(DOM::HTMLTableCellElementImpl::ch):
(DOM::HTMLTableCellElementImpl::setCh):
(DOM::HTMLTableCellElementImpl::chOff):
(DOM::HTMLTableCellElementImpl::setChOff):
(DOM::HTMLTableCellElementImpl::setColSpan):
(DOM::HTMLTableCellElementImpl::headers):
(DOM::HTMLTableCellElementImpl::setHeaders):
(DOM::HTMLTableCellElementImpl::height):
(DOM::HTMLTableCellElementImpl::setHeight):
(DOM::HTMLTableCellElementImpl::noWrap):
(DOM::HTMLTableCellElementImpl::setNoWrap):
(DOM::HTMLTableCellElementImpl::setRowSpan):
(DOM::HTMLTableCellElementImpl::scope):
(DOM::HTMLTableCellElementImpl::setScope):
(DOM::HTMLTableCellElementImpl::vAlign):
(DOM::HTMLTableCellElementImpl::setVAlign):
(DOM::HTMLTableCellElementImpl::width):
(DOM::HTMLTableCellElementImpl::setWidth):
(DOM::HTMLTableColElementImpl::align):
(DOM::HTMLTableColElementImpl::setAlign):
(DOM::HTMLTableColElementImpl::ch):
(DOM::HTMLTableColElementImpl::setCh):
(DOM::HTMLTableColElementImpl::chOff):
(DOM::HTMLTableColElementImpl::setChOff):
(DOM::HTMLTableColElementImpl::setSpan):
(DOM::HTMLTableColElementImpl::vAlign):
(DOM::HTMLTableColElementImpl::setVAlign):
(DOM::HTMLTableColElementImpl::width):
(DOM::HTMLTableColElementImpl::setWidth):
(DOM::HTMLTableCaptionElementImpl::parseHTMLAttribute):
(DOM::HTMLTableCaptionElementImpl::align):
(DOM::HTMLTableCaptionElementImpl::setAlign):
* khtml/html/html_tableimpl.h:
(DOM::HTMLTableColElementImpl::span):
* khtml/rendering/render_applet.cpp:
(RenderApplet::createWidgetIfNecessary):
* khtml/rendering/render_frames.cpp:
(RenderFrame::slotViewCleared):
(RenderPartObject::updateWidget):
(RenderPartObject::slotViewCleared):
* khtml/xml/dom_docimpl.cpp:
(DocumentImpl::completeURL):
* khtml/xml/dom_docimpl.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9151
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
sullivan [Tue, 10 May 2005 18:01:26 +0000 (18:01 +0000)]
Reviewed by Chris.
- fixed <rdar://problem/
4067981> Mail places RTF flavor before RTFD flavor when dragging
mixed image/text content.
* WebView.subproj/WebHTMLView.m:
(+[WebHTMLView _selectionPasteboardTypes]):
put RTFD type before RTF type in array of types to declare
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9150
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mjs [Tue, 10 May 2005 04:40:49 +0000 (04:40 +0000)]
Reviewed by Kevin.
- remove more isFirst/isLast functions and use isStart/isEnd verions instead
* khtml/editing/htmlediting.cpp:
(khtml::DeleteSelectionCommand::initializePositionData):
(khtml::InsertParagraphSeparatorCommand::calculateStyleBeforeInsertion):
(khtml::InsertTextCommand::input):
(khtml::ReplaceSelectionCommand::doApply):
(khtml::ReplaceSelectionCommand::removeLinePlaceholderIfNeeded):
* khtml/editing/visible_position.cpp:
(khtml::VisiblePosition::previous):
(khtml::setAffinityUsingLinePosition):
(khtml::isFirstVisiblePositionInNode):
* khtml/editing/visible_position.h:
* khtml/editing/visible_units.cpp:
(khtml::endOfLine):
(khtml::previousLinePosition):
* khtml/xml/dom_position.cpp:
(DOM::Position::previousCharacterPosition):
(DOM::Position::nextCharacterPosition):
* kwq/WebCoreBridge.mm:
(-[WebCoreBridge smartInsertForString:replacingRange:beforeString:afterString:]):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9149
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mjs [Tue, 10 May 2005 04:03:34 +0000 (04:03 +0000)]
Reviewed by Kevin.
- remove isFirstVisiblePositionInBlock and isLastVisiblePositionInBlock, in favor of isStartOfBlock and isEndOfBlock
It turned out that both isEndOfBlock and isLastVisiblePositionInBlock had (different) bugs,
and there was code relying on the bugs of each. So in addition I fixed isEndOfBlock and fixed
the parts of the code relying on buggy behavior.
I also removed the includeEndOfLine parameter to endOfBlock since no one used it and it's not
clear if it would ever be useful.
* khtml/editing/htmlediting.cpp:
(khtml::InsertLineBreakCommand::doApply): Use new calls.
(khtml::InsertParagraphSeparatorCommand::calculateStyleBeforeInsertion): Don't gratuitously make
an UPSTREAM VisiblePosition, as this will cause trouble comparing it to end of block.
(khtml::InsertParagraphSeparatorCommand::doApply): Use new calls.
(khtml::ReplaceSelectionCommand::doApply): Use new calls. Also, don't make a position <BR,0> and test
if it is the end of a block, that can never be true, although the buggy code in
isLastVisiblePositionInBlock would say it is. Make <BR,1> instead.
* khtml/editing/markup.cpp:
(khtml::createMarkup): Instead of checking isEndOfBlock on the start position, check if the start's
next is in a different block, to avoid relying on the buggy old isEndOfBlock behavior.
* khtml/editing/visible_position.cpp:
(khtml::isFirstVisiblePositionInParagraph): Use isStartOfBlock.
(khtml::isLastVisiblePositionInParagraph): Use isEndOfBlock.
* khtml/editing/visible_position.h:
* khtml/editing/visible_units.cpp:
(khtml::endOfBlock): Greatly simplify, and no longer consider the start of a descendant
block to be the end of the block. That's inconsistent with how startOfBlock works. Also
remove include end of line parameter.
(khtml::isEndOfBlock): Don't pass unneeded parameter.
* khtml/editing/visible_units.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9148
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
adele [Tue, 10 May 2005 01:04:52 +0000 (01:04 +0000)]
fix for <rdar://problem/
4110775> Crash will occur when double-clicking outerHTML link on W3 DOM test
Reviewed by Darin.
* khtml/html/html_elementimpl.cpp: (HTMLElementImpl::setOuterHTML): added nil check.
This was causing a crash when you tried to set the outerHTML on an element that was no longer in the DOM tree.
* layout-tests/fast/dom/outerText-no-element.html: Added. Tests case where you try to set outerText on an element no longer in the DOM tree.
* layout-tests/fast/dom/outerText-no-element-expected.txt: Added.
* layout-tests/fast/dynamic/outerHTML-doc.html: Added. Tests case where someone tries to set outerHTML on the document.
* layout-tests/fast/dynamic/outerHTML-doc-expected.txt: Added..
* layout-tests/fast/dynamic/outerHTML-no-element.html: Added. Tests case where you try to set outerHTML on an element no longer in the DOM tree.
* layout-tests/fast/dynamic/outerHTML-no-element-expected.txt: Added.
* layout-tests/fast/dynamic/outerHTML-img.html: moved images to resources directory
* layout-tests/fast/dynamic/resources/apple.gif: Added.
* layout-tests/fast/dynamic/resources/mozilla.gif: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9146
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Mon, 9 May 2005 23:57:33 +0000 (23:57 +0000)]
Reviewed by John.
- turn on conservative GC unconditionally and start on SPI changes to
eliminate the now-unneeded smart pointers since we don't ref count any more
* kjs/value.h: Removed macros to turn conservative GC on and off.
Removed ref and deref functions.
(KJS::ValueImp::ValueImp): Removed non-conservative-GC code path.
(KJS::ValueImp::isUndefined): Added. New SPI to make it easier to deal with ValueImp directly.
(KJS::ValueImp::isNull): Ditto.
(KJS::ValueImp::isBoolean): Ditto.
(KJS::ValueImp::isNumber): Ditto.
(KJS::ValueImp::isString): Ditto.
(KJS::ValueImp::isObject): Ditto.
(KJS::Value::Value): Removed non-conservative-GC code path and made constructor no
longer explicit so we can quietly create Value wrappers from ValueImp *; inexpensive with
conservative GC and eases the transition.
(KJS::Value::operator ValueImp *): Added. Quietly creates ValueImp * from Value.
(KJS::ValueImp::marked): Removed non-conservative-GC code path.
* kjs/value.cpp:
(KJS::ValueImp::mark): Removed non-conservative-GC code path.
(KJS::ValueImp::isUndefinedOrNull): Added. New SPI to make it easier to deal with ValueImp directly.
(KJS::ValueImp::isBoolean): Ditto.
(KJS::ValueImp::isNumber): Ditto.
(KJS::ValueImp::isString): Ditto.
(KJS::ValueImp::asString): Ditto.
(KJS::ValueImp::isObject): Ditto.
(KJS::undefined): Ditto.
(KJS::null): Ditto.
(KJS::boolean): Ditto.
(KJS::string): Ditto.
(KJS::zero): Ditto.
(KJS::one): Ditto.
(KJS::two): Ditto.
(KJS::number): Ditto.
* kjs/object.h: Made constructor no longer explicit so we can quietly create Object
wrappers from ObjectImp *; inexpensive with conservative GC and eases the transition.
(KJS::Object::operator ObjectImp *): Added. Quietly creates ObjectImp * from Object.
(KJS::ValueImp::isObject): Added. Implementation of new object-related ValueImp function.
(KJS::ValueImp::asObject): Ditto.
* kjs/object.cpp:
(KJS::ObjectImp::setInternalValue): Remove non-conservative-GC code path.
(KJS::ObjectImp::putDirect): Ditto.
(KJS::error): Added. Function in the new SPI style to create an error object.
* kjs/internal.h: Added the new number-constructing functions as friends of NumberImp.
There may be a more elegant way to do this later; what's important now is the new SPI.
* kjs/collector.h: Remove non-conservative-GC code path and also take out some
unneeded APPLE_CHANGES.
* bindings/runtime_root.cpp:
(KJS::Bindings::addNativeReference): Remove non-conservative-GC code path.
(KJS::Bindings::removeNativeReference): Ditto.
(RootObject::removeAllNativeReferences): Ditto.
* bindings/runtime_root.h:
(KJS::Bindings::RootObject::~RootObject): Ditto.
(KJS::Bindings::RootObject::setRootObjectImp): Ditto.
* kjs/collector.cpp:
(KJS::Collector::allocate): Ditto.
(KJS::Collector::collect): Ditto.
(KJS::Collector::numGCNotAllowedObjects): Ditto.
(KJS::Collector::numReferencedObjects): Ditto.
(KJS::Collector::rootObjectClasses): Ditto.
* kjs/internal.cpp:
(NumberImp::create): Ditto.
(InterpreterImp::globalInit): Ditto.
(InterpreterImp::globalClear): Ditto.
* kjs/list.cpp:
(KJS::List::markProtectedLists): Ditto.
(KJS::List::clear): Ditto.
(KJS::List::append): Ditto.
* kjs/list.h:
(KJS::List::List): Ditto.
(KJS::List::deref): Ditto.
(KJS::List::operator=): Ditto.
* kjs/protect.h:
(KJS::gcProtect): Ditto.
(KJS::gcUnprotect): Ditto.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9145
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mjs [Mon, 9 May 2005 21:03:25 +0000 (21:03 +0000)]
Reviewed by Kevin.
- remove code for DoNotStayInBlock variant of upstream/downstream and make
the methods take no parameters
* khtml/editing/htmlediting.cpp:
(khtml::CompositeEditCommand::deleteInsignificantTextDownstream):
(khtml::CompositeEditCommand::moveParagraphContentsToNewBlockIfNecessary):
(khtml::ApplyStyleCommand::applyRelativeFontStyleChange):
(khtml::ApplyStyleCommand::applyInlineStyle):
(khtml::ApplyStyleCommand::removeInlineStyle):
(khtml::ApplyStyleCommand::nodeFullySelected):
(khtml::ApplyStyleCommand::nodeFullyUnselected):
(khtml::DeleteSelectionCommand::initializePositionData):
(khtml::DeleteSelectionCommand::fixupWhitespace):
(khtml::InsertLineBreakCommand::insertNodeAfterPosition):
(khtml::InsertLineBreakCommand::insertNodeBeforePosition):
(khtml::InsertLineBreakCommand::doApply):
(khtml::InsertParagraphSeparatorCommand::doApply):
(khtml::InsertParagraphSeparatorInQuotedContentCommand::doApply):
(khtml::InsertTextCommand::prepareForTextInsertion):
(khtml::InsertTextCommand::input):
(khtml::InsertTextCommand::insertSpace):
(khtml::ReplaceSelectionCommand::doApply):
* khtml/editing/selection.cpp:
(khtml::Selection::toRange):
(khtml::Selection::validate):
* khtml/editing/visible_position.cpp:
(khtml::VisiblePosition::previousVisiblePosition):
(khtml::VisiblePosition::nextVisiblePosition):
(khtml::VisiblePosition::downstreamDeepEquivalent):
(khtml::isFirstVisiblePositionInParagraph):
(khtml::isFirstVisiblePositionInBlock):
(khtml::isLastVisiblePositionInParagraph):
* khtml/xml/dom2_rangeimpl.cpp:
(DOM::RangeImpl::editingStartPosition):
* khtml/xml/dom_position.cpp:
(DOM::isStreamer):
(DOM::Position::upstream):
(DOM::Position::downstream):
(DOM::Position::leadingWhitespacePosition):
(DOM::Position::trailingWhitespacePosition):
* khtml/xml/dom_position.h:
* kwq/WebCoreBridge.mm:
(-[WebCoreBridge smartDeleteRangeForProposedRange:]):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9144
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
cblu [Mon, 9 May 2005 20:31:04 +0000 (20:31 +0000)]
Turned assertion into error message to prevent crash when encountering this bug:
<rdar://problem/
4067625> connection:willCacheResponse: is called inside of [NSURLConnection initWithRequest:delegate:]
* WebView.subproj/WebBaseResourceHandleDelegate.h:
* WebView.subproj/WebBaseResourceHandleDelegate.m:
(-[WebBaseResourceHandleDelegate loadWithRequest:]): set flag to track when we're initializing the connection
(-[WebBaseResourceHandleDelegate connection:willCacheResponse:]): log error
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9143
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mjs [Mon, 9 May 2005 19:04:29 +0000 (19:04 +0000)]
Reviewed by Dave Harrison.
- remove remaining uses of upstream/downstream DoNotStayInBlock
* khtml/editing/htmlediting.cpp:
(khtml::CompositeEditCommand::moveParagraphContentsToNewBlockIfNecessary):
(khtml::ApplyStyleCommand::nodeFullySelected):
(khtml::ApplyStyleCommand::nodeFullyUnselected):
(khtml::DeleteSelectionCommand::insertPlaceholderForAncestorBlockContent):
(khtml::InsertParagraphSeparatorCommand::doApply):
(khtml::InsertParagraphSeparatorInQuotedContentCommand::doApply):
(khtml::InsertTextCommand::insertSpace):
(khtml::ReplaceSelectionCommand::doApply):
* khtml/editing/visible_position.cpp:
(khtml::enclosingBlockFlowElement): New helper function.
* khtml/editing/visible_position.h:
* khtml/editing/visible_units.cpp:
(khtml::inSameBlock): Check enclosing block flows instead of comparing
visible block starts. Two nested blocks may have the same visible start but
different visible ends, so the old check would give false positives.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9142
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
harrison [Mon, 9 May 2005 19:01:19 +0000 (19:01 +0000)]
Add layout test for <rdar://problem/
4110366>.
* layout-tests/editing/deleting/delete-at-paragraph-boundaries-011-expected.txt: Added.
* layout-tests/editing/deleting/delete-at-paragraph-boundaries-011.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9141
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
cblu [Mon, 9 May 2005 18:46:43 +0000 (18:46 +0000)]
Workaround gcc 3.3 internal compiler errors.
Reviewed by darin.
* bindings/objc/WebScriptObject.mm:
(-[WebScriptObject stringRepresentation]): call [NSString stringWithCString:encoding] rather than using @""
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9140
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Mon, 9 May 2005 16:23:20 +0000 (16:23 +0000)]
- checked in a result for the Flash replacement test that Dave added
* layout-tests/fast/dynamic/flash-replacement-test-expected.txt: Added.
Hope it's right! If not, Dave can update it.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9139
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Mon, 9 May 2005 16:10:46 +0000 (16:10 +0000)]
top level:
* Makefile.am: Don't set up PBXIntermediatesDirectory explicitly;
Not needed to make builds work, spews undesirable error messages too.
* configure.in: Ditto.
Tools:
* CommitLogEditor/Makefile.am: Don't set up PBXIntermediatesDirectory explicitly;
Not needed to make builds work, spews undesirable error messages too.
* HotSpotFinder/Makefile.am: Ditto.
* jst/Makefile.am: Ditto.
JavaScriptCore:
* Makefile.am: Don't set up PBXIntermediatesDirectory explicitly;
Not needed to make builds work, spews undesirable error messages too.
Tests:
* Makefile.am: Don't set up PBXIntermediatesDirectory explicitly;
Not needed to make builds work, spews undesirable error messages too.
* TestBindingsPlugin/Makefile.am: Ditto.
WebCore:
* Makefile.am: Don't set up PBXIntermediatesDirectory explicitly;
Not needed to make builds work, spews undesirable error messages too.
* WebCore.pbproj/project.pbxproj: Remove unneeded $(DSTROOT) in framework paths.
WebKit:
* Makefile.am: Don't set up PBXIntermediatesDirectory explicitly;
Not needed to make builds work, spews undesirable error messages too.
WebBrowser:
* Makefile.am: Don't set up PBXIntermediatesDirectory explicitly;
Not needed to make builds work, spews undesirable error messages too.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9138
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mjs [Sun, 8 May 2005 21:02:57 +0000 (21:02 +0000)]
Reviewed by Kevin.
- remove some of the uses of upstream/downstream DoNotStayInBlock
* khtml/editing/markup.cpp:
(khtml::createMarkup): Instead of using upstream to decide if a line break should be
added at the end, use inSameParagraph.
* khtml/editing/selection.cpp:
(khtml::Selection::debugPosition): Remove the code to print upstream and downstream,
the selection endpoints themselves are adequate for debugging and are what we use for
layout tests.
* khtml/xml/dom2_rangeimpl.cpp:
(DOM::RangeImpl::editingStartPosition): Skip a possible paragraph break at the start
of the selection in a more explicit way to avoid DoNotStayInBlock.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9137
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
harrison [Sat, 7 May 2005 17:37:41 +0000 (17:37 +0000)]
Reviewed by John.
<rdar://problem/
4110366> Deleting text at the end of email moves insertion point to the top of the document
* khtml/editing/htmlediting.cpp:
(khtml::DeleteSelectionCommand::handleGeneralDelete):
Update m_upstreamStart when deleting m_downstreamEnd.node() if the former is no longer in the document.
Better to update here than trying to recover later in calculateEndingPosition().
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9133
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
harrison [Sat, 7 May 2005 12:24:48 +0000 (12:24 +0000)]
Remove workaround for <rdar://problem/
4103339>.
* khtml/editing/htmlediting.cpp:
(khtml::DeleteSelectionCommand::initializePositionData):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9132
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mjs [Sat, 7 May 2005 07:02:35 +0000 (07:02 +0000)]
Reviewed by Dave Harrison.
- make StayInBlock vs DoNotStayInBlock explicit in all calls to
upstream/downstream, in preparation for phasing out the
DoNotStayInBlock variant.
* khtml/editing/htmlediting.cpp:
(khtml::ApplyStyleCommand::nodeFullySelected):
(khtml::ApplyStyleCommand::nodeFullyUnselected):
(khtml::DeleteSelectionCommand::insertPlaceholderForAncestorBlockContent):
(khtml::InsertParagraphSeparatorInQuotedContentCommand::doApply):
(khtml::InsertTextCommand::insertSpace):
(khtml::ReplaceSelectionCommand::doApply):
* khtml/editing/markup.cpp:
(khtml::createMarkup):
* khtml/editing/selection.cpp:
(khtml::Selection::debugPosition):
* khtml/xml/dom_position.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9131
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
harrison [Sat, 7 May 2005 00:45:31 +0000 (00:45 +0000)]
Reviewed by Maciej, Darin.
<rdar://problem/
4103339> VisiblePosition and PositionIterator iterators do not return positions in order
* WebCore.pbproj/project.pbxproj:
Removed dom_positioniterator.h and dom_positioniterator.cpp.
* khtml/editing/htmlediting.cpp:
Removed unused include of dom_positioniterator.h and "using" of PositionIterator.
* khtml/editing/selection.cpp:
Removed unused include of dom_positioniterator.h.
* khtml/editing/visible_position.h:
* khtml/editing/visible_position.cpp:
(khtml::VisiblePosition::previousVisiblePosition):
(khtml::VisiblePosition::nextVisiblePosition):
(khtml::VisiblePosition::downstreamDeepEquivalent):
Use Position::next(), Position::previous(), Position::atStart(), Position::atEnd() instead of duplicated code.
* khtml/xml/dom_nodeimpl.h:
* khtml/xml/dom_nodeimpl.cpp:
(NodeImpl::maxDeepOffset):
Added to support Position::next(), Position::previous(), Position::atStart(), Position::atEnd()
* khtml/xml/dom_position.h:
* khtml/xml/dom_position.cpp:
(DOM::Position::previous):
(DOM::Position::next):
(DOM::Position::atStart):
(DOM::Position::atEnd):
Moved here, replacing VisiblePosition's duplicate and PositionIterator. Fixed to
return positions in order and not skip positions.
(DOM::Position::previousCharacterPosition):
(DOM::Position::nextCharacterPosition):
Use Position::next(), Position::previous(), Position::atStart(), Position::atEnd() instead of PositionIterator.
(DOM::isStreamer):
(DOM::Position::upstream):
(DOM::Position::downstream):
Use Position::next(), Position::previous(), Position::atStart(), Position::atEnd() instead of PositionIterator.
* khtml/xml/dom_positioniterator.cpp: Removed.
* khtml/xml/dom_positioniterator.h: Removed.
Removed in favor of Position::next(), Position::previous(), Position::atStart(), Position::atEnd()
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9130
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mjs [Fri, 6 May 2005 20:40:55 +0000 (20:40 +0000)]
Reviewed by Darin.
<rdar://problem/
4058167> Unit Converter and Weather widgets crashed in KJS::Collector::markCurrentThreadConservatively
Avoid possibly allocating new prototype objects as parameters to
superclass constructors - there may be an allocated but
uninitilized object so this is a bad time to allocate. Instead,
set the prototype in the constructor body, since the object is
happily allocated by then.
* khtml/ecma/kjs_binding.h:
* khtml/ecma/kjs_css.cpp:
(DOMCSSStyleDeclaration::DOMCSSStyleDeclaration):
(DOMMediaList::DOMMediaList):
(DOMCSSStyleSheet::DOMCSSStyleSheet):
(DOMCSSPrimitiveValue::DOMCSSPrimitiveValue):
(DOMCSSValueList::DOMCSSValueList):
* khtml/ecma/kjs_css.h:
(KJS::DOMStyleSheet::DOMStyleSheet):
(KJS::DOMCSSValue::DOMCSSValue):
* khtml/ecma/kjs_dom.cpp:
(DOMNode::DOMNode):
(DOMDocument::DOMDocument):
(DOMElement::DOMElement):
(DOMDOMImplementation::DOMDOMImplementation):
(DOMNamedNodeMap::DOMNamedNodeMap):
(DOMNamedNodesCollection::DOMNamedNodesCollection):
(DOMCharacterData::DOMCharacterData):
(DOMText::DOMText):
* khtml/ecma/kjs_dom.h:
(KJS::NodeConstructor::NodeConstructor):
(KJS::DOMExceptionConstructor::DOMExceptionConstructor):
* khtml/ecma/kjs_events.cpp:
(DOMEvent::DOMEvent):
(Clipboard::Clipboard):
* khtml/ecma/kjs_html.cpp:
(HTMLCollection::HTMLCollection):
* khtml/ecma/kjs_range.cpp:
(DOMRange::DOMRange):
* khtml/ecma/kjs_traversal.cpp:
(DOMNodeIterator::DOMNodeIterator):
(DOMNodeFilter::DOMNodeFilter):
(DOMTreeWalker::DOMTreeWalker):
* khtml/ecma/xmlhttprequest.cpp:
(KJS::XMLHttpRequest::XMLHttpRequest):
* khtml/ecma/xmlserializer.cpp:
(KJS::XMLSerializer::XMLSerializer):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9129
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Fri, 6 May 2005 19:39:06 +0000 (19:39 +0000)]
top level:
Reviewed by Maciej.
- make building multiple trees with make work better
* configure.in: Update code to set up Xcode build directory instead of setting the
Project Builder build directory.
* Makefile.am: Set up Xcode build directory before invoking xcodebuild.
Tools:
Reviewed by Maciej.
- make building multiple trees with make work better
* CommitLogEditor/Makefile.am: Set up Xcode build directory before invoking xcodebuild.
* HotSpotFinder/Makefile.am: Set up Xcode build directory before invoking xcodebuild.
* jst/Makefile.am: Set up Xcode build directory before invoking xcodebuild.
JavaScriptCore:
Reviewed by Maciej.
- make building multiple trees with make work better
* Makefile.am: Set up Xcode build directory before invoking xcodebuild.
Tests:
Reviewed by Maciej.
- make building multiple trees with make work better
* Makefile.am: Set up Xcode build directory before invoking xcodebuild.
* TestBindingsPlugin/Makefile.am: Set up Xcode build directory before invoking xcodebuild.
WebCore:
Reviewed by Maciej.
- make building multiple trees with make work better
* Makefile.am: Set up Xcode build directory before invoking xcodebuild.
WebKit:
Reviewed by Maciej.
- make building multiple trees with make work better
* Makefile.am: Set up Xcode build directory before invoking xcodebuild.
WebBrowser:
Reviewed by Maciej.
- make building multiple trees with make work better
* Makefile.am: Set up Xcode build directory before invoking xcodebuild.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9128
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
hyatt [Thu, 5 May 2005 20:24:45 +0000 (20:24 +0000)]
Eliminate the FOUCS on wired.com. innerWidth and innerHeight on window should not do a layout that ignores
pending stylesheets, since even if stylesheets are loading the correct window dimensions can be determined with
a normal layout.
The radar # is
4109888.
Reviewed by rjw
* khtml/ecma/kjs_window.cpp:
(Window::get):
(Window::updateLayout):
* khtml/ecma/kjs_window.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9127
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
hyatt [Thu, 5 May 2005 18:35:22 +0000 (18:35 +0000)]
Fix for
4109667, sIFR flash replacement technique often malfunctions. This bug occurs when the plugin
widget update causes the onload for the document to fire. Because you can be in the middle of a style
recalc when doing an attach (in response to a stylesheet load), the onload fires in the middle of the attach
process when the tree is in a bogus state.
The fix is to add a bit to the document that tells style recalc that the implicitClose() method was invoked
during the style recalc process and the code has been patched so that when this situation occurs, the close is
deferred until after the style recalc has finished.
Reviewed by John Sullivan
* khtml/xml/dom_docimpl.cpp:
(DocumentImpl::DocumentImpl):
(DocumentImpl::recalcStyle):
(DocumentImpl::implicitClose):
* khtml/xml/dom_docimpl.h:
* layout-tests/fast/dynamic/flash-replacement-test.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9126
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Thu, 5 May 2005 17:55:06 +0000 (17:55 +0000)]
Reviewed by Dave Hyatt.
- fixed <rdar://problem/
4109564> REGRESSION (Atlanta): maps.google.com doesn't always center California correctly
* khtml/ecma/kjs_events.cpp: (offsetFromTarget): Fix two places that said X where they should say Y.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9119
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
harrison [Thu, 5 May 2005 17:01:07 +0000 (17:01 +0000)]
Reviewed by me.
Restore fixed setEndingSelection. Fixed method was ifdef'd out
because change was at end of Tiger development, but method is
unused. You just can never be _too_ safe.
* khtml/editing/htmlediting.cpp:
(khtml::EditCommandPtr::setEndingSelection):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9118
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mjs [Thu, 5 May 2005 06:04:06 +0000 (06:04 +0000)]
Reviewed by Vicki.
- renamed NodeBaseImpl to ContainerNodeImpl
* khtml/ecma/kjs_dom.cpp:
(DOMNodeProtoFunc::tryCall): Avoid use of NodeBaseImpl and avoid
use of obsolete checkNoOwner call, use isAncestor instead.
* khtml/html/html_elementimpl.cpp:
(HTMLElementImpl::setOuterText): Avoid gratuitous use of
NodeBaseImpl.
* khtml/xml/dom_nodeimpl.cpp:
(NodeBaseImpl::checkNoOwner): Removed.
Ther rest is all just simple renaming.
* khtml/xml/dom_docimpl.cpp:
(DocumentImpl::DocumentImpl):
(DocumentImpl::attach):
(DocumentImpl::detach):
(DocumentFragmentImpl::DocumentFragmentImpl):
* khtml/xml/dom_docimpl.h:
* khtml/xml/dom_elementimpl.cpp:
(AttrImpl::AttrImpl):
(ElementImpl::ElementImpl):
(ElementImpl::insertedIntoDocument):
(ElementImpl::removedFromDocument):
(ElementImpl::attach):
(ElementImpl::dump):
* khtml/xml/dom_elementimpl.h:
* khtml/xml/dom_nodeimpl.cpp:
(ContainerNodeImpl::ContainerNodeImpl):
(ContainerNodeImpl::~ContainerNodeImpl):
(ContainerNodeImpl::firstChild):
(ContainerNodeImpl::lastChild):
(ContainerNodeImpl::insertBefore):
(ContainerNodeImpl::replaceChild):
(ContainerNodeImpl::removeChild):
(ContainerNodeImpl::removeChildren):
(ContainerNodeImpl::appendChild):
(ContainerNodeImpl::hasChildNodes):
(ContainerNodeImpl::setFirstChild):
(ContainerNodeImpl::setLastChild):
(ContainerNodeImpl::checkSameDocument):
(ContainerNodeImpl::checkIsChild):
(ContainerNodeImpl::addChild):
(ContainerNodeImpl::attach):
(ContainerNodeImpl::detach):
(ContainerNodeImpl::insertedIntoDocument):
(ContainerNodeImpl::removedFromDocument):
(ContainerNodeImpl::cloneChildNodes):
(ContainerNodeImpl::getElementsByTagNameNS):
(ContainerNodeImpl::getUpperLeftCorner):
(ContainerNodeImpl::getLowerRightCorner):
(ContainerNodeImpl::getRect):
(ContainerNodeImpl::setFocus):
(ContainerNodeImpl::setActive):
(ContainerNodeImpl::childNodeCount):
(ContainerNodeImpl::childNode):
(ContainerNodeImpl::dispatchChildInsertedEvents):
(ContainerNodeImpl::dispatchChildRemovalEvents):
* khtml/xml/dom_nodeimpl.h:
* khtml/xml/dom_xmlimpl.cpp:
(DOM::EntityImpl::EntityImpl):
(DOM::EntityReferenceImpl::EntityReferenceImpl):
(DOM::NotationImpl::NotationImpl):
(DOM::ProcessingInstructionImpl::ProcessingInstructionImpl):
* khtml/xml/dom_xmlimpl.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9116
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mjs [Thu, 5 May 2005 00:29:30 +0000 (00:29 +0000)]
Reviewed by Darin.
<rdar://problem/
4086570> Crash in JavaScriptCore with RSS Visualizer
* kjs/internal.cpp:
(InterpreterImp::mark): mark staticNaN, it is usually protected by the Number
prototype but there is a small window where it can get collected.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9115
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
vicki [Thu, 5 May 2005 00:16:00 +0000 (00:16 +0000)]
Reviewed by Darin.
- fix mismatched parentheses in one of the ifdefs
* khtml/html/html_headimpl.cpp:
(HTMLTitleElementImpl::childrenChanged):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9112
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Thu, 5 May 2005 00:07:02 +0000 (00:07 +0000)]
Reviewed by Dave Hyatt.
- another gcc-4.0-related fix
* bindings/runtime_root.h: Take off extra namespace prefixes that apparently cause problems
compiling with gcc 4.0, although I have not observed the problems.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9110
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Wed, 4 May 2005 23:52:36 +0000 (23:52 +0000)]
Reviewed by Dave Hyatt.
- fixed layout tests
* WebKit.pbproj/project.pbxproj: Set deployment target to 10.3 in the build styles.
When built without a build style (by Apple B&I) we want to get the target from the
environment. But when built with a build style (by Safari engineers and others), we want
to use 10.3. Because our deployment target was not set, we ran into this bug:
<rdar://problem/
4108717> CTFontGetGlyphWithName doesn't work with some strings
* Makefile.am: Took out extra parameters that make command-line building different from
Xcode building. Now that this is fixed, you should not get a full rebuild if you switch
from command line to Xcode or back.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9109
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Wed, 4 May 2005 23:51:42 +0000 (23:51 +0000)]
Reviewed by Dave Hyatt.
- fixed build rules to match other projects
* WebCore.pbproj/project.pbxproj: Set deployment target to 10.3 in the build styles.
When built without a build style (by Apple B&I) we want to get the target from the
environment. But when built with a build style (by Safari engineers and others), we want
to use 10.3.
* Makefile.am: Took out extra parameters that make command-line building different from
Xcode building. Now that this is fixed, you should not get a full rebuild if you switch
from command line to Xcode or back.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9108
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Wed, 4 May 2005 23:50:05 +0000 (23:50 +0000)]
Reviewed by Dave Hyatt.
- fixed build rules to match other projects
* JavaScriptCore.pbproj/project.pbxproj: Set deployment target to 10.3 in the build styles.
When built without a build style (by Apple B&I) we want to get the target from the
environment. But when built with a build style (by Safari engineers and others), we want
to use 10.3.
* Makefile.am: Took out extra parameters that make command-line building different from
Xcode building. Now that this is fixed, you should not get a full rebuild if you switch
from command line to Xcode or back.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9107
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mjs [Wed, 4 May 2005 21:37:07 +0000 (21:37 +0000)]
- revert presumably accidental change to mozilla JS test expected results, this
was making the tests fail.
* tests/mozilla/expected.html:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9106
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
vicki [Wed, 4 May 2005 21:11:23 +0000 (21:11 +0000)]
Reviewed by darin.
- fixed <rdar://problem/
3986228> Not able to load additional script blocks dynamically
Run scripts when they're inserted into the document. Use createdByParser bit to make sure
that scripts aren't run twice, once while parsing and again when inserting.
* khtml/html/html_headimpl.cpp:
(HTMLScriptElementImpl::HTMLScriptElementImpl):
(HTMLScriptElementImpl::~HTMLScriptElementImpl):
(HTMLScriptElementImpl::insertedIntoDocument):
(HTMLScriptElementImpl::removedFromDocument):
(HTMLScriptElementImpl::notifyFinished):
* khtml/html/html_headimpl.h:
(DOM::HTMLScriptElementImpl::setCreatedByParser):
* khtml/html/htmlparser.cpp:
(KHTMLParser::getElement):
* khtml/xml/xml_tokenizer.cpp:
(khtml::XMLTokenizer::startElement):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9105
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
cblu [Wed, 4 May 2005 18:50:56 +0000 (18:50 +0000)]
Fixed:
<rdar://problem/
4078417> REGRESSION (125-412): MLB gameday page doesn't update (Flash)
<rdar://problem/
4072280> XMLHttpRequest calls onReadyStateChange callback with bogus status value
Reviewed by john.
Our WebKit-level caching of subresources "dumbed-down" information held in NSURLResponse. This caused some loads to lack response headers and thus disabling cache directives. Status codes were also not retained and this caused XMLHttpRequest to fail frequently. The fix is to have WebResource retain the NSURLResponse and to use the NSURLResponse when we decide to load from WebResources.
* WebCoreSupport.subproj/WebBridge.m:
(-[WebBridge objectLoadedFromCacheWithURL:response:data:]): call new [WebResource _initWithData:URL:response:]
* WebView.subproj/WebBaseResourceHandleDelegate.m:
(-[WebBaseResourceHandleDelegate _canUseResourceWithResponse:]): new, checks response cache directives
(-[WebBaseResourceHandleDelegate loadWithRequest:]): call _canUseResourceWithResponse:
(-[WebBaseResourceHandleDelegate saveResource]): call new [WebResource _initWithData:URL:response:]
* WebView.subproj/WebResource.m:
(-[WebResourcePrivate dealloc]):
(-[WebResource initWithData:URL:MIMEType:textEncodingName:frameName:]): call renamed _initWithData:URL:MIMEType:textEncodingName:frameName:response:copyData:
(-[WebResource initWithCoder:]): decode the NSURLReponse
(-[WebResource encodeWithCoder:]): encode the NSURLReponse
(-[WebResource _initWithData:URL:MIMEType:textEncodingName:frameName:response:copyData:]): take the NSURLReponse
(-[WebResource _initWithData:URL:response:]): new
(-[WebResource _initWithPropertyList:]): decode the NSURLReponse
(-[WebResource _propertyListRepresentation]): encode the NSURLReponse
(-[WebResource _response]): return ivar if we have one
* WebView.subproj/WebResourcePrivate.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9104
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
hyatt [Wed, 4 May 2005 00:16:31 +0000 (00:16 +0000)]
Fix build bustage.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9103
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
rjw [Wed, 4 May 2005 00:09:47 +0000 (00:09 +0000)]
Fixed <rdar://problem/
4102644> Crash in LiveConnect below KJS::Bindings::JavaInstance::stringValue() const
Correctly handle accessing nil objects from a Java object array.
Reviewed by John.
* bindings/jni/jni_runtime.cpp:
(JavaArray::valueAt):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9102
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
hyatt [Tue, 3 May 2005 23:08:02 +0000 (23:08 +0000)]
Normalize all our custom properties in our implementation to be -khtml (remove all the -apple).
Make sure that -apple, -khtml, and -moz are all able to be used. -apple and -moz just map to -khtml.
Add support for automatically converting -khtml-opacity to opacity (for legacy Safari 1.1 compat).
Reviewed by darin
* khtml/css/css_computedstyle.cpp:
(DOM::):
(DOM::CSSComputedStyleDeclarationImpl::getPropertyCSSValue):
* khtml/css/cssparser.cpp:
(CSSParser::parseValue):
* khtml/css/cssproperties.in:
* khtml/css/cssstyleselector.cpp:
(khtml::CSSStyleSelector::applyDeclarations):
(khtml::CSSStyleSelector::applyProperty):
* khtml/css/parser.y:
* khtml/ecma/kjs_css.cpp:
(cssPropertyName):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9101
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Tue, 3 May 2005 22:50:37 +0000 (22:50 +0000)]
- fix the build
* WebCore.pbproj/project.pbxproj: Fix some SYMROOTS that should have been SYMROOT.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9100
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
hyatt [Tue, 3 May 2005 21:46:40 +0000 (21:46 +0000)]
Fix for
4098281, news.com missing a bunch of content. Make sure not to apply strict SGML parsing
when stripping comments out of scripts.
New test is comments-in-script.html
* khtml/html/htmltokenizer.cpp:
(khtml::HTMLTokenizer::parseComment):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9099
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
hyatt [Tue, 3 May 2005 21:34:30 +0000 (21:34 +0000)]
Remove unused notification to avoid ERROR messages spewing on the acid2 test.
Reviewed by darin
* khtml/khtml_part.cpp:
(KHTMLPart::processObjectRequest):
* khtml/rendering/render_frames.cpp:
(RenderPartObject::updateWidget):
* khtml/rendering/render_frames.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9098
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
hyatt [Tue, 3 May 2005 20:57:01 +0000 (20:57 +0000)]
Adding acid2 test to layout tests.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9097
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Tue, 3 May 2005 20:55:32 +0000 (20:55 +0000)]
Reviewed by Dave Hyatt.
No new layout tests needed.
- eliminated the bogus kMin/kMax macros that we had in addition to inline functions
of the same name
* kwq/KWQKGlobal.h: Remove the kMin/kMax macros.
* khtml/css/cssstyleselector.cpp:
(khtml::CSSStyleSelector::applyProperty): Change type of constant so both sides
of kMin calls match.
(khtml::CSSStyleSelector::fontSizeForKeyword): Ditto.
* khtml/html/htmltokenizer.cpp: (khtml::HTMLTokenizer::parseEntity): Ditto.
- remove unused parameter to dirtyLinesFromChangedChild for clarity
* khtml/rendering/render_object.h: Don't take the parameter.
* khtml/rendering/render_object.cpp: (RenderObject::dirtyLinesFromChangedChild): Ditto.
* khtml/rendering/render_flow.h: Don't take the parameter.
* khtml/rendering/render_flow.cpp:
(RenderFlow::detach): Don't pass the parameter.
(RenderFlow::dirtyLinesFromChangedChild): Don't take the parameter.
* khtml/rendering/render_text.cpp: (RenderText::detach): Don't pass the parameter.
- convert DOM::NodeImpl into an abstract base class by making a couple of functions
pure virtual for clarity
* khtml/xml/dom_nodeimpl.h: Made nodeName and nodeType pure virtual.
* khtml/xml/dom_nodeimpl.cpp: Remove bodies of nodeName and nodeType.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9096
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
hyatt [Tue, 3 May 2005 20:47:27 +0000 (20:47 +0000)]
Fix for object element to support fallback content. WIth this change Safari passes the Acid2 test.
Reviewed by Maciej
* khtml/css/html4.css:
* khtml/html/html_objectimpl.cpp:
(HTMLObjectElementImpl::HTMLObjectElementImpl):
(HTMLObjectElementImpl::parseHTMLAttribute):
(HTMLObjectElementImpl::rendererIsNeeded):
(HTMLObjectElementImpl::createRenderer):
(HTMLObjectElementImpl::attach):
(HTMLObjectElementImpl::detach):
(HTMLObjectElementImpl::recalcStyle):
(HTMLObjectElementImpl::childrenChanged):
(HTMLObjectElementImpl::isURLAttribute):
(HTMLObjectElementImpl::isImageType):
(HTMLObjectElementImpl::renderFallbackContent):
* khtml/html/html_objectimpl.h:
* khtml/khtml_part.cpp:
(KHTMLPart::requestObject):
(KHTMLPart::selectFrameElementInParentIfFullySelected):
(KHTMLPart::handleFallbackContent):
* khtml/khtml_part.h:
* khtml/khtmlpart_p.h:
(khtml::ChildFrame::ChildFrame):
* khtml/rendering/render_frames.cpp:
(RenderPartObject::RenderPartObject):
(RenderPartObject::updateWidget):
* khtml/rendering/render_frames.h:
(khtml::RenderPart::hasFallbackContent):
* khtml/rendering/render_replaced.cpp:
(RenderReplaced::RenderReplaced):
* kwq/KWQKHTMLPart.mm:
(KWQKHTMLPart::createPart):
* kwq/WebCoreBridge.h:
* kwq/WebCoreBridge.mm:
(-[WebCoreBridge mainResourceError]):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9095
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
hyatt [Tue, 3 May 2005 20:44:35 +0000 (20:44 +0000)]
Fix object element support so that fallback content works. With this change Safari passes the Acid2 test.
Reviewed by Maciej
* WebCoreSupport.subproj/WebBridge.m:
(-[WebBridge determineObjectFromMIMEType:URL:]):
* WebView.subproj/WebDataSource.m:
(-[WebDataSource _receivedMainResourceError:complete:]):
* WebView.subproj/WebMainResourceClient.m:
(-[WebMainResourceClient continueAfterContentPolicy:response:]):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9094
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Tue, 3 May 2005 20:32:52 +0000 (20:32 +0000)]
* WebView.subproj/WebUIDelegate.h: Fixed incorrect comment.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9093
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Tue, 3 May 2005 01:17:08 +0000 (01:17 +0000)]
top level:
- move to Xcode native targets and stop checking in generated files
* configure.in: Removed gperf and yacc sections, and all the makefile paths for subdirectories
of JavaScriptCore and WebCore, since those directories no longer have makefiles.
Tools:
- move to Xcode native targets and stop checking in generated files
* CommitLogEditor/CommitLogEditor.pbproj/project.pbxproj: Updated to use native targets.
* CommitLogEditor/Info.plist: Added. Native targets use a separate file for this.
* HotSpotFinder/HotSpotFinder.pbproj/project.pbxproj: Updated to use native targets.
* HotSpotFinder/Info.plist: Added. Native targets use a separate file for this.
JavaScriptCore:
- move to Xcode native targets and stop checking in generated files
* JavaScriptCore.pbproj/project.pbxproj: Updated to use native targets and generate all the generated
files, so we don't have to check them in any more.
* Info.plist: Added. Native targets use a separate file for this.
* Makefile.am: Removed pcre and kjs SUBDIRS. Also removed code that deleted the embedded copy of this
framework, since we haven't been embedding it for some time.
* kjs/grammar_wrapper.cpp: Added. Shell used to compile grammar.cpp since we can't add a generated file
easily to the list of files to be compiled.
* kjs/.cvsignore: Removed.
* kjs/Makefile.am: Removed.
* kjs/array_object.lut.h: Removed.
* kjs/date_object.lut.h: Removed.
* kjs/grammar.cpp: Removed.
* kjs/grammar.cpp.h: Removed.
* kjs/grammar.h: Removed.
* kjs/lexer.lut.h: Removed.
* kjs/math_object.lut.h: Removed.
* kjs/number_object.lut.h: Removed.
* kjs/string_object.lut.h: Removed.
* pcre/.cvsignore: Removed.
* pcre/Makefile.am: Removed.
* pcre/chartables.c: Removed.
WebCore:
- move to Xcode native targets and stop checking in generated files
* WebCore.pbproj/project.pbxproj: Updated to use native targets and generate all the generated
files, so we don't have to check them in any more.
* Info.plist: Added. Native targets use a separate file for this.
* Makefile.am: Removed rule to generate WebCore-combined.exp since this is now handled by the
Xcode project. Removed the code to remove the embedded copy of the framework since we don't
do that any more. Removed timestamp cleaning rules since we don't use those any more.
* WebCore-tests.exp: Removed symbols that aren't really needed. The native target gives an
error when you mention a nonexistent symbol, so we can't have them any more.
* khtml/css/parser_wrapper.cpp: Added. Shell used to compile parser.cpp since we can't add
a generated file easily to the list of files to be compiled.
* .cvsignore: Removed various timestamp files.
* WebCore-combined.exp: Removed.
* force-clean-timestamp: Removed.
* force-js-clean-timestamp: Removed.
* khtml/.cvsignore: Removed.
* khtml/Makefile.am: Removed.
* khtml/css/.cvsignore: Removed.
* khtml/css/Makefile.am: Removed.
* khtml/css/cssproperties.c: Removed.
* khtml/css/cssproperties.h: Removed.
* khtml/css/cssvalues.c: Removed.
* khtml/css/cssvalues.h: Removed.
* khtml/css/parser.cpp: Removed.
* khtml/css/parser.h: Removed.
* khtml/css/tokenizer.cpp: Removed.
* khtml/ecma/.cvsignore: Removed.
* khtml/ecma/Makefile.am: Removed.
* khtml/ecma/kjs_css.lut.h: Removed.
* khtml/ecma/kjs_dom.lut.h: Removed.
* khtml/ecma/kjs_events.lut.h: Removed.
* khtml/ecma/kjs_html.lut.h: Removed.
* khtml/ecma/kjs_navigator.lut.h: Removed.
* khtml/ecma/kjs_range.lut.h: Removed.
* khtml/ecma/kjs_traversal.lut.h: Removed.
* khtml/ecma/kjs_views.lut.h: Removed.
* khtml/ecma/kjs_window.lut.h: Removed.
* khtml/ecma/xmlhttprequest.lut.h: Removed.
* khtml/ecma/xmlserializer.lut.h: Removed.
* khtml/html/.cvsignore: Removed.
* khtml/html/Makefile.am: Removed.
* khtml/html/doctypes.cpp: Removed.
* khtml/html/kentities.c: Removed.
* khtml/misc/.cvsignore: Removed.
* khtml/misc/Makefile.am: Removed.
* khtml/misc/htmlattrs.c: Removed.
* khtml/misc/htmlattrs.h: Removed.
* khtml/misc/htmltags.c: Removed.
* khtml/misc/htmltags.h: Removed.
* kwq/.cvsignore: Removed.
* kwq/KWQCharsetData.c: Removed.
* kwq/KWQColorData.c: Removed.
* kwq/Makefile.am: Removed.
WebKit:
- move to Xcode native targets and stop checking in generated files
* WebKit.pbproj/project.pbxproj: Updated to use native targets and generate all the generated
files, so we don't have to check them in any more.
* Info.plist: Added. Native targets use a separate file for this.
* Plugins.subproj/npapi.m: Fixed import statement to get npapi.h from <WebKit/> rather than current directory.
* Makefile.am: Removed timestamp cleaning rules since we don't use it any more.
* .cvsignore: Removed various timestamp files.
* DOM.subproj/DOM-compat.h: Removed.
* DOM.subproj/DOM.h: Removed.
* DOM.subproj/DOMCSS.h: Removed.
* DOM.subproj/DOMCore.h: Removed.
* DOM.subproj/DOMEvents.h: Removed.
* DOM.subproj/DOMExtensions.h: Removed.
* DOM.subproj/DOMHTML.h: Removed.
* DOM.subproj/DOMPrivate.h: Removed.
* DOM.subproj/DOMRange.h: Removed.
* DOM.subproj/DOMStylesheets.h: Removed.
* DOM.subproj/DOMTraversal.h: Removed.
* DOM.subproj/DOMViews.h: Removed.
* Plugins.subproj/WebScriptObject.h: Removed.
* Plugins.subproj/npapi.h: Removed.
* Plugins.subproj/npruntime.h: Removed.
* copy-webcore-files-to-webkit: Removed.
* embed-frameworks.sh: Removed.
* force-clean-timestamp: Removed.
WebBrowser:
- move to Xcode native targets and stop checking in generated files
* WebBrowser.pbproj/project.pbxproj: Updated to use native target.
* Info.plist: Added. Native targets use a separate file for this.
* .cvsignore: Took out .DS_Store, since that's always ignored server-wide.
* English.lproj/.cvsignore: Removed.
* Preferences.subproj/.cvsignore: Removed.
* Resources/.cvsignore: Removed.
* Resources/Images/.cvsignore: Removed.
WebKitExamples:
- move to Xcode native targets and stop checking in generated files
* Blot/Blot.xcode/project.pbxproj: Updated to use a native target.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9092
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Mon, 2 May 2005 23:05:29 +0000 (23:05 +0000)]
Fix layout test paths.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9091
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Mon, 2 May 2005 18:39:16 +0000 (18:39 +0000)]
Reviewed by Vicki.
Added two layout tests for regression testing.
- redid frameElement (fix for
4091082 below)
The first version lacked a security check, and was also broken.
* khtml/ecma/kjs_window.cpp:
(frameElement): Refactored into separate function; added isSafeScript check.
(Window::get): Call the new frameElement function.
* fast/frames/frameElement-frame.html: Added.
* fast/frames/frameElement-frame-expected.txt: Added.
* fast/frames/frameElement-iframe.html: Added.
* fast/frames/frameElement-iframe-expected.txt: Added.
* fast/frames/resources/frameElement-contents.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9086
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
harrison [Mon, 2 May 2005 17:11:26 +0000 (17:11 +0000)]
Reviewed by Vicki.
Fix isStartOfEditableContent and isEndOfEditableContent to return actual, rather than inverted, answers.
No Radar. Found this when trying to use isEndOfEditableContent() in some new code.
* khtml/editing/visible_units.cpp:
(khtml::isStartOfEditableContent):
(khtml::isEndOfEditableContent):
Flip expressions.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9085
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Fri, 29 Apr 2005 22:34:24 +0000 (22:34 +0000)]
Reviewed by David Harrison.
* khtml/xml/dom_nodeimpl.cpp: (NodeImpl::displayNode): Turn newlines into \n for better dumping.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9084
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
harrison [Fri, 29 Apr 2005 20:13:42 +0000 (20:13 +0000)]
Reviewed by Darin.
<rdar://problem/
4083333> When deleting link at end of sentence, entire sentence gets deleted
* khtml/editing/htmlediting.cpp:
(khtml::DeleteSelectionCommand::initializePositionData):
Work around bug #
4103339 (whose real fix is somewhat risky), so this fix can get into a software update.
(khtml::DeleteSelectionCommand::handleGeneralDelete):
Add isAncestor check when comparing m_downstreamEnd.node() and m_startNode.
* layout-tests/editing/deleting/delete-
4083333-fix-expected.txt: Added.
* layout-tests/editing/deleting/delete-
4083333-fix.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9083
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Fri, 29 Apr 2005 19:10:13 +0000 (19:10 +0000)]
Reviewed by Dave Harrison.
- changed layout tests to dump more minimal information about caret and selection
* kwq/KWQRenderTreeDebug.cpp:
(nodePosition): Changed name; now does position relative to document.
(writeSelection): Removed upstream/downstream code and changed format slightly.
* layout-tests/editing/*-expected.txt: Regenerated in new format.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9082
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Fri, 29 Apr 2005 17:28:54 +0000 (17:28 +0000)]
Reviewed by Chris Blumenberg.
Added two layout tests for regression testing.
- fixed <rdar://problem/
4097849> REGRESSION (162-163): importNode creates non-HTML elements, thus style attributes (and some others) don't work
* khtml/xml/dom_docimpl.cpp:
(DocumentImpl::importNode): Reorganized and partly rewrote this. The change that fixes the bug at
hand is to explicitly use XHTML_NAMESPACE for HTML elements, since the old way of getting the namespace
will return the null string for HTML elements, and createElementNS will not create an HTML element
if passed a null string for the namespace.
(DocumentImpl::processHttpEquiv): Removed some bogus getDocument() calls -- no need to call getDocument()
in a document object.
(DocumentImpl::attrName): Ditto.
(DocumentImpl::tagName): Ditto.
(DocumentImpl::setFocusNode): Ditto.
* khtml/html/html_elementimpl.cpp: (HTMLElementImpl::cloneNode): Moved the actual cloning here
from ElementImpl::cloneNode, because XMLElementImpl already had its own version, and in here
we can use createHTMLElement, which will work properly even in an XML document, and is also slightly
more efficient.
* khtml/xml/dom_nodeimpl.h: Added a namespaceURI method function to go along with localName.
* khtml/xml/dom_nodeimpl.cpp: (NodeImpl::namespaceURI): Added. Returns null string to be consistent
with localName (only works on certain types of elements as documented).
* khtml/xml/dom_elementimpl.h: Removed ElementImpl::cloneNode (see above). Added an override of
namespaceURI for XMLElementImpl.
* khtml/xml/dom_elementimpl.cpp: (XMLElementImpl::namespaceURI): Added. Returns the namespace
(consistent with localName).
* layout-tests/fast/dom/importNodeHTML.html: Added. Tests both importNode and cloneNode (for comparison).
* layout-tests/fast/dom/importNodeHTML-expected.txt: Added.
* layout-tests/fast/dom/importNodeXML.xhtml: Added. XML version of the same test as above. Tests a different
code path, so useful to have.
* layout-tests/fast/dom/importNodeXML-expected.txt: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9081
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Fri, 29 Apr 2005 01:13:11 +0000 (01:13 +0000)]
Reviewed by Maciej.
- fixed problems preventing us from compiling with gcc 4.0
* WebKit.pbproj/project.pbxproj: Removed -fobjc-exceptions because I can't figure out an easy
way to pass it only when compiling Objective-C/C++. Removed -Wmissing-prototypes from
WARNING_CPLUSPLUSFLAGS since it's now a C-only warning.
* History.subproj/WebHistoryItem.m: (-[WebHistoryItem pageCache]): Changed return type
to match the declaration.
* WebCoreSupport.subproj/WebBridge.m: (-[WebBridge _retrieveKeyboardUIModeFromPreferences:]):
Fixed a BOOL that should have been a Boolean.
* WebCoreSupport.subproj/WebTextRenderer.m: Removed redundant copy of ROUND_TO_INT, also in
a WebCore header.
(-[WebTextRenderer _computeWidthForSpace]): Had to add cast because of difference in type of
ROUND_TO_INT vs. CEIL_TO_INT.
(pathFromFont): Added a cast to convert UInt8 * to char *.
* WebView.subproj/WebFrameView.m:
(-[WebFrameView _setDocumentView:]): Fixed parameter type to match the declaration.
(-[WebFrameView documentView]): Fixed return type to match the declaration.
* WebView.subproj/WebHTMLView.m:
(-[WebHTMLView _startDraggingImage:at:operation:event:sourceIsDHTML:DHTMLWroteData:]):
Initialized a variable to quiet an incorrect gcc 4.0 uninitialized variable warning.
(-[WebHTMLView deleteToMark:]): Switched from @try style to NS_DURING style of exception handler
because we can't pass -fobjc-exceptions just to Objective-C at the moment (see above).
(-[WebHTMLView selectToMark:]): Ditto.
(-[WebHTMLView swapWithMark:]): Ditto.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9080
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Fri, 29 Apr 2005 00:31:01 +0000 (00:31 +0000)]
Reviewed by Dave Harrison.
- fixed problems preventing us from compiling with gcc 4.0
* WebCore.pbproj/project.pbxproj: Removed -fobjc-exceptions because I can't figure out an easy
way to pass it only when compiling Objective-C/C++. Removed -Wmissing-prototypes from
WARNING_CPLUSPLUSFLAGS since it's now a C-only warning.
* khtml/css/parser.y: Changed some rules that were using a float to pass around an enum to use an
int instead to avoid a warning.
* khtml/css/parser.cpp: Regenerated.
* khtml/css/parser.h: Regenerated.
* khtml/ecma/kjs_dom.cpp: (DOMTextProtoFunc::tryCall): Rearranged a return statement to avoid an incorrect
warning.
* khtml/ecma/kjs_html.cpp: (KJS::Context2DFunction::tryCall): Initialized a couple of variables to avoid
an incorrect warning.
* khtml/ecma/kjs_proxy.cpp: (KJSProxyImpl::evaluate): Rearranged how we exit from the function to avoid
an incorret warning.
* khtml/editing/selection.cpp: (khtml::Selection::debugPosition): Changed some %d to %ld where the
parameters where long ints.
* khtml/editing/visible_position.cpp: (khtml::VisiblePosition::debugPosition): Ditto.
* khtml/xml/dom_position.cpp: (DOM::Position::debugPosition): Ditto.
* kwq/DOMEvents.mm: (-[DOMMouseEvent initMouseEvent:::::::::::::::]): Rearranged code to avoid a cast
that was causing an incorrect warning.
* kwq/DOMUtility.mm:
(createObjCDOMNode): Broke out as a separate function.
(KJS::ScriptInterpreter::createObjcInstanceForValue): Rearranged code to avoid a namespace collision with
KJS::DOMNode and the Objective-C DOMNode class.
* kwq/KWQFileButton.mm: Made fields of KWQFileButtonAdapter public to avoid an error, new to gcc 4.0,
about accessing protected Objective-C fields.
* kwq/KWQKHTMLPart.mm:
(KWQKHTMLPart::matchLabelsAgainstElement): Rearranged a return statement to avoid an incorrect warning.
(KWQKHTMLPart::imageFromRect): Rearranged how this function does its exception handling to avoid a
"may be clobbered" warning.
* kwq/KWQKJavaAppletWidget.mm: Fixed incorrect import that said "KHTMLView.h" instead of "khtmlview.h".
* kwq/KWQObject.mm: Made fields of KWQObjectTimerTarget public to avoid an error, new to gcc 4.0,
about accessing protected Objective-C fields.
* kwq/WebCoreBridge.mm: (partHasSelection): Used [bridge part] instead of getting directly at instance
variable to avoid an error, new to gcc 4.0, about accessing protected Objective-C fields.
* WebCore-combined.exp: Regenerated.
* WebCore-tests.exp: Added some additional symbols needed by the tests under gcc 4.0.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9079
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Fri, 29 Apr 2005 00:22:55 +0000 (00:22 +0000)]
Reviewed by Dave Harrison.
- fixed problems preventing us from compiling with gcc 4.0
* JavaScriptCore.pbproj/project.pbxproj: Removed -Wmissing-prototypes from
WARNING_CPLUSPLUSFLAGS since it's now a C-only warning.
* bindings/jni/jni_jsobject.cpp:
(JSObject::getSlot): Changed some %d to %ld where the parameters where long ints.
(JSObject::setSlot): Ditto.
* bindings/jni/jni_utility.cpp:
(KJS::Bindings::getJavaVM): Ditto.
(KJS::Bindings::getJNIEnv): Ditto.
* bindings/objc/objc_utility.mm: Fixed include of <JavascriptCore/internal.h> that needed the
letter "S" capitalized.
* kjs/bool_object.cpp: (BooleanProtoFuncImp::call): Rearranged how this function returns to
avoid incorrect gcc 4.0 warning.
* kjs/collector.cpp: (KJS::Collector::markStackObjectsConservatively): Changed code to check
the alignment of the passed-in pointers to only require pointer-level alignment, not 8-byte alignment.
Prevents a crash on garbage collect when compiled with gcc 4.0.
* kjs/nodes.cpp:
(WhileNode::execute): Added a redundant return after an infinite loop to work around incorrect gcc 4.0 warning.
(ForNode::execute): Ditto.
(SwitchNode::execute):Rearranged how this function returns to avoid incorrect gcc 4.0 warning.
(LabelNode::execute): Ditto.
* kjs/string_object.cpp: (replace): Ditto.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9078
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Fri, 29 Apr 2005 00:07:23 +0000 (00:07 +0000)]
Fix ChangeLog
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9077
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Fri, 29 Apr 2005 00:07:03 +0000 (00:07 +0000)]
* WebCore.pbproj/project.pbxproj: Add back the main_thread_malloc files, rolled out by accident.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9076
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
adele [Thu, 28 Apr 2005 01:04:59 +0000 (01:04 +0000)]
Rolling out fix for <rdar://problem/
4097849> because the following layout tests were failing:
fast/css/namespaces/001
fast/css/namespaces/002
fast/css/namespaces/004
fast/css/namespaces/005
fast/css/namespaces/006
fast/overflow/003
* khtml/html/html_documentimpl.cpp:
* khtml/html/html_documentimpl.h:
* khtml/html/html_elementimpl.cpp:
(HTMLElementImpl::namespaceURI):
* khtml/xml/dom_docimpl.cpp:
(DocumentImpl::importNode):
(DocumentImpl::createElementNS):
(DocumentImpl::createHTMLElement):
(DocumentImpl::attrId):
(DocumentImpl::tagId):
* khtml/xml/dom_docimpl.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9075
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
vicki [Thu, 28 Apr 2005 01:03:24 +0000 (01:03 +0000)]
one more tweak
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9073
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
vicki [Thu, 28 Apr 2005 00:06:31 +0000 (00:06 +0000)]
WebCore-413.1
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9072
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
sullivan [Wed, 27 Apr 2005 21:34:35 +0000 (21:34 +0000)]
Reviewed by Darin.
Experimental prototype of user-resizable textareas. All the new code is guarded by
#if ALLOW_RESIZING_TEXTAREAS, which is false unless you remove a comment and rebuild.
This code allows you to press near the bottom-right corner of any textarea and drag
to resize the textarea on the page. It works correctly with textareas in left-aligned
or centered blocks, but is weird in right-aligned blocks. It also does something
sensible if the width is specified as a % (in that case, you can resize vertically only).
The user-created-size survives resizing the window and survives the back/forward cache.
It does not survive reloading the page.
This complete-lack-of-affordance UI is obviously not shippable, but this proof of concept
code could lead to a real user feature.
* kwq/KWQTextArea.mm:
(-[KWQTextArea getNumColumns:andNumRows:forSize:]):
new method that determines cols and rows for a given textarea frame size
(-[KWQTextAreaTextView _trackResizeFromMouseDown:]):
new method that tracks a drag and does a live resize-and-relayout
(-[KWQTextAreaTextView mouseDown:]):
if the mouse down is in the bottom-right corner, call _trackResizeFromMouseDown:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9067
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
sullivan [Wed, 27 Apr 2005 21:32:26 +0000 (21:32 +0000)]
Reviewed by Adele.
- fixed problem with mouse wheel patch where alt and shift keys were switched
* khtml/xml/dom2_eventsimpl.h:
use the order cntl, alt, shift, meta in KeyboardEventImpl constructors to match
superclass. This isn't necessary to fix the bug, but is better for clarity.
* khtml/xml/dom2_eventsimpl.cpp:
(KeyboardEventImpl::KeyboardEventImpl):
switch parameter order to match superclass. Then pass the parameters to superclass's
constructor in the right order.
(KeyboardEventImpl::initKeyboardEvent):
Pass parameters to superclass's constructor in the right order.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9066
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
sullivan [Wed, 27 Apr 2005 17:59:15 +0000 (17:59 +0000)]
Reviewed by Dave Harrison.
- fixed <rdar://problem/
3547489> pop-up window blocking preference and
menu item can easily get out of sync.
* WebView.subproj/WebPreferences.m:
(-[WebPreferences _setStringValue:forKey:]):
save local value before setting value in NSUserDefaults, so clients reacting to NSUserDefaults
change notification but calling back on WebPreferences API will see the updated value.
(-[WebPreferences _setIntegerValue:forKey:]):
ditto
(-[WebPreferences _setBoolValue:forKey:]):
ditto
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9064
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
adele [Wed, 27 Apr 2005 05:52:08 +0000 (05:52 +0000)]
Fixed by Darin, reviewed by me.
Fix for <rdar://problem/
4084029> designMode doesn't allow editing when iframe src = "" or = about:blank
This change will add an HTML element for empty documents. Now that there will be an HTMLDocument in this case,
a body will also be created (see rdar://problem/
3758785). This was preventing frames with empty documents from
being editable.
* khtml/html/htmlparser.cpp: (KHTMLParser::finished):
Updated these tests to expect the HTML and BODY elements
* layout-tests/fast/flexbox/016-expected.txt:
* layout-tests/fast/frames/001-expected.txt:
* layout-tests/fast/frames/002-expected.txt:
* layout-tests/fast/frames/contentWindow_Frame-expected.txt:
* layout-tests/fast/frames/contentWindow_iFrame-expected.txt:
* layout-tests/fast/frames/empty-frame-src-expected.txt:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9062
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
rjw [Wed, 27 Apr 2005 01:03:57 +0000 (01:03 +0000)]
JavaScriptCore:
Fixed <rdar://problem/
4098713> Scripting API is incompatible with Mozilla
We were incompatible with Mozilla's implementation of the scripting APIs in
two ways:
Their NPN_SetException has the following signature:
void NPN_SetException(NPObject *npobj, const NPUTF8 *message);
ours has:
void NPN_SetException (NPObject * npobj, const NPString *message);
Also, they expect the string returned from NPN_UTF8FromIdentifier() to be freed by caller.
We do not.
I changed both behaviors to match Mozilla.
Reviewed by Chris.
* bindings/NP_jsobject.cpp:
(_NPN_SetException):
* bindings/npruntime.cpp:
(_NPN_UTF8FromIdentifier):
(_NPN_IntFromIdentifier):
(_NPN_SetExceptionWithUTF8):
* bindings/npruntime.h:
* bindings/npruntime_impl.h:
WebKit:
Fixed <rdar://problem/
4098713> Scripting API is incompatible with Mozilla
Reviewed by Chris.
* Plugins.subproj/npfunctions.h:
* Plugins.subproj/npruntime.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9061
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mjs [Wed, 27 Apr 2005 00:18:14 +0000 (00:18 +0000)]
JavaScriptCore:
Reviewed by Chris.
<rdar://problem/
4092136> reproducible crash in KJS::kjs_fast_realloc loading maps.google.com
* kjs/string_object.cpp:
(StringObjectFuncImp::call): Allocate adopted ustring buffer properly.
WebCore:
New test case for <rdar://problem/
4092136> reproducible crash in KJS::kjs_fast_realloc loading maps.google.com
* layout-tests/fast/js/string-from-char-code-expected.txt: Added.
* layout-tests/fast/js/string-from-char-code.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9059
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Tue, 26 Apr 2005 23:36:34 +0000 (23:36 +0000)]
WebCore:
Reviewed by John.
- fixed <rdar://problem/
3655817> please add support for mouse wheel events and the onmousewheel handler
Loose ends:
- need to test behavior of Windows IE with horizontal scroll wheeling; we currently send a distinct event
for that relatively obscure case, which means the event handlers won't fire at all; might be incorrect
- overflow scrolling is done after all DOM event handling, but ideally should be done in the overflowing
element's default event handler; not important in practice
- frame scrolling is done after all DOM event handling, but probably should be done in a default event handler;
not sure about this, but it's probably not important in practice and definitely not required
- JavaScript
* khtml/ecma/kjs_events.h: Added DOMWheelEvent.
* khtml/ecma/kjs_events.cpp:
(KJS::getDOMEvent): Added a case for wheel event. To be forward looking, I use the event's impl pointer
instead of a C++ DOM wrapper. Eventually it will all work this way.
(offsetFromTarget): Added. Factored out code to compute offsetX/Y for an event.
(DOMMouseEvent::getValueProperty): Changed to call offsetFromTarget for offsetX/Y.
(DOMWheelEvent::DOMWheelEvent): Added.
(DOMWheelEvent::tryGet): Added.
(DOMWheelEvent::getValueProperty): Added.
(DOMWheelEventProtoFunc::tryCall): Added. Nothing at the moment, but might get contents later.
* khtml/ecma/kjs_dom.h: Added OnMouseWheel to the enum with the list of properties.
* khtml/ecma/kjs_dom.cpp: Added onmousewheel as a property of DOM nodes.
(DOMNode::getValueProperty): Return the mouse wheel event handler.
(DOMNode::putValue): Set the mouse wheel event handler.
* khtml/ecma/kjs_window.cpp: Added onmousewheel as a property of the window.
(Window::get): Return the mouse wheel event handler.
(Window::put): Set the mouse wheel event handler.
* khtml/ecma/kjs_window.h: Added OnWindowMouseWheel to the enum with the list of properties.
(Other properties distinguish the window handler by lower-casing the initial letter, way too subtle,
so I did this one a good way.)
* khtml/dom/dom2_events.h: Made the constructors for Event and UIEvent public. There's no good reason
for them to be private, and I had to use the UIEvent one in the JavaScript implementation.
- DOM
* khtml/xml/dom2_eventsimpl.h: Added events for mouse wheel and horizontal mouse wheel.
Added isWheelEvent function to EventImpl.
(DOM::UIEventWithKeyStateImpl): Added. Base class shared by mouse, wheel, and keyboard events.
(DOM::MouseRelatedEventImpl): Added. Base class shared by mouse and wheel events.
(DOM::WheelEventImpl): Added.
* khtml/xml/dom2_eventsimpl.cpp: Added "mousewheel" to list of event names and a placeholder for
the horizontal mouse wheel.
(EventImpl::isWheelEvent): Added. Returns false.
(MouseRelatedEventImpl::MouseRelatedEventImpl): Added. Factored out what's shared between mouse
events and wheel events to avoid duplicated code.
(MouseRelatedEventImpl::computeLayerPos): Moved to MouseRelatedWheelEventImpl.
(MouseEventImpl::MouseEventImpl): Changed since MouseRelatedWheelEventImpl is now the base class
so we can share more code with wheel events.
(KeyboardEventImpl::KeyboardEventImpl): Changed since UIEventWithKeyStateImpl is now the base class
so we can share more code with mouse and wheel events.
(WheelEventImpl::WheelEventImpl): Added.
(WheelEventImpl::isWheelEvent): Added. Returns true.
* khtml/misc/htmlattrs.in: Added "onmousewheel" attribute name.
* khtml/html/html_elementimpl.cpp: (HTMLElementImpl::parseHTMLAttribute): Added parsing of the
"onmousewheel" atribute, consistent with other event handler attributes.
- event handling
* kwq/WebCoreBridge.h: Renamed scrollOverflowWithScrollWheelEvent to sendScrollWheelEvent.
* kwq/WebCoreBridge.mm: (-[WebCoreBridge sendScrollWheelEvent:]): Renamed.
* kwq/KWQEvent.h: Added Wheel as an event type value.
(QWheelEvent::QWheelEvent): Added.
* kwq/KWQEvent.mm:
(positionForEvent): Updated to know that wheel events have valid positions in them.
(orientationForEvent): Added.
(deltaForEvent): Added.
(QWheelEvent::QWheelEvent): Added.
* kwq/KWQKHTMLPart.h: Renamed scrollOverflowWithScrollWheelEvent to wheelEvent.
* kwq/KWQKHTMLPart.mm: (KWQKHTMLPart::wheelEvent): Renamed and added code to construct a QWheelEvent
and send it along to KHTMLView::viewportWheelEvent, consistent with how mouse events work.
* khtml/khtmlview.cpp: (KHTMLView::viewportWheelEvent): Do a hit test to figure out which node to
send the event to, and then call dispatchWheelEvent.
* khtml/xml/dom_nodeimpl.h: Added dispatchWheelEvent.
* khtml/xml/dom_nodeimpl.cpp: (NodeImpl::dispatchWheelEvent): Added.
- generated files
* khtml/ecma/kjs_dom.lut.h: Regenerated.
* khtml/ecma/kjs_events.lut.h: Regenerated.
* khtml/ecma/kjs_window.lut.h: Regenerated.
* khtml/misc/htmlattrs.c: Regenerated.
* khtml/misc/htmlattrs.h: Regenerated.
WebKit:
Reviewed by John.
- fixed <rdar://problem/
3655817> please add support for mouse wheel events and the onmousewheel handler
* WebView.subproj/WebHTMLView.m: (-[WebHTMLView scrollWheel:]): Call sendScrollWheelEvent: method
instead of the old scrollOverflowWithScrollWheelEvent: (just a name change).
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9057
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
harrison [Tue, 26 Apr 2005 22:39:33 +0000 (22:39 +0000)]
Reviewed by Darin, Maciej.
<rdar://problem/
4075576> Deleting text in new message borks content
Fixed by removing the methods that attempted to preserve the position. The idea
of preserving position is a very recent one, and turned out to not actually address
the problem it was intended to fix (see below). Further, is unclear how the position
could be preserved in a form that could be properly used later on. Therefore,
removing the code to work like before is the preferred alternative for this software
update. I've written <rdar://problem/
4099839> to cover the bug that position
preservation was supposed to fix (but did not). Added layout tests for
both this bug and
4099839. Also, updated existing tests with correct expected results
(delete-at-paragraph-boundaries-003 and 004).
* khtml/editing/htmlediting.cpp:
(khtml::CompositeEditCommand::removeFullySelectedNode):
(khtml::CompositeEditCommand::removeChildrenInRange):
(khtml::DeleteSelectionCommand::handleGeneralDelete):
* khtml/editing/htmlediting.h:
* layout-tests/editing/deleting/delete-at-paragraph-boundaries-003-expected.txt:
* layout-tests/editing/deleting/delete-at-paragraph-boundaries-004-expected.txt:
* layout-tests/editing/deleting/delete-at-paragraph-boundaries-007-expected.txt: Added.
* layout-tests/editing/deleting/delete-at-paragraph-boundaries-007.html: Added.
* layout-tests/editing/deleting/delete-at-paragraph-boundaries-008-expected.txt: Added.
* layout-tests/editing/deleting/delete-at-paragraph-boundaries-008.html: Added.
* layout-tests/editing/deleting/delete-at-paragraph-boundaries-009-expected.txt: Added.
* layout-tests/editing/deleting/delete-at-paragraph-boundaries-009.html: Added.
* layout-tests/editing/deleting/delete-at-paragraph-boundaries-010-expected.txt: Added.
* layout-tests/editing/deleting/delete-at-paragraph-boundaries-010.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9054
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Tue, 26 Apr 2005 21:20:28 +0000 (21:20 +0000)]
- fixed development builds
* khtml/misc/main_thread_malloc.h: Use inlines instead of macros for allocation functions.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9053
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
hyatt [Tue, 26 Apr 2005 21:12:02 +0000 (21:12 +0000)]
Fix for
4097842, changing 1st line of a url that wraps doesn't update the second line. Make sure to
update line break info for the last dirty line so that when a clean line tries to figure out where it
started, it will get an accurate position taking into account the updated string. By doing this, the code
will be able to properly distinguish between the old and new positions and not accidentally assume they are
the same.
Reviewed by darin
* khtml/rendering/render_text.cpp:
(RenderText::setTextWithOffset):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9052
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Tue, 26 Apr 2005 21:02:08 +0000 (21:02 +0000)]
Reviewed by Maciej.
- fixed <rdar://problem/
4098826> Bezier curves broken in new Safari canvas object (last two parameters parsed incorrectly)
* khtml/ecma/kjs_html.cpp: (KJS::Context2DFunction::tryCall): Fixed incorrect argument indices.
Thanks to Brian Campbell who figured out what was wrong.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9051
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
mjs [Tue, 26 Apr 2005 18:46:04 +0000 (18:46 +0000)]
Reviewed by Darin.
- use single-threaded malloc in places where malloc is hot for an
8% speed improvement on cvs-base
* ForwardingHeaders/misc/fast_malloc.h: Added.
* WebCore.pbproj/project.pbxproj:
* khtml/css/css_base.h:
* khtml/css/css_ruleimpl.h:
* khtml/css/css_valueimpl.h:
* khtml/css/cssstyleselector.h:
* khtml/misc/arena.cpp:
(ArenaAllocate):
(FreeArenaList):
(ArenaFinish):
* khtml/misc/main_thread_malloc.cpp: Added.
* khtml/misc/main_thread_malloc.h: Added.
* khtml/rendering/render_style.h:
* khtml/xml/dom2_eventsimpl.h:
* khtml/xml/dom2_rangeimpl.h:
* khtml/xml/dom2_traversalimpl.h:
* khtml/xml/dom2_viewsimpl.h:
* khtml/xml/dom_docimpl.h:
* khtml/xml/dom_elementimpl.cpp:
(NamedAttrMapImpl::NamedAttrMapImpl):
(NamedAttrMapImpl::clearAttributes):
(NamedAttrMapImpl::operator=):
(NamedAttrMapImpl::addAttribute):
(NamedAttrMapImpl::removeAttribute):
* khtml/xml/dom_elementimpl.h:
* khtml/xml/dom_nodeimpl.h:
* khtml/xml/dom_stringimpl.h:
* kwq/KWQFontFamily.h:
* kwq/KWQListImpl.mm:
* kwq/KWQString.h:
* kwq/KWQString.mm:
(ALLOC_CHAR):
(ALLOC_QCHAR):
(QString::setBufferFromCFString):
(allocatePageNode):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9050
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
sullivan [Mon, 25 Apr 2005 23:35:14 +0000 (23:35 +0000)]
Reviewed by Dave Harrison.
- fixed <rdar://problem/
4098731> [DOMHTMLTextAreaElement cols] returns wrong value (usually zero)
* kwq/DOMHTML.mm:
(-[DOMHTMLTextAreaElement cols]):
use ATTR_COLS instead of ATTR_ACCESSKEY (D'oh!)
(-[DOMHTMLTextAreaElement setCols:]):
fixed whitespace
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9049
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
vicki [Mon, 25 Apr 2005 18:37:06 +0000 (18:37 +0000)]
JavaScriptCore-412.1
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9047
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Mon, 25 Apr 2005 15:55:02 +0000 (15:55 +0000)]
Reviewed by John.
- fixed <rdar://problem/
4097849> REGRESSION (162-163): importNode creates non-HTML elements, thus style attributes (and some others) don't work
* khtml/xml/dom_docimpl.h: Add virtual functions HTMLElementNamespace and isHTMLNamespace.
* khtml/xml/dom_docimpl.cpp:
(DocumentImpl::importNode): Rearranged this function and fixed the following problems: 1) made sure to ref node while attributes are
being set on it so it doesn't get destroyed; 2) fixed code to get namespace from the element we are importing to use the IDs from
the source document, not the destination document; 3) removed unneeded getDocument() call which just returns this; 4) fixed error
handling for cases where an exception happens while processing the children.
(DocumentImpl::HTMLElementNamespace): Added. Returns XHTML_NAMESPACE.
(DocumentImpl::isHTMLNamespace): Added. Returns true for any namespace that matches XHTML_NAMESPACE (case insensitive).
(DocumentImpl::createElementNS): Changed to call isHTMLNamespace, which will cause it to accept the null namespace in an HTML document.
This is the change that fixes the bug. Also fixed the code path to do a little less wasteful work in the non-XHTML case.
(DocumentImpl::createHTMLElement): Pass in HTMLElementNamespace() rather than 0 to tagId.
(DocumentImpl::attrId): Use isHTMLNamespace instead of allowing the null namespace explicitly.
(DocumentImpl::tagId): Ditto.
* khtml/html/html_documentimpl.h: Add overrides for HTMLElementNamespace and isHTMLNamespace.
* khtml/html/html_documentimpl.cpp:
(HTMLDocumentImpl::HTMLElementNamespace): Added. Returns 0 so we use the null string for HTML elements inside HTML documents (as before).
(HTMLDocumentImpl::isHTMLNamespace): Added. Allows 0, and then calls base class to check for the actual XHTML namespace. Thus, we allow
both no namespace at all and the XHTML namespace inside HTML documents.
* khtml/html/html_elementimpl.cpp: (HTMLElementImpl::namespaceURI): Changed to call HTMLElementNamespace rather than checking
isHTMLDocument. Same result as before, but better division of responsibilities.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9046
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Mon, 25 Apr 2005 15:43:10 +0000 (15:43 +0000)]
Reviewed by John.
- fixed <rdar://problem/
4091956> JavaScript drop handlers don't receive more than one dropped item
* kwq/KWQClipboard.mm:
(cocoaTypeFromMIMEType): Remove some use of compare -- less efficient than a simpler "==" check.
Fixed non-GC-safe code to use KWQCFAutorelease instead.
(MIMETypeFromCocoaType): Use fromCFString instead of fromNSString to avoid a cast.
(KWQClipboard::getData): Rearrange so that we'll use filenames if both filenames and a URL are present, since
filenames can accomodate multiple items. Fix bug where we'd return multiple filenames when the type requested
is "URL". Fixed loop that computed the count over and over again for the loop termination condition. Check
that the data for NSFilenamesPboardType is an NSArray instead of assuming it is.
(KWQClipboard::setData): Use isEqualToString: instead of == when comparing types.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9045
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
hyatt [Sat, 23 Apr 2005 00:42:00 +0000 (00:42 +0000)]
Fix for
4096878, drop shadow effect not displayed correctly on tbray.org/ongoing/. Block minmaxwidth was
broken when negative margins were used and did not properly decrease the max width.
Reviewed by Maciej
* khtml/rendering/render_block.cpp:
(khtml::RenderBlock::calcBlockMinMaxWidth):
* layout-tests/fast/block/float/034-expected.txt: Added.
* layout-tests/fast/block/float/034.html: Added.
* layout-tests/fast/block/float/035-expected.txt: Added.
* layout-tests/fast/block/float/035.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9044
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
hyatt [Sat, 23 Apr 2005 00:08:30 +0000 (00:08 +0000)]
Remove some dead code from css_valueimpl. It wasn't used at all.
* khtml/css/css_valueimpl.cpp:
* khtml/css/css_valueimpl.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9043
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Fri, 22 Apr 2005 21:53:58 +0000 (21:53 +0000)]
Reviewed by Maciej.
* kjs/ustring.cpp: (KJS::UString::UTF8String): Fix off-by-one error in surrogate pair logic.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9042
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Fri, 22 Apr 2005 21:19:58 +0000 (21:19 +0000)]
* khtml/ecma/kjs_html.h: Removed unnecessary bogus class name qualifiers.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9041
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
hyatt [Fri, 22 Apr 2005 18:12:16 +0000 (18:12 +0000)]
Fix for
4096681, fix regression in how the list-style property is parsed. It no longer parses when it hits
a url in the property value list now, because the list pointer did not get advanced. This fixes alistapart.com.
Reviewed by john
* khtml/css/cssparser.cpp:
(CSSParser::parseValue):
* layout-tests/fast/lists/009-expected.txt: Added.
* layout-tests/fast/lists/009.html: Added.
* layout-tests/fast/lists/resources/listmark.gif: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9040
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Fri, 22 Apr 2005 16:48:44 +0000 (16:48 +0000)]
Reviewed by John.
- fixed <rdar://problem/
4090046> JavaScript throw statement causes parse error when no semicolon is present
* kjs/grammar.y: Added an additional rule for throw like the ones we have for all the other semicolon rules.
Not sure why we missed this one earlier.
* kjs/grammar.cpp: Regenerated.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9039
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Fri, 22 Apr 2005 16:30:28 +0000 (16:30 +0000)]
Reviewed by John.
- fixed <rdar://problem/
4091082> Google Suggest no longer works due to lack of "frameElement"
* khtml/ecma/kjs_window.h: Added FrameElement.
* khtml/ecma/kjs_window.cpp: (Window::get): Added "frameElement".
* khtml/ecma/kjs_window.lut.h: Regenerated.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9038
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Fri, 22 Apr 2005 16:29:51 +0000 (16:29 +0000)]
Reviewed by John.
- a small editing-related code cleanup
* khtml/rendering/render_text.h: Added positionForOffset and made offsetForPosition const.
* khtml/rendering/render_text.cpp:
(InlineTextBox::offsetForPosition): Made const.
(InlineTextBox::positionForOffset): Added. Moved code here from caretRect.
(RenderText::caretRect): Call positionForOffset instead of doing the work here.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9037
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
hyatt [Thu, 21 Apr 2005 20:55:15 +0000 (20:55 +0000)]
Fix for
4095839, wrong background image used on flechtwerk.de. Make sure that the global mapped
attribute cache hashed background attributes into per-document buckets.
* khtml/html/html_baseimpl.cpp:
(HTMLBodyElementImpl::mapToEntry):
* khtml/html/html_elementimpl.h:
(DOM::):
* khtml/html/html_tableimpl.cpp:
(HTMLTableElementImpl::mapToEntry):
(HTMLTablePartElementImpl::mapToEntry):
* khtml/xml/dom_docimpl.cpp:
(DocumentImpl::DocumentImpl):
* khtml/xml/dom_docimpl.h:
(DOM::DocumentImpl::docID):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9036
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
vicki [Thu, 21 Apr 2005 16:07:43 +0000 (16:07 +0000)]
- layout test for
4065447, outerHTML on images
* layout-tests/fast/dynamic/outerHTML-img-expected.txt: Added.
* layout-tests/fast/dynamic/outerHTML-img.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9035
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
vicki [Thu, 21 Apr 2005 16:02:24 +0000 (16:02 +0000)]
Reviewed by hyatt.
- fixed <rdar://problem/
4065447> support outerHTML on IMG elements
* khtml/html/html_elementimpl.cpp:
(HTMLElementImpl::setOuterHTML):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9034
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Wed, 20 Apr 2005 10:14:35 +0000 (10:14 +0000)]
Reviewed by Maciej.
- speedups, total 12% on JavaScript iBench
I ran the benchmark under Shark and followed its advice a lot, mainly.
* kjs/collector.cpp:
(KJS::Collector::allocate): Take out special case for 0; costing speed but unexercised.
Use numLiveObjectsAtLastCollect instead of numAllocationsSinceLastCollect so we don't
have to bump it each time we call allocate. Put numLiveObjects into a local variable to
cut down on global variable accesses. Make "next" cell pointer be a byte offset rather
than a pointer so we don't need a special case for NULL. Allow freeList to point to some
bogus item when the entire block is full rather than going out of our way to make it
point to NULL.
(KJS::Collector::markProtectedObjects): Get table size and pointer into locals outside
the loop to avoid re-loading them over and over again.
(KJS::Collector::collect): Put numLiveObjects into a local variable to cut down on global
variable accesses. Make "next" cell pointer be a byte offset as above. Put numLiveObjects
into a local variable to cut down on global variable accesses. Set numLiveObjectsAtLastCollect
rather than numAllocationsSinceLastCollect.
(KJS::Collector::numReferencedObjects): Get table size and pointer into locals outside
the loop to avoid re-loading them over and over again.
(KJS::Collector::rootObjectClasses): Ditto.
* kjs/internal.h: Make Value be a friend of NumberImp so it can construct number objects
directly, avoiding the conversion from Number to Value.
* kjs/internal.cpp: (StringImp::toObject): Don't use Object::dynamicCast, because we know
the thing is an object and we don't want to do all the extra work; just cast directly.
* kjs/list.cpp: (KJS::List::List): Construct valueRefCount in a way that avoids the need for
a branch -- in the hot case this just meant avoiding checking a variable we just set to false.
* kjs/lookup.cpp: (keysMatch): Marked this inline.
* kjs/nodes.cpp: Disabled KJS_BREAKPOINT, to avoid calling hitStatement all the time.
(BooleanNode::evaluate): Make a Value directly, rather than making a Boolean which is converted
into a Value.
(NumberNode::evaluate): Ditto.
(StringNode::evaluate): Ditto.
(ArrayNode::evaluate): Ditto.
(FunctionCallNode::evaluate): Use new inline baseIfMutable to avoid unnecessary getBase function.
Also just use a pointer for func, rather than an Object.
(PostfixNode::evaluate): Change code so that it doesn't make an excess Number, and so that it
passes a "known to be integer" boolean in, often avoiding a conversion from floating point to
integer and back.
(DeleteNode::evaluate): Make a Value directly.
(TypeOfNode::evaluate): Use new inline baseIfMutable and make Value directly.
(PrefixNode::evaluate): Change code so that it doesn't make an excess Number, and so that it
passes a "known to be integer" boolean in, often avoiding a conversion from floating point to
integer and back.
(UnaryPlusNode::evaluate): Make a Value directly.
(NegateNode::evaluate): Change code so that it doesn't make an excess Number, and so that it
passes a "known to be integer" boolean in, often avoiding a conversion from floating point to
integer and back.
(BitwiseNotNode::evaluate): Make a Value directly.
(LogicalNotNode::evaluate): Ditto.
(ShiftNode::evaluate): Don't convert to a double before making a Value.
(RelationalNode::evaluate): Make a Value directly.
(EqualNode::evaluate): Ditto.
(BitOperNode::evaluate): Ditto.
(AssignNode::evaluate): Make a Value directly. Change code so that it passes a "known to be integer"
boolean in, often avoiding a conversion from floating point to integer and back.
(VarDeclNode::evaluate): Make a Value directly.
(ForNode::execute): Remove unused local variable.
* kjs/operations.h:
(KJS::isNaN): Inlined.
(KJS::isInf): Ditto.
(KJS::isPosInf): Ditto.
(KJS::isNegInf): Ditto.
* kjs/operations.cpp: Change isNaN, isInf, isPosInf, and isNegInf to be inlines.
(KJS::equal): Rewrite to avoid creating values and recursing back into the function.
(KJS::relation): Rearranged code so that we don't need explicit isNaN checks.
(KJS::add): Changed code to make Value directly, and so that it passes a "known to be integer"
boolean in, often avoiding a conversion from floating point to integer and back.
(KJS::mult): Ditto.
* kjs/property_map.cpp:
(KJS::PropertyMap::~PropertyMap): Get size and entries pointer outside loop to avoid
re-getting them inside the loop.
(KJS::PropertyMap::clear): Ditto. Clear value pointer in addition to key, so we can just
look at the value pointer in the mark function.
(KJS::PropertyMap::get): Get sizeMask and entries pointer outside loop to avoid
re-getting them inside the loop.
(KJS::PropertyMap::put): Ditto.
(KJS::PropertyMap::insert): Ditto.
(KJS::PropertyMap::remove): Ditto.
(KJS::PropertyMap::mark): Get size and entries pointer outside loop to avoid
re-getting them inside the loop. Don't bother checking key for 0, since we already have
to check value for 0. (Also had to change clear() to set value to 0.)
(KJS::PropertyMap::addEnumerablesToReferenceList): Get size and entries pointer outside
loop to avoid re-getting them inside the loop.
(KJS::PropertyMap::addSparseArrayPropertiesToReferenceList): Ditto.
(KJS::PropertyMap::save): Ditto.
- other changes
* kjs/protected_values.h: Remove unneeded class name qualifiers.
* kjs/reference.h:
(KJS::Reference::baseIfMutable): New inline function: replaces isMutable().
(KJS::Reference::Reference): Inlined.
* kjs/reference.cpp:
(KJS::Reference::getValue): Rewrite to not use getBase.
(KJS::Reference::putValue): Ditto.
(KJS::Reference::deleteValue): Dittol
* kjs/simple_number.h:
(KJS::SimpleNumber::integerFits): Added. For use when the parameter is known to be integral.
* kjs/string_object.cpp: (StringProtoFuncImp::call): Create the number without first converting
to double in various cases that involve integers.
* kjs/ustring.h:
(KJS::UString::attach): Inlined.
(KJS::UString::release): Inlined.
* kjs/ustring.cpp:
(KJS::UString::find): Get first character outside the loop instead of re-fetching it each time.
* kjs/value.cpp:
(Value::Value): Added overloads for all the various specific types of values, so you don't have
to convert from, say, Number to Value, just to create one.
(Number::Number): Added an overload that takes a boolean to indicate the number is already
known to be an integer.
* kjs/value.h: Added more Value constructors, added a version of toNumber that returns
a boolean to indicate if the number is known to be an integer (because it was a "simple number").
(KJS::ValueImp::marked): Inlined.
(KJS::ValueImp::dispatchType): Inlined.
(KJS::ValueImp::dispatchToPrimitive): Inlined.
(KJS::ValueImp::dispatchToBoolean): Inlined.
(KJS::ValueImp::dispatchToNumber): Inlined.
(KJS::ValueImp::dispatchToString): Inlined.
(KJS::ValueImp::dispatchToUInt32): Inlined.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9033
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
darin [Tue, 19 Apr 2005 01:17:53 +0000 (01:17 +0000)]
Reviewed by Hyatt.
- fixed <rdar://problem/
4092614> REGRESSION (Tiger): progressively loaded background images "scroll around" instead of just appearing
* WebCoreSupport.subproj/WebImageData.m:
(-[WebImageData _imageSourceOptions]): Moved a global inside this function, since it's only used here.
(-[WebImageData _cacheImages:allImages:]): Fixed a sizeof that was getting the size of the wrong thing.
(-[WebImageData _isSizeAvailable]): Used calloc in a more consistent way.
(drawPattern): Removed an unneeded cast.
(-[WebImageData tileInRect:fromPoint:context:]): Here's the actual bug fix. Don't use the image size
when deciding whether the image needs to be tiled as a pattern nor when creating the pattern: in both
cases, use the tile size. The old way was wrong, and the new way works perfectly. Also removed uneeded
error message when the image is not yet loaded enough to create a CGImageRef for it -- it's fine to
draw nothing in that case.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9032
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
hyatt [Mon, 18 Apr 2005 20:57:04 +0000 (20:57 +0000)]
Fix min-height so that when it resolves to auto it does not use the box's intrinsic height.
* khtml/rendering/render_box.cpp:
(RenderBox::calcHeight):
(RenderBox::calcHeightUsing):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9030
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
hyatt [Mon, 18 Apr 2005 20:56:04 +0000 (20:56 +0000)]
Fix layout test.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9029
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
hyatt [Mon, 18 Apr 2005 18:12:42 +0000 (18:12 +0000)]
Back out fix for
4032346, since it is causing garbled image content on many sites.
The bug tracking the fix is
4069093.
(khtml::RenderBlock::matchedEndLine):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9028
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
hyatt [Mon, 18 Apr 2005 11:07:34 +0000 (11:07 +0000)]
Fix the smile in the Acid2 test. Floats should not grow to contain other floats unless height is auto. Otherwise
the float should use the specified height.
Also fix row 14 of the Acid2 test. Although ambiguous, just modify the table cell baseline alignment code to align
to the bottom of the cell's content height if no suitable baseline could be found.
* khtml/rendering/render_block.cpp:
(khtml::RenderBlock::layoutBlock):
* khtml/rendering/render_block.h:
(khtml::RenderBlock::firstRootBox):
(khtml::RenderBlock::lastRootBox):
* khtml/rendering/render_table.cpp:
(RenderTableSection::calcRowHeight):
(RenderTableCell::baselinePosition):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9027
268f45cc-cd09-0410-ab3c-
d52691b4dbfc