@hailin-zheng/editor-core 1.0.55 → 1.0.56

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.js CHANGED
@@ -6660,6 +6660,7 @@ class DocumentSelection {
6660
6660
  const range = this.selectionState.range;
6661
6661
  //转换选区
6662
6662
  this.transformRange();
6663
+ this.selectionState.clear();
6663
6664
  if (!range) {
6664
6665
  return false;
6665
6666
  }
@@ -6781,7 +6782,7 @@ class SelectionState {
6781
6782
  */
6782
6783
  rangeDirty = false;
6783
6784
  addRange(range) {
6784
- //this.clear();
6785
+ this.clear();
6785
6786
  this.range = range;
6786
6787
  this.rangeDirty = true;
6787
6788
  this.onChangedEvent.next();
@@ -16034,10 +16035,10 @@ class CanvasTextEditor {
16034
16035
  */
16035
16036
  refreshView(rePaint) {
16036
16037
  const ssChanged = this.documentSelection.updateSelectionState();
16037
- this.setCursor();
16038
16038
  this.selectionOverlays.getSelectionTreeData();
16039
16039
  this.documentPaint.refreshView(rePaint);
16040
16040
  this.setScrollSize();
16041
+ this.setCursor();
16041
16042
  ssChanged && this.selectionChanged.next(this.documentSelection.selectionState);
16042
16043
  this.docRule.refreshRule();
16043
16044
  }