feat:add control readonly

This commit is contained in:
Hufe921
2022-04-10 20:22:42 +08:00
parent b5b2c8ff6b
commit 193b9d7a41
2 changed files with 3 additions and 1 deletions
+2
View File
@@ -79,6 +79,8 @@ export class Control {
}
public initControl() {
const isReadonly = this.draw.isReadonly()
if (isReadonly) return
const elementList = this.getElementList()
const range = this.getRange()
const element = elementList[range.startIndex]
+1 -1
View File
@@ -167,7 +167,7 @@ export class CanvasEvent {
y: evt.offsetY
})
// 激活控件
if (positionResult.isControl) {
if (positionResult.isControl && !isReadonly) {
const {
index,
isTable,