UnityEditor.ModelImporterClipEditor.AddClipInList C# (CSharp) Method

AddClipInList() private method

private AddClipInList ( ReorderableList list ) : void
list UnityEditorInternal.ReorderableList
return void
        private void AddClipInList(ReorderableList list)
        {
            if (this.m_DefaultClipsSerializedObject != null)
            {
                this.TransferDefaultClipsToCustomClips();
            }
            int index = 0;
            if ((0 < this.selectedClipIndex) && (this.selectedClipIndex < this.m_ClipAnimations.arraySize))
            {
                AnimationClipInfoProperties animationClipInfoAtIndex = this.GetAnimationClipInfoAtIndex(this.selectedClipIndex);
                for (int i = 0; i < this.singleImporter.importedTakeInfos.Length; i++)
                {
                    if (this.singleImporter.importedTakeInfos[i].name == animationClipInfoAtIndex.takeName)
                    {
                        index = i;
                        break;
                    }
                }
            }
            this.AddClip(this.singleImporter.importedTakeInfos[index]);
            this.UpdateList();
            this.SelectClip(list.list.Count - 1);
        }