EgtCAM5 :
- Migliorie varie.
This commit is contained in:
@@ -10,6 +10,8 @@ Namespace EgtCAM5
|
||||
|
||||
#Region "FIELDS"
|
||||
|
||||
Private m_CloseProgram As Boolean = False
|
||||
|
||||
'PROJECT PAGE'S PANELS
|
||||
Private m_GridViewPanel As BaseWindowView
|
||||
Private m_DrawPanel As BaseWindowView
|
||||
@@ -26,21 +28,6 @@ Namespace EgtCAM5
|
||||
Get
|
||||
If m_bfirst Then
|
||||
SceneHost = New WindowsFormsHost() With {.Child = m_ProjectScene}
|
||||
PreInitializeScene()
|
||||
If Not m_ProjectScene.Init() Then
|
||||
EgtOutLog("Error in Project scene creation")
|
||||
' Box di avviso
|
||||
MsgBox(EgtMsg(MSG_MISSINGKEYWD + 2) & vbCrLf & EgtMsg(MSG_MISSINGKEYWD + 3), MsgBoxStyle.OkOnly, EgtMsg(MSG_MISSINGKEYWD + 1))
|
||||
' Chiudo il programma
|
||||
Application.Msn.NotifyColleagues(Application.CLOSEAPPLICATIONCOMMAND)
|
||||
' Verifico abilitazione prodotto
|
||||
ElseIf (IniFile.m_nKeyOptions And KEY_OPT.BASE) = 0 Then
|
||||
MsgBox(EgtMsg(MSG_MISSINGKEYWD + 5), MsgBoxStyle.OkOnly, EgtMsg(MSG_MISSINGKEYWD + 1))
|
||||
End If
|
||||
IniFile.m_ProjectSceneContext = m_ProjectScene.GetCtx
|
||||
PostInitializeScene()
|
||||
' inizializzo gestore lavorazioni
|
||||
EgtInitMachMgr(IniFile.m_sMachinesRoot)
|
||||
m_bfirst = False
|
||||
End If
|
||||
Return SceneHost
|
||||
@@ -48,6 +35,8 @@ Namespace EgtCAM5
|
||||
End Property
|
||||
' Scene controller
|
||||
Private WithEvents m_Controller As New Controller
|
||||
' Definizione comandi
|
||||
Private m_cmdLoaded As ICommand
|
||||
|
||||
#End Region
|
||||
|
||||
@@ -112,6 +101,58 @@ Namespace EgtCAM5
|
||||
|
||||
#End Region
|
||||
|
||||
#Region "COMMANDS"
|
||||
|
||||
#Region "LoadedCommand"
|
||||
|
||||
''' <summary>
|
||||
''' Returns a command that do Point.
|
||||
''' </summary>
|
||||
Public ReadOnly Property LoadedCommand As ICommand
|
||||
Get
|
||||
If m_cmdLoaded Is Nothing Then
|
||||
m_cmdLoaded = New RelayCommand(AddressOf Loaded, AddressOf CanLoaded)
|
||||
End If
|
||||
Return m_cmdLoaded
|
||||
End Get
|
||||
End Property
|
||||
|
||||
''' <summary>
|
||||
''' Execute the Point. This method is invoked by the PointCommand.
|
||||
''' </summary>
|
||||
Public Sub Loaded(ByVal param As Object)
|
||||
PreInitializeScene()
|
||||
If Not m_ProjectScene.Init() Then
|
||||
EgtOutLog("Error in Project scene creation")
|
||||
SceneHost.Child = Nothing
|
||||
' Box di avviso
|
||||
MsgBox(EgtMsg(MSG_MISSINGKEYWD + 2) & vbCrLf & EgtMsg(MSG_MISSINGKEYWD + 3), MsgBoxStyle.OkOnly, EgtMsg(MSG_MISSINGKEYWD + 1))
|
||||
' Chiudo il programma
|
||||
Application.Msn.NotifyColleagues(Application.CLOSEAPPLICATIONCOMMAND)
|
||||
' Verifico abilitazione prodotto
|
||||
ElseIf (IniFile.m_nKeyOptions And KEY_OPT.BASE) = 0 Then
|
||||
m_CloseProgram = True
|
||||
MsgBox(EgtMsg(MSG_MISSINGKEYWD + 5), MsgBoxStyle.OkOnly, EgtMsg(MSG_MISSINGKEYWD + 1))
|
||||
Else
|
||||
IniFile.m_ProjectSceneContext = m_ProjectScene.GetCtx
|
||||
PostInitializeScene()
|
||||
' inizializzo gestore lavorazioni
|
||||
EgtInitMachMgr(IniFile.m_sMachinesRoot)
|
||||
End If
|
||||
|
||||
End Sub
|
||||
|
||||
''' <summary>
|
||||
''' Returns always true.
|
||||
''' </summary>
|
||||
Private Function CanLoaded(ByVal param As Object) As Boolean
|
||||
Return True
|
||||
End Function
|
||||
|
||||
#End Region ' LoadedCommand
|
||||
|
||||
#End Region
|
||||
|
||||
#Region "METHODS"
|
||||
|
||||
Private Sub PreInitializeScene()
|
||||
|
||||
Reference in New Issue
Block a user