浏览代码

Reigister postlayout callback on graphview rather than inspector view

/main
Jens Holm 7 年前
当前提交
ec88c9f3
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 2
      MaterialGraphProject/Assets/UnityShaderEditor/Editor/Drawing/Views/GraphEditorView.cs

2
MaterialGraphProject/Assets/UnityShaderEditor/Editor/Drawing/Views/GraphEditorView.cs


m_GraphInspectorView = new GraphInspectorView(assetName, previewManager, graph) { name = "inspector" };
m_GraphInspectorView.AddManipulator(new Draggable(OnMouseDrag, true));
m_GraphInspectorView.RegisterCallback<PostLayoutEvent>(OnPostLayout);
m_GraphView.RegisterCallback<PostLayoutEvent>(OnPostLayout);
m_GraphView.onSelectionChanged += m_GraphInspectorView.UpdateSelection;
m_GraphView.Add(m_GraphInspectorView);

正在加载...
取消
保存