undo问题
This commit is contained in:
@@ -361,8 +361,7 @@ export class Stage extends Laya.Script {
|
||||
const undo = this.data.pop_undo()
|
||||
if (undo) {
|
||||
// console.log("onClickUndo>>>>", JSON.stringify(undo))
|
||||
this.selectedBlock = this.blocks[undo.index]
|
||||
this.onApplyBlock(this.selectedBlock)
|
||||
this.onApplyBlock(this.blocks[undo.index])
|
||||
if (undo.notes && undo.notes.length > 0) {
|
||||
this.selectedBlock.setNotes(undo.notes)
|
||||
} else {
|
||||
@@ -372,8 +371,7 @@ export class Stage extends Laya.Script {
|
||||
const undos = this.data.get_undos()
|
||||
if (undos.length > 0) {
|
||||
const last = undos[undos.length - 1]
|
||||
this.selectedBlock = this.blocks[last.index]
|
||||
this.onApplyBlock(this.selectedBlock)
|
||||
this.onApplyBlock(this.blocks[last.index])
|
||||
}
|
||||
this.onSetBlock(this.selectedBlock)
|
||||
this.onUpdateCandys()
|
||||
|
||||
Reference in New Issue
Block a user