Beispiel #1
0
        private void MainContentOnGUI()
        {
            Rect contentLayoutRect = this.GetContentLayoutRect();

            if (this.m_State.animatorIsOptimized)
            {
                Vector2 vector2 = GUI.skin.label.CalcSize(AnimationWindowStyles.animatorOptimizedText);
                GUI.Label(new Rect((float)((double)contentLayoutRect.x + (double)contentLayoutRect.width * 0.5 - (double)vector2.x * 0.5), (float)((double)contentLayoutRect.y + (double)contentLayoutRect.height * 0.5 - (double)vector2.y * 0.5), vector2.x, vector2.y), AnimationWindowStyles.animatorOptimizedText);
            }
            else
            {
                if (this.m_State.disabled)
                {
                    this.SetupWizardOnGUI(contentLayoutRect);
                }
                else if (this.m_State.showCurveEditor)
                {
                    this.CurveEditorOnGUI(contentLayoutRect);
                }
                else
                {
                    this.DopeSheetOnGUI(contentLayoutRect);
                }
                this.HandleCopyPaste();
                AnimationWindowUtility.DrawVerticalSplitLine(new Vector2(contentLayoutRect.xMin + 1f, contentLayoutRect.yMin), new Vector2(contentLayoutRect.xMin + 1f, contentLayoutRect.yMax));
            }
        }
Beispiel #2
0
 private void MainContentOnGUI(Rect contentLayoutRect)
 {
     if (this.m_State.animatorIsOptimized)
     {
         Vector2 vector   = GUI.skin.label.CalcSize(AnimationWindowStyles.animatorOptimizedText);
         Rect    position = new Rect(contentLayoutRect.x + contentLayoutRect.width * 0.5f - vector.x * 0.5f, contentLayoutRect.y + contentLayoutRect.height * 0.5f - vector.y * 0.5f, vector.x, vector.y);
         GUI.Label(position, AnimationWindowStyles.animatorOptimizedText);
         return;
     }
     if (this.m_State.disabled)
     {
         this.SetupWizardOnGUI(contentLayoutRect);
     }
     else if (this.m_State.showCurveEditor)
     {
         this.CurveEditorOnGUI(contentLayoutRect);
     }
     else
     {
         this.DopeSheetOnGUI(contentLayoutRect);
     }
     this.HandleCopyPaste();
     AnimationWindowUtility.DrawVerticalSplitLine(new Vector2(contentLayoutRect.xMin + 1f, contentLayoutRect.yMin), new Vector2(contentLayoutRect.xMin + 1f, contentLayoutRect.yMax));
 }
Beispiel #3
0
        private void MainContentOnGUI()
        {
            if (this.m_State.animatorIsOptimized)
            {
                GUILayout.Label("Editing optimized game object hierarchy is not supported.\nPlease select a game object that does not have 'Optimize Game Objects' applied.", new GUILayoutOption[0]);
                return;
            }
            Rect contentLayoutRect = this.GetContentLayoutRect();

            if (this.m_State.disabled)
            {
                this.SetupWizardOnGUI(contentLayoutRect);
            }
            else if (this.m_State.showCurveEditor)
            {
                this.CurveEditorOnGUI(contentLayoutRect);
            }
            else
            {
                this.DopeSheetOnGUI(contentLayoutRect);
            }
            this.HandleCopyPaste();
            AnimationWindowUtility.DrawVerticalSplitLine(new Vector2(contentLayoutRect.xMin + 1f, contentLayoutRect.yMin), new Vector2(contentLayoutRect.xMin + 1f, contentLayoutRect.yMax));
        }