EgtCAM5 :
- Implementato uso della EgtSaveFileDialog da EgtWPFLib5. - Abbozzata gestione dei file per GunStock. - Aggiunta virtualizzazione dell'albero dei layer. - Corretta visualizzazione pallini colorati nell'albero dei layer. - Miglioramenti nel salvataggio delle MTable e selezione di quella corrente. - Aggiunto colore Egaltech1 in IniFile per poterlo usare da codice.
This commit is contained in:
@@ -1,67 +1,152 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports EgtUILib
|
||||
|
||||
Namespace EgtCAM5
|
||||
|
||||
Public Class GunStockPanelViewModel
|
||||
Inherits ViewModelBase
|
||||
|
||||
Public ReadOnly Property MruGunStockNames As ObservableCollection(Of String)
|
||||
Public ReadOnly Property MruNewGunStockNames As ObservableCollection(Of String)
|
||||
Get
|
||||
Return IniFile.m_MruGunStock.m_FileNames
|
||||
Return IniFile.m_MruNewGunStock.m_FileNames
|
||||
End Get
|
||||
End Property
|
||||
|
||||
' Definizione comandi
|
||||
Private m_cmdGunStock As ICommand
|
||||
Private Shared m_cmdOpenMruGunStock As ICommand
|
||||
Public ReadOnly Property MruModifyGunStockNames As ObservableCollection(Of String)
|
||||
Get
|
||||
Return IniFile.m_MruModifyGunStock.m_FileNames
|
||||
End Get
|
||||
End Property
|
||||
|
||||
#Region "Messages"
|
||||
|
||||
Public ReadOnly Property NewGunStockMsg As String
|
||||
Get
|
||||
Return EgtMsg(MSG_DOORS + 4)
|
||||
End Get
|
||||
End Property
|
||||
Public ReadOnly Property ModifyGunStockMsg As String
|
||||
Get
|
||||
Return EgtMsg(MSG_DOORS + 4)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
#End Region ' Messages
|
||||
|
||||
#Region "ToolTip"
|
||||
|
||||
Public ReadOnly Property NewGunStockToolTip As String
|
||||
Get
|
||||
Return EgtMsg(MSG_DOORS + 4)
|
||||
End Get
|
||||
End Property
|
||||
Public ReadOnly Property ModifyGunStockToolTip As String
|
||||
Get
|
||||
Return EgtMsg(MSG_DOORS + 4)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
#End Region ' ToolTip
|
||||
|
||||
' Definizione comandi
|
||||
Private m_cmdNewGunStock As ICommand
|
||||
Private m_cmdModifyGunStock As ICommand
|
||||
Private Shared m_cmdOpenMruNewGunStock As ICommand
|
||||
Private Shared m_cmdOpenMruModifyGunStock As ICommand
|
||||
|
||||
#Region "COMMANDS"
|
||||
|
||||
#Region "GunStockCommand"
|
||||
#Region "NewGunStockCommand"
|
||||
|
||||
''' <summary>
|
||||
''' Returns a command that do Import.
|
||||
''' </summary>
|
||||
Public ReadOnly Property GunStockCommand As ICommand
|
||||
Public ReadOnly Property NewGunStockCommand As ICommand
|
||||
Get
|
||||
If m_cmdGunStock Is Nothing Then
|
||||
m_cmdGunStock = New RelayCommand(AddressOf GunStock)
|
||||
If m_cmdNewGunStock Is Nothing Then
|
||||
m_cmdNewGunStock = New RelayCommand(AddressOf NewGunStock)
|
||||
End If
|
||||
Return m_cmdGunStock
|
||||
Return m_cmdNewGunStock
|
||||
End Get
|
||||
End Property
|
||||
|
||||
''' <summary>
|
||||
''' Execute the Door. This method is invoked by the DoorsCommand.
|
||||
''' </summary>
|
||||
Public Sub GunStock(ByVal param As Object)
|
||||
Public Sub NewGunStock(ByVal param As Object)
|
||||
Application.Msn.NotifyColleagues(Application.GUNSTOCKSCRIPT, String.Empty)
|
||||
End Sub
|
||||
|
||||
#End Region ' GunStockCommand
|
||||
#End Region ' NewGunStockCommand
|
||||
|
||||
#Region "OpenMruGunStockCommand"
|
||||
#Region "ModifyGunStockCommand"
|
||||
|
||||
''' <summary>
|
||||
''' Returns a command that do Import.
|
||||
''' </summary>
|
||||
Public ReadOnly Property ModifyGunStockCommand As ICommand
|
||||
Get
|
||||
If m_cmdModifyGunStock Is Nothing Then
|
||||
m_cmdModifyGunStock = New RelayCommand(AddressOf ModifyGunStock)
|
||||
End If
|
||||
Return m_cmdModifyGunStock
|
||||
End Get
|
||||
End Property
|
||||
|
||||
''' <summary>
|
||||
''' Execute the Door. This method is invoked by the DoorsCommand.
|
||||
''' </summary>
|
||||
Public Sub ModifyGunStock(ByVal param As Object)
|
||||
Application.Msn.NotifyColleagues(Application.GUNSTOCKSCRIPT, String.Empty)
|
||||
End Sub
|
||||
|
||||
#End Region ' ModifyGunStockCommand
|
||||
|
||||
#Region "OpenMruNewGunStockCommand"
|
||||
|
||||
''' <summary>
|
||||
''' Returns a command that do Open.
|
||||
''' </summary>
|
||||
Public Shared ReadOnly Property OpenMruGunStockCommand As ICommand
|
||||
Public Shared ReadOnly Property OpenMruNewGunStockCommand As ICommand
|
||||
Get
|
||||
If m_cmdOpenMruGunStock Is Nothing Then
|
||||
m_cmdOpenMruGunStock = New RelayCommand(AddressOf OpenMruGunStock)
|
||||
If m_cmdOpenMruNewGunStock Is Nothing Then
|
||||
m_cmdOpenMruNewGunStock = New RelayCommand(AddressOf OpenMruNewGunStock)
|
||||
End If
|
||||
Return m_cmdOpenMruGunStock
|
||||
Return m_cmdOpenMruNewGunStock
|
||||
End Get
|
||||
End Property
|
||||
|
||||
''' <summary>
|
||||
''' Execute the Open. This method is invoked by the OpenCommand.
|
||||
''' </summary>
|
||||
Public Shared Sub OpenMruGunStock(ByVal param As Object)
|
||||
Public Shared Sub OpenMruNewGunStock(ByVal param As Object)
|
||||
Application.Msn.NotifyColleagues(Application.GUNSTOCKSCRIPT, DirectCast(param, String).Replace("__", "_"))
|
||||
End Sub
|
||||
|
||||
#End Region ' OpenMruGunStockCommand
|
||||
#End Region ' OpenMruNewGunStockCommand
|
||||
|
||||
#Region "OpenMruNewGunStockCommand"
|
||||
|
||||
''' <summary>
|
||||
''' Returns a command that do Open.
|
||||
''' </summary>
|
||||
Public Shared ReadOnly Property OpenMruModifyGunStockCommand As ICommand
|
||||
Get
|
||||
If m_cmdOpenMruModifyGunStock Is Nothing Then
|
||||
m_cmdOpenMruModifyGunStock = New RelayCommand(AddressOf OpenMruModifyGunStock)
|
||||
End If
|
||||
Return m_cmdOpenMruModifyGunStock
|
||||
End Get
|
||||
End Property
|
||||
|
||||
''' <summary>
|
||||
''' Execute the Open. This method is invoked by the OpenCommand.
|
||||
''' </summary>
|
||||
Public Shared Sub OpenMruModifyGunStock(ByVal param As Object)
|
||||
Application.Msn.NotifyColleagues(Application.GUNSTOCKSCRIPT, DirectCast(param, String).Replace("__", "_"))
|
||||
End Sub
|
||||
|
||||
#End Region ' OpenMruNewGunStockCommand
|
||||
|
||||
#End Region
|
||||
|
||||
|
||||
Reference in New Issue
Block a user