W3C home > Mailing lists > Public > whatwg@whatwg.org > October 2011

[whatwg] UndoManager: restoring selection after undoing deletion

From: Ryosuke Niwa <rniwa@webkit.org>
Date: Wed, 26 Oct 2011 13:10:15 -0700
Message-ID: <CABNRm60zcHOOtv5wziU49seibg=8VRKF4M=SUi3B87pEBHrZpA@mail.gmail.com>
On Wed, Oct 26, 2011 at 1:03 PM, Ehsan Akhgari <ehsan at mozilla.com> wrote:

> > Say you had "hello world" and "world" is deleted by an user. When the
> > user undoes the deletion, WebKit selects "world" whereas Firefox and
> > Internet Explorer do not select "world". WebKit's behavior matches
> > Mac's NSTextView and we probably would like to keep the current
> > behavior.
>
> This confuses me. I think that WebKit's behavior doesn't make a lot of
> sense (at least in every case).  For example, when Ctrl+Backspacing after a
> word.  But moreover, why is this relevant to the question of whether/how we
> should restore a selection after undoing an operation?
>

WebKit's trying to match Mac's NSTextView here. This is relevant because
unapplying / reapplying an automatic transaction should behave like
unapplying / reapplying native editing actions.

- Ryosuke
Received on Wednesday, 26 October 2011 13:10:15 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 16:59:37 UTC