not really known
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

25 lines
609 B

  1. /* Undo button will undo the canvas using the history */
  2. define([], function() {
  3. function undo() {
  4. var data = PaintApp.undoCanvas();
  5. }
  6. function initGui() {
  7. var undoButton = document.getElementById('undo-button');
  8. PaintApp.elements.undoButton = undoButton;
  9. undoButton.addEventListener('click', undo);
  10. }
  11. function hideGui() {
  12. var undoButton = document.getElementById('undo-button');
  13. PaintApp.elements.undoButton = undoButton;
  14. PaintApp.elements.undoButton.disabled = true;
  15. }
  16. var undoButton = {
  17. initGui: initGui,
  18. hideGui: hideGui
  19. };
  20. return undoButton;
  21. });