- Cleanup and comments
This commit is contained in:
@@ -838,6 +838,10 @@ namespace FlaxEditor.Surface.Archetypes
|
||||
box.CurrentType = type ? type : ScriptType.FlaxObject;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sets the type of the picker and the type of the output box
|
||||
/// </summary>
|
||||
/// <param name="type">Target Type</param>
|
||||
public void SetPickerValue(ScriptType type)
|
||||
{
|
||||
_picker.Value = type;
|
||||
@@ -1004,6 +1008,10 @@ namespace FlaxEditor.Surface.Archetypes
|
||||
GetBox(4).CurrentType = type ? type : _picker.Type;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sets the type of the picker and the type of the output box
|
||||
/// </summary>
|
||||
/// <param name="type">Target Type</param>
|
||||
public void SetPickerValue(ScriptType type)
|
||||
{
|
||||
_picker.Value = type;
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using FlaxEditor.Scripting;
|
||||
using FlaxEditor.Surface.Undo;
|
||||
using FlaxEngine;
|
||||
@@ -843,6 +842,7 @@ namespace FlaxEditor.Surface.Elements
|
||||
throw new NullReferenceException("Casting failed. Cast node is invalid!");
|
||||
}
|
||||
|
||||
// We set the position of the cast node here to set it relative to the target nodes input box
|
||||
undoEnabled = castNode.Surface.Undo.Enabled;
|
||||
castNode.Surface.Undo.Enabled = false;
|
||||
var wantedOffset = iB.ParentNode.Location - new Float2(casterXOffset, -(iB.LocalY - castOutputBox.LocalY));
|
||||
@@ -876,6 +876,7 @@ namespace FlaxEditor.Surface.Elements
|
||||
throw new NullReferenceException("Casting failed. Cast node is invalid!");
|
||||
}
|
||||
|
||||
// We set the position of the cast node here to set it relative to the target nodes input box
|
||||
var wantedOffset = iB.ParentNode.Location - new Float2(casterXOffset, -(iB.LocalY - castOutputBox.LocalY));
|
||||
castNode.Location = Surface.Root.PointFromParent(ref wantedOffset);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user