mirror of
https://github.com/Tencent/tmagic-editor.git
synced 2025-04-06 03:57:56 +08:00
fix: 修复快速点选拖动时有残影的问题
This commit is contained in:
parent
2e12812aac
commit
a52d25fb70
@ -83,6 +83,10 @@ export default class StageCore extends EventEmitter {
|
|||||||
})
|
})
|
||||||
.on('highlight', async (event: MouseEvent) => {
|
.on('highlight', async (event: MouseEvent) => {
|
||||||
await this.setElementFromPoint(event);
|
await this.setElementFromPoint(event);
|
||||||
|
if (this.highlightedDom === this.selectedDom) {
|
||||||
|
this.highlightLayer.clearHighlight();
|
||||||
|
return;
|
||||||
|
}
|
||||||
this.highlightLayer.highlight(this.highlightedDom as HTMLElement);
|
this.highlightLayer.highlight(this.highlightedDom as HTMLElement);
|
||||||
this.emit('highlight', this.highlightedDom);
|
this.emit('highlight', this.highlightedDom);
|
||||||
})
|
})
|
||||||
|
Loading…
x
Reference in New Issue
Block a user