undo method
void
undo()
Undoes the last drawing or action.
Implementation
void undo() {
if (_history[_currentPage]?.isNotEmpty == true) {
var lastAction = _history[_currentPage]!.removeLast();
_undoStack[_currentPage]!.add(lastAction);
notifyListeners();
}
}