snapshot-command.js 388 B

1234567891011121314151617181920212223
  1. class SnapshotCommand {
  2. undoData;
  3. redoData;
  4. panel;
  5. manager;
  6. constructor(undoData, redoData) {
  7. this.undoData = undoData;
  8. this.redoData = redoData;
  9. }
  10. async undo() {
  11. await this.execute(this.undoData);
  12. }
  13. async redo() {
  14. await this.execute(this.redoData);
  15. }
  16. async execute() {}
  17. }
  18. module.exports = SnapshotCommand;