Skip to content

Commit e33f4b8

Browse files
committed
feat: Added ConcreteClassAdded event to ConcreteClassCreator
1 parent b700db4 commit e33f4b8

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

Editor/Util/ConcreteClassCreator.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@
1717
internal static class ConcreteClassCreator<TObject>
1818
where TObject : Object
1919
{
20+
public static event Action<Type, Type[]> ConcreteClassAdded;
21+
2022
/// <summary>
2123
/// Creates a new concrete class assembly, adds it to the database, and adds a task to update behaviour icon
2224
/// if the generic type is MonoBehaviour.
@@ -31,6 +33,8 @@ public static void CreateConcreteClass(Type genericTypeWithoutArgs, Type[] argum
3133
IconSetter.AddAssemblyForIconChange(genericTypeInfo.GUID, assemblyGUID, typeof(TObject) == typeof(GenericScriptableObject));
3234

3335
AddToDatabase(genericTypeInfo, argumentTypes, assemblyGUID);
36+
37+
ConcreteClassAdded?.Invoke(genericTypeWithoutArgs, argumentTypes);
3438
}
3539

3640
/// <summary>

0 commit comments

Comments
 (0)