Closed MorphZhou closed 4 years ago
the same issue as one in the jgraph/mxgraph2 repo
the key code is here: https://github.com/jgraph/mxgraph/blob/master/javascript/src/js/view/mxGraph.js#L8008
this.view.setTranslate((horizontal) ? Math.floor(t.x - bounds.x * s + dx * cx / s) : t.x, (vertical) ? Math.floor(t.y - bounds.y * s + dy * cy / s) : t.y);
the expressionbounds.x * s and bounds.y * s should be bounds.x / s and bounds.y / s
bounds.x * s
bounds.y * s
bounds.x / s
bounds.y / s
the same issue as one in the jgraph/mxgraph2 repo
the key code is here: https://github.com/jgraph/mxgraph/blob/master/javascript/src/js/view/mxGraph.js#L8008
the expression
bounds.x * s
andbounds.y * s
should bebounds.x / s
andbounds.y / s