I try to make Undo / Redo functions but it doesn't work

MrHax

New Member
I try to make undo redo functions but when I click undo or redo buttons I recive just text message redo was clicked. This is my code from CanvasView\[code\]public void Undo() { // TODO Auto-generated method stub if (paths.size()>0) { undonePaths.add(paths.remove(paths.size()-1)); invalidate(); }}public void Redo() { // TODO Auto-generated method stub if (undonePaths.size()>0) { paths.add(undonePaths.remove(undonePaths.size()-1)); invalidate(); }}\[/code\]
 
Back
Top