I want to add undo & redo feature to the finger paint, does anyone got ideas?
it is suitable to use in finger paint of android API demos.
I want to add undo & redo feature to the finger paint, does anyone
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You want to record your drawing steps, such as using an array of Paths every time a new path is drawn. When the undo button is pressed, you decrease your “draw counter” by one and redraw all the paths up to your “draw counter”. When you redo, increase your “draw counter” by one and redraw all the paths up to the counter (or end of the array, naturally!). And after undoing and then drawing anew, remove the later entries from the draw array.