UnityEditor.IconSelector.ConvertLargeIconToSmallIcon C# (CSharp) Method

ConvertLargeIconToSmallIcon() private method

private ConvertLargeIconToSmallIcon ( Texture2D largeIcon, bool &isLabelIcon ) : Texture2D
largeIcon UnityEngine.Texture2D
isLabelIcon bool
return UnityEngine.Texture2D
        private Texture2D ConvertLargeIconToSmallIcon(Texture2D largeIcon, ref bool isLabelIcon)
        {
            if (largeIcon == null)
            {
                return null;
            }
            isLabelIcon = true;
            for (int i = 0; i < this.m_LabelLargeIcons.Length; i++)
            {
                if (this.m_LabelLargeIcons[i].image == largeIcon)
                {
                    return (Texture2D) this.m_LabelIcons[i].image;
                }
            }
            isLabelIcon = false;
            for (int j = 0; j < this.m_LargeIcons.Length; j++)
            {
                if (this.m_LargeIcons[j].image == largeIcon)
                {
                    return (Texture2D) this.m_SmallIcons[j].image;
                }
            }
            return largeIcon;
        }