Seneral / Node_Editor_Framework

A flexible and modular Node Editor Framework for creating node based displays and editors in Unity
https://nodeeditor.seneral.dev
MIT License
2.01k stars 415 forks source link

DrawNode #131

Closed AtheosCode closed 7 years ago

AtheosCode commented 7 years ago

Can we use GUI. Window draw Node to repair the focus the bugs need to click twice。

Seneral commented 7 years ago

GUI.window has many limitations and I've come to the conclusion long ago that we're going to be better off making custom windows and handling all controls ourselves. The focus bug is indeed a problem, but it has other, more convenient workarounds than falling back to the limiting GUI.window. For example you can disable node reordering (selected nodes popping to the front) which fixes the bug, simply comment the apropriate line in NodeEditor.DrawSubNodeCanvas. Of course if you want you can add an optional check to fall back to GUI.window and create a pull request:)