We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 49360fd commit 6bed83bCopy full SHA for 6bed83b
src/editor/core/draw/control/Control.ts
@@ -272,8 +272,6 @@ export class Control {
272
}
273
274
public initControl() {
275
- const isReadonly = this.draw.isReadonly()
276
- if (isReadonly) return
277
const elementList = this.getElementList()
278
const range = this.getRange()
279
const element = elementList[range.startIndex]
@@ -296,6 +294,8 @@ export class Control {
296
294
// 销毁旧激活控件
297
295
this.destroyControl()
298
// 激活控件
+ const isReadonly = this.draw.isReadonly()
+ if (isReadonly) return
299
const control = element.control!
300
if (control.type === ControlType.TEXT) {
301
this.activeControl = new TextControl(element, this)
0 commit comments