77 lines
1.9 KiB
VB.net
77 lines
1.9 KiB
VB.net
Imports EgtWPFLib5
|
|
Imports EgtUILib
|
|
Imports System.IO
|
|
|
|
Public Class SecondaryWindowVM
|
|
Inherits VMBase
|
|
|
|
#Region "FIELDS & PROPERTIES"
|
|
|
|
Public ReadOnly Property sTitle As String
|
|
Get
|
|
Return "EgtStone3D"
|
|
End Get
|
|
End Property
|
|
|
|
Public ReadOnly Property sProjectName As String
|
|
Get
|
|
Dim sFilePath As String = ""
|
|
EgtGetCurrFilePath(sFilePath)
|
|
If String.IsNullOrEmpty(sFilePath) Then
|
|
sFilePath = EgtMsg(30501) & Map.refMainWindowVM.MainWindowM.nInstance.ToString()
|
|
Return sFilePath
|
|
Else
|
|
Return Path.GetFileNameWithoutExtension(sFilePath) & If(EgtGetModified(), "*", "")
|
|
End If
|
|
End Get
|
|
End Property
|
|
|
|
Public ReadOnly Property sProjectPath As String
|
|
Get
|
|
Dim sFilePath As String = ""
|
|
EgtGetCurrFilePath(sFilePath)
|
|
If String.IsNullOrEmpty(sFilePath) Then
|
|
sFilePath = EgtMsg(30501) & Map.refMainWindowVM.MainWindowM.nInstance.ToString()
|
|
End If
|
|
Return sFilePath
|
|
End Get
|
|
End Property
|
|
|
|
' definizione comandi
|
|
Private m_cmdCloseApplication As ICommand
|
|
|
|
#End Region ' Fields & Properties
|
|
|
|
#Region "CONSTRUCTOR"
|
|
|
|
Sub New()
|
|
|
|
End Sub
|
|
|
|
#End Region ' Constructor
|
|
|
|
#Region "COMMANDS"
|
|
|
|
#Region "CloseApplicationCommand"
|
|
|
|
' Returns a command that manage the MainWindow_Unloaded command
|
|
Public ReadOnly Property CloseApplicationCommand() As ICommand
|
|
Get
|
|
If m_cmdCloseApplication Is Nothing Then
|
|
m_cmdCloseApplication = New Command(AddressOf CloseApplication)
|
|
End If
|
|
Return m_cmdCloseApplication
|
|
End Get
|
|
End Property
|
|
|
|
' Manage the MainWindow_Unloaded event. This method is invoked by the cmdMainWindow_Unloaded.
|
|
Public Sub CloseApplication(ByVal param As Object)
|
|
Map.refMainWindowVM.CloseApplication()
|
|
End Sub
|
|
|
|
#End Region ' CloseApplicationCommand
|
|
|
|
#End Region ' COMMANDS
|
|
|
|
End Class
|