Files
egtbeamwall/EgtBEAMWALL.ViewerOptimizer/FeatureManager/FeatureManagerVM.vb
T
Dario Sassi d781989da9 EgtBEAMWALL :
- risistemazione.
2025-01-21 16:50:49 +01:00

116 lines
3.1 KiB
VB.net

Imports EgtBEAMWALL.Core
Imports EgtUILib
Imports EgtWPFLib5
Public Class FeatureManagerVM
Inherits VMBase
#Region "FIELDS & PROPERTIES"
Private m_FeatureManager_IsEnabled As Boolean = True
Public Property FeatureManager_IsEnabled As Boolean
Get
Return m_FeatureManager_IsEnabled
End Get
Set(value As Boolean)
m_FeatureManager_IsEnabled = value
End Set
End Property
Private m_Variant_Visibility As Visibility = Visibility.Collapsed
Public ReadOnly Property Variant_Visibility As Visibility
Get
Return m_Variant_Visibility
End Get
End Property
Public Sub SetVariant_Visibility(value As Visibility)
m_Variant_Visibility = value
NotifyPropertyChanged(NameOf(Variant_Visibility))
End Sub
Public ReadOnly Property Edit_IsEnabled As Boolean
Get
Return m_FeatureManager_IsEnabled AndAlso Not IsNothing(Map.refProjectVM.BTLStructureVM) AndAlso
Map.refProjectVM.BTLStructureVM.SelBTLParts.Count > 0 AndAlso
Not IsNothing(Map.refProjectVM.BTLStructureVM.SelBTLParts(0)) AndAlso
Not IsNothing(Map.refProjectVM.BTLStructureVM.SelBTLParts(0).SelBTLFeatureVM) AndAlso
Map.refProjectVM.BTLStructureVM.SelBTLParts(0).SelBTLFeatureVM.BTLFeatureM.IsFreeContour() AndAlso
Map.refProjectVM.BTLStructureVM.SelBTLParts(0).SelBTLFeatureVM.bDO
End Get
End Property
Public ReadOnly Property Priority_Visibility As Visibility
Get
Return If(CurrentMachine.nType = Core.ConstBeam.MachineType.WALL AndAlso CurrentMachine.bIsEnabledPriority, Visibility.Visible, Visibility.Collapsed)
End Get
End Property
#Region "Messages"
Public ReadOnly Property Face_Msg As String
Get
Return EgtMsg(61824)
End Get
End Property
Public ReadOnly Property Group_Msg As String
Get
Return EgtMsg(61825)
End Get
End Property
Public ReadOnly Property Priority_Msg As String
Get
Return EgtMsg(61895)
End Get
End Property
Public ReadOnly Property Edit_Msg As String
Get
Return EgtMsg(61826)
End Get
End Property
Public ReadOnly Property Save_Msg As String
Get
Return EgtMsg(61827)
End Get
End Property
Public ReadOnly Property Cancel_Msg As String
Get
Return EgtMsg(61828)
End Get
End Property
#End Region ' Messages
#End Region ' FIELDS & PROPERTIES
#Region "CONSTRUCTORS"
Sub New()
' imposto riferimento in Map
Map.SetRefFeatureManagerVM(Me)
End Sub
#End Region ' CONSTRUCTORS
#Region "METHODS"
Friend Sub SetFeatureManagerIsEnabled(bIsEnabled As Boolean)
m_FeatureManager_IsEnabled = bIsEnabled
NotifyPropertyChanged(NameOf(FeatureManager_IsEnabled))
NotifyPropertyChanged(NameOf(Edit_IsEnabled))
End Sub
Friend Sub SetEditIsEnabled()
' aggiorno stato abilitazione del bottone modifica free contour
NotifyPropertyChanged(NameOf(Edit_IsEnabled))
End Sub
#End Region ' METHODS
End Class