From aae8557dca9845322cbe1ac8ea1fc492cd59efef Mon Sep 17 00:00:00 2001 From: Emmanuele Sassi Date: Fri, 8 Oct 2021 12:47:27 +0200 Subject: [PATCH] Miglioramento gestione nesting --- EgtBEAMWALL.Core/MachGroupPanel/PartVM.vb | 2 +- .../EgtBEAMWALL.ViewerOptimizer.vbproj | 8 + .../MachGroupPanel/MyMachGroupVM.vb | 2 +- .../NestingRunningWnd/NestingRunningWndV.xaml | 37 ++++ .../NestingRunningWndV.xaml.vb | 22 ++ .../NestingRunningWnd/NestingRunningWndVM.vb | 191 ++++++++++++++++++ .../OptimizePanel/OptimizePanelVM.vb | 186 +++++++++-------- .../StatusBar/MyStatusBarVM.vb | 2 +- .../WarehouseWnd/WarehouseHelper.vb | 4 - 9 files changed, 360 insertions(+), 94 deletions(-) create mode 100644 EgtBEAMWALL.ViewerOptimizer/NestingRunningWnd/NestingRunningWndV.xaml create mode 100644 EgtBEAMWALL.ViewerOptimizer/NestingRunningWnd/NestingRunningWndV.xaml.vb create mode 100644 EgtBEAMWALL.ViewerOptimizer/NestingRunningWnd/NestingRunningWndVM.vb diff --git a/EgtBEAMWALL.Core/MachGroupPanel/PartVM.vb b/EgtBEAMWALL.Core/MachGroupPanel/PartVM.vb index 97ab4070..913121a1 100644 --- a/EgtBEAMWALL.Core/MachGroupPanel/PartVM.vb +++ b/EgtBEAMWALL.Core/MachGroupPanel/PartVM.vb @@ -549,7 +549,7 @@ Public MustInherit Class PartVM Public Sub CalcGlobalUpdate() m_PartM.nCALC_GlobalState = nCALC_State For Each Feature In FeatureVMList - If Feature.bDO Then Continue For + If Not Feature.bDO Then Continue For If Feature.nState > m_PartM.nCALC_GlobalState Then m_PartM.nCALC_GlobalState = Feature.nState m_PartM.nCALC_GlobalERR = Feature.nCALC_ERR diff --git a/EgtBEAMWALL.ViewerOptimizer/EgtBEAMWALL.ViewerOptimizer.vbproj b/EgtBEAMWALL.ViewerOptimizer/EgtBEAMWALL.ViewerOptimizer.vbproj index 3e0a7708..c55f0194 100644 --- a/EgtBEAMWALL.ViewerOptimizer/EgtBEAMWALL.ViewerOptimizer.vbproj +++ b/EgtBEAMWALL.ViewerOptimizer/EgtBEAMWALL.ViewerOptimizer.vbproj @@ -201,6 +201,10 @@ + + NestingRunningWndV.xaml + + ProjectTypeWndV.xaml @@ -378,6 +382,10 @@ MSBuild:Compile Designer + + Designer + MSBuild:Compile + MSBuild:Compile Designer diff --git a/EgtBEAMWALL.ViewerOptimizer/MachGroupPanel/MyMachGroupVM.vb b/EgtBEAMWALL.ViewerOptimizer/MachGroupPanel/MyMachGroupVM.vb index 0ae8e6e1..57776327 100644 --- a/EgtBEAMWALL.ViewerOptimizer/MachGroupPanel/MyMachGroupVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/MachGroupPanel/MyMachGroupVM.vb @@ -350,7 +350,7 @@ Public Class MyMachGroupVM Dim Index As Integer = Map.refMachGroupPanelVM.MachGroupVMList.IndexOf(Me) If Index = 0 Then If Map.refMachGroupPanelVM.MachGroupVMList.Count > 1 Then - Map.refMachGroupPanelVM.SelectedMachGroup = Map.refMachGroupPanelVM.MachGroupVMList(0) + Map.refMachGroupPanelVM.SelectedMachGroup = Map.refMachGroupPanelVM.MachGroupVMList(1) Else Map.refMachGroupPanelVM.SelectedMachGroup = Nothing EgtDraw() diff --git a/EgtBEAMWALL.ViewerOptimizer/NestingRunningWnd/NestingRunningWndV.xaml b/EgtBEAMWALL.ViewerOptimizer/NestingRunningWnd/NestingRunningWndV.xaml new file mode 100644 index 00000000..24457672 --- /dev/null +++ b/EgtBEAMWALL.ViewerOptimizer/NestingRunningWnd/NestingRunningWndV.xaml @@ -0,0 +1,37 @@ + + + + + + + + + + + + + + +