private static CheckArgumentsAndReturnType ( object args, |
||
args | object | |
method | ||
returnType | ||
return | bool |
private static AssetMoveResult OnWillMoveAsset(string fromPath, string toPath, string[] newPaths, string[] NewMetaPaths) { AssetMoveResult assetMoveResult = AssetMoveResult.DidNotMove; if (!InternalEditorUtility.HasTeamLicense()) { return(assetMoveResult); } assetMoveResult = AssetModificationHook.OnWillMoveAsset(fromPath, toPath); foreach (Type current in AssetModificationProcessorInternal.AssetModificationProcessors) { MethodInfo method = current.GetMethod("OnWillMoveAsset", BindingFlags.Static | BindingFlags.Public | BindingFlags.NonPublic); if (method != null) { AssetModificationProcessorInternal.RequireTeamLicense(); object[] array = new object[] { fromPath, toPath }; if (AssetModificationProcessorInternal.CheckArgumentsAndReturnType(array, method, assetMoveResult.GetType())) { assetMoveResult |= (AssetMoveResult)((int)method.Invoke(null, array)); } } } return(assetMoveResult); }
private static AssetDeleteResult OnWillDeleteAsset(string assetPath, RemoveAssetOptions options) { AssetDeleteResult assetDeleteResult = AssetDeleteResult.DidNotDelete; if (!InternalEditorUtility.HasTeamLicense()) { return(assetDeleteResult); } foreach (Type current in AssetModificationProcessorInternal.AssetModificationProcessors) { MethodInfo method = current.GetMethod("OnWillDeleteAsset", BindingFlags.Static | BindingFlags.Public | BindingFlags.NonPublic); if (method != null) { AssetModificationProcessorInternal.RequireTeamLicense(); object[] array = new object[] { assetPath, options }; if (AssetModificationProcessorInternal.CheckArgumentsAndReturnType(array, method, assetDeleteResult.GetType())) { assetDeleteResult |= (AssetDeleteResult)((int)method.Invoke(null, array)); } } } if (assetDeleteResult != AssetDeleteResult.DidNotDelete) { return(assetDeleteResult); } assetDeleteResult = AssetModificationHook.OnWillDeleteAsset(assetPath, options); return(assetDeleteResult); }
private static AssetMoveResult OnWillMoveAsset(string fromPath, string toPath, string[] newPaths, string[] NewMetaPaths) { AssetMoveResult assetMoveResult1 = AssetMoveResult.DidNotMove; if (!InternalEditorUtility.HasTeamLicense()) { return(assetMoveResult1); } AssetMoveResult assetMoveResult2 = AssetModificationHook.OnWillMoveAsset(fromPath, toPath); foreach (System.Type modificationProcessor in AssetModificationProcessorInternal.AssetModificationProcessors) { MethodInfo method = modificationProcessor.GetMethod("OnWillMoveAsset", BindingFlags.Static | BindingFlags.Public | BindingFlags.NonPublic); if (method != null) { AssetModificationProcessorInternal.RequireTeamLicense(); object[] objArray = new object[2] { (object)fromPath, (object)toPath }; if (AssetModificationProcessorInternal.CheckArgumentsAndReturnType(objArray, method, assetMoveResult2.GetType())) { assetMoveResult2 |= (AssetMoveResult)method.Invoke((object)null, objArray); } } } return(assetMoveResult2); }
internal static void OnStatusUpdated() { WindowPending.OnStatusUpdated(); foreach (Type current in AssetModificationProcessorInternal.AssetModificationProcessors) { MethodInfo method = current.GetMethod("OnStatusUpdated", BindingFlags.Static | BindingFlags.Public | BindingFlags.NonPublic); if (method != null) { AssetModificationProcessorInternal.RequireTeamLicense(); object[] array = new object[0]; if (AssetModificationProcessorInternal.CheckArgumentsAndReturnType(array, method, typeof(void))) { method.Invoke(null, array); } } } }