Implemented CTRL+Z Undo