コード例 #1
0
        public UAnimationWindow_2017_1()
        {
            var asmUnityEditor      = Assembly.LoadFrom(InternalEditorUtility.GetEditorAssemblyPath());
            var animationWindowType = asmUnityEditor.GetType("UnityEditor.AnimationWindow");

            Assert.IsNotNull(mi_EditSequencerClip = animationWindowType.GetMethod("EditSequencerClip", BindingFlags.Public | BindingFlags.Instance));
            Assert.IsNotNull(mi_UnlinkSequencer   = animationWindowType.GetMethod("UnlinkSequencer", BindingFlags.Public | BindingFlags.Instance));

            uAnimationWindowState = uAnimationWindowState_2017_1 = new UAnimationWindowState_2017_1(asmUnityEditor);
#if UNITY_2018_2_OR_NEWER
            uTimelineWindow = new UTimelineWindow_2018_2();
#else
            uTimelineWindow = new UTimelineWindow();
#endif
        }
コード例 #2
0
        public UAnimationWindow_2018_1()
        {
            var asmUnityEditor      = Assembly.LoadFrom(InternalEditorUtility.GetEditorAssemblyPath());
            var animationWindowType = asmUnityEditor.GetType("UnityEditor.AnimationWindow");

            uAnimEditor           = uAnimEditor_2018_1 = new UAnimEditor_2018_1(asmUnityEditor);
            uAnimationWindowState = uAnimationWindowState_2018_1 = new UAnimationWindowState_2018_1(asmUnityEditor);
#if VERYANIMATION_TIMELINE
#if UNITY_2018_3_OR_NEWER
            uTimelineWindow = uTimelineWindow_2018_2 = uTimelineWindow_2018_3 = new UTimelineWindow_2018_3();
#elif UNITY_2018_2_OR_NEWER
            uTimelineWindow = uTimelineWindow_2018_2 = new UTimelineWindow_2018_2();
#endif
#endif
            uEditorGUIUtility_2018_1 = new UEditorGUIUtility_2018_1();
            Assert.IsNotNull(dg_get_m_LockTracker = EditorCommon.CreateGetFieldDelegate <object>(animationWindowType.GetField("m_LockTracker", BindingFlags.NonPublic | BindingFlags.Instance)));
        }