public static bool ShrunkListIfNeeded()
        {
            bool hasChanged = false;

            if (SelectedObjectsCount >= UnityEssentialsPreferences.GetMaxSelectedObjectStored())
            {
                hasChanged = true;
                SelectedObjectsList.RemoveAt(0);
            }
            while (SelectedObjectsWithoutDuplicateCount >= UnityEssentialsPreferences.GetMaxObjectSHown())
            {
                hasChanged = true;
                SelectedObjectsWithoutDuplicateList.RemoveAt(0);
            }
            while (PinnedObjectsCount >= UnityEssentialsPreferences.GetMaxPinnedObject())
            {
                hasChanged = true;
                PinnedObjectsList.RemoveAt(0);
            }
            while (PinnedObjectsInScenesCount >= UnityEssentialsPreferences.GetMaxPinnedObject())
            {
                hasChanged = true;
                PinnedObjectsInScenesList.RemoveAt(0);
                PinnedObjectsNameInScenesList.RemoveAt(0);
                PinnedObjectsScenesLinkList.RemoveAt(0);
            }
            return(hasChanged);
        }
        public static void RemoveItemInSelection(int index)
        {
            if (LastSelectedObject == SelectedObjectsWithoutDuplicateIndex(index))
            {
                ChangeLastSelectedObject(null);
            }
            SelectedObjectsList.RemoveAllObject(SelectedObjectsWithoutDuplicateIndex(index));
            SelectedObjectsWithoutDuplicateList.RemoveAt(index);

            Save();
        }
 public static void RemoveSelectedWithoutDuplicateAt(int index)
 {
     SelectedObjectsWithoutDuplicateList.RemoveAt(index);
 }