|
@@ -6,6 +6,7 @@ using Autodesk.Revit.Attributes;
|
|
|
using Autodesk.Revit.DB;
|
|
|
using Autodesk.Revit.UI;
|
|
|
using SAGA.DotNetUtils.Others;
|
|
|
+using SAGA.DotNetUtils.WPF;
|
|
|
using SAGA.GplotDrawData;
|
|
|
using SAGA.GplotDrawData.View;
|
|
|
using SAGA.GplotManage.RelationManager;
|
|
@@ -37,14 +38,25 @@ namespace SAGA.GplotManage
|
|
|
var state = SpaceComputerDataUtil.ComputeFileState();
|
|
|
if (state==CacheFileState.Miss)
|
|
|
{
|
|
|
- SpaceComputerHandler.ComputerAllRelations();
|
|
|
+ if (CalcMessageTip.StartCalc("此拓扑需要初始化计算!"))
|
|
|
+ {
|
|
|
+ SpaceComputerHandler.ComputerAllRelations();
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ return Result.Succeeded;
|
|
|
+ }
|
|
|
}
|
|
|
else if(state == CacheFileState.Expire)
|
|
|
{
|
|
|
- if (MessageShowBase.ConfirmYesNo("您是否要重新计算?"))
|
|
|
+ if (CalcMessageTip.StartCalc("拓扑已发生变化,需要重新计算!"))
|
|
|
{
|
|
|
SpaceComputerHandler.ComputerAllRelations();
|
|
|
}
|
|
|
+ else
|
|
|
+ {
|
|
|
+ return Result.Succeeded;
|
|
|
+ }
|
|
|
}
|
|
|
var win = new WinDrawSpace_Web(GplotShowType.ViewPlan);//
|
|
|
win.Show();
|
|
@@ -65,21 +77,28 @@ namespace SAGA.GplotManage
|
|
|
{
|
|
|
public override Result Execute(ExternalCommandData commandData, ref string message, ElementSet elements)
|
|
|
{
|
|
|
- //if (!MessageShowBase.Confirm("确定要执行拓扑计算命令吗"))
|
|
|
- //{
|
|
|
- // return Result.Succeeded;
|
|
|
- //}
|
|
|
var state = SpaceComputerDataUtil.ComputeFileState();
|
|
|
if (state == CacheFileState.Miss)
|
|
|
{
|
|
|
- SpaceComputerHandler.ComputerAllRelations();
|
|
|
+ if (CalcMessageTip.StartCalc("此拓扑需要初始化计算!"))
|
|
|
+ {
|
|
|
+ SpaceComputerHandler.ComputerAllRelations();
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ return Result.Succeeded;
|
|
|
+ }
|
|
|
}
|
|
|
else if (state == CacheFileState.Expire)
|
|
|
{
|
|
|
- if (MessageShowBase.ConfirmYesNo("您是否要重新计算?"))
|
|
|
+ if (CalcMessageTip.StartCalc("拓扑已发生变化,需要重新计算!"))
|
|
|
{
|
|
|
SpaceComputerHandler.ComputerAllRelations();
|
|
|
}
|
|
|
+ else
|
|
|
+ {
|
|
|
+ return Result.Succeeded;
|
|
|
+ }
|
|
|
}
|
|
|
var win = new WinDrawSpace_Web(GplotShowType.VerticalPlan);
|
|
|
win.Show();
|
|
@@ -108,14 +127,25 @@ namespace SAGA.GplotManage
|
|
|
var state = SystemComputerHandler.ComputeFileState();
|
|
|
if (state == CacheFileState.Miss)
|
|
|
{
|
|
|
- SystemComputerHandler.ComputerAllRelations();
|
|
|
+ if (CalcMessageTip.StartCalc("此拓扑需要初始化计算!"))
|
|
|
+ {
|
|
|
+ SystemComputerHandler.ComputerAllRelations();
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ return Result.Succeeded;
|
|
|
+ }
|
|
|
}
|
|
|
else if (state == CacheFileState.Expire)
|
|
|
{
|
|
|
- if (MessageShowBase.ConfirmYesNo("您是否要重新计算?"))
|
|
|
+ if (CalcMessageTip.StartCalc("拓扑已发生变化,需要重新计算!"))
|
|
|
{
|
|
|
SystemComputerHandler.ComputerAllRelations();
|
|
|
}
|
|
|
+ else
|
|
|
+ {
|
|
|
+ return Result.Succeeded;
|
|
|
+ }
|
|
|
}
|
|
|
WinSystem floorWin = new WinSystem(GplotShowType.ViewPlan);
|
|
|
floorWin.Show();
|
|
@@ -137,21 +167,29 @@ namespace SAGA.GplotManage
|
|
|
{
|
|
|
public override Result Execute(ExternalCommandData commandData, ref string message, ElementSet elements)
|
|
|
{
|
|
|
- //if (!MessageShowBase.Confirm("确定要执行拓扑计算命令吗"))
|
|
|
- //{
|
|
|
- // return Result.Succeeded;
|
|
|
- //}
|
|
|
+
|
|
|
var state = SystemComputerHandler.ComputeFileState();
|
|
|
if (state == CacheFileState.Miss)
|
|
|
{
|
|
|
- SystemComputerHandler.ComputerAllRelations();
|
|
|
+ if (CalcMessageTip.StartCalc("此拓扑需要初始化计算!"))
|
|
|
+ {
|
|
|
+ SystemComputerHandler.ComputerAllRelations();
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ return Result.Succeeded;
|
|
|
+ }
|
|
|
}
|
|
|
else if (state == CacheFileState.Expire)
|
|
|
{
|
|
|
- if (MessageShowBase.ConfirmYesNo("您是否要重新计算?"))
|
|
|
+ if (CalcMessageTip.StartCalc("拓扑已发生变化,需要重新计算!"))
|
|
|
{
|
|
|
SystemComputerHandler.ComputerAllRelations();
|
|
|
}
|
|
|
+ else
|
|
|
+ {
|
|
|
+ return Result.Succeeded;
|
|
|
+ }
|
|
|
}
|
|
|
WinSystem floorWin = new WinSystem(GplotShowType.ViewPlan);
|
|
|
floorWin.Show();
|
|
@@ -173,21 +211,28 @@ namespace SAGA.GplotManage
|
|
|
{
|
|
|
public override Result Execute(ExternalCommandData commandData, ref string message, ElementSet elements)
|
|
|
{
|
|
|
- //if (!MessageShowBase.Confirm("确定要执行拓扑计算命令吗"))
|
|
|
- //{
|
|
|
- // return Result.Succeeded;
|
|
|
- //}
|
|
|
var state = SystemComputerHandler.ComputeFileState();
|
|
|
if (state == CacheFileState.Miss)
|
|
|
{
|
|
|
- SystemComputerHandler.ComputerAllRelations();
|
|
|
+ if (CalcMessageTip.StartCalc("此拓扑需要初始化计算!"))
|
|
|
+ {
|
|
|
+ SystemComputerHandler.ComputerAllRelations();
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ return Result.Succeeded;
|
|
|
+ }
|
|
|
}
|
|
|
else if (state == CacheFileState.Expire)
|
|
|
{
|
|
|
- if (MessageShowBase.ConfirmYesNo("您是否要重新计算?"))
|
|
|
+ if (CalcMessageTip.StartCalc("拓扑已发生变化,需要重新计算!"))
|
|
|
{
|
|
|
SystemComputerHandler.ComputerAllRelations();
|
|
|
}
|
|
|
+ else
|
|
|
+ {
|
|
|
+ return Result.Succeeded;
|
|
|
+ }
|
|
|
}
|
|
|
WinSystem verticalWin = new WinSystem(GplotShowType.VerticalPlan);
|
|
|
verticalWin.Show();
|
|
@@ -210,21 +255,28 @@ namespace SAGA.GplotManage
|
|
|
{
|
|
|
public override Result Execute(ExternalCommandData commandData, ref string message, ElementSet elements)
|
|
|
{
|
|
|
- //if (!MessageShowBase.Confirm("确定要执行拓扑计算命令吗"))
|
|
|
- //{
|
|
|
- // return Result.Succeeded;
|
|
|
- //}
|
|
|
var state = SystemComputerHandler.ComputeFileState();
|
|
|
if (state == CacheFileState.Miss)
|
|
|
{
|
|
|
- SystemComputerHandler.ComputerAllRelations();
|
|
|
+ if (CalcMessageTip.StartCalc("此拓扑需要初始化计算!"))
|
|
|
+ {
|
|
|
+ SystemComputerHandler.ComputerAllRelations();
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ return Result.Succeeded;
|
|
|
+ }
|
|
|
}
|
|
|
else if (state == CacheFileState.Expire)
|
|
|
{
|
|
|
- if (MessageShowBase.ConfirmYesNo("您是否要重新计算?"))
|
|
|
+ if (CalcMessageTip.StartCalc("拓扑已发生变化,需要重新计算!"))
|
|
|
{
|
|
|
SystemComputerHandler.ComputerAllRelations();
|
|
|
}
|
|
|
+ else
|
|
|
+ {
|
|
|
+ return Result.Succeeded;
|
|
|
+ }
|
|
|
}
|
|
|
WinMachineRoom room = new WinMachineRoom();
|
|
|
room.Show();
|