浏览代码

Frame all when graph "restarts"

/main
Peter Bay Bastian 7 年前
当前提交
ac0a8cfe
共有 1 个文件被更改,包括 2 次插入8 次删除
  1. 10
      MaterialGraphProject/Assets/UnityShaderEditor/Editor/Drawing/AbstractMaterialGraphEditWindow.cs

10
MaterialGraphProject/Assets/UnityShaderEditor/Editor/Drawing/AbstractMaterialGraphEditWindow.cs


var presenter = CreateInstance<GraphEditorPresenter>();
presenter.Initialize(inMemoryAsset, this, selected.name);
m_GraphEditorView.presenter = presenter;
m_GraphEditorView.RegisterCallback<PostLayoutEvent>(OnPostLayout);
}
m_GraphEditorView.presenter.graphPresenter.UpdateTimeDependentNodes();
}

{
m_GraphEditorView = new GraphEditorView();
rootVisualContainer.Add(m_GraphEditorView);
var presenter = CreateInstance<GraphEditorPresenter>();
presenter.Initialize(inMemoryAsset, this, selected != null ? selected.name : "");
m_GraphEditorView.presenter = presenter;
}
void OnDisable()

inMemoryAsset.OnEnable();
inMemoryAsset.ValidateGraph();
var presenter = CreateInstance<GraphEditorPresenter>();
presenter.Initialize(inMemoryAsset, this, selected.name);
m_GraphEditorView.presenter = presenter;
m_GraphEditorView.RegisterCallback<PostLayoutEvent>(OnPostLayout);
m_GraphEditorView.presenter = null;
titleContent = new GUIContent(selected.name);
Repaint();

正在加载...
取消
保存