4ce3213e69
- in simulazione corretta visualizzazione coordinate esatte su stop e pausa - gestita chiusura certa simulazione al passaggio in disegna.
96 lines
4.5 KiB
VB.net
96 lines
4.5 KiB
VB.net
Imports EgtUILib
|
|
|
|
Namespace EgtCAM5
|
|
|
|
Public Class OptionPanelViewModel
|
|
Inherits ViewModelBase
|
|
|
|
Private m_DrawIsChecked As Boolean = True
|
|
|
|
Private m_MachiningIsChecked As Boolean = False
|
|
|
|
' GRAPHICAL ELEMENTS
|
|
Private m_OperationExpander As OperationExpanderView
|
|
Private m_ManageLayerExpander As ManageLayerExpanderView
|
|
Public ReadOnly Property ManageLayerExpander As ContentControl
|
|
Get
|
|
If m_DrawIsChecked Then
|
|
If IsNothing(m_ManageLayerExpander) Then
|
|
m_ManageLayerExpander = New ManageLayerExpanderView
|
|
m_ManageLayerExpander.DataContext = New ManageLayerExpanderViewModel
|
|
End If
|
|
Return m_ManageLayerExpander
|
|
Else
|
|
If IsNothing(m_OperationExpander) Then
|
|
m_OperationExpander = New OperationExpanderView
|
|
m_OperationExpander.DataContext = New OperationExpanderViewModel
|
|
End If
|
|
Application.Msn.NotifyColleagues(Application.LOADOPERATIONLIST, -1)
|
|
Return m_OperationExpander
|
|
End If
|
|
End Get
|
|
End Property
|
|
|
|
Private m_MachiningsTreeExpander As MachiningTreeExpanderView
|
|
Private m_InfoExpander As InfoExpanderView
|
|
Public ReadOnly Property InfoExpander As ContentControl
|
|
Get
|
|
If m_DrawIsChecked Then
|
|
If IsNothing(m_InfoExpander) Then
|
|
m_InfoExpander = New InfoExpanderView
|
|
m_InfoExpander.DataContext = New InfoExpanderViewModel
|
|
End If
|
|
Return m_InfoExpander
|
|
Else
|
|
If IsNothing(m_MachiningsTreeExpander) Then
|
|
m_MachiningsTreeExpander = New MachiningTreeExpanderView
|
|
m_MachiningsTreeExpander.DataContext = New MachiningTreeExpanderViewModel
|
|
End If
|
|
Return m_MachiningsTreeExpander
|
|
End If
|
|
End Get
|
|
End Property
|
|
|
|
Private m_SimulationExpander As SimulationExpanderView
|
|
Private m_InputExpander As InputExpanderView
|
|
Public ReadOnly Property InputExpander As ContentControl
|
|
Get
|
|
If m_DrawIsChecked Then
|
|
If IsNothing(m_InputExpander) Then
|
|
m_InputExpander = New InputExpanderView
|
|
m_InputExpander.DataContext = New InputExpanderViewModel
|
|
End If
|
|
Return m_InputExpander
|
|
Else
|
|
If IsNothing(m_SimulationExpander) Then
|
|
m_SimulationExpander = New SimulationExpanderView
|
|
m_SimulationExpander.DataContext = New SimulationExpanderViewModel
|
|
End If
|
|
Return m_SimulationExpander
|
|
End If
|
|
End Get
|
|
End Property
|
|
|
|
Sub New()
|
|
Application.Msn.Register(Application.MACHININGMODE_ISCHECKED, Sub()
|
|
m_DrawIsChecked = False
|
|
m_MachiningIsChecked = True
|
|
EgtZoom(ZM.ALL, False)
|
|
OnPropertyChanged("ManageLayerExpander")
|
|
OnPropertyChanged("InfoExpander")
|
|
OnPropertyChanged("InputExpander")
|
|
End Sub)
|
|
Application.Msn.Register(Application.DRAWMODE_ISCHECKED, Sub()
|
|
m_DrawIsChecked = True
|
|
m_MachiningIsChecked = False
|
|
Application.Msn.NotifyColleagues(Application.SIMULATIONEXPANDER_SET_ISEXPANDED, False)
|
|
OnPropertyChanged("ManageLayerExpander")
|
|
OnPropertyChanged("InfoExpander")
|
|
OnPropertyChanged("InputExpander")
|
|
End Sub)
|
|
|
|
End Sub
|
|
|
|
End Class
|
|
|
|
End Namespace |