0.2.0: Added drag and drop between entries in list and fixed some bugs

This commit is contained in:
Anders Ejlersen 2021-02-14 13:01:59 +01:00
parent dea60c6e4a
commit 1e1736f94a
8 changed files with 150 additions and 38 deletions

View file

@ -1,4 +1,5 @@
using UnityEditor;
using System.Collections.Generic;
using UnityEditor;
namespace Game.NavigationTool.Editor
{
@ -16,6 +17,24 @@ namespace Game.NavigationTool.Editor
return FAVORITES ?? (FAVORITES = new Favorites());
}
public static bool IsLoaded()
{
return FAVORITES != null;
}
public static void RefreshAll()
{
if (FAVORITES == null)
return;
List<Favorites.Entry> entries = FAVORITES.entries;
for (var i = 0; i < entries.Count; i++)
{
entries[i].Refresh();
}
}
[MenuItem("Tools/Utilities/Favorites/Delete")]
public static void DeleteAll()
{