PDA

View Full Version : QUndoStack: How can I cancel in QUndoCommand::redo() the QUndoStack::push() function?



mikemc
3rd August 2010, 12:47
Hi!

I am calling QUndoStack::push( myCommand )
In myCommand::redo() I am calling a function called "bool dosomething()"
If the result is false I want to cancel the push()-Function.

If this is not possible, how can I remove explicitly the last QUndoCommand from QUndoStack?

Sorry for my broken english...

Mike from Vienna