Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

is:issue is:open node节点的zIndex设置了显示不会变化,这是为啥 #25

Open
evillier opened this issue Jun 29, 2020 · 0 comments

Comments

@evillier
Copy link

您好:

我是这么写的
zIndexAdd: function () {
if (editor.currentNode instanceof JTopo.Node) {
console.log(editor.currentNode.zIndex)
editor.currentNode.zIndex =+ 10;//node的层级属性zIndex的值发生了变化。但是图形却没有移动到上层。初始化整个图形zIndex还是有效的。就是动态改变图形不会变层级。
}
}
,其他的比如角度之类的已修改就变了。
还发现只要设置的zIndex再做其他操作都不生效,比如先设置zIndex,再删除这个节点也不行。
editor.currentNode.zIndex =+ 10;
editor.scene.remove(editor.currentNode.zIndex) //结果节点删除不了
但是先设置其他的再操作不会这样。
比如
editor.currentNode.rotate =+ 10;
editor.scene.remove(editor.currentNode.zIndex)//结果节点可删除

求解。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant