WebCore:
authorsullivan <sullivan@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 14 Dec 2004 19:17:31 +0000 (19:17 +0000)
committersullivan <sullivan@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 14 Dec 2004 19:17:31 +0000 (19:17 +0000)
commitae6226bc2a0529cc76ed15806395d8ea66c2c2d2
tree0bb861a4433e65cbb0d1fbae13e7701449c3e55c
parentd3d2221e360c5a54f2efd263a50a138833534ef5
WebCore:

        Reviewed by Ken.

        - architecture for WebCore part of fix for <rdar://problem/3790011> undoable operations all say "Undo" in the menu,
        no specific action names

        The remaining step is to make each EditCommand subclass override editingAction() to return an
        appropriate value. (Unfortunately the mapping between subclass and user-distinguishable action
        is not completely straightforward, so this next step isn't trivial.)

        * khtml/editing/htmlediting.h:
        new enum for HTMLEditAction

        * khtml/editing/htmlediting.cpp:
        (khtml::EditCommandPtr::editingAction):
        new method, calls through to EditCommand
        (khtml::EditCommand::editingAction):
        new method for subclasses to override, returns HTMLEditActionUnspecified at this level
        (khtml::TypingCommand::editingAction):
        proof of concept override, returns HTMLEditActionTyping

        * kwq/KWQKHTMLPart.h:
        declare new private bottleneck method registerCommandForUndoOrRedo
        * kwq/KWQKHTMLPart.mm:
        (KWQKHTMLPart::registerCommandForUndoOrRedo):
        new bottleneck method to reduce code duplication; now calls over the bridge
        to get the localized string to use for the Undo action name
        (KWQKHTMLPart::registerCommandForUndo):
        now calls new bottleneck method
        (KWQKHTMLPart::registerCommandForRedo):
        now calls new bottleneck method

        * kwq/WebCoreBridge.h:
        new enum for WebUndoAction, maps directly to HTMLEditAction.
        Declaration of nameForUndoAction:

WebKit:

        Reviewed by Ken.

        - WebKit part of fix for <rdar://problem/3790011> undoable operations all say "Undo" in the menu,
        no specific action names

        * WebCoreSupport.subproj/WebBridge.m:
        (-[WebBridge nameForUndoAction:]):
        renamed from setUndoActionNamePlaceholder, replaced arbitrary integers with enum values, and
        handled new "unspecified" case as a fallback

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@8206 268f45cc-cd09-0410-ab3c-d52691b4dbfc
WebCore/ChangeLog-2005-08-23
WebCore/khtml/editing/htmlediting.cpp
WebCore/khtml/editing/htmlediting.h
WebCore/kwq/KWQKHTMLPart.h
WebCore/kwq/KWQKHTMLPart.mm
WebCore/kwq/WebCoreBridge.h
WebKit/ChangeLog
WebKit/WebCoreSupport.subproj/WebBridge.m