X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/526954c5968baa29218c994ec48e476ae2bd4b9f..1b7751aaa9a86d76a850b9267bc0c201e3cea30f:/interface/wx/cmdproc.h diff --git a/interface/wx/cmdproc.h b/interface/wx/cmdproc.h index 2f418bf36b..5d948d6c27 100644 --- a/interface/wx/cmdproc.h +++ b/interface/wx/cmdproc.h @@ -75,7 +75,7 @@ public: know the ordering of Undos; the user can never Undo at an arbitrary position in the command history. - Restore the entire document state (perhaps using document - transactioning). Potentially very inefficient, but possibly easier to + transacting). Potentially very inefficient, but possibly easier to code if the user interface and data are complex, and an "inverse execute" operation is hard to write. The docview sample uses the first method, to remove or restore segments in the drawing. @@ -126,6 +126,12 @@ public: */ virtual bool CanUndo() const; + /** + Returns @true if the currently-active command can be redone, @false + otherwise. + */ + virtual bool CanRedo() const; + /** Deletes all commands in the list and sets the current command pointer to @NULL. @@ -137,6 +143,11 @@ public: */ wxList& GetCommands(); + /** + Returns the current command. + */ + wxCommand *GetCurrentCommand() const; + /** Returns the edit menu associated with the command processor. */ @@ -235,6 +246,12 @@ public: */ virtual bool Submit(wxCommand* command, bool storeIt = true); + /** + Just store the command without executing it. The command is stored in the + history list, and the associated edit menu (if any) updated appropriately. + */ + virtual void Store(wxCommand *command); + /** Undoes the last command executed. */