using System;
using System.Collections.Generic;
using System.Linq;
using Jovian.Utilities;
using UnityEngine;
using Object = UnityEngine.Object;
namespace InspectorToolkit
{
///
/// Finds all objects in the project matching filter string and lists alphabetically in a dropdown (if they are assetType)
///
public class AssetDropdownAttribute : PropertyAttribute
{
public readonly Type assetType;
public readonly string filter;
public AssetDropdownAttribute(Type assetType, string filter)
{
this.assetType = assetType;
this.filter = filter;
}
}
}
#if UNITY_EDITOR
namespace InspectorToolkit.Internal
{
using UnityEditor;
[CustomPropertyDrawer(typeof(AssetDropdownAttribute))]
public class AssetDropdownAttributeDrawer : PropertyDrawer
{
private bool isInitialized;
private bool hasValidTarget;
private List