Skip to content

Commit

Permalink
chore:
Browse files Browse the repository at this point in the history
  • Loading branch information
army8735 committed Dec 31, 2024
1 parent 2c6db6e commit 0ca173d
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 6 deletions.
2 changes: 1 addition & 1 deletion src/control/BasicPanel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -522,7 +522,7 @@ class BasicPanel extends Panel {
}

override show(nodes: Node[]) {
this.nodes = nodes;
super.show(nodes);
this.data = [];
const panel = this.panel;
if (this.listener.state === State.EDIT_GEOM) {
Expand Down
2 changes: 1 addition & 1 deletion src/control/BlurPanel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -356,7 +356,7 @@ class BlurPanel extends Panel {
}

override show(nodes: Node[]) {
this.nodes = nodes;
super.show(nodes);
const panel = this.panel;
if (!nodes.length || this.listener.state === State.EDIT_GEOM) {
panel.style.display = 'none';
Expand Down
2 changes: 2 additions & 0 deletions src/control/Geometry.ts
Original file line number Diff line number Diff line change
Expand Up @@ -156,6 +156,7 @@ export default class Geometry {
node.refresh();
node.checkPointsChange();
this.show(node);
listener.emit(Listener.POINT_NODE, [node]);
}
}
}
Expand Down Expand Up @@ -217,6 +218,7 @@ export default class Geometry {
if (isDrag || isControlF || isControlT) {
isDrag = isControlF = isControlT = false;
this.update();
listener.emit(Listener.POINT_NODE, [this.node]);
}
});

Expand Down
1 change: 1 addition & 0 deletions src/control/Listener.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2033,6 +2033,7 @@ export default class Listener extends Event {
static VISIBLE_NODE = 'VISIBLE_NODE';
static ART_BOARD_NODE = 'ART_BOARD_NODE';
static CONSTRAIN_PROPORTION_NODE = 'CONSTRAIN_PROPORTION_NODE';
static POINT_NODE = 'POINT_NODE';
static ZOOM_PAGE = 'ZOOM_PAGE';
static CONTEXT_MENU = 'CONTEXT_MENU';
static STATE_CHANGE = 'STATE_CHANGE';
Expand Down
4 changes: 2 additions & 2 deletions src/control/OpacityPanel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -175,8 +175,8 @@ class OpacityPanel extends Panel {
});
}

show(nodes: Node[]) {
this.nodes = nodes;
override show(nodes: Node[]) {
super.show(nodes);
const panel = this.panel;
if (!nodes.length || this.listener.state === State.EDIT_GEOM) {
panel.style.display = 'none';
Expand Down
4 changes: 2 additions & 2 deletions src/control/ShadowPanel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -371,8 +371,8 @@ class ShadowPanel extends Panel {
});
}

show(nodes: Node[]) {
this.nodes = nodes;
override show(nodes: Node[]) {
super.show(nodes);
const panel = this.panel;
// 老的清除
this.panel.querySelectorAll('.line').forEach(item => {
Expand Down

0 comments on commit 0ca173d

Please sign in to comment.