This commit is contained in:
Kovid Goyal 2014-09-21 15:28:15 +05:30
parent 55288fcfdc
commit 1c7a90f21e

View File

@ -176,6 +176,8 @@ def make_undoable(spinbox):
if self.allow_undo: if self.allow_undo:
cmd = UndoCommand(self, val) cmd = UndoCommand(self, val)
self.undo_stack.push(cmd) self.undo_stack.push(cmd)
else:
self.undo_stack.clear()
if hasattr(self, 'setDateTime'): if hasattr(self, 'setDateTime'):
self.setDateTime(val) self.setDateTime(val)
elif hasattr(self, 'setValue'): elif hasattr(self, 'setValue'):