From f94ad67676d194c854fe48c521aed335c873cfe6 Mon Sep 17 00:00:00 2001 From: Dario Sassi Date: Wed, 28 Feb 2018 09:38:21 +0000 Subject: [PATCH] EgtCAM5 : - aggiunta gestione lavorazione di mortasatura. --- MachiningsDbWindow/MachiningTreeView.vb | 61 ++++++++++++------- MachiningsDbWindow/MachiningsDbViewModel.vb | 2 +- .../MachiningParameterExpanderView.xaml | 21 ++++--- .../MachiningParameterExpanderViewModel.vb | 59 +++++++++++------- .../SimulationExpanderViewModel.vb | 5 +- SharedFieldsClass.vb | 52 ++++++++++------ ToolsDbWindow/ToolDraw.vb | 10 ++- ToolsDbWindow/ToolTreeView.vb | 10 +-- 8 files changed, 141 insertions(+), 79 deletions(-) diff --git a/MachiningsDbWindow/MachiningTreeView.vb b/MachiningsDbWindow/MachiningTreeView.vb index c119c48..d2fdf7b 100644 --- a/MachiningsDbWindow/MachiningTreeView.vb +++ b/MachiningsDbWindow/MachiningTreeView.vb @@ -209,6 +209,10 @@ Public Class MachiningTreeViewItem Public ReadOnly Property WorkSideList As ObservableCollection(Of IdNameStruct) Get Select Case m_Type + Case MCH_MY.MORTISING + m_WorkSideList = New ObservableCollection(Of IdNameStruct)( + {New IdNameStruct(MCH_MORTISE_WS.LEFT, EgtMsg(MSG_MACHININGSDBPAGE + 121)), + New IdNameStruct(MCH_MORTISE_WS.RIGHT, EgtMsg(MSG_MACHININGSDBPAGE + 122))}) Case MCH_MY.CHISELING m_WorkSideList = New ObservableCollection(Of IdNameStruct)( {New IdNameStruct(MCH_CHISEL_WS.LEFT, EgtMsg(MSG_MACHININGSDBPAGE + 121)), @@ -600,30 +604,43 @@ Public Class MachiningTreeViewItem End Property 'ObservableCollection che contiene le variabili per il combobox FaceUseType - Private m_FaceUseTypeList As New ObservableCollection(Of IdNameStruct)( - {New IdNameStruct(MCH_MIL_FU.NONE, EgtMsg(MSG_MACHININGSDBPAGE + 153)), - New IdNameStruct(MCH_MIL_FU.PARAL_DOWN, EgtMsg(MSG_MACHININGSDBPAGE + 157) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), - New IdNameStruct(MCH_MIL_FU.PARAL_TOP, EgtMsg(MSG_MACHININGSDBPAGE + 158) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), - New IdNameStruct(MCH_MIL_FU.PARAL_FRONT, EgtMsg(MSG_MACHININGSDBPAGE + 159) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), - New IdNameStruct(MCH_MIL_FU.PARAL_BACK, EgtMsg(MSG_MACHININGSDBPAGE + 160) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), - New IdNameStruct(MCH_MIL_FU.PARAL_LEFT, EgtMsg(MSG_MACHININGSDBPAGE + 161) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), - New IdNameStruct(MCH_MIL_FU.PARAL_RIGHT, EgtMsg(MSG_MACHININGSDBPAGE + 162) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), - New IdNameStruct(MCH_MIL_FU.ORTHO_DOWN, EgtMsg(MSG_MACHININGSDBPAGE + 157) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), - New IdNameStruct(MCH_MIL_FU.ORTHO_TOP, EgtMsg(MSG_MACHININGSDBPAGE + 158) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), - New IdNameStruct(MCH_MIL_FU.ORTHO_FRONT, EgtMsg(MSG_MACHININGSDBPAGE + 159) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), - New IdNameStruct(MCH_MIL_FU.ORTHO_BACK, EgtMsg(MSG_MACHININGSDBPAGE + 160) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), - New IdNameStruct(MCH_MIL_FU.ORTHO_LEFT, EgtMsg(MSG_MACHININGSDBPAGE + 161) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), - New IdNameStruct(MCH_MIL_FU.ORTHO_RIGHT, EgtMsg(MSG_MACHININGSDBPAGE + 162) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), - New IdNameStruct(MCH_MIL_FU.ORTHO_CONT, EgtMsg(MSG_MACHININGSDBPAGE + 163) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), - New IdNameStruct(MCH_MIL_FU.ORTUP_DOWN, EgtMsg(MSG_MACHININGSDBPAGE + 157) & EgtMsg(MSG_MACHININGSDBPAGE + 156)), - New IdNameStruct(MCH_MIL_FU.ORTUP_TOP, EgtMsg(MSG_MACHININGSDBPAGE + 158) & EgtMsg(MSG_MACHININGSDBPAGE + 156)), - New IdNameStruct(MCH_MIL_FU.ORTUP_FRONT, EgtMsg(MSG_MACHININGSDBPAGE + 159) & EgtMsg(MSG_MACHININGSDBPAGE + 156)), - New IdNameStruct(MCH_MIL_FU.ORTUP_BACK, EgtMsg(MSG_MACHININGSDBPAGE + 160) & EgtMsg(MSG_MACHININGSDBPAGE + 156)), - New IdNameStruct(MCH_MIL_FU.ORTUP_LEFT, EgtMsg(MSG_MACHININGSDBPAGE + 161) & EgtMsg(MSG_MACHININGSDBPAGE + 156)), - New IdNameStruct(MCH_MIL_FU.ORTUP_RIGHT, EgtMsg(MSG_MACHININGSDBPAGE + 162) & EgtMsg(MSG_MACHININGSDBPAGE + 156)), - New IdNameStruct(MCH_MIL_FU.ORTUP_CONT, EgtMsg(MSG_MACHININGSDBPAGE + 163) & EgtMsg(MSG_MACHININGSDBPAGE + 156))}) + Private m_FaceUseTypeList As ObservableCollection(Of IdNameStruct) Public ReadOnly Property FaceUseTypeList As ObservableCollection(Of IdNameStruct) Get + Select Case m_Type + Case MCH_MY.MORTISING + m_FaceUseTypeList = New ObservableCollection(Of IdNameStruct)( + {New IdNameStruct(MCH_MIL_FU.NONE, EgtMsg(MSG_MACHININGSDBPAGE + 153)), + New IdNameStruct(MCH_MIL_FU.PARAL_DOWN, EgtMsg(MSG_MACHININGSDBPAGE + 157) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), + New IdNameStruct(MCH_MIL_FU.PARAL_TOP, EgtMsg(MSG_MACHININGSDBPAGE + 158) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), + New IdNameStruct(MCH_MIL_FU.PARAL_FRONT, EgtMsg(MSG_MACHININGSDBPAGE + 159) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), + New IdNameStruct(MCH_MIL_FU.PARAL_BACK, EgtMsg(MSG_MACHININGSDBPAGE + 160) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), + New IdNameStruct(MCH_MIL_FU.PARAL_LEFT, EgtMsg(MSG_MACHININGSDBPAGE + 161) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), + New IdNameStruct(MCH_MIL_FU.PARAL_RIGHT, EgtMsg(MSG_MACHININGSDBPAGE + 162) & EgtMsg(MSG_MACHININGSDBPAGE + 154))}) + Case Else + m_FaceUseTypeList = New ObservableCollection(Of IdNameStruct)( + {New IdNameStruct(MCH_MIL_FU.NONE, EgtMsg(MSG_MACHININGSDBPAGE + 153)), + New IdNameStruct(MCH_MIL_FU.PARAL_DOWN, EgtMsg(MSG_MACHININGSDBPAGE + 157) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), + New IdNameStruct(MCH_MIL_FU.PARAL_TOP, EgtMsg(MSG_MACHININGSDBPAGE + 158) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), + New IdNameStruct(MCH_MIL_FU.PARAL_FRONT, EgtMsg(MSG_MACHININGSDBPAGE + 159) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), + New IdNameStruct(MCH_MIL_FU.PARAL_BACK, EgtMsg(MSG_MACHININGSDBPAGE + 160) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), + New IdNameStruct(MCH_MIL_FU.PARAL_LEFT, EgtMsg(MSG_MACHININGSDBPAGE + 161) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), + New IdNameStruct(MCH_MIL_FU.PARAL_RIGHT, EgtMsg(MSG_MACHININGSDBPAGE + 162) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), + New IdNameStruct(MCH_MIL_FU.ORTHO_DOWN, EgtMsg(MSG_MACHININGSDBPAGE + 157) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), + New IdNameStruct(MCH_MIL_FU.ORTHO_TOP, EgtMsg(MSG_MACHININGSDBPAGE + 158) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), + New IdNameStruct(MCH_MIL_FU.ORTHO_FRONT, EgtMsg(MSG_MACHININGSDBPAGE + 159) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), + New IdNameStruct(MCH_MIL_FU.ORTHO_BACK, EgtMsg(MSG_MACHININGSDBPAGE + 160) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), + New IdNameStruct(MCH_MIL_FU.ORTHO_LEFT, EgtMsg(MSG_MACHININGSDBPAGE + 161) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), + New IdNameStruct(MCH_MIL_FU.ORTHO_RIGHT, EgtMsg(MSG_MACHININGSDBPAGE + 162) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), + New IdNameStruct(MCH_MIL_FU.ORTHO_CONT, EgtMsg(MSG_MACHININGSDBPAGE + 163) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), + New IdNameStruct(MCH_MIL_FU.ORTUP_DOWN, EgtMsg(MSG_MACHININGSDBPAGE + 157) & EgtMsg(MSG_MACHININGSDBPAGE + 156)), + New IdNameStruct(MCH_MIL_FU.ORTUP_TOP, EgtMsg(MSG_MACHININGSDBPAGE + 158) & EgtMsg(MSG_MACHININGSDBPAGE + 156)), + New IdNameStruct(MCH_MIL_FU.ORTUP_FRONT, EgtMsg(MSG_MACHININGSDBPAGE + 159) & EgtMsg(MSG_MACHININGSDBPAGE + 156)), + New IdNameStruct(MCH_MIL_FU.ORTUP_BACK, EgtMsg(MSG_MACHININGSDBPAGE + 160) & EgtMsg(MSG_MACHININGSDBPAGE + 156)), + New IdNameStruct(MCH_MIL_FU.ORTUP_LEFT, EgtMsg(MSG_MACHININGSDBPAGE + 161) & EgtMsg(MSG_MACHININGSDBPAGE + 156)), + New IdNameStruct(MCH_MIL_FU.ORTUP_RIGHT, EgtMsg(MSG_MACHININGSDBPAGE + 162) & EgtMsg(MSG_MACHININGSDBPAGE + 156)), + New IdNameStruct(MCH_MIL_FU.ORTUP_CONT, EgtMsg(MSG_MACHININGSDBPAGE + 163) & EgtMsg(MSG_MACHININGSDBPAGE + 156))}) + End Select Return m_FaceUseTypeList End Get End Property diff --git a/MachiningsDbWindow/MachiningsDbViewModel.vb b/MachiningsDbWindow/MachiningsDbViewModel.vb index d1a117e..67e02a9 100644 --- a/MachiningsDbWindow/MachiningsDbViewModel.vb +++ b/MachiningsDbWindow/MachiningsDbViewModel.vb @@ -484,7 +484,7 @@ Namespace EgtCAM5 NewMachiningItem.IsSelected = True NewMachiningItem.NotifyPropertyChanged("IsSelected") End If - ' Verifico se sia selezionata una lavorazione + ' Verifico se sia selezionata una lavorazione ElseIf TypeOf param Is MachiningTreeViewItem Then Dim MachiningCopied As MachiningTreeViewItem = DirectCast(param, MachiningTreeViewItem) Dim NewName As String = MachiningCopied.Name diff --git a/ProjectPage/OptionPanel/MachiningOptionPanel/OperationExpander/MachiningParameterExpander/MachiningParameterExpanderView.xaml b/ProjectPage/OptionPanel/MachiningOptionPanel/OperationExpander/MachiningParameterExpander/MachiningParameterExpanderView.xaml index 6fe0d47..9ae9f56 100644 --- a/ProjectPage/OptionPanel/MachiningOptionPanel/OperationExpander/MachiningParameterExpander/MachiningParameterExpanderView.xaml +++ b/ProjectPage/OptionPanel/MachiningOptionPanel/OperationExpander/MachiningParameterExpander/MachiningParameterExpanderView.xaml @@ -64,6 +64,8 @@ 52 53 54 + 55 + 56 @@ -251,14 +253,17 @@ + IsSynchronizedWithCurrentItem="True" + Visibility="{Binding Type, + Converter={StaticResource OperationParamVisibilityConverter}, + ConverterParameter={StaticResource LeadInType}}"> @@ -296,10 +301,9 @@ - @@ -307,7 +311,10 @@ VerticalAlignment="Center"/> + IsSynchronizedWithCurrentItem="True" + Visibility="{Binding Type, + Converter={StaticResource OperationParamVisibilityConverter}, + ConverterParameter={StaticResource LeadOutType}}"> diff --git a/ProjectPage/OptionPanel/MachiningOptionPanel/OperationExpander/MachiningParameterExpander/MachiningParameterExpanderViewModel.vb b/ProjectPage/OptionPanel/MachiningOptionPanel/OperationExpander/MachiningParameterExpander/MachiningParameterExpanderViewModel.vb index e81dba4..80087b3 100644 --- a/ProjectPage/OptionPanel/MachiningOptionPanel/OperationExpander/MachiningParameterExpander/MachiningParameterExpanderViewModel.vb +++ b/ProjectPage/OptionPanel/MachiningOptionPanel/OperationExpander/MachiningParameterExpander/MachiningParameterExpanderViewModel.vb @@ -91,7 +91,7 @@ Namespace EgtCAM5 Public ReadOnly Property WorkSideList As ObservableCollection(Of IdNameStruct) Get Select Case m_Type - Case MCH_MY.CHISELING + Case MCH_MY.CHISELING, MCH_MY.MORTISING m_WorkSideList = New ObservableCollection(Of IdNameStruct)( {New IdNameStruct(MCH_CHISEL_WS.LEFT, EgtMsg(MSG_MACHININGSDBPAGE + 121)), New IdNameStruct(MCH_CHISEL_WS.RIGHT, EgtMsg(MSG_MACHININGSDBPAGE + 122))}) @@ -464,30 +464,43 @@ Namespace EgtCAM5 End Property 'ObservableCollection che contiene le variabili per il combobox FaceUseType - Private m_FaceUseTypeList As New ObservableCollection(Of IdNameStruct)( - {New IdNameStruct(MCH_MIL_FU.NONE, EgtMsg(MSG_MACHININGSDBPAGE + 153)), - New IdNameStruct(MCH_MIL_FU.PARAL_DOWN, EgtMsg(MSG_MACHININGSDBPAGE + 157) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), - New IdNameStruct(MCH_MIL_FU.PARAL_TOP, EgtMsg(MSG_MACHININGSDBPAGE + 158) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), - New IdNameStruct(MCH_MIL_FU.PARAL_FRONT, EgtMsg(MSG_MACHININGSDBPAGE + 159) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), - New IdNameStruct(MCH_MIL_FU.PARAL_BACK, EgtMsg(MSG_MACHININGSDBPAGE + 160) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), - New IdNameStruct(MCH_MIL_FU.PARAL_LEFT, EgtMsg(MSG_MACHININGSDBPAGE + 161) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), - New IdNameStruct(MCH_MIL_FU.PARAL_RIGHT, EgtMsg(MSG_MACHININGSDBPAGE + 162) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), - New IdNameStruct(MCH_MIL_FU.ORTHO_DOWN, EgtMsg(MSG_MACHININGSDBPAGE + 157) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), - New IdNameStruct(MCH_MIL_FU.ORTHO_TOP, EgtMsg(MSG_MACHININGSDBPAGE + 158) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), - New IdNameStruct(MCH_MIL_FU.ORTHO_FRONT, EgtMsg(MSG_MACHININGSDBPAGE + 159) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), - New IdNameStruct(MCH_MIL_FU.ORTHO_BACK, EgtMsg(MSG_MACHININGSDBPAGE + 160) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), - New IdNameStruct(MCH_MIL_FU.ORTHO_LEFT, EgtMsg(MSG_MACHININGSDBPAGE + 161) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), - New IdNameStruct(MCH_MIL_FU.ORTHO_RIGHT, EgtMsg(MSG_MACHININGSDBPAGE + 162) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), - New IdNameStruct(MCH_MIL_FU.ORTHO_CONT, EgtMsg(MSG_MACHININGSDBPAGE + 163) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), - New IdNameStruct(MCH_MIL_FU.ORTUP_DOWN, EgtMsg(MSG_MACHININGSDBPAGE + 157) & EgtMsg(MSG_MACHININGSDBPAGE + 156)), - New IdNameStruct(MCH_MIL_FU.ORTUP_TOP, EgtMsg(MSG_MACHININGSDBPAGE + 158) & EgtMsg(MSG_MACHININGSDBPAGE + 156)), - New IdNameStruct(MCH_MIL_FU.ORTUP_FRONT, EgtMsg(MSG_MACHININGSDBPAGE + 159) & EgtMsg(MSG_MACHININGSDBPAGE + 156)), - New IdNameStruct(MCH_MIL_FU.ORTUP_BACK, EgtMsg(MSG_MACHININGSDBPAGE + 160) & EgtMsg(MSG_MACHININGSDBPAGE + 156)), - New IdNameStruct(MCH_MIL_FU.ORTUP_LEFT, EgtMsg(MSG_MACHININGSDBPAGE + 161) & EgtMsg(MSG_MACHININGSDBPAGE + 156)), - New IdNameStruct(MCH_MIL_FU.ORTUP_RIGHT, EgtMsg(MSG_MACHININGSDBPAGE + 162) & EgtMsg(MSG_MACHININGSDBPAGE + 156)), - New IdNameStruct(MCH_MIL_FU.ORTUP_CONT, EgtMsg(MSG_MACHININGSDBPAGE + 163) & EgtMsg(MSG_MACHININGSDBPAGE + 156))}) + Private m_FaceUseTypeList As ObservableCollection(Of IdNameStruct) Public ReadOnly Property FaceUseTypeList As ObservableCollection(Of IdNameStruct) Get + Select Case m_Type + Case MCH_MY.MORTISING + m_FaceUseTypeList = New ObservableCollection(Of IdNameStruct)( + {New IdNameStruct(MCH_MIL_FU.NONE, EgtMsg(MSG_MACHININGSDBPAGE + 153)), + New IdNameStruct(MCH_MIL_FU.PARAL_DOWN, EgtMsg(MSG_MACHININGSDBPAGE + 157) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), + New IdNameStruct(MCH_MIL_FU.PARAL_TOP, EgtMsg(MSG_MACHININGSDBPAGE + 158) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), + New IdNameStruct(MCH_MIL_FU.PARAL_FRONT, EgtMsg(MSG_MACHININGSDBPAGE + 159) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), + New IdNameStruct(MCH_MIL_FU.PARAL_BACK, EgtMsg(MSG_MACHININGSDBPAGE + 160) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), + New IdNameStruct(MCH_MIL_FU.PARAL_LEFT, EgtMsg(MSG_MACHININGSDBPAGE + 161) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), + New IdNameStruct(MCH_MIL_FU.PARAL_RIGHT, EgtMsg(MSG_MACHININGSDBPAGE + 162) & EgtMsg(MSG_MACHININGSDBPAGE + 154))}) + Case Else + m_FaceUseTypeList = New ObservableCollection(Of IdNameStruct)( + {New IdNameStruct(MCH_MIL_FU.NONE, EgtMsg(MSG_MACHININGSDBPAGE + 153)), + New IdNameStruct(MCH_MIL_FU.PARAL_DOWN, EgtMsg(MSG_MACHININGSDBPAGE + 157) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), + New IdNameStruct(MCH_MIL_FU.PARAL_TOP, EgtMsg(MSG_MACHININGSDBPAGE + 158) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), + New IdNameStruct(MCH_MIL_FU.PARAL_FRONT, EgtMsg(MSG_MACHININGSDBPAGE + 159) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), + New IdNameStruct(MCH_MIL_FU.PARAL_BACK, EgtMsg(MSG_MACHININGSDBPAGE + 160) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), + New IdNameStruct(MCH_MIL_FU.PARAL_LEFT, EgtMsg(MSG_MACHININGSDBPAGE + 161) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), + New IdNameStruct(MCH_MIL_FU.PARAL_RIGHT, EgtMsg(MSG_MACHININGSDBPAGE + 162) & EgtMsg(MSG_MACHININGSDBPAGE + 154)), + New IdNameStruct(MCH_MIL_FU.ORTHO_DOWN, EgtMsg(MSG_MACHININGSDBPAGE + 157) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), + New IdNameStruct(MCH_MIL_FU.ORTHO_TOP, EgtMsg(MSG_MACHININGSDBPAGE + 158) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), + New IdNameStruct(MCH_MIL_FU.ORTHO_FRONT, EgtMsg(MSG_MACHININGSDBPAGE + 159) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), + New IdNameStruct(MCH_MIL_FU.ORTHO_BACK, EgtMsg(MSG_MACHININGSDBPAGE + 160) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), + New IdNameStruct(MCH_MIL_FU.ORTHO_LEFT, EgtMsg(MSG_MACHININGSDBPAGE + 161) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), + New IdNameStruct(MCH_MIL_FU.ORTHO_RIGHT, EgtMsg(MSG_MACHININGSDBPAGE + 162) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), + New IdNameStruct(MCH_MIL_FU.ORTHO_CONT, EgtMsg(MSG_MACHININGSDBPAGE + 163) & EgtMsg(MSG_MACHININGSDBPAGE + 155)), + New IdNameStruct(MCH_MIL_FU.ORTUP_DOWN, EgtMsg(MSG_MACHININGSDBPAGE + 157) & EgtMsg(MSG_MACHININGSDBPAGE + 156)), + New IdNameStruct(MCH_MIL_FU.ORTUP_TOP, EgtMsg(MSG_MACHININGSDBPAGE + 158) & EgtMsg(MSG_MACHININGSDBPAGE + 156)), + New IdNameStruct(MCH_MIL_FU.ORTUP_FRONT, EgtMsg(MSG_MACHININGSDBPAGE + 159) & EgtMsg(MSG_MACHININGSDBPAGE + 156)), + New IdNameStruct(MCH_MIL_FU.ORTUP_BACK, EgtMsg(MSG_MACHININGSDBPAGE + 160) & EgtMsg(MSG_MACHININGSDBPAGE + 156)), + New IdNameStruct(MCH_MIL_FU.ORTUP_LEFT, EgtMsg(MSG_MACHININGSDBPAGE + 161) & EgtMsg(MSG_MACHININGSDBPAGE + 156)), + New IdNameStruct(MCH_MIL_FU.ORTUP_RIGHT, EgtMsg(MSG_MACHININGSDBPAGE + 162) & EgtMsg(MSG_MACHININGSDBPAGE + 156)), + New IdNameStruct(MCH_MIL_FU.ORTUP_CONT, EgtMsg(MSG_MACHININGSDBPAGE + 163) & EgtMsg(MSG_MACHININGSDBPAGE + 156))}) + End Select Return m_FaceUseTypeList End Get End Property diff --git a/ProjectPage/OptionPanel/MachiningOptionPanel/SimulationExpander/SimulationExpanderViewModel.vb b/ProjectPage/OptionPanel/MachiningOptionPanel/SimulationExpander/SimulationExpanderViewModel.vb index 2f0e9ba..01672e4 100644 --- a/ProjectPage/OptionPanel/MachiningOptionPanel/SimulationExpander/SimulationExpanderViewModel.vb +++ b/ProjectPage/OptionPanel/MachiningOptionPanel/SimulationExpander/SimulationExpanderViewModel.vb @@ -490,10 +490,7 @@ Namespace EgtCAM5 ' Recupero la fase corrente Dim nPhase As Integer = EgtGetCurrPhase() ' Aggiorno le lavorazioni - If Not UpdateAllMachinings() Then - EgtSetCurrPhase(If(nPhase = 0, 1, nPhase), True) - Return - End If + If Not UpdateAllMachinings() Then EgtSetCurrPhase(If(nPhase = 0, 1, nPhase), True) ' Costringo ad aggiornare UI UpdateUI() ' Imposto stato corrente diff --git a/SharedFieldsClass.vb b/SharedFieldsClass.vb index 25c84ab..e9e1131 100644 --- a/SharedFieldsClass.vb +++ b/SharedFieldsClass.vb @@ -15,15 +15,15 @@ Friend Compo(25) As Visibility ' Array che contiene il valore della proprietà visibility per ogni campo della lavorazione - Friend Milling(54) As Visibility - Friend Drilling(54) As Visibility - Friend Sawing(54) As Visibility - Friend Pocketing(54) As Visibility - Friend Mortising(54) As Visibility - Friend Sawroughing(54) As Visibility - Friend Sawfinishing(54) As Visibility - Friend GenMachining(54) As Visibility - Friend Chiseling(54) As Visibility + Friend Milling(56) As Visibility + Friend Drilling(56) As Visibility + Friend Sawing(56) As Visibility + Friend Pocketing(56) As Visibility + Friend Mortising(56) As Visibility + Friend Sawroughing(56) As Visibility + Friend Sawfinishing(56) As Visibility + Friend GenMachining(56) As Visibility + Friend Chiseling(56) As Visibility ' Array che contiene il valore della proprietà visibility per ogni campo delle operazioni Friend OperationDisposition(49) As Visibility @@ -337,6 +337,8 @@ Milling(52) = Visibility.Visible ' BlockedAxesRef Milling(53) = Visibility.Visible ' FaceUseType Milling(54) = Visibility.Visible ' InvertToolDir + Milling(55) = Visibility.Visible ' Expander LeadIn + Milling(56) = Visibility.Visible ' Expander LeadOut ' Parametri Drilling Drilling(0) = Visibility.Visible ' Invert @@ -394,6 +396,8 @@ Drilling(52) = Visibility.Visible ' BlockedAxesRef Drilling(53) = Visibility.Collapsed ' FaceUseType Drilling(54) = Visibility.Collapsed ' InvertToolDir + Drilling(55) = Visibility.Collapsed ' Expander LeadIn + Drilling(56) = Visibility.Collapsed ' Expander LeadOut ' Parametri Sawing Sawing(0) = Visibility.Visible ' Invert @@ -451,6 +455,8 @@ Sawing(52) = Visibility.Visible ' BlockedAxesRef Sawing(53) = Visibility.Collapsed ' FaceUseType Sawing(54) = Visibility.Collapsed ' InvertToolDir + Sawing(55) = Visibility.Visible ' Expander LeadIn + Sawing(56) = Visibility.Visible ' Expander LeadOut ' Parametri Pocketing Pocketing(0) = Visibility.Visible ' Invert @@ -508,11 +514,13 @@ Pocketing(52) = Visibility.Visible ' BlockedAxesRef Pocketing(53) = Visibility.Collapsed ' FaceUseType Pocketing(54) = Visibility.Visible ' InvertToolDir + Pocketing(55) = Visibility.Visible ' Expander LeadIn + Pocketing(56) = Visibility.Visible ' Expander LeadOut ' Parametri Mortising Mortising(0) = Visibility.Visible ' Invert Mortising(1) = Visibility.Collapsed ' LeaveTab - Mortising(2) = Visibility.Collapsed ' WorkSide + Mortising(2) = Visibility.Visible ' WorkSide Mortising(3) = Visibility.Collapsed ' HeadSide Mortising(4) = Visibility.Collapsed ' LeadInType Mortising(5) = Visibility.Collapsed ' ExtLinkType @@ -525,15 +533,15 @@ Mortising(12) = Visibility.Visible ' StartFeed Mortising(13) = Visibility.Visible ' EndFeed Mortising(14) = Visibility.Visible ' TipFeed - Mortising(15) = Visibility.Collapsed ' OffSr - Mortising(16) = Visibility.Collapsed ' OffSl + Mortising(15) = Visibility.Visible ' OffSr + Mortising(16) = Visibility.Visible ' OffSl Mortising(17) = Visibility.Collapsed ' SideAngle Mortising(18) = Visibility.Collapsed ' Approx Mortising(19) = Visibility.Visible ' StartPos Mortising(20) = Visibility.Collapsed ' StartSlowLen Mortising(21) = Visibility.Collapsed ' EndSlowLen Mortising(22) = Visibility.Collapsed ' ThroughAddlen - Mortising(23) = Visibility.Collapsed ' StepPar + Mortising(23) = Visibility.Visible ' StepPar Mortising(24) = Visibility.Collapsed ' Returnpos Mortising(25) = Visibility.Collapsed ' TabLen Mortising(26) = Visibility.Collapsed ' TabDist @@ -547,8 +555,8 @@ Mortising(34) = Visibility.Collapsed ' LoPerp Mortising(35) = Visibility.Collapsed ' LoElev Mortising(36) = Visibility.Collapsed ' LoCompLen - Mortising(37) = Visibility.Collapsed ' StartAddLen - Mortising(38) = Visibility.Collapsed ' EndAddLen + Mortising(37) = Visibility.Visible ' StartAddLen + Mortising(38) = Visibility.Visible ' EndAddLen Mortising(39) = Visibility.Collapsed ' StepExtArc Mortising(40) = Visibility.Collapsed ' StepIntArc Mortising(41) = Visibility.Collapsed ' SideStep @@ -563,8 +571,10 @@ Mortising(50) = Visibility.Visible ' SelectedSolChoiceType Mortising(51) = Visibility.Visible ' AxRotRef Mortising(52) = Visibility.Visible ' BlockedAxesRef - Mortising(53) = Visibility.Collapsed ' FaceUseType - Mortising(54) = Visibility.Collapsed ' InvertToolDir + Mortising(53) = Visibility.Visible ' FaceUseType + Mortising(54) = Visibility.Visible ' InvertToolDir + Mortising(55) = Visibility.Visible ' Expander LeadIn + Mortising(56) = Visibility.Visible ' Expander LeadOut ' Parametri Sawroughing Sawroughing(0) = Visibility.Visible ' Invert @@ -622,6 +632,8 @@ Sawroughing(52) = Visibility.Visible ' BlockedAxesRef Sawroughing(53) = Visibility.Collapsed ' FaceUseType Sawroughing(54) = Visibility.Collapsed ' InvertToolDir + Sawroughing(55) = Visibility.Collapsed ' Expander LeadIn + Sawroughing(56) = Visibility.Collapsed ' Expander LeadOut ' Parametri Sawfinishing Sawfinishing(0) = Visibility.Visible ' Invert @@ -679,6 +691,8 @@ Sawfinishing(52) = Visibility.Visible ' BlockedAxesRef Sawfinishing(53) = Visibility.Collapsed ' FaceUseType Sawfinishing(54) = Visibility.Collapsed ' InvertToolDir + Sawfinishing(55) = Visibility.Collapsed ' Expander LeadIn + Sawfinishing(56) = Visibility.Collapsed ' Expander LeadOut ' Parametri GenMachining GenMachining(0) = Visibility.Visible ' Invert @@ -736,6 +750,8 @@ GenMachining(52) = Visibility.Visible ' BlockedAxesRef GenMachining(53) = Visibility.Collapsed ' FaceUseType GenMachining(54) = Visibility.Visible ' InvertToolDir + GenMachining(55) = Visibility.Collapsed ' Expander LeadIn + GenMachining(56) = Visibility.Collapsed ' Expander LeadOut ' Parametri Chiseling Chiseling(0) = Visibility.Visible ' Invert @@ -793,6 +809,8 @@ Chiseling(52) = Visibility.Visible ' BlockedAxesRef Chiseling(53) = Visibility.Collapsed ' FaceUseType Chiseling(54) = Visibility.Visible ' InvertToolDir + Chiseling(55) = Visibility.Collapsed ' Expander LeadIn + Chiseling(56) = Visibility.Collapsed ' Expander LeadOut ' Parametri OperationDisposition OperationDisposition(0) = Visibility.Collapsed diff --git a/ToolsDbWindow/ToolDraw.vb b/ToolsDbWindow/ToolDraw.vb index 302032e..0afb01f 100644 --- a/ToolsDbWindow/ToolDraw.vb +++ b/ToolsDbWindow/ToolDraw.vb @@ -56,6 +56,14 @@ Module ToolDraw EgtLuaSetGlobNumVar("TOOL.HEIGHT", dThick) EgtLuaSetGlobNumVar("TOOL.SIDEANG", dSideAng) EgtLuaSetGlobNumVar("TOOL.CORNRAD", dCornRad) + Case MCH_TY.MORTISE_STD + ' imposto dati utensile + EgtLuaSetGlobStringVar("TOOL.TOOLHOLDER", sToolHolder) + EgtLuaSetGlobNumVar("TOOL.LEN", dLen) + EgtLuaSetGlobNumVar("TOOL.DIAM", dDiam) + EgtLuaSetGlobNumVar("TOOL.MAXMAT", dMaxMat) + EgtLuaSetGlobNumVar("TOOL.THICK", dThick) + EgtLuaSetGlobNumVar("TOOL.CORNRAD", dCornRad) Case Else nError = 999 Return False @@ -140,7 +148,7 @@ Module ToolDraw If nType <> MCH_TY.DRILL_STD And nType <> MCH_TY.DRILL_LONG And nType <> MCH_TY.SAW_STD And nType <> MCH_TY.SAW_FLAT And nType <> MCH_TY.MILL_STD And nType <> MCH_TY.MILL_NOTIP And - nType <> MCH_TY.CHISEL_STD Then + nType <> MCH_TY.CHISEL_STD And nType <> MCH_TY.MORTISE_STD Then Return False End If ' Path del file da salvare diff --git a/ToolsDbWindow/ToolTreeView.vb b/ToolsDbWindow/ToolTreeView.vb index 7900b7c..f7f3d49 100644 --- a/ToolsDbWindow/ToolTreeView.vb +++ b/ToolsDbWindow/ToolTreeView.vb @@ -789,7 +789,7 @@ Public Class ToolTreeViewItem Dim DbDraw As String = String.Empty EgtSetCurrentContext(IniFile.m_ProjectSceneContext) EgtTdbGetCurrToolParam(MCH_TP.DRAW, DbDraw) - m_IsModifiedDraw = If(value <> DbDraw, True, False) + m_IsModifiedDraw = (value <> DbDraw) NotifyPropertyChanged("Draw") End If End Set @@ -1239,7 +1239,7 @@ Public Class ToolTreeViewItem Private Sub CreateToolDraw() ' Imposto dati per creazione utensile ToolDraw.nToolContext = IniFile.m_ToolsDbSceneContext - ToolDraw.sHeadName = m_SelectedHead.HName + ToolDraw.sHeadName = If(Not IsNothing(m_SelectedHead), m_SelectedHead.HName, "") ToolDraw.sExitName = m_SelectedExit ToolDraw.nType = m_Type StringToLen(m_TotLen, ToolDraw.dTotLen) @@ -1257,6 +1257,8 @@ Public Class ToolTreeViewItem If m_nDrawingError <> 0 Then EgtNewFile() m_Draw = String.Empty + Else + m_Draw = Uuid & ".nge" End If ' Aggiorno visualizzazione EgtSetView(VT.TOP, False) @@ -1759,7 +1761,7 @@ Public Class ToolTreeViewItem If OpenFileDialog.EgtShowDialog <> True Then Return End If - m_Draw = Path.GetFileName(OpenFileDialog.FileName) + Draw = Path.GetFileName(OpenFileDialog.FileName) UpdateSceneToolDraw() End Sub @@ -1791,7 +1793,7 @@ Public Class ToolTreeViewItem ''' Creata the new tool. This method is invoked by the NewCommand. ''' Public Sub AutoDraw(ByVal param As Object) - m_Draw = m_Uuid & ".nge" + Draw = m_Uuid & ".nge" UpdateSceneToolDraw() End Sub