[Project_owners] Manually adding things to the undo pile

Erwin Wessels erwin at transpontine.com
Wed Oct 15 14:38:25 EDT 2003



>> I think you do this by creating an nsITransaction and adding it to 
>> the transaction manager. The transaction does the operation and 
>> handles undo/redo. There's an example in 
>> chrome://editor/content/EditorCommandsDebug.js
>
>
> editor.beginTransaction();
> ...
> editor.endTransaction();
>
> This creates an undo/redo block. See:
>
> chrome://editor/content/editor.js
>
> Does textbox have an editor object to use this I wonder?

No, it does not, I know from personal experience.

-E

-- 
This is a signature.




More information about the Project_owners mailing list