Class GraphEditorWindow
GraphEditorWindow, extends the editor window for SystemGraph asset manipulation. Implements the EditorWindow
Inherited Members
Namespace: Mechatronics.SystemGraph
Syntax
public class GraphEditorWindow : EditorWindow
Fields
Cursor
The mouse cursor icon
Declaration
public MouseCursor Cursor
Field Value
| Type | Description |
|---|---|
| MouseCursor |
MousePosition
The current mouse position
Declaration
public Vector2 MousePosition
Field Value
| Type | Description |
|---|---|
| Vector2 |
Properties
Dirty
Dirty flag for unsaved changes
Declaration
public bool Dirty { get; set; }
Property Value
| Type | Description |
|---|---|
| Boolean |
LogicGraphEditorView
Gets or sets the logic graph editor view.
Declaration
public GraphEditorView LogicGraphEditorView { get; set; }
Property Value
| Type | Description |
|---|---|
| GraphEditorView | The logic graph editor view. |
SelectedGuid
Gets the selected asset unique identifier.
Declaration
public string SelectedGuid { get; }
Property Value
| Type | Description |
|---|---|
| String | The selected unique identifier of this editor window asset. |
Methods
AssetRenamed(String, String)
Signaled when asset file name is changed
Declaration
public void AssetRenamed(string sourceFile, string destinationFile)
Parameters
| Type | Name | Description |
|---|---|---|
| String | sourceFile | Source file name. |
| String | destinationFile | Destination file name. |
AttachRuntimeGraph(SystemGraphComponent)
Attaches a SystemGraphComponent to this editor window.
Declaration
public void AttachRuntimeGraph(SystemGraphComponent attachRuntimeGraph)
Parameters
| Type | Name | Description |
|---|---|---|
| SystemGraphComponent | attachRuntimeGraph | The attached runtime graph. |
Initialize(String, SystemGraphComponent)
Initializes the graph editor window with the asset guid.
Declaration
public void Initialize(string guid, SystemGraphComponent attachRuntimeGraph = null)
Parameters
| Type | Name | Description |
|---|---|---|
| String | guid | Asset guid. |
| SystemGraphComponent | attachRuntimeGraph | Optional SystemGraphComponent instance to attach to the editor window. |
OnGUI()
Called when [GUI] needs to draw.
Declaration
public void OnGUI()
PingAsset()
Pings the asset in the project folder view.
Declaration
public void PingAsset()
SaveChanges()
Saves changes when requested by user upon window close
Declaration
public override void SaveChanges()
Overrides
UpdateAsset()
Updates the asset in the AssetDatabase.
Declaration
public void UpdateAsset()