fix: 支持清空操作框,增加movingcache更新场景

This commit is contained in:
0JARVIS0 2019-11-29 12:20:50 +08:00
parent 93b0eac9be
commit 6e789867ed

View File

@ -15,6 +15,7 @@ Component({
paintCount: 0,
currentPalette: {},
movingCache: {},
needClear: false,
/**
* 组件的属性列表
*/
@ -60,7 +61,9 @@ Component({
type: Object,
observer: function (newVal, oldVal) {
if (newVal) {
this.doAction(newVal)
this.doAction(newVal, (callbackInfo) => {
this.movingCache = callbackInfo
})
}
},
},
@ -72,7 +75,21 @@ Component({
frontStyle: style
})
}
}
},
clearActionBox: {
type: Boolean,
observer: function (needClear) {
if (needClear && !this.needClear) {
if (this.frontContext) {
this.frontContext.draw()
this.touchedView = {};
this.prevFindedIndex = this.findedIndex
this.findedIndex = -1;
}
}
this.needClear = needClear
}
},
},
data: {