|
@@ -22,6 +22,9 @@ export class SUndoStack extends SObject {
|
|
|
return this.cmdStack.length <= 0;
|
|
|
}
|
|
|
|
|
|
+
|
|
|
+ isChange: boolean = false;
|
|
|
+
|
|
|
|
|
|
* 执行redo操作
|
|
|
*/
|
|
@@ -32,6 +35,7 @@ export class SUndoStack extends SObject {
|
|
|
|
|
|
this._index++;
|
|
|
this.cmdStack[this._index].redo();
|
|
|
+ this.isChange = true;
|
|
|
}
|
|
|
|
|
|
|
|
@@ -44,6 +48,7 @@ export class SUndoStack extends SObject {
|
|
|
|
|
|
this.cmdStack[this._index].undo();
|
|
|
this._index--;
|
|
|
+ this.isChange = true;
|
|
|
}
|
|
|
|
|
|
|
|
@@ -70,6 +75,7 @@ export class SUndoStack extends SObject {
|
|
|
clear(): void {
|
|
|
this.cmdStack.length = 0;
|
|
|
this._index = -1;
|
|
|
+ this.isChange = true;
|
|
|
}
|
|
|
|
|
|
|
|
@@ -106,6 +112,7 @@ export class SUndoStack extends SObject {
|
|
|
|
|
|
this.cmdStack.push(cmd);
|
|
|
this._index = this.cmdStack.length - 1;
|
|
|
+ this.isChange = true;
|
|
|
}
|
|
|
|
|
|
|