From 3b4286b8ef9d75ff8ef053313ae046b45c5e9db0 Mon Sep 17 00:00:00 2001 From: pharan Date: Thu, 16 Mar 2017 12:16:21 +0800 Subject: [PATCH] [unity] Minor cleanup. --- .../spine-unity/Editor/BoneFollowerInspector.cs | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/spine-unity/Assets/spine-unity/Editor/BoneFollowerInspector.cs b/spine-unity/Assets/spine-unity/Editor/BoneFollowerInspector.cs index 58ac0fce0..3f5e68bd3 100644 --- a/spine-unity/Assets/spine-unity/Editor/BoneFollowerInspector.cs +++ b/spine-unity/Assets/spine-unity/Editor/BoneFollowerInspector.cs @@ -31,9 +31,13 @@ using UnityEditor; using UnityEngine; -namespace Spine.Unity.Editor { +namespace Spine.Unity.Editor { + + using Editor = UnityEditor.Editor; + using Event = UnityEngine.Event; + [CustomEditor(typeof(BoneFollower)), CanEditMultipleObjects] - public class BoneFollowerInspector : UnityEditor.Editor { + public class BoneFollowerInspector : Editor { SerializedProperty boneName, skeletonRenderer, followZPosition, followBoneRotation, followLocalScale, followSkeletonFlip; BoneFollower targetBoneFollower; bool needsReset; @@ -121,7 +125,7 @@ namespace Spine.Unity.Editor { return; } - if (needsReset && UnityEngine.Event.current.type == EventType.Layout) { + if (needsReset && Event.current.type == EventType.Layout) { targetBoneFollower.Initialize(); targetBoneFollower.LateUpdate(); needsReset = false; @@ -171,7 +175,7 @@ namespace Spine.Unity.Editor { } } - var current = UnityEngine.Event.current; + var current = Event.current; bool wasUndo = (current.type == EventType.ValidateCommand && current.commandName == "UndoRedoPerformed"); if (wasUndo) targetBoneFollower.Initialize();