Timeline



May 26, 2004:

11:35 PM Changeset in webkit [6698] by rjw
  • 6 edits in trunk/WebCore

Added shadow support (w/ Louch).
Added infrastructure for drawing images.

New context methods:

setShadow
setShadowWithColor
clearShadow

Reviewed by me and Louch.

  • khtml/ecma/kjs_html.cpp: (KJS::Context2DFunction::tryCall):
  • khtml/ecma/kjs_html.h: (KJS::Image::image): (KJS::Context2D::):
  • khtml/ecma/kjs_html.lut.h: (KJS::):
  • kwq/KWQPainter.h:
  • kwq/KWQPainter.mm: (QPainter::drawPixmap):
11:32 PM Changeset in webkit [6697] by mjs
  • 3 edits in trunk/WebKit

Reviewed by Dave.

  • fix further problems with Emerson feed: redirection for RSS feeds

This is done by removing removing the calls to defer callbacks
while waiting for

  • WebView.subproj/WebMainResourceClient.m: (-[WebMainResourceClient continueAfterNavigationPolicy:formState:]): (-[WebMainResourceClient connection:willSendRequest:redirectResponse:]): (-[WebMainResourceClient continueAfterContentPolicy:response:]): (-[WebMainResourceClient checkContentPolicyForResponse:]):
10:58 PM Changeset in webkit [6696] by beard
  • 35 edits in branches/AutoZoneGC_Branch_20040430

Now using NSAllocateScannedUncollectable(size) rather than NSZoneMalloc(NULL, size) when scanned but uncollectable memor
y is needed. Ran sources through gctools/automate.rb to generate finalizers and wrap CFMakeCollectable around bridged CF

types.

6:02 PM Changeset in webkit [6695] by cblu
  • 6 edits in trunk/WebKit

Added and implemented proposed dragging API changes. These changes are necessary to make JS dragging work properly.

Reviewed by trey.

  • WebView.subproj/WebDefaultUIDelegate.m: (-[WebDefaultUIDelegate webView:shouldDetermineDragOperationForDraggingInfo:dragOperation:]): instead of calling back to the WebView to get the default drag operation, return YES. Return NO in order to return a custom drag operation. Removed element parameter since another new API provides a way to get that. (-[WebDefaultUIDelegate webView:shouldProcessDragWithDraggingInfo:]): Removed element parameter since another new API provides a way to get that.
  • WebView.subproj/WebDocumentInternal.h:
  • WebView.subproj/WebHTMLView.m: (-[WebHTMLView draggingUpdatedWithDraggingInfo:]): now returns a drag operation (-[WebHTMLView draggingCancelledWithDraggingInfo:]): moved
  • WebView.subproj/WebUIDelegatePrivate.h:
  • WebView.subproj/WebView.m: (-[WebView elementAtPoint:]): new proposed API (-[WebView dragOperationForDraggingInfo:]): removed code from this API that should be removed (-[WebView _dragOperationForDraggingInfo:]): call new API (-[WebView concludeDragOperation:]): call new API
5:23 PM Changeset in webkit [6694] by rjw
  • 4 edits in trunk/WebCore

Fixed build snafu.

  • khtml/ecma/kjs_html.cpp: (KJS::Context2DFunction::tryCall):
  • khtml/ecma/kjs_html.h: (KJS::Context2D::):
  • khtml/ecma/kjs_html.lut.h: (KJS::):
4:58 PM Changeset in webkit [6693] by rjw
  • 13 edits in trunk/WebCore

Part 2 of the new <CANVAS> tag implementation. This adds the
basic machinery and draw operations for the <CANVAS> tag. Pretty cool.

function drawLine() {

var canvas1 = document.getElementById ("canvas1");
var context = canvas1.getContext("context-2d");

context.setStrokeColor ("red");
context.setLineWidth (10);
context.beginPath();
context.moveToPoint (0,0);
context.addLineToPoint (400,400);
context.strokePath();

}

...

<canvas id="canvas1" width="400" height="400">

Currently supported operations on the 2D context are:

Save, Restore,
Scale, Rotate, Translate,
BeginPath, ClosePath,
SetStrokeColor, SetFillColor, SetLineWidth, SetLineCap, SetLineJoin, SetMiterLimit,
FillPath, StrokePath,
MoveToPoint, AddLineToPoint, AddQuadraticCurveToPoint, AddBezierCurveToPoint,
ClearRect

More to come.

Reviewed by Dave.

  • khtml/ecma/kjs_html.cpp: (KJS::HTMLElementFunction::tryCall): (KJS::Context2DFunction::tryCall): (Context2D::tryGet): (Context2D::getValueProperty): (Context2D::tryPut): (Context2D::putValue): (Context2D::Context2D): (Context2D::~Context2D):
  • khtml/ecma/kjs_html.h: (KJS::Context2D::toBoolean): (KJS::Context2D::classInfo): (KJS::Context2D::):
  • khtml/ecma/kjs_html.lut.h: (KJS::):
  • khtml/html/html_canvasimpl.cpp: (HTMLCanvasElementImpl::HTMLCanvasElementImpl):
  • khtml/html/htmlparser.cpp: (KHTMLParser::getElement):
  • khtml/rendering/render_canvasimage.cpp: (RenderCanvasImage::RenderCanvasImage): (RenderCanvasImage::~RenderCanvasImage): (RenderCanvasImage::createDrawingContext): (RenderCanvasImage::drawingContext): (RenderCanvasImage::setNeedsImageUpdate): (RenderCanvasImage::updateDrawnImage): (RenderCanvasImage::drawnImage): (RenderCanvasImage::paint): (RenderCanvasImage::layout):
  • khtml/rendering/render_canvasimage.h:
  • khtml/rendering/render_image.cpp: (RenderImage::paint):
  • khtml/rendering/render_image.h:
  • khtml/rendering/render_replaced.cpp: (RenderReplaced::shouldPaint): (RenderWidget::paint):
  • kwq/KWQPainter.h:
  • kwq/KWQPainter.mm: (QPainter::currentContext):
2:16 PM Changeset in webkit [6692] by darin
  • 7 edits in trunk/WebKit

Reviewed by John.

  • moved HTML editing operations from WebView to WebHTMLView, leaving only forwarding machinery at the WebView level
  • fixed <rdar://problem/3655412>: (Editing:�startSpeaking:�ethod�nimplemented�WebKit�diting�PI))
  • fixed <rdar://problem/3655414>: (Editing:�stopSpeaking:�ethod�nimplemented�WebKit�diting�PI))
  • fixed <rdar://problem/3655375>: (Editing:�pasteAsRichText:�ethod�nimplemented�WebKit�diting�PI))
  • WebView.subproj/WebView.h: Added missing declaration of selectionAffinity. I think this omission was an editorial mistake.
  • WebView.subproj/WebView.m: (-[WebView searchFor:direction:caseSensitive:wrap:]): Use _frameForCurrentSelection directly, since it no longer returns nil. (-[WebView pasteboardTypesForSelection]): Use _frameForCurrentSelection instead of going through the bridge. (-[WebView _frameForCurrentSelection]): Renamed from _currentFrame and changed to return main frame rather than nil when called on WebView that has no current selection. (-[WebView _bridgeForCurrentSelection]): Moved in file. (-[WebView _updateFontPanel]): Removed the one call to _currentSelectionIsEditable here, since it was the only one left in this file. Eventually this code will move to WebHTMLView. (-[WebView _performResponderOperation:with:]): Name change.
  • WebView.subproj/WebDataSource.m: (-[WebDataSource _documentFragmentWithImageResource:]): Build document fragment using DOM instead of composing HTML text.
  • WebView.subproj/WebHTMLView.m: (-[WebHTMLView _documentFragmentFromPasteboard:allowPlainText:]): Added allowPlainText boolean, moved method into new location in file so it can be in the right category, changed link pasting to use DOM instead of composing HTML text. (-[WebHTMLView _replaceSelectionWithPasteboard:selectReplacement:allowPlainText:]): Added allowPlainText boolean, moved method into new location in file so it can be in the right category. (-[WebHTMLView concludeDragForDraggingInfo:]): Pass YES for allowPlainText. (-[WebHTMLView centerSelectionInVisibleArea:]): Moved here from WebView. (-[WebHTMLView _alterCurrentSelection:direction:granularity:]): Ditto. (-[WebHTMLView moveBackward:]): Ditto. (-[WebHTMLView moveBackwardAndModifySelection:]): Ditto. (-[WebHTMLView moveDown:]): Ditto. (-[WebHTMLView moveDownAndModifySelection:]): Ditto. (-[WebHTMLView moveForward:]): Ditto. (-[WebHTMLView moveForwardAndModifySelection:]): Ditto. (-[WebHTMLView moveLeft:]): Ditto. (-[WebHTMLView moveLeftAndModifySelection:]): Ditto. (-[WebHTMLView moveRight:]): Ditto. (-[WebHTMLView moveRightAndModifySelection:]): Ditto. (-[WebHTMLView moveToBeginningOfDocument:]): Ditto. (-[WebHTMLView moveToBeginningOfLine:]): Ditto. (-[WebHTMLView moveToBeginningOfParagraph:]): Ditto. (-[WebHTMLView moveToEndOfDocument:]): Ditto. (-[WebHTMLView moveToEndOfLine:]): Ditto. (-[WebHTMLView moveToEndOfParagraph:]): Ditto. (-[WebHTMLView moveUp:]): Ditto. (-[WebHTMLView moveUpAndModifySelection:]): Ditto. (-[WebHTMLView moveWordBackward:]): Ditto. (-[WebHTMLView moveWordBackwardAndModifySelection:]): Ditto. (-[WebHTMLView moveWordForward:]): Ditto. (-[WebHTMLView moveWordForwardAndModifySelection:]): Ditto. (-[WebHTMLView moveWordLeft:]): Ditto. (-[WebHTMLView moveWordLeftAndModifySelection:]): Ditto. (-[WebHTMLView moveWordRight:]): Ditto. (-[WebHTMLView moveWordRightAndModifySelection:]): Ditto. (-[WebHTMLView pageDown:]): Ditto. (-[WebHTMLView pageUp:]): Ditto. (-[WebHTMLView selectParagraph:]): Ditto. (-[WebHTMLView selectLine:]): Ditto. (-[WebHTMLView selectWord:]): Ditto. (-[WebHTMLView copy:]): Moved down in file so it's in the right category. (-[WebHTMLView cut:]): Ditto. (-[WebHTMLView delete:]): Ditto. (-[WebHTMLView paste:]): Ditto. (-[WebHTMLView copyFont:]): Moved here from WebView. (-[WebHTMLView pasteFont:]): Ditto. (-[WebHTMLView pasteAsPlainText:]): Ditto. (-[WebHTMLView pasteAsRichText:]): Implemented this by calling the paste code with allowPlainText:NO; believe it or not, that's what this means in NSTextView. (-[WebHTMLView changeFont:]): Moved here from WebView. (-[WebHTMLView changeAttributes:]): Ditto. (-[WebHTMLView changeDocumentBackgroundColor:]): Ditto. (-[WebHTMLView changeColor:]): Ditto. (-[WebHTMLView alignCenter:]): Ditto. (-[WebHTMLView alignJustified:]): Ditto. (-[WebHTMLView alignLeft:]): Ditto. (-[WebHTMLView alignRight:]): Ditto. (-[WebHTMLView indent:]): Ditto. (-[WebHTMLView insertTab:]): Moved here from WebView, also call insertText rather than replaceSelectionWithText so it's undoable like a typed character. (-[WebHTMLView insertBacktab:]): Moved here from WebView. (-[WebHTMLView insertNewline:]): Moved here from WebView, also call insertText rather than replaceSelectionWithText so it's undoable like a typed character. (-[WebHTMLView insertParagraphSeparator:]): Moved here from WebView. (-[WebHTMLView changeCaseOfLetter:]): Ditto. (-[WebHTMLView uppercaseWord:]): Ditto. (-[WebHTMLView lowercaseWord:]): Ditto. (-[WebHTMLView capitalizeWord:]): Ditto. (-[WebHTMLView deleteForward:]): Ditto. (-[WebHTMLView deleteBackward:]): Ditto. (-[WebHTMLView deleteBackwardByDecomposingPreviousCharacter:]): Ditto. (-[WebHTMLView deleteWordForward:]): Ditto. (-[WebHTMLView deleteWordBackward:]): Ditto. (-[WebHTMLView deleteToBeginningOfLine:]): Ditto. (-[WebHTMLView deleteToEndOfLine:]): Ditto. (-[WebHTMLView deleteToBeginningOfParagraph:]): Ditto. (-[WebHTMLView deleteToEndOfParagraph:]): Ditto. (-[WebHTMLView complete:]): Ditto. (-[WebHTMLView checkSpelling:]): Ditto. (-[WebHTMLView showGuessPanel:]): Ditto. (-[WebHTMLView performFindPanelAction:]): Ditto. (-[WebHTMLView startSpeaking:]): Implemented this. (-[WebHTMLView stopSpeaking:]): Implemented this. (-[WebHTMLView insertText:]): Moved here from WebView.
  • WebView.subproj/WebHTMLViewPrivate.h: Removed declarations of methods that are neither SPI nor needed outside WebHTMLView.m.
  • WebView.subproj/WebViewInternal.h: Removed _currentFrame, and added _frameForCurrentSelection and _bridgeForCurrentSelection.
9:05 AM Changeset in webkit [6691] by darin
  • 2 edits in trunk/WebCore
  • fixed warning that prevents Deployment build from compiling
  • kwq/KWQKHTMLPart.mm: (KWQKHTMLPart::khtmlMousePressEvent): Moved use of single-click boolean outside the scope of the "block exceptions" macros.
12:17 AM Changeset in webkit [6690] by mjs
  • 3 edits in trunk/WebKit

Reviewed by Richard.

<rdar://problem/3652498>: new sniffing support is crashing

  • WebView.subproj/WebMainResourceClient.m: (-[WebMainResourceClient checkContentPolicyForResponse:]): Retain listener around call, in case delegate does something that ends up invalidating it, like navigating to a new URL.

May 25, 2004:

4:45 PM Changeset in webkit [6689] by cblu
  • 2 edits in trunk/WebCore

Fixed a regression where selections that were created via double or triple were not draggable.

Reviewed by darin.

  • kwq/KWQKHTMLPart.mm: (KWQKHTMLPart::khtmlMousePressEvent): if the click count is greater than 1, don't allow drags (KWQKHTMLPart::khtmlMouseMoveEvent): allow drags to occur even if the selection was originally created via double or triple click
4:05 PM Changeset in webkit [6688] by cblu
  • 5 edits in trunk

WebCore:

Fixed regression where undoing typing would undo character-by-character.

Reviewed by kocienda.

  • kwq/WebCoreBridge.h:
  • kwq/WebCoreBridge.mm: (-[WebCoreBridge insertText:]): new, this method used to be replaceSelectionWithText, but replaceSelectionWithText now is one operation whereas calls to insertText: are coalesced

WebKit:

Fixed regression where undoing typing would undo character-by-character.

Reviewed by kocienda.

  • WebView.subproj/WebView.m:
(-[WebView insertText:]): call insertText: rather than …
since text insertion via insertText: is coalesced and this is the behavior we want here
2:56 PM Changeset in webkit [6687] by kocienda
  • 10 edits in trunk

WebCore:

Reviewed by John

Change postDidChangeSelectionNotification and postDidChangeNotification tp
respondToChangedSelection and respondToChangedContents, respectively, to
account for the fact that we do work in these calls other than post a
notification.

  • khtml/khtml_part.cpp: (KHTMLPart::notifySelectionChanged): Use new names. (KHTMLPart::appliedEditing): Ditto. (KHTMLPart::unappliedEditing): Ditto. (KHTMLPart::reappliedEditing): Ditto.
  • kwq/KWQKHTMLPart.h: Change name of functions as described.
  • kwq/KWQKHTMLPart.mm: (KWQKHTMLPart::respondToChangedSelection): Ditto. (KWQKHTMLPart::respondToChangedContents): Ditto.
  • kwq/WebCoreBridge.h: Ditto.

WebKit:

Reviewed by John

Change postDidChangeSelectionNotification and postDidChangeNotification tp
respondToChangedSelection and respondToChangedContents, respectively, to
account for the fact that we do work in these calls other than post a
notification. The need to clear the typing style on both kinds of changes
inspired the name change.

Add in support to set and access typing style. We don't do anything with it yet
except store and return it. Using the typing style is still to come.

  • WebCoreSupport.subproj/WebBridge.m: (-[WebBridge respondToChangedContents]): Change name of functions as described. (-[WebBridge respondToChangedSelection]): Change name of functions as described.
  • WebView.subproj/WebView.m: (-[WebView dealloc:]): Dealloc typing style ivar. (-[WebView setTypingStyle:]): Change to set typing style ivar. (-[WebView typingStyle]): Return new typing style ivar.
  • WebView.subproj/WebViewPrivate.h: Add ivar for typing style.
2:51 PM Changeset in webkit [6686] by mjs
  • 1 edit
    1 add in trunk/WebCore

Fixed build.

  • ForwardingHeaders/misc/khtml_text_operations.h: Added.
2:37 PM Changeset in webkit [6685] by rjw
  • 10 edits
    6 adds in trunk/WebCore

Part 1 of the new <CANVAS> tag implementation. This patch
adds the boiler plate for the new element.

Reviewed by Dave.

  • ForwardingHeaders/html/html_canvasimpl.h: Added.
  • ForwardingHeaders/rendering/render_canvasimage.h: Added.
  • WebCore.pbproj/project.pbxproj:
  • khtml/ecma/kjs_html.cpp: (KJS::HTMLElement::classInfo): (KJS::HTMLElementFunction::tryCall):
  • khtml/ecma/kjs_html.h: (KJS::HTMLElement::):
  • khtml/ecma/kjs_html.lut.h: (KJS::):
  • khtml/html/dtd.cpp: (DOM::checkChild):
  • khtml/html/html_canvasimpl.cpp: Added. (HTMLCanvasElementImpl::HTMLCanvasElementImpl): (HTMLCanvasElementImpl::~HTMLCanvasElementImpl): (HTMLCanvasElementImpl::id): (HTMLCanvasElementImpl::mapToEntry): (HTMLCanvasElementImpl::parseHTMLAttribute): (HTMLCanvasElementImpl::createRenderer): (HTMLCanvasElementImpl::attach): (HTMLCanvasElementImpl::detach): (HTMLCanvasElementImpl::isURLAttribute):
  • khtml/html/html_canvasimpl.h: Added.
  • khtml/html/htmlparser.cpp: (KHTMLParser::getElement):
  • khtml/misc/htmltags.c: (hash_tag): (findTag):
  • khtml/misc/htmltags.h:
  • khtml/misc/htmltags.in:
  • khtml/rendering/render_canvasimage.cpp: Added. (RenderCanvasImage::RenderCanvasImage): (RenderCanvasImage::~RenderCanvasImage): (RenderCanvasImage::paint): (RenderCanvasImage::layout):
  • khtml/rendering/render_canvasimage.h: Added. (khtml::RenderCanvasImage::renderName): (khtml::RenderCanvasImage::element):
2:30 PM Changeset in webkit [6684] by cblu
  • 4 edits in trunk/WebCore

Fixed: <rdar://problem/3546418>: (when dragging text within an editable HTML doc, the selection should be moved not copied)

Reviewed by kocienda.

  • khtml/editing/htmlediting_impl.cpp: (khtml::MoveSelectionCommandImpl::doApply): implemented
  • khtml/khtml_part.cpp: (KHTMLPart::setDragCaret): make the old drag cursor rect dirty
  • khtml/khtml_part.h:
2:00 PM Changeset in webkit [6683] by mjs
  • 6 edits in trunk/WebCore

Reviewed by John.

  • fixed <rdar://problem/3657363>: (Editing: export innerText, innerHTML, outerText, outerHTML and setters to Objective-C)
  • partial fix for <rdar://problem/3656706>: (Fix innerText and setInnerText DOM extensions)
  • khtml/html/html_elementimpl.cpp: (HTMLElementImpl::innerText): Use plainText() to make the text, to match other browsers. (HTMLElementImpl::outerText): Extended comment.
  • khtml/misc/khtml_text_operations.h:
  • kwq/DOMExtensions.h:
  • kwq/DOMHTML.mm: (-[DOMHTMLElement outerText]): Added new ObjC wrapper for this. (-[DOMHTMLElement setOuterText:]): Ditto.
1:29 PM Changeset in webkit [6682] by kocienda
  • 3 edits in trunk/WebCore

Reviewed by Chris

Defer setting the selection to delete when none has been passed in to the
time that the command is run. This fixes a problem where a command nested
in a composite was not correctly picking up the right selection to begin
its work. Now, the command will correctly use the ending selection of
its parent when no selection has been passed in.

  • khtml/editing/htmlediting_impl.cpp: (khtml::DeleteCollapsibleWhitespaceCommandImpl::DeleteCollapsibleWhitespaceCommandImpl): (khtml::DeleteCollapsibleWhitespaceCommandImpl::doApply): (khtml::DeleteSelectionCommandImpl::DeleteSelectionCommandImpl): (khtml::DeleteSelectionCommandImpl::doApply):
  • khtml/editing/htmlediting_impl.h:
11:27 AM Changeset in webkit [6681] by kocienda
  • 3 edits in trunk/WebKit

Reviewed by John

Improve _bridgeForCurrentSelection so that it is frame-savvy.
Fixup setSelectedDOMRange:affinity: so that it uses the right bridge.

  • WebView.subproj/WebView.m: (-[WebView _bridgeForCurrentSelection]): Use _currentFrame not mainFrame. (-[WebView _currentFrame]): Moved to WebView (WebInternal) category so _bridgeForCurrentSelection can use it. (-[WebView setSelectedDOMRange:affinity:]): Derive the bridge to use from the range passed in; _bridgeForCurrentSelection is not the right way to get at the document for the range.
  • WebView.subproj/WebViewInternal.h: Add _currentFrame declaration.

May 24, 2004:

5:25 PM Changeset in webkit [6680] by darin
  • 2 edits in trunk/WebKit

Reviewed by Ken.

  • fixed <rdar://problem/3666022>: (REGRESSION: crash from infinite regress in -[WebFrameView(WebPrivate) scrollPageDown:])
  • WebView.subproj/WebView.m: (-[WebView _performResponderOperation:sender:]): Helper method that knows how to pass on operations to the responder chain, allowing us to implement operations that will get passed to views inside us as necessary. Moved a few methods to this, and soon will move even more. (-[WebView scrollLineDown:]): Use the above method. (-[WebView scrollLineUp:]): Ditto. (-[WebView scrollPageDown:]): Ditto. (-[WebView scrollPageUp:]): Ditto. (-[WebView copy:]): Ditto. (-[WebView cut:]): Ditto. (-[WebView paste:]): Ditto. (-[WebView delete:]): Ditto. (-[WebView insertBacktab:]): Ditto.
5:18 PM Changeset in webkit [6679] by mjs
  • 1 edit
    2 adds in trunk

Reviewed by Dave.

Added a new simple layout test for outerText.

  • layout-tests/fast/dom/outerText-expected.txt: Added.
  • layout-tests/fast/dom/outerText.html: Added.
3:53 PM Changeset in webkit [6678] by darin
  • 2 edits in trunk/WebCore

Reviewed by Vicki.

  • fixed <rdar://problem/3665813>: (iBench is crashing in TOT)
  • khtml/html/html_formimpl.cpp: (HTMLSelectElementImpl::HTMLSelectElementImpl): Initialize m_options to 0.
3:19 PM Changeset in webkit [6677] by rjw
  • 6 edits
    1 add in trunk/JavaScriptCore

Changed RuntimeArrayImp to inherit from ArrayInstanceImp and
fixed ClassInfo to correctly reflect inheritance. This is required
because of the runtime checks in JSC for arrays, i.e. in
the Function objects apply method.

Reviewed by Ken.

  • bindings/jni/jni_runtime.cpp: (JavaArray::convertJObjectToArray):
  • bindings/objc/objc_utility.mm: (KJS::Bindings::convertObjcValueToValue):
  • bindings/runtime_array.cpp: (RuntimeArrayImp::RuntimeArrayImp):
  • bindings/runtime_array.h:
  • bindings/testM.js: Added.
  • bindings/testbindings.mm: (+[MyFirstInterface webScriptNameForSelector:]): (-[MyFirstInterface logMessages:]): (-[MyFirstInterface logMessage:prefix:]): (-[MyFirstInterface callJSObject::]):
3:18 PM Changeset in webkit [6676] by kocienda
  • 7 edits in trunk/WebCore

Reviewed by Richard

  • khtml/xml/dom_selection.cpp: (DOM::Selection::toRange): Improved the code to return ranges that are convenient to use by WebKit code which needs to perform text-editor-like operations with ranges. Comments in the code describe this behavior. (DOM::Selection::nodeIsBeforeNode): Make this method const.
  • khtml/xml/dom_selection.h: Ditto.
2:55 PM Changeset in webkit [6675] by cblu
  • 21 edits in trunk

WebCore:

Improved editing via drag.

Reviewed by kocienda.

  • khtml/editing/htmlediting.cpp: Renamed PasteMarkupCommand to ReplaceSelectionCommand (khtml::ReplaceSelectionCommand::ReplaceSelectionCommand): (khtml::ReplaceSelectionCommand::~ReplaceSelectionCommand): (khtml::ReplaceSelectionCommand::impl): (khtml::MoveSelectionCommand::MoveSelectionCommand): (khtml::MoveSelectionCommand::~MoveSelectionCommand): (khtml::MoveSelectionCommand::impl):
  • khtml/editing/htmlediting.h: (khtml::):
  • khtml/editing/htmlediting_impl.cpp: (khtml::ReplaceSelectionCommandImpl::ReplaceSelectionCommandImpl): (khtml::ReplaceSelectionCommandImpl::~ReplaceSelectionCommandImpl): (khtml::ReplaceSelectionCommandImpl::commandID): (khtml::ReplaceSelectionCommandImpl::doApply): (khtml::MoveSelectionCommandImpl::MoveSelectionCommandImpl): new command (khtml::MoveSelectionCommandImpl::~MoveSelectionCommandImpl): (khtml::MoveSelectionCommandImpl::commandID): (khtml::MoveSelectionCommandImpl::doApply):
  • khtml/editing/htmlediting_impl.h:
  • khtml/khtml_part.cpp: (KHTMLPart::dragCaret): new (KHTMLPart::setDragCaret): new (KHTMLPart::notifyDragCaretChanged): new (KHTMLPart::paintDragCaret): new
  • khtml/khtml_part.h:
  • khtml/khtmlpart_p.h:
  • khtml/rendering/render_block.cpp: (khtml::RenderBlock::paintObject): paint the drag caret
  • kwq/DOM.mm: (+[DOMDocumentFragment _documentFragmentWithImpl:]): made internally available (-[DOMDocumentFragment _fragmentImpl]):
  • kwq/DOMInternal.h:
  • kwq/WebCoreBridge.h:
  • kwq/WebCoreBridge.mm: (-[WebCoreBridge documentFragmentWithMarkupString:baseURLString:]): new (-[WebCoreBridge documentFragmentWithText:]): new (-[WebCoreBridge replaceSelectionWithFragment:selectReplacement:]): new (-[WebCoreBridge replaceSelectionWithNode:selectReplacement:]): renamed to take the selectReplacement BOOL (-[WebCoreBridge replaceSelectionWithMarkupString:baseURLString:selectReplacement:]): ditto (-[WebCoreBridge replaceSelectionWithText:selectReplacement:]): ditto (-[WebCoreBridge replaceSelectionWithNewline]): moved (-[WebCoreBridge setSelectionToDragCaret]): new (-[WebCoreBridge moveSelectionToDragCaret:]): new (-[WebCoreBridge moveDragCaretToPoint:]): set the drag caret, not the selection (-[WebCoreBridge removeDragCaret]): new

WebKit:

Improved editing via drag

Reviewed by kocienda.

  • WebView.subproj/WebDataSource.m: (-[WebDataSource _documentFragmentWithImageResource:]): made this method return a fragment instead of replace the selection so that the caller do other things with the fragment (-[WebDataSource _documentFragmentWithArchive:]): ditto (-[WebDataSource _replaceSelectionWithArchive:selectReplacement:]): call renamed methods
  • WebView.subproj/WebDataSourcePrivate.h:
  • WebView.subproj/WebDocumentInternal.h:
  • WebView.subproj/WebHTMLView.m: (-[WebHTMLView _documentFragmentFromPasteboard:]): made this method return a fragment instead of replace the selection so that the caller do other things with the fragment (-[WebHTMLView _replaceSelectionWithPasteboard:selectReplacement:]): new (-[WebHTMLView paste:]): call _replaceSelectionWithPasteboard:selectReplacement: (-[WebHTMLView dragOperationForDraggingInfo:]): handle the case where the destination is editable, but the source is not (-[WebHTMLView draggingCancelledWithDraggingInfo:]): new, removes drag caret (-[WebHTMLView draggingUpdatedWithDraggingInfo:]): remove drag caret when we can't handle the drag (-[WebHTMLView concludeDragForDraggingInfo:]): instead of calling paste, move the selection when doing a move and replace the drag caret when doing a copy
  • WebView.subproj/WebHTMLViewPrivate.h:
  • WebView.subproj/WebView.m: (-[WebViewPrivate dealloc]): (-[WebView _setDraggingDocumentView:]): new (-[WebView _dragOperationForDraggingInfo:]): if the current dragging document view changes, tell the previous dragging document view that dragging cancelled (-[WebView draggingExited:]): new, tell the previous dragging document view that dragging cancelled (-[WebView concludeDragOperation:]): release the dragging document view (-[WebView replaceSelectionWithNode:]): pass the selectReplacement BOOL to the bridge (-[WebView replaceSelectionWithText:]): ditto (-[WebView replaceSelectionWithMarkupString:]): ditto (-[WebView replaceSelectionWithArchive:]): ditto (-[WebView pasteAsPlainText:]): ditto (-[WebView insertTab:]): ditto (-[WebView insertText:]): ditto
  • WebView.subproj/WebViewPrivate.h:
1:40 PM Changeset in webkit [6674] by kocienda
  • 4 edits in trunk/WebCore

Reviewed by John

Fixed some life-cycle issues with node iterators and detaching. Big deal is
to detach in DOMNodeIterator dealloc. Otherwise, NodeIterators created from
obj-c leak.

  • khtml/xml/dom2_traversalimpl.cpp: (DOM::NodeIteratorImpl::detach): Only detach if not yet detached.
  • khtml/xml/dom2_traversalimpl.h: (DOM::NodeIteratorImpl::setDetached): New convenience.
  • kwq/DOM.mm: (-[DOMNodeIterator dealloc]): Detach here, if not yet detached; fixes leak.
1:14 PM Changeset in webkit [6673] by kocienda
  • 2 edits in trunk/WebCore

Reviewed by Hyatt

  • khtml/css/css_computedstyle.cpp: (DOM::CSSComputedStyleDeclarationImpl::getPropertyValue): Fixed to return the property value, as it should, instead of the whole property, as it was doing before.
1:01 PM Changeset in webkit [6672] by sullivan
  • 3 edits in trunk/WebKit

WebKit:

Reviewed by Dave.

  • added private RSSFeedReferrer field to WebHistoryItem so RSS feeds in the back/forward list can remember what page (if any) they were initiated from.
  • History.subproj/WebHistoryItem.m: new RSSFeedReferrer ivar in private structure (-[WebHistoryItemPrivate dealloc]): release RSSFeedReferrer (-[WebHistoryItem copyWithZone:]): copy RSSFeedReferrer (-[WebHistoryItem RSSFeedReferrer]): return RSSFeedReferrer (-[WebHistoryItem setRSSFeedReferrer:]): set RSSFeedReferrer
  • History.subproj/WebHistoryItemPrivate.h: declare -RSSFeedReferrer and -setRSSFeedReferrer:

WebBrowser:

Reviewed by Dave.

More work on Emerson show/hide button. Now when the "Show RSS Feed" button
is clicked, we stash away the URL we are expecting to load. When (if) that URL
is loaded, we find the previous URL from the back list and store that in the
RSS feed's history item, so that if we revisit this RSS feed using the back/forward
list, we'll correctly display the "Hide RSS Feed" button. (If the RSS feed's URL
is visited some other way, it won't have a corresponding URL to "return" to, and
the "Hide RSS Feed" button will not appear.)

  • BrowserWebController.h: new ivar and getter/setter for pendingRSSFeedURLString
  • BrowserWebController.m: (-[BrowserWebView dealloc]): release _pendingRSSFeedURLString (-[BrowserWebView pendingRSSFeedURLString]): get _pendingRSSFeedURLString (-[BrowserWebView setPendingRSSFeedURLString:]): set _pendingRSSFeedURLString (-[BrowserWebView counterpartURLForRSS]): get RSS feed referrer from current back/forward list history item
  • BrowserWindowController.m: (-[BrowserWindowController windowShouldGoToURL:]): cleanup noticed in passing: use [[self currentWebView] goToURL:URL] instead of [[self browserDocument] goToURL:URL] because it seems clearer (and does the same thing) (-[BrowserWindowController performQuickSearch:]): ditto (-[BrowserWindowController updateRSSButton]): added comment (-[BrowserWindowController goToCounterpartURLForRSS]): when going to an RSS feed, call setPendingRSSFeedURLString so we will set the referrer on the history item in the upcoming commit
  • LocationChangeHandler.m: (-[LocationChangeHandler webView:didCommitLoadForFrame:]): if the incoming URL matches the pending RSS feed, set the RSS feed referrer on the history item for the incoming URL

May 23, 2004:

9:45 PM Changeset in webkit [6671] by darin
  • 4 edits in trunk/WebCore

Reviewed by Ken.

  • fixed <rdar://problem/3259919>: (Shift click should extend selection)
  • khtml/khtmlpart_p.h: Renamed m_textElement to m_selectionGranularity and m_mouseMovedSinceLastMousePress to m_beganSelectingText.
  • khtml/khtml_part.cpp: (KHTMLPart::handleMousePressEventDoubleClick): Set m_beganSelectingText if the double-click began selecting text. (KHTMLPart::handleMousePressEventTripleClick): Ditto. (KHTMLPart::handleMousePressEventSingleClick): Added code to extend selection if shift is down. (KHTMLPart::khtmlMousePressEvent): Remove code that sets the selection granularity to "by character". We only want to do that if we start selecting with a single click. Otherwise we want to leave the selection granularity alone. (KHTMLPart::khtmlMouseReleaseEvent): Change the code that clears the selection on a plain old click to check the m_beganSelectingText boolean so it won't run when you shift-click, for example.
  • kwq/KWQKHTMLPart.mm: (KWQKHTMLPart::khtmlMouseMoveEvent): Updated for m_textElement name change.
3:45 PM Changeset in webkit [6670] by darin
  • 35 edits
    4 adds
    12 deletes in trunk/WebCore

Reviewed by Ken.

  • went through things marked "unimplemented" or "not implemented" and removed or implemented as many as possible
  • kwq/DOM.mm: (-[DOMNode dispatchEvent:]): Implemented. Also moved DOMAbstractView and DOMDocumentView into DOMViews.mm.
  • kwq/DOM-CSS.mm: (-[DOMDocument getComputedStyle::]): Implemented.
  • kwq/DOMEventsInternal.h: Added.
  • kwq/DOMEvents.mm: (-[DOMEvent type]): Implemented. (-[DOMEvent target]): Implemented. (-[DOMEvent currentTarget]): Implemented. (-[DOMEvent eventPhase]): Implemented. (-[DOMEvent bubbles]): Implemented. (-[DOMEvent cancelable]): Implemented. (-[DOMEvent timeStamp]): Implemented. (-[DOMEvent stopPropagation]): Implemented. (-[DOMEvent preventDefault]): Implemented. (-[DOMEvent initEvent:::]): Implemented. (-[DOMEvent _eventImpl]): Added. (-[DOMEvent _initWithEventImpl:]): Added. (+[DOMEvent _eventWithImpl:]): Added. (-[DOMMouseEvent _mouseEventImpl]): Added. (-[DOMMouseEvent screenX]): Implemented. (-[DOMMouseEvent screenY]): Implemented. (-[DOMMouseEvent clientX]): Implemented. (-[DOMMouseEvent clientY]): Implemented. (-[DOMMouseEvent ctrlKey]): Implemented. (-[DOMMouseEvent shiftKey]): Implemented. (-[DOMMouseEvent altKey]): Implemented. (-[DOMMouseEvent metaKey]): Implemented. (-[DOMMouseEvent button]): Implemented. (-[DOMMouseEvent relatedTarget]): Implemented. (-[DOMMouseEvent initMouseEvent:::::::::::::::]): Implemented. (-[DOMMutationEvent _mutationEventImpl]): Added. (-[DOMMutationEvent relatedNode]): Implemented. (-[DOMMutationEvent prevValue]): Implemented. (-[DOMMutationEvent newValue]): Implemented. (-[DOMMutationEvent attrName]): Implemented. (-[DOMMutationEvent attrChange]): Implemented. (-[DOMMutationEvent initMutationEvent::::::::]): (-[DOMUIEvent _UIEventImpl]): Added. (-[DOMUIEvent view]): Implemented. (-[DOMUIEvent detail]): Implemented. (-[DOMUIEvent initUIEvent:::::]): Implemented. (-[DOMDocument createEvent:]): Implemented.
  • kwq/DOMHTMLInternal.h: Added.
  • kwq/DOMHTML.mm: (+[DOMHTMLOptionsCollection _optionsCollectionWithImpl:]): Added. (-[DOMHTMLOptionsCollection length]): Implemented. (-[DOMHTMLOptionsCollection setLength:]): Implemented. (-[DOMHTMLOptionsCollection item:]): Implemented. (-[DOMHTMLOptionsCollection namedItem:]): Implemented. (-[DOMHTMLSelectElement options]): Implemented.
  • kwq/DOMViews.h: Changed DOMDocumentView to be a category on DOMDocument rather than a separate class.
  • kwq/DOMViewsInternal.h: Added.
  • kwq/DOMViews.mm: Added. (-[DOMAbstractView document]): Implemnted. (-[DOMAbstractView _abstractViewImpl]): Added. (-[DOMAbstractView _initWithAbstractViewImpl:]): Added. (+[DOMAbstractView _abstractViewWithImpl:]): Added. (-[DOMDocument defaultView]): Implemented.
  • khtml/dom/dom2_views.h: Made AbstractView constructor public to allow creation in the bindings. Would not be necessary if the impl classes were used consistently.
  • khtml/html/html_formimpl.h: Added options() function to HTMLSelectElementImpl. Added HTMLOptionsCollectionImpl class.
  • khtml/html/html_formimpl.cpp: (HTMLSelectElementImpl::~HTMLSelectElementImpl): Added code to detach and deref the options collection. (HTMLSelectElementImpl::options): Create an options collection if needed. (HTMLOptionsCollectionImpl::length): Added. Not yet implemented. (HTMLOptionsCollectionImpl::setLength): Ditto. (HTMLOptionsCollectionImpl::item): Ditto. (HTMLOptionsCollectionImpl::namedItem): Ditto.
  • khtml/khtmlview.h: Move unused focusNextPrevChild virtual function inside !APPLE_CHANGES.
  • khtml/khtmlview.cpp: Put the tp, paintBuffer, and formCompletions fields entirely inside !APPLE_CHANGES. Also made QT_NO_TOOLTIP entirely disable the tooltip field. Also put focusNextPrevChild and formCompletionItems functions inside !APPLE_CHANGES.
  • khtml/rendering/render_text.h: Removed unused isFixedWidthFont member function.
  • khtml/rendering/render_text.cpp: Ditto.
  • kwq/KWQCursor.h: Removed unused pos member function.
  • kwq/KWQCursor.mm: Ditto.
  • kwq/KWQFontMetrics.h: Removed unused rightBearing and leftBearing member functions.
  • kwq/KWQFontMetrics.mm: Ditto.
  • kwq/KWQKComboBox.h: Removed KCompletionBase as a base class.
  • kwq/KWQKConfigBase.h: Removed unused readBoolEntry, writeEntry, and readListEntry member functions.
  • kwq/KWQKConfigBase.mm: Ditto. (KConfig::readEntry): Improved "not implemented" message to indicate which key is uinimplemented. (KConfig::readNumEntry): Ditto. (KConfig::readUnsignedNumEntry): Ditto.
  • kwq/KWQKLineEdit.h: Removed everything, since all the KLineEdit stuff was unused. Changed KLineEdit to just be a typedef for QLineEdit.
  • kwq/KWQSlot.mm: Removed slotAutoScroll. (KWQSlot::KWQSlot): And from here. (KWQSlot::call): And from here.
  • kwq/KWQTextStream.h: Removed unused QTextOStream and QTextIStream.
  • kwq/KWQTextStream.mm: Removed unused QTextIStream function. Also made buffer sizes larger so we don't have any problems on 64-bit systems. 10 bytes might not be long enough to sprintf an integer or a long or a pointer, but 100 bytes surely will.
  • kwq/KWQWidget.h: Removed unused focusNextPrevChild.
  • kwq/KWQWidget.mm: Ditto.
  • WebCore.pbproj/project.pbxproj: Removed some files, added others.
  • ForwardingHeaders/kcompletionbox.h: Emptied out, no KWQKCompletionBox.h any more.
  • ForwardingHeaders/kiconloader.h: Emptied out, no KWQKIconLoader.h any more.
  • ForwardingHeaders/kmimetype.h: Emptied out, no KWQKMimeType.h any more.
  • ForwardingHeaders/ksimpleconfig.h: Emptied out, no KWQKSimpleConfig.h any more.
  • ForwardingHeaders/qfontinfo.h: Emptied out, no KWQFontInfo.h any more.
  • ForwardingHeaders/qtooltip.h: Replaced with define of QT_NO_TOOLTIP, no KWQToolTip.h any more.
  • kwq/KWQCompletion.h: Removed.
  • kwq/KWQCompletion.mm: Removed.
  • kwq/KWQFontInfo.h: Removed.
  • kwq/KWQFontInfo.mm: Removed.
  • kwq/KWQKCompletionBox.h: Removed.
  • kwq/KWQKIconLoader.h: Removed.
  • kwq/KWQKIconLoader.mm: Removed.
  • kwq/KWQKMimeType.h: Removed.
  • kwq/KWQKMimeType.mm: Removed.
  • kwq/KWQKSimpleConfig.h: Removed.
  • kwq/KWQKSimpleConfig.mm: Removed.
  • kwq/KWQToolTip.h: Removed.
3:34 PM Changeset in webkit [6669] by darin
  • 6 edits in trunk/WebKit

Reviewed by Ken.

  • implemented some of the trivial WebView editing operations; some had bug reports, to wit:
  • fixed <rdar://problem/3655342>: (Editing: -centerSelectionInVisibleArea: method unimplemented (WebKit editing API))
  • fixed <rdar://problem/3655398>: (Editing: -deleteWordBackward: method unimplemented (WebKit editing API))
  • fixed <rdar://problem/3655397>: (Editing: -deleteWordForward: method unimplemented (WebKit editing API))
  • fixed <rdar://problem/3655387>: (Editing: -insertBacktab: method unimplemented (WebKit editing API))
  • fixed <rdar://problem/3655386>: (Editing: -insertTab: method unimplemented (WebKit editing API))
  • fixed <rdar://problem/3655351>: (Editing: -moveWordBackward: method unimplemented (WebKit editing API))
  • fixed <rdar://problem/3655352>: (Editing: -moveWordBackwardAndModifySelection: method unimplemented (WebKit editing API))
  • fixed <rdar://problem/3655353>: (Editing: -moveWordForward: method unimplemented (WebKit editing API))
  • fixed <rdar://problem/3655354>: (Editing: -moveWordForwardAndModifySelection: method unimplemented (WebKit editing API))
  • fixed <rdar://problem/3655374>: (Editing: -pasteAsPlainText: method unimplemented (WebKit editing API))
  • fixed <rdar://problem/3655362>: (Editing: -scrollLineDown: method unimplemented (WebKit editing API))
  • fixed <rdar://problem/3655363>: (Editing: -scrollLineUp: method unimplemented (WebKit editing API))
  • WebView.subproj/WebView.m: (-[WebView centerSelectionInVisibleArea:]): Implemented. The implementation isn't perfect, but it's hooked up. It simply calls ensureCaretVisible for now. (-[WebView moveBackward:]): Implemented. The WebCore API already has a way to specify backward as opposed to left. A separate issue is the fact that these operations don't have bi-di-savvy implementations, but now this method is hooked up and will work at least for left-to-right text. (-[WebView moveBackwardAndModifySelection:]): Ditto. (-[WebView moveForward:]): Ditto. (-[WebView moveForwardAndModifySelection:]): Ditto. (-[WebView moveWordBackward:]): Ditto. (-[WebView moveWordBackwardAndModifySelection:]): Ditto. (-[WebView moveWordForward:]): Ditto. (-[WebView moveWordForwardAndModifySelection:]): Ditto. (-[WebView scrollLineDown:]): Forward to WebFrameView. (-[WebView scrollLineUp:]): Ditto. (-[WebView scrollPageDown:]): Ditto. (-[WebView scrollPageUp:]): Ditto. (-[WebView delete:]): Implemented. Follows pattern used in cut, copy, and paste. (-[WebView pasteAsPlainText:]): Implemented. Calls delegate, then replaceSelectionWithText: on the bridge. (-[WebView insertTab:]): Implemented. Calls delegate, then replaceSelectionWithText: on the bridge. (-[WebView insertBacktab:]): Implemented. Does nothing. If we ever change so that you can use a WebView as a field editor, then we might have to add code here. (-[WebView deleteWordForward:]): Implement by calling moveForwardAndModifySelection: and then delete:. Might not be a perfect implementation in the presence of delegates who refuse to delete because it will change the selection even if the delete is disallowed. (-[WebView deleteWordBackward:]): Implement by calling moveBackwardAndModifySelection: and then delete:. Same issue about about delegates as deleteWordForward:.
  • WebView.subproj/WebHTMLView.m: (-[WebHTMLView _pasteFromPasteboard:]): Added a FIXME.
  • DOM.subproj/DOMViews.h: Updated from recent change to WebCore.

May 22, 2004:

12:18 AM Changeset in webkit [6668] by darin
  • 2 edits in trunk/JavaScriptCore

Reviewed by Maciej.

  • fixed <rdar://problem/3664260>: (JS needs to listen to timezone change notifications)
  • kjs/date_object.cpp: (CopyLocalTimeZone): As per Chris Kane and Jordan Hubbard, use <notify.h> with a hardcoded string of "com.apple.system.timezone", and do CFTimeZoneResetSystem since CoreFoundation doesn't do this itself. Turns out this affects the default time zone as long as it hasn't been set explicitly.
Note: See TracTimeline for information about the timeline view.