Icarus 2.4l2 :
- corretti movimenti e rotazioni di LayerStart, Ribs e Reduce - bottone impostazioni Grid visibile solo se Grid abilitata - migliorato controllo esistenza direttorio generazione CN.
This commit is contained in:
@@ -74,8 +74,8 @@ Public Class ShellNumberPanelVM
|
||||
Dim dNewXPos As Double = b3Reference.Min.x
|
||||
StringToLen(value, dNewXPos)
|
||||
If dNewXPos >= 0 AndAlso dNewXPos <= CurrentMachine.b3Tab.DimX Then
|
||||
EgtMove(m_SelShellNumber.nCurveId, New Point3d(dNewXPos, b3Reference.Min.y, b3Reference.Min.z) - b3Reference.Min)
|
||||
EgtMove(m_SelShellNumber.nExtrusionId, New Point3d(dNewXPos, b3Reference.Min.y, b3Reference.Min.z) - b3Reference.Min)
|
||||
EgtMove(m_SelShellNumber.nCurveId, New Point3d(dNewXPos, b3Reference.Min.y, b3Reference.Min.z) - b3Reference.Min, GDB_RT.GLOB)
|
||||
EgtMove(m_SelShellNumber.nExtrusionId, New Point3d(dNewXPos, b3Reference.Min.y, b3Reference.Min.z) - b3Reference.Min, GDB_RT.GLOB)
|
||||
EgtDraw()
|
||||
Else
|
||||
NotifyPropertyChanged(NameOf(sXPos))
|
||||
@@ -103,8 +103,8 @@ Public Class ShellNumberPanelVM
|
||||
Dim dNewYPos As Double = b3Reference.Min.y
|
||||
StringToLen(value, dNewYPos)
|
||||
If dNewYPos >= 0 AndAlso dNewYPos <= CurrentMachine.b3Tab.DimY Then
|
||||
EgtMove(m_SelShellNumber.nCurveId, New Point3d(b3Reference.Min.x, dNewYPos, b3Reference.Min.z) - b3Reference.Min)
|
||||
EgtMove(m_SelShellNumber.nExtrusionId, New Point3d(b3Reference.Min.x, dNewYPos, b3Reference.Min.z) - b3Reference.Min)
|
||||
EgtMove(m_SelShellNumber.nCurveId, New Point3d(b3Reference.Min.x, dNewYPos, b3Reference.Min.z) - b3Reference.Min, GDB_RT.GLOB)
|
||||
EgtMove(m_SelShellNumber.nExtrusionId, New Point3d(b3Reference.Min.x, dNewYPos, b3Reference.Min.z) - b3Reference.Min, GDB_RT.GLOB)
|
||||
EgtDraw()
|
||||
Else
|
||||
NotifyPropertyChanged(NameOf(sYPos))
|
||||
@@ -132,8 +132,8 @@ Public Class ShellNumberPanelVM
|
||||
Dim dNewZPos As Double = b3Reference.Min.y
|
||||
StringToLen(value, dNewZPos)
|
||||
If dNewZPos >= 0 Then
|
||||
EgtMove(m_SelShellNumber.nCurveId, New Point3d(b3Reference.Min.x, b3Reference.Min.y, dNewZPos) - b3Reference.Min)
|
||||
EgtMove(m_SelShellNumber.nExtrusionId, New Point3d(b3Reference.Min.x, b3Reference.Min.y, dNewZPos) - b3Reference.Min)
|
||||
EgtMove(m_SelShellNumber.nCurveId, New Point3d(b3Reference.Min.x, b3Reference.Min.y, dNewZPos) - b3Reference.Min, GDB_RT.GLOB)
|
||||
EgtMove(m_SelShellNumber.nExtrusionId, New Point3d(b3Reference.Min.x, b3Reference.Min.y, dNewZPos) - b3Reference.Min, GDB_RT.GLOB)
|
||||
EgtDraw()
|
||||
Else
|
||||
NotifyPropertyChanged(NameOf(sZPos))
|
||||
@@ -144,12 +144,28 @@ Public Class ShellNumberPanelVM
|
||||
End Property
|
||||
|
||||
Private m_RotAxes() As Boolean = {False, False, True}
|
||||
Public Property RotAxes As Boolean()
|
||||
Public Property RotX As Boolean
|
||||
Get
|
||||
Return m_RotAxes
|
||||
Return m_RotAxes(0)
|
||||
End Get
|
||||
Set(value As Boolean())
|
||||
m_RotAxes = value
|
||||
Set(value As Boolean)
|
||||
m_RotAxes(0) = value
|
||||
End Set
|
||||
End Property
|
||||
Public Property RotY As Boolean
|
||||
Get
|
||||
Return m_RotAxes(1)
|
||||
End Get
|
||||
Set(value As Boolean)
|
||||
m_RotAxes(1) = value
|
||||
End Set
|
||||
End Property
|
||||
Public Property RotZ As Boolean
|
||||
Get
|
||||
Return m_RotAxes(2)
|
||||
End Get
|
||||
Set(value As Boolean)
|
||||
m_RotAxes(2) = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
@@ -159,7 +175,7 @@ Public Class ShellNumberPanelVM
|
||||
Return Vector3d.X_AX
|
||||
ElseIf m_RotAxes(1) Then
|
||||
Return Vector3d.Y_AX
|
||||
ElseIf m_RotAxes(2) Then
|
||||
Else
|
||||
Return Vector3d.Z_AX
|
||||
End If
|
||||
End Get
|
||||
@@ -179,20 +195,20 @@ Public Class ShellNumberPanelVM
|
||||
End If
|
||||
Dim nId As Integer = If(m_SelShellNumber.Type = ShellNumberEntity.ShellNumberTypes.FROMDRAW, m_SelShellNumber.nCurveId, m_SelShellNumber.nExtrusionId)
|
||||
Dim b3Rib As New BBox3d
|
||||
EgtGetBBox(nId, GDB_BB.STANDARD, b3Rib)
|
||||
EgtGetBBoxGlob(nId, GDB_BB.STANDARD, b3Rib)
|
||||
Dim bOk As Boolean = False
|
||||
bOk = EgtRotate(nId, b3Rib.Center(), vtSelRotAxes, dNewAngle)
|
||||
If bOk AndAlso m_SelShellNumber.Type = ShellNumberEntity.ShellNumberTypes.FROMDRAW Then EgtRotate(m_SelShellNumber.nExtrusionId, b3Rib.Center, vtSelRotAxes, dNewAngle)
|
||||
bOk = EgtRotate(nId, b3Rib.Center(), vtSelRotAxes, dNewAngle, GDB_RT.GLOB)
|
||||
If bOk AndAlso m_SelShellNumber.Type = ShellNumberEntity.ShellNumberTypes.FROMDRAW Then EgtRotate(m_SelShellNumber.nExtrusionId, b3Rib.Center, vtSelRotAxes, dNewAngle, GDB_RT.GLOB)
|
||||
If bOk Then
|
||||
EgtDraw()
|
||||
RefreshPos()
|
||||
m_sRotAngle = 0
|
||||
NotifyPropertyChanged(NameOf(sRotAngle))
|
||||
' Imposto flag di ricalcolo slice
|
||||
EgtSetInfo(Map.refTopPanelVM.SelPart.nPartId, MAC_TORECALC_SLICE, True)
|
||||
Else
|
||||
m_sRotAngle = value
|
||||
End If
|
||||
' Imposto flag di ricalcolo slice
|
||||
EgtSetInfo(Map.refTopPanelVM.SelPart.nPartId, MAC_TORECALC_SLICE, True)
|
||||
End Set
|
||||
End Property
|
||||
|
||||
@@ -264,6 +280,12 @@ Public Class ShellNumberPanelVM
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Public ReadOnly Property bGrid_IsEnabled As Boolean
|
||||
Get
|
||||
Return Map.refMyStatusBarVM.bGridVisibility
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Private m_bMove_IsChecked As Boolean
|
||||
Public Property bMove_IsChecked As Boolean
|
||||
Get
|
||||
@@ -411,6 +433,9 @@ Public Class ShellNumberPanelVM
|
||||
#Region "METHODS"
|
||||
|
||||
Friend Sub Init()
|
||||
' asse rotazione di default
|
||||
RotZ = True
|
||||
NotifyPropertyChanged(NameOf(RotZ))
|
||||
' azzero indice
|
||||
StartEntity.ResetSharedIndex()
|
||||
' fisso frame originale
|
||||
@@ -418,7 +443,11 @@ Public Class ShellNumberPanelVM
|
||||
' recupero dati pezzo selezionato layer ed entita'
|
||||
m_nPartId = Map.refTopPanelVM.SelPart.nPartId
|
||||
m_nShellNumberLayerId = Map.refTopPanelVM.SelPart.nShellNumberLayerId
|
||||
'recupero tutte le entita' rib
|
||||
If m_nShellNumberLayerId = GDB_ID.NULL Then
|
||||
m_nShellNumberLayerId = EgtCreateGroup(m_nPartId)
|
||||
EgtSetName(m_nShellNumberLayerId, LAY_SHELL_NBR)
|
||||
End If
|
||||
'recupero tutte le entita' shell number
|
||||
m_ShellNumberList.Clear()
|
||||
Dim nShellNumberId As Integer = EgtGetFirstInGroup(m_nShellNumberLayerId)
|
||||
While nShellNumberId <> GDB_ID.NULL
|
||||
@@ -1308,7 +1337,7 @@ Public Class ShellNumberEntity
|
||||
Sub New(Type As ShellNumberTypes, nId As Integer)
|
||||
m_nIndex = nSharedIndex
|
||||
m_Type = Type
|
||||
EgtSetInfo(nId, KEY_RIB_TYPE, Type)
|
||||
EgtSetInfo(nId, KEY_SHELLNBR_TYPE, Type)
|
||||
Select Case Type
|
||||
Case ShellNumberTypes.FROMDRAW
|
||||
m_nCurveId = nId
|
||||
|
||||
Reference in New Issue
Block a user