2025-04-24 20:56:10 +08:00
|
|
|
|
using Autodesk.Revit.DB;
|
|
|
|
|
|
using Autodesk.Revit.UI;
|
|
|
|
|
|
|
2026-02-21 16:31:24 +08:00
|
|
|
|
namespace ShrlAlgoToolkit.RevitCore.Assists;
|
2025-04-24 20:56:10 +08:00
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// 已经打开文档
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
public class HasActiveDocument : IExternalCommandAvailability
|
|
|
|
|
|
{
|
|
|
|
|
|
public bool IsCommandAvailable(UIApplication applicationData, CategorySet selectedCategories) => applicationData.ActiveUIDocument != null;
|
|
|
|
|
|
}
|