static bool IsApplicableForOperation( string path, bool isDirectory, AssetMenuOperations operation, IAssetStatusCache assetStatusCache) { SelectedAssetGroupInfo info = SelectedAssetGroupInfo.BuildFromSingleFile( path, isDirectory, assetStatusCache); return(AssetMenuUpdater.GetAvailableMenuOperations(info).HasFlag(operation)); }
static bool ShouldMenuItemBeEnabled(AssetMenuOperations operation) { if (sOperations == null) { return(false); } SelectedAssetGroupInfo selectedGroupInfo = SelectedAssetGroupInfo. BuildFromAssetList( sAssetSelection.GetSelectedAssets(), sAssetStatusCache); AssetMenuOperations operations = AssetMenuUpdater. GetAvailableMenuOperations(selectedGroupInfo); return(operations.HasFlag(operation)); }