From 25ba9a047e467ed317561ab694b4ea5bb6136915 Mon Sep 17 00:00:00 2001 From: fan <18706759286@163.com> Date: Fri, 10 Dec 2021 17:20:10 +0800 Subject: [PATCH] =?UTF-8?q?=E5=88=97=E8=BD=A6=E8=AF=A6=E6=83=85=E6=98=BE?= =?UTF-8?q?=E7=A4=BA=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/jmapNew/shape/graph/Train/EMouse.js | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/jmapNew/shape/graph/Train/EMouse.js b/src/jmapNew/shape/graph/Train/EMouse.js index f4301f899..264214dcc 100644 --- a/src/jmapNew/shape/graph/Train/EMouse.js +++ b/src/jmapNew/shape/graph/Train/EMouse.js @@ -171,7 +171,13 @@ class EMouse extends Group { } mouseover() { if (this.device.model.style.Train.common.trainTip) { - const zrRect = { x: this.device.model.model.zrOptions.offsetX, y: this.device.model.model.zrOptions.offsetY, width: store.state.config.width, height: store.state.config.height }; + const scaleRate = parseFloat(this.device.model.model.zrOptions.scaleRate); + const zrRect = { + x: this.device.model.model.zrOptions.offsetX / scaleRate, + y: this.device.model.model.zrOptions.offsetY / scaleRate, + width: store.state.config.width / scaleRate, + height: store.state.config.height / scaleRate + }; this.device.deviceModel.__down = true; const arrowTextRect = this.arrowText.getBoundingRect(); const zrRectX = zrRect.x + zrRect.width;