modify
This commit is contained in:
parent
0499cf9f4d
commit
208bab1c7a
@ -342,11 +342,18 @@ internal class UXButtonEditor : Editor
|
|||||||
float spacing = 2f;
|
float spacing = 2f;
|
||||||
float y = position.y;
|
float y = position.y;
|
||||||
|
|
||||||
|
var currentTransition = GetTransition(transition);
|
||||||
|
|
||||||
|
switch (currentTransition)
|
||||||
|
{
|
||||||
|
case Selectable.Transition.ColorTint:
|
||||||
|
case Selectable.Transition.SpriteSwap:
|
||||||
Rect targetRect = new Rect(position.x, y, position.width, lineHeight);
|
Rect targetRect = new Rect(position.x, y, position.width, lineHeight);
|
||||||
EditorGUI.PropertyField(targetRect, targetGraphic);
|
EditorGUI.PropertyField(targetRect, targetGraphic);
|
||||||
y += lineHeight + spacing;
|
y += lineHeight + spacing;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
var currentTransition = GetTransition(transition);
|
|
||||||
|
|
||||||
Rect transitionRect = new Rect(position.x, y, position.width, lineHeight);
|
Rect transitionRect = new Rect(position.x, y, position.width, lineHeight);
|
||||||
EditorGUI.PropertyField(transitionRect, transition);
|
EditorGUI.PropertyField(transitionRect, transition);
|
||||||
@ -418,14 +425,19 @@ internal class UXButtonEditor : Editor
|
|||||||
targetGraphic.objectReferenceValue = graphic;
|
targetGraphic.objectReferenceValue = graphic;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
EditorGUILayout.PropertyField(targetGraphic);
|
|
||||||
|
|
||||||
SerializedProperty transition = m_TransitionData.FindPropertyRelative("transition");
|
SerializedProperty transition = m_TransitionData.FindPropertyRelative("transition");
|
||||||
EditorGUILayout.PropertyField(transition);
|
|
||||||
|
|
||||||
var currentTransition = GetTransition(transition);
|
var currentTransition = GetTransition(transition);
|
||||||
|
|
||||||
|
switch (currentTransition)
|
||||||
|
{
|
||||||
|
case Selectable.Transition.ColorTint:
|
||||||
|
case Selectable.Transition.SpriteSwap:
|
||||||
|
EditorGUILayout.PropertyField(targetGraphic);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
EditorGUILayout.PropertyField(transition);
|
||||||
|
|
||||||
var animator = graphic != null ? graphic.GetComponent<Animator>() : null;
|
var animator = graphic != null ? graphic.GetComponent<Animator>() : null;
|
||||||
switch (currentTransition)
|
switch (currentTransition)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user