[whatwg] UndoManager: rationale for having undoManager.position and undoManager.item?

Caio Marcelo de Oliveira Filho caio.oliveira at openbossa.org
Mon Jun 25 15:23:19 PDT 2012


In the June 8, 2012 version, there's a note after the description of

"Note: Being able to access an arbitrary element in the undo
transaction history is needed to allow scripts to determine whether
new DOM transaction and the last DOM transaction should being to the
same entry or not."

I'm guessing undoManager.position exists to be used together with
undoManager.item to achieve this.

After checking the problem descriptions again
(http://wiki.whatwg.org/wiki/UndoManager_Problem_Descriptions), I'm
wondering if the use case is only checking the last transaction,
couldn't we have a smaller API? Or we have other situations where
"peeking" in the undo stack is desired? Maybe is needed for a specific
case in Collaborative editing that I couldn't grasp in the problem


Caio Marcelo de Oliveira Filho
openBossa @ INdT - Instituto Nokia de Tecnologia

More information about the whatwg mailing list