EgtCAM5 :
- Cambiati nomi classi e file.
This commit is contained in:
@@ -0,0 +1,87 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports EgtUILib
|
||||
|
||||
Namespace EgtCAM5
|
||||
|
||||
Public Class ExecutePanelVM
|
||||
Inherits ViewModelBase
|
||||
|
||||
#Region "FIELDS & PROPERTIES"
|
||||
|
||||
Public ReadOnly Property MruScriptNames As ObservableCollection(Of String)
|
||||
Get
|
||||
Return IniFile.m_MruScripts.m_FileNames
|
||||
End Get
|
||||
End Property
|
||||
|
||||
' Definizione comandi
|
||||
Private m_cmdExec As ICommand
|
||||
Private Shared m_cmdOpenMruScript As ICommand
|
||||
|
||||
#Region "ToolTip"
|
||||
|
||||
Public ReadOnly Property ExecToolTip As String
|
||||
Get
|
||||
Return EgtMsg(MSG_TOPCOMMANDBAR + 8)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
#End Region ' ToolTip
|
||||
|
||||
#End Region ' FIELDS & PROPERTIES
|
||||
|
||||
#Region "COMMANDS"
|
||||
|
||||
#Region "ExecCommand"
|
||||
|
||||
''' <summary>
|
||||
''' Returns a command that do Exec.
|
||||
''' </summary>
|
||||
Public ReadOnly Property ExecCommand As ICommand
|
||||
Get
|
||||
If m_cmdExec Is Nothing Then
|
||||
m_cmdExec = New RelayCommand(AddressOf Exec)
|
||||
End If
|
||||
Return m_cmdExec
|
||||
End Get
|
||||
End Property
|
||||
|
||||
''' <summary>
|
||||
''' Execute the Exec. This method is invoked by the ExecCommand.
|
||||
''' </summary>
|
||||
Public Sub Exec(ByVal param As Object)
|
||||
Application.Msn.NotifyColleagues(Application.PREEXECSCRIPT, True)
|
||||
Application.Msn.NotifyColleagues(Application.EXECSCRIPT, String.Empty)
|
||||
End Sub
|
||||
|
||||
#End Region ' ExecCommand
|
||||
|
||||
#Region "OpenMruScriptCommand"
|
||||
|
||||
''' <summary>
|
||||
''' Returns a command that do Open.
|
||||
''' </summary>
|
||||
Public Shared ReadOnly Property OpenMruScriptCommand As ICommand
|
||||
Get
|
||||
If m_cmdOpenMruScript Is Nothing Then
|
||||
m_cmdOpenMruScript = New RelayCommand(AddressOf OpenMruScript)
|
||||
End If
|
||||
Return m_cmdOpenMruScript
|
||||
End Get
|
||||
End Property
|
||||
|
||||
''' <summary>
|
||||
''' Execute the Open. This method is invoked by the OpenCommand.
|
||||
''' </summary>
|
||||
Public Shared Sub OpenMruScript(ByVal param As Object)
|
||||
Application.Msn.NotifyColleagues(Application.PREEXECSCRIPT, True)
|
||||
Application.Msn.NotifyColleagues(Application.EXECSCRIPT, DirectCast(param, String).Replace("__", "_"))
|
||||
End Sub
|
||||
|
||||
#End Region ' OpenMruFileCommand
|
||||
|
||||
#End Region ' COMMANDS
|
||||
|
||||
End Class
|
||||
|
||||
End Namespace
|
||||
Reference in New Issue
Block a user