UIAtlasMaker.GetSelectedTextures C# (CSharp) Method

GetSelectedTextures() private method

Helper function that retrieves the list of currently selected textures.
private GetSelectedTextures ( ) : List
return List
    List<Texture> GetSelectedTextures()
    {
        List<Texture> textures = new List<Texture>();

        if (Selection.objects != null && Selection.objects.Length > 0)
        {
            Object[] objects = EditorUtility.CollectDependencies(Selection.objects);

            foreach (Object o in objects)
            {
                Texture tex = o as Texture;
                if (tex != null && (NGUISettings.atlas == null || NGUISettings.atlas.texture != tex)) textures.Add(tex);
            }
        }
        return textures;
    }