#523 Alternative (no alt-key) merge mode

closed-rejected
Kimmo Varis
None
3
2004-04-03
2004-02-06
Kimmo Varis
No

RFE #837803 Make Alt key optional.

Finally, this many-many times discussed and requested
feature is implemented!

It was suprisingly simple after all. Idea is to set
both buffers Read-Only when in simple mode. That
prevents editing, but allows copying text with mouse
etc. When user presses cursor key, we trap it in
CMergeEditView::PreTranslateMessage() and call normal
merge functions. CMergeDoc::ListCopy() first checks if
we are in simple mode and unsets ReadOnly status while
copying/deleting lines.

Weak point in this patch is keydown-event handling in
PreTranslateMessage(). Its not efficient way, but I
don't currently know better way to do it.

And one issue is of course name! I choosed "Simple"
mode, because it kind of describes this mode, merging
and diff navigating is simpler.

But I really hope somebody comes with better suggestion
for name.

Perry, maybe you can make experimental patch-demo from
this patch someday?

Discussion

1 2 > >> (Page 1 of 2)
  • Kimmo Varis
    Kimmo Varis
    2004-02-06

    Original and altered files

     
    Attachments
  • Perry
    Perry
    2004-02-06

    Logged In: YES
    user_id=60964

    I will try to make some experimental releases this weekend.

     
  • Kimmo Varis
    Kimmo Varis
    2004-02-06

    • summary: Simple (no alt-key) merge mode --> Alternative (no alt-key) merge mode
     
  • Kimmo Varis
    Kimmo Varis
    2004-02-06

    Updated patch, now "Merging mode"

     
    Attachments
  • Kimmo Varis
    Kimmo Varis
    2004-02-06

    Logged In: YES
    user_id=631874

    Attached new patch, menu item is now "Merge mode" (gah, typo
    in patch description). It's checkbox item in menu, and F7 is
    shortcut key for it.

     
  • Perry
    Perry
    2004-02-07

    Logged In: YES
    user_id=60964

    Experimental release 2.1.5.10 (patch demo), released today,
    contains this patch.

     
  • Kimmo Varis
    Kimmo Varis
    2004-02-09

    Logged In: YES
    user_id=631874

    I've locally modified code to store state of normal/merging
    mode. I don't know yet how to deal with that ro-state. Its
    kind of nice we show in statusbar that files are read-only
    etc. But then I'd have to restore files' original states,
    which I now lose.

     
  • Kimmo Varis
    Kimmo Varis
    2004-02-22

    Updated patch

     
    Attachments
  • Kimmo Varis
    Kimmo Varis
    2004-02-22

    Logged In: YES
    user_id=631874

    Attaching updated patch merged to CVS 2004-02-22
    (MergeMode2.zip).

    Bugs fixed:
    - mode is remembered between sessions
    - no indicator in statusbar when dirview is active
    - restore file's read-only status (do not lose read-only)
    - saving works from merging mode :)

    Just noticed that undo and closing window with ESC key does
    not work with this patch.

     
  • Kimmo Varis
    Kimmo Varis
    2004-02-25

    Updated patch

     
    Attachments
1 2 > >> (Page 1 of 2)