您最多选择25个主题
主题必须以中文或者字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符
28 行
886 B
28 行
886 B
using System;
|
|
using UnityEditor.Experimental.UIElements.GraphView;
|
|
using UnityEngine;
|
|
using UnityEngine.Experimental.UIElements;
|
|
|
|
namespace UnityEditor.ShaderGraph.Drawing
|
|
{
|
|
sealed class ShaderPort : Port
|
|
{
|
|
ShaderPort(Orientation portOrientation, Direction portDirection, Type type)
|
|
: base(portOrientation, portDirection, type) { }
|
|
|
|
public static Port Create(Orientation orientation, Direction direction, Type type, IEdgeConnectorListener connectorListener)
|
|
{
|
|
var port = new ShaderPort(orientation, direction, type)
|
|
{
|
|
m_EdgeConnector = new EdgeConnector<Edge>(connectorListener),
|
|
};
|
|
port.AddManipulator(port.m_EdgeConnector);
|
|
return port;
|
|
}
|
|
|
|
public VisualElement connectorBox
|
|
{
|
|
get { return m_ConnectorBox; }
|
|
}
|
|
}
|
|
}
|