Compare commits
42 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 0d31c0dd28 | |||
| 9fd4fb3f60 | |||
| 7b6063d337 | |||
| 63dec23d10 | |||
| 32b743c7e1 | |||
| c7debc8c31 | |||
| 1a5d6a5ab5 | |||
| d812365abc | |||
| acc8cd3a5e | |||
| 5f2c355121 | |||
| f3bd024f29 | |||
| 305913a8a9 | |||
| 82f4944844 | |||
| 16203c4596 | |||
| ef196d84e5 | |||
| 456e8697be | |||
| 88502249dd | |||
| 412df1c856 | |||
| fac1206613 | |||
| 9dc4278783 | |||
| 3388afffb5 | |||
| 93a54a47bb | |||
| 7d1b2004d9 | |||
| 34493aca8f | |||
| 8035f6ee87 | |||
| 2023a6217d | |||
| 6043e8bf16 | |||
| 95b1d94ea9 | |||
| 8f1e5821cd | |||
| c1272fa5d2 | |||
| 8adc2d749b | |||
| 69f52511e0 | |||
| 7a7e15f34b | |||
| 9adb463d30 | |||
| d3a7ef97a6 | |||
| 48edd0abc4 | |||
| edb2d25953 | |||
| 4786a666fd | |||
| bf6d36be9b | |||
| 701c6e816a | |||
| f2da51ffa7 | |||
| 1e006a8eb6 |
@@ -0,0 +1,48 @@
|
|||||||
|
Imports EgtUILib
|
||||||
|
|
||||||
|
Public Class AngleVM
|
||||||
|
Inherits SceneUserControlVM
|
||||||
|
|
||||||
|
#Region "CONSTRUCTOR"
|
||||||
|
|
||||||
|
Public Sub New()
|
||||||
|
MyBase.New()
|
||||||
|
Title = EGT_ADDCONSTRAINT.ToUpper()
|
||||||
|
|
||||||
|
DirectCast(Map.refSceneButtonVM.m_AngleUC, SceneUserControlV).Preview.Visibility = Visibility.Hidden
|
||||||
|
DirectCast(Map.refSceneButtonVM.m_AngleUC, SceneUserControlV).Annulla.Visibility = Visibility.Hidden
|
||||||
|
|
||||||
|
LoadParamList()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
#End Region ' Constructor
|
||||||
|
|
||||||
|
#Region "METHODS"
|
||||||
|
|
||||||
|
Public Overrides Sub LoadParamList()
|
||||||
|
' ' Inserisci Angolo
|
||||||
|
AddGenericParam(New _TextBlockParam(EGT_MESSAGE, EgtMsg(110048), ParamType.STR))
|
||||||
|
' Angolo
|
||||||
|
AddGenericParam(New _TextBoxParam(EgtMsg(110006), 0, ParamType.DOUB, Visibility.Visible, True))
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Overrides Sub Conferma()
|
||||||
|
LoadEditParametric()
|
||||||
|
Close()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Overrides Sub ShowPreview()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Overrides Sub Annulla()
|
||||||
|
Close()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub Close()
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_AngleUC)
|
||||||
|
SolidManagerM.ManageUndoRedo()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
#End Region ' Methods
|
||||||
|
|
||||||
|
End Class
|
||||||
@@ -11,6 +11,16 @@ Public Class ParametricCompoVM
|
|||||||
Friend ReadOnly bFileExsist As Boolean = False
|
Friend ReadOnly bFileExsist As Boolean = False
|
||||||
Private m_nVeinCtx As Integer
|
Private m_nVeinCtx As Integer
|
||||||
|
|
||||||
|
Private m_nPartId As Integer = GDB_ID.NULL
|
||||||
|
Public Property nPartId As Integer
|
||||||
|
Get
|
||||||
|
Return m_nPartId
|
||||||
|
End Get
|
||||||
|
Set(value As Integer)
|
||||||
|
m_nPartId = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
#End Region ' Fields & Properties
|
#End Region ' Fields & Properties
|
||||||
|
|
||||||
#Region "CONSTRUCTOR"
|
#Region "CONSTRUCTOR"
|
||||||
@@ -52,7 +62,7 @@ Public Class ParametricCompoVM
|
|||||||
Dim sName As String = String.Empty
|
Dim sName As String = String.Empty
|
||||||
EgtLuaGetGlobStringVar("CMP.Nome", sName)
|
EgtLuaGetGlobStringVar("CMP.Nome", sName)
|
||||||
Dim nPar As Integer = CInt(sPar)
|
Dim nPar As Integer = CInt(sPar)
|
||||||
ParamList.Add(New _TextBlockParam("Messaggio", sName, Visibility.Visible))
|
ParamList.Add(New _TextBlockParam(EGT_MESSAGE, sName, Visibility.Visible))
|
||||||
' Recupero nome, tipo e valore delle variabili globali
|
' Recupero nome, tipo e valore delle variabili globali
|
||||||
For Index As Integer = 1 To nPar
|
For Index As Integer = 1 To nPar
|
||||||
Dim NewCompo As GenericParam = Nothing
|
Dim NewCompo As GenericParam = Nothing
|
||||||
@@ -82,6 +92,15 @@ Public Class ParametricCompoVM
|
|||||||
Next
|
Next
|
||||||
EgtLuaExecLine("CMP_Draw" & "(true)")
|
EgtLuaExecLine("CMP_Draw" & "(true)")
|
||||||
EgtLuaResetGlobVar("CMP")
|
EgtLuaResetGlobVar("CMP")
|
||||||
|
|
||||||
|
' rinomino il part con un nome univoco
|
||||||
|
Dim nPart As Integer = EgtGetLastPart()
|
||||||
|
EgtLuaSetGlobNumVar("TOOL.nId", nPart)
|
||||||
|
EgtLuaCallFunction("TOOL.RenameNewPart")
|
||||||
|
EgtLuaCallFunction("TOOL.ReorganizeEdges")
|
||||||
|
EgtLuaCallFunction("TOOL.ClearVariables")
|
||||||
|
|
||||||
|
nPartId = EgtGetLastPart()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Public Overrides Sub Conferma()
|
Public Overrides Sub Conferma()
|
||||||
@@ -92,7 +111,8 @@ Public Class ParametricCompoVM
|
|||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Public Overrides Sub Annulla()
|
Public Overrides Sub Annulla()
|
||||||
EgtErase(EgtGetFirstPart())
|
Dim PartSolidSel As PartSolidM = GetPartSolid(nPartId)
|
||||||
|
SolidManagerM.Delete(nPartId)
|
||||||
EgtDraw()
|
EgtDraw()
|
||||||
Close()
|
Close()
|
||||||
End Sub
|
End Sub
|
||||||
@@ -105,6 +125,10 @@ Public Class ParametricCompoVM
|
|||||||
|
|
||||||
Private Sub Close()
|
Private Sub Close()
|
||||||
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_ParametricCompoUC)
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_ParametricCompoUC)
|
||||||
|
SolidManagerM.RefreshPartSolid(nPartId)
|
||||||
|
' debug
|
||||||
|
EgtSaveFile("D:\\Temp\\marmo\\Vein3D\\template.nge", 2)
|
||||||
|
' debug
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Function NameTypeValueFromLua(nInd As Integer, ByRef Param As GenericParam) As Boolean
|
Private Function NameTypeValueFromLua(nInd As Integer, ByRef Param As GenericParam) As Boolean
|
||||||
|
|||||||
@@ -11,18 +11,32 @@
|
|||||||
Public Const EGT_SEL_TYPE As String = "SelType"
|
Public Const EGT_SEL_TYPE As String = "SelType"
|
||||||
Public Const EGT_IMPORT_LOOP As String = "ImportLoop"
|
Public Const EGT_IMPORT_LOOP As String = "ImportLoop"
|
||||||
Public Const EGT_CREATE_SOLID_LOOP As String = "CreateSolidFromLoop"
|
Public Const EGT_CREATE_SOLID_LOOP As String = "CreateSolidFromLoop"
|
||||||
|
Public Const EGT_CREATE_ALL_SOLIDS As String = "CreateAllSolids"
|
||||||
Public Const EGT_MOVE As String = "Move"
|
Public Const EGT_MOVE As String = "Move"
|
||||||
Public Const EGT_ALZ As String = "AddSplashTop"
|
Public Const EGT_ADD_ALZ As String = "AddSplashTop"
|
||||||
Public Const EGT_FRO As String = "AddWaterfall"
|
Public Const EGT_ADD_FRO As String = "AddWaterfall"
|
||||||
Public Const EGT_PANEL As String = "AddPanel"
|
Public Const EGT_ADD_PANEL As String = "AddPanel"
|
||||||
Public Const EGT_EDIT_PANEL As String = "EditPanel"
|
Public Const EGT_EDIT_PANEL As String = "EditPanel"
|
||||||
Public Const EGT_EDIT_TOPK As String = "EditTopKitchen"
|
Public Const EGT_EDIT_PARAMETRIC As String = "EditParametric"
|
||||||
Public Const EGT_EXPORTPROJECT As String = "ExportProject"
|
Public Const EGT_EXPORTPROJECT As String = "ExportProject"
|
||||||
Public Const EGT_DELETE As String = "Delete"
|
Public Const EGT_DELETE As String = "Delete"
|
||||||
Public Const EGT_RECTANGE As String = "Rettangolo"
|
|
||||||
Public Const EGT_POLIGON As String = "Poligono"
|
|
||||||
Public Const EGT_ELLIPSE As String = "Ellisse"
|
|
||||||
Public Const EGT_PARAMETRIC As String = "Parametric Compo"
|
Public Const EGT_PARAMETRIC As String = "Parametric Compo"
|
||||||
|
Public Const EGT_LENGHT As String = "Lunghezza"
|
||||||
|
Public Const EGT_ANGLE As String = "Angolo"
|
||||||
|
Public Const EGT_EXTREMITY As String = "Estremita'"
|
||||||
|
Public Const EGT_ADDCONSTRAINT As String = "Aggiungi Vincolo"
|
||||||
|
Public Const EGT_MESSAGE As String = "Messaggio"
|
||||||
|
|
||||||
|
Public Const EGT_PANEL As String = "Paretina"
|
||||||
|
Public Const EGT_BOTTOM As String = "Fondo"
|
||||||
|
Public Const EGT_SPLASHTOP As String = "Alzatina"
|
||||||
|
Public Const EGT_WATERFALL As String = "Frontalino"
|
||||||
|
Public Const EGT_SINK As String = "Paretine e fondo"
|
||||||
|
Public Const EGT_SINK_SPLITBOTTOM As String = "Paretine e fondo composto"
|
||||||
|
Public Const EGT_SPLITBOTTOM As String = "Fondo composito"
|
||||||
|
|
||||||
|
Public Const EGT_SLOT As String = "Fessura"
|
||||||
|
Public Const EGT_BORE As String = "Foro"
|
||||||
|
|
||||||
Public Const EGT_X As String = "X"
|
Public Const EGT_X As String = "X"
|
||||||
Public Const EGT_Y As String = "Y"
|
Public Const EGT_Y As String = "Y"
|
||||||
@@ -70,6 +84,9 @@
|
|||||||
Public Const BOTTOMLIST_BTN As String = "BottomListBtn"
|
Public Const BOTTOMLIST_BTN As String = "BottomListBtn"
|
||||||
Public Const BOTTOMCENTERLIST_BTN As String = "BottomCenterListBtn"
|
Public Const BOTTOMCENTERLIST_BTN As String = "BottomCenterListBtn"
|
||||||
Public Const TOPPANELLIST_BTN As String = "TopPanelListBtn"
|
Public Const TOPPANELLIST_BTN As String = "TopPanelListBtn"
|
||||||
|
Public Const PARAMETRICLIST_BTN As String = "ParametricListBtn"
|
||||||
|
Public Const INFOLLIST_BTN As String = "InfoListBtn"
|
||||||
|
Public Const TOPPANELOFFICELIST_BTN As String = "TopPanelOfficeListBtn"
|
||||||
|
|
||||||
Public Const UTILITY_FOLDER As String = "Utility"
|
Public Const UTILITY_FOLDER As String = "Utility"
|
||||||
|
|
||||||
@@ -122,7 +139,8 @@
|
|||||||
Unknown = -1
|
Unknown = -1
|
||||||
TopKitchen = 0
|
TopKitchen = 0
|
||||||
Panel = 1
|
Panel = 1
|
||||||
Sink = 2
|
SinkSplitBottom = 2
|
||||||
|
Sink = 3
|
||||||
End Enum
|
End Enum
|
||||||
|
|
||||||
Public Enum JunctionType As Integer
|
Public Enum JunctionType As Integer
|
||||||
@@ -132,7 +150,7 @@
|
|||||||
End Enum
|
End Enum
|
||||||
|
|
||||||
'enum per le fasi di modifica di un piano cucina
|
'enum per le fasi di modifica di un piano cucina
|
||||||
Public Enum EditTopKStage As Integer
|
Public Enum EditParametricStage As Integer
|
||||||
SelectPart = 0
|
SelectPart = 0
|
||||||
SelectPoint = 1
|
SelectPoint = 1
|
||||||
SelectEdge = 2
|
SelectEdge = 2
|
||||||
@@ -151,4 +169,5 @@
|
|||||||
Public Const LUA_VALUE As String = LUA_CMP_VARS & ".V"
|
Public Const LUA_VALUE As String = LUA_CMP_VARS & ".V"
|
||||||
Public Const LUA_NAME As String = LUA_CMP_VARS & ".N"
|
Public Const LUA_NAME As String = LUA_CMP_VARS & ".N"
|
||||||
Public Const LUA_TYPE As String = LUA_CMP_VARS & ".T"
|
Public Const LUA_TYPE As String = LUA_CMP_VARS & ".T"
|
||||||
|
|
||||||
End Module
|
End Module
|
||||||
|
|||||||
@@ -234,7 +234,8 @@
|
|||||||
<DataGrid ItemsSource="{Binding SelTreeItem.FolderList, Mode=TwoWay}"
|
<DataGrid ItemsSource="{Binding SelTreeItem.FolderList, Mode=TwoWay}"
|
||||||
SelectedItem="{Binding ItemSelected}"
|
SelectedItem="{Binding ItemSelected}"
|
||||||
ColumnHeaderStyle="{StaticResource DataGridColumnHeader}"
|
ColumnHeaderStyle="{StaticResource DataGridColumnHeader}"
|
||||||
RowStyle="{StaticResource RowDataGrid_CustomHighLight}">
|
RowStyle="{StaticResource RowDataGrid_CustomHighLight}"
|
||||||
|
CellStyle="{StaticResource CellDataGrid_CustomHighLight}">
|
||||||
<DataGrid.Columns>
|
<DataGrid.Columns>
|
||||||
<DataGridTemplateColumn Width="5*">
|
<DataGridTemplateColumn Width="5*">
|
||||||
<DataGridTemplateColumn.HeaderTemplate>
|
<DataGridTemplateColumn.HeaderTemplate>
|
||||||
|
|||||||
@@ -557,8 +557,15 @@ Public Class EgtManageFileDialogVM
|
|||||||
Dim CurrItemSelected As EgtFolder = DirectCast(m_ItemSelected, EgtFolder)
|
Dim CurrItemSelected As EgtFolder = DirectCast(m_ItemSelected, EgtFolder)
|
||||||
CurrItemSelected.SetIsSelected(True, True)
|
CurrItemSelected.SetIsSelected(True, True)
|
||||||
m_sSelPath = CurrItemSelected.sFullName
|
m_sSelPath = CurrItemSelected.sFullName
|
||||||
Else
|
ElseIf TypeOf m_ItemSelected Is EgtItem Then
|
||||||
m_ItemSelected.IsSelected = True
|
Dim CurrItemSelected As EgtItem = DirectCast(m_ItemSelected, EgtItem)
|
||||||
|
m_ItemSelected.IsExpanded = False
|
||||||
|
If File.Exists(CurrItemSelected.sFullName) Then
|
||||||
|
m_sFileName = CurrItemSelected.sFullName
|
||||||
|
RaiseEvent m_CloseWindow(DialogResult.OK)
|
||||||
|
Else
|
||||||
|
EgtOutLog("File Inesistente")
|
||||||
|
End If
|
||||||
End If
|
End If
|
||||||
NotifyPropertyChanged(NameOf(sSelPath))
|
NotifyPropertyChanged(NameOf(sSelPath))
|
||||||
End Sub
|
End Sub
|
||||||
|
|||||||
@@ -8,17 +8,23 @@ EndProject
|
|||||||
Global
|
Global
|
||||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||||
Debug|Any CPU = Debug|Any CPU
|
Debug|Any CPU = Debug|Any CPU
|
||||||
|
Debug|x64 = Debug|x64
|
||||||
Debug|x86 = Debug|x86
|
Debug|x86 = Debug|x86
|
||||||
Release|Any CPU = Release|Any CPU
|
Release|Any CPU = Release|Any CPU
|
||||||
|
Release|x64 = Release|x64
|
||||||
Release|x86 = Release|x86
|
Release|x86 = Release|x86
|
||||||
EndGlobalSection
|
EndGlobalSection
|
||||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||||
{10C7D2D3-8D43-4F83-9299-2DF704A55CD6}.Debug|Any CPU.ActiveCfg = Debug|x86
|
{10C7D2D3-8D43-4F83-9299-2DF704A55CD6}.Debug|Any CPU.ActiveCfg = Debug|x86
|
||||||
{10C7D2D3-8D43-4F83-9299-2DF704A55CD6}.Debug|Any CPU.Build.0 = Debug|x86
|
{10C7D2D3-8D43-4F83-9299-2DF704A55CD6}.Debug|Any CPU.Build.0 = Debug|x86
|
||||||
|
{10C7D2D3-8D43-4F83-9299-2DF704A55CD6}.Debug|x64.ActiveCfg = Debug|x64
|
||||||
|
{10C7D2D3-8D43-4F83-9299-2DF704A55CD6}.Debug|x64.Build.0 = Debug|x64
|
||||||
{10C7D2D3-8D43-4F83-9299-2DF704A55CD6}.Debug|x86.ActiveCfg = Debug|x86
|
{10C7D2D3-8D43-4F83-9299-2DF704A55CD6}.Debug|x86.ActiveCfg = Debug|x86
|
||||||
{10C7D2D3-8D43-4F83-9299-2DF704A55CD6}.Debug|x86.Build.0 = Debug|x86
|
{10C7D2D3-8D43-4F83-9299-2DF704A55CD6}.Debug|x86.Build.0 = Debug|x86
|
||||||
{10C7D2D3-8D43-4F83-9299-2DF704A55CD6}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
{10C7D2D3-8D43-4F83-9299-2DF704A55CD6}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||||
{10C7D2D3-8D43-4F83-9299-2DF704A55CD6}.Release|Any CPU.Build.0 = Release|Any CPU
|
{10C7D2D3-8D43-4F83-9299-2DF704A55CD6}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||||
|
{10C7D2D3-8D43-4F83-9299-2DF704A55CD6}.Release|x64.ActiveCfg = Release|x64
|
||||||
|
{10C7D2D3-8D43-4F83-9299-2DF704A55CD6}.Release|x64.Build.0 = Release|x64
|
||||||
{10C7D2D3-8D43-4F83-9299-2DF704A55CD6}.Release|x86.ActiveCfg = Release|x86
|
{10C7D2D3-8D43-4F83-9299-2DF704A55CD6}.Release|x86.ActiveCfg = Release|x86
|
||||||
{10C7D2D3-8D43-4F83-9299-2DF704A55CD6}.Release|x86.Build.0 = Release|x86
|
{10C7D2D3-8D43-4F83-9299-2DF704A55CD6}.Release|x86.Build.0 = Release|x86
|
||||||
EndGlobalSection
|
EndGlobalSection
|
||||||
|
|||||||
+76
-2
@@ -12,6 +12,21 @@
|
|||||||
<MyType>Custom</MyType>
|
<MyType>Custom</MyType>
|
||||||
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
|
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
|
||||||
<Deterministic>true</Deterministic>
|
<Deterministic>true</Deterministic>
|
||||||
|
<PublishUrl>publish\</PublishUrl>
|
||||||
|
<Install>true</Install>
|
||||||
|
<InstallFrom>Disk</InstallFrom>
|
||||||
|
<UpdateEnabled>false</UpdateEnabled>
|
||||||
|
<UpdateMode>Foreground</UpdateMode>
|
||||||
|
<UpdateInterval>7</UpdateInterval>
|
||||||
|
<UpdateIntervalUnits>Days</UpdateIntervalUnits>
|
||||||
|
<UpdatePeriodically>false</UpdatePeriodically>
|
||||||
|
<UpdateRequired>false</UpdateRequired>
|
||||||
|
<MapFileExtensions>true</MapFileExtensions>
|
||||||
|
<ApplicationRevision>0</ApplicationRevision>
|
||||||
|
<ApplicationVersion>1.0.0.%2a</ApplicationVersion>
|
||||||
|
<IsWebBootstrapper>false</IsWebBootstrapper>
|
||||||
|
<UseApplicationTrust>false</UseApplicationTrust>
|
||||||
|
<BootstrapperEnabled>true</BootstrapperEnabled>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||||
@@ -72,6 +87,30 @@
|
|||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<ApplicationIcon>Resources\EgalwareLogo.ico</ApplicationIcon>
|
<ApplicationIcon>Resources\EgalwareLogo.ico</ApplicationIcon>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
<PropertyGroup>
|
||||||
|
<ApplicationManifest>My Project\app.manifest</ApplicationManifest>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|x64'">
|
||||||
|
<DebugSymbols>true</DebugSymbols>
|
||||||
|
<DefineDebug>true</DefineDebug>
|
||||||
|
<DefineTrace>true</DefineTrace>
|
||||||
|
<OutputPath>bin\x64\Debug\</OutputPath>
|
||||||
|
<DocumentationFile>EgtStone3D.xml</DocumentationFile>
|
||||||
|
<NoWarn>41999,42016,42017,42018,42019,42020,42021,42022,42032,42036,42314</NoWarn>
|
||||||
|
<DebugType>full</DebugType>
|
||||||
|
<PlatformTarget>x64</PlatformTarget>
|
||||||
|
<Prefer32Bit>true</Prefer32Bit>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|x64'">
|
||||||
|
<DefineTrace>true</DefineTrace>
|
||||||
|
<OutputPath>bin\x64\Release\</OutputPath>
|
||||||
|
<DocumentationFile>EgtStone3D.xml</DocumentationFile>
|
||||||
|
<Optimize>true</Optimize>
|
||||||
|
<NoWarn>41999,42016,42017,42018,42019,42020,42021,42022,42032,42036,42314</NoWarn>
|
||||||
|
<DebugType>pdbonly</DebugType>
|
||||||
|
<PlatformTarget>x64</PlatformTarget>
|
||||||
|
<Prefer32Bit>true</Prefer32Bit>
|
||||||
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Reference Include="EgtUILib">
|
<Reference Include="EgtUILib">
|
||||||
<HintPath>..\..\..\EgtProg\Dll32\EgtUILib.dll</HintPath>
|
<HintPath>..\..\..\EgtProg\Dll32\EgtUILib.dll</HintPath>
|
||||||
@@ -80,6 +119,9 @@
|
|||||||
<SpecificVersion>False</SpecificVersion>
|
<SpecificVersion>False</SpecificVersion>
|
||||||
<HintPath>..\..\EgtProg\EgtStone3D\EgtWPFLib5.dll</HintPath>
|
<HintPath>..\..\EgtProg\EgtStone3D\EgtWPFLib5.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
|
<Reference Include="ICSharpCode.AvalonEdit, Version=6.3.0.90, Culture=neutral, PublicKeyToken=9cc39be672370310, processorArchitecture=MSIL">
|
||||||
|
<HintPath>packages\AvalonEdit.6.3.0.90\lib\net462\ICSharpCode.AvalonEdit.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
<Reference Include="PresentationFramework.Aero2" />
|
<Reference Include="PresentationFramework.Aero2" />
|
||||||
<Reference Include="System.Core" />
|
<Reference Include="System.Core" />
|
||||||
<Reference Include="System.Drawing" />
|
<Reference Include="System.Drawing" />
|
||||||
@@ -106,6 +148,7 @@
|
|||||||
<Compile Include="AboutBoxWindow\AboutBoxV.xaml.vb">
|
<Compile Include="AboutBoxWindow\AboutBoxV.xaml.vb">
|
||||||
<DependentUpon>AboutBoxV.xaml</DependentUpon>
|
<DependentUpon>AboutBoxV.xaml</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
|
<Compile Include="Angle\AngleVM.vb" />
|
||||||
<Compile Include="CompoLib\ParametricCompoVM.vb" />
|
<Compile Include="CompoLib\ParametricCompoVM.vb" />
|
||||||
<Compile Include="Constants\ConstEgtStone3D.vb" />
|
<Compile Include="Constants\ConstEgtStone3D.vb" />
|
||||||
<Compile Include="EgtColorPicker\EgtColorPickerV.xaml.vb">
|
<Compile Include="EgtColorPicker\EgtColorPickerV.xaml.vb">
|
||||||
@@ -118,6 +161,7 @@
|
|||||||
<Compile Include="EgtMessageBox\EgtMessageBoxV.xaml.vb">
|
<Compile Include="EgtMessageBox\EgtMessageBoxV.xaml.vb">
|
||||||
<DependentUpon>EgtMessageBoxV.xaml</DependentUpon>
|
<DependentUpon>EgtMessageBoxV.xaml</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
|
<Compile Include="Extremity\ExtremityVM.vb" />
|
||||||
<Compile Include="GridPanel\GridDimensionPanelV.xaml.vb">
|
<Compile Include="GridPanel\GridDimensionPanelV.xaml.vb">
|
||||||
<DependentUpon>GridDimensionPanelV.xaml</DependentUpon>
|
<DependentUpon>GridDimensionPanelV.xaml</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
@@ -128,6 +172,7 @@
|
|||||||
<Compile Include="GridPanel\GridViewPanelV.xaml.vb">
|
<Compile Include="GridPanel\GridViewPanelV.xaml.vb">
|
||||||
<DependentUpon>GridViewPanelV.xaml</DependentUpon>
|
<DependentUpon>GridViewPanelV.xaml</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
|
<Compile Include="Length\LengthVM.vb" />
|
||||||
<Compile Include="MainWindow\MainWindowV.xaml.vb">
|
<Compile Include="MainWindow\MainWindowV.xaml.vb">
|
||||||
<DependentUpon>MainWindowV.xaml</DependentUpon>
|
<DependentUpon>MainWindowV.xaml</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
@@ -139,7 +184,7 @@
|
|||||||
<Compile Include="OptionsWindow\OptionWindowVM.vb" />
|
<Compile Include="OptionsWindow\OptionWindowVM.vb" />
|
||||||
<Compile Include="Pair\PairVM.vb" />
|
<Compile Include="Pair\PairVM.vb" />
|
||||||
<Compile Include="Panel\EditPanelVM.vb" />
|
<Compile Include="Panel\EditPanelVM.vb" />
|
||||||
<Compile Include="Panel\EditTopKitchenVM.vb" />
|
<Compile Include="Panel\EditParametricVM.vb" />
|
||||||
<Compile Include="Panel\NewPanelVM.vb" />
|
<Compile Include="Panel\NewPanelVM.vb" />
|
||||||
<Compile Include="Panel\PanelManagerM.vb" />
|
<Compile Include="Panel\PanelManagerM.vb" />
|
||||||
<Compile Include="ProjManager\ProjManagerButtonV.xaml.vb">
|
<Compile Include="ProjManager\ProjManagerButtonV.xaml.vb">
|
||||||
@@ -198,12 +243,18 @@
|
|||||||
<Compile Include="TopPanel\TopPanelHomeV.xaml.vb">
|
<Compile Include="TopPanel\TopPanelHomeV.xaml.vb">
|
||||||
<DependentUpon>TopPanelHomeV.xaml</DependentUpon>
|
<DependentUpon>TopPanelHomeV.xaml</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
|
<Compile Include="TopPanel\TopPanelInfoParametricV.xaml.vb">
|
||||||
|
<DependentUpon>TopPanelInfoParametricV.xaml</DependentUpon>
|
||||||
|
</Compile>
|
||||||
<Compile Include="TopPanel\TopPanelListButton_1V.xaml.vb">
|
<Compile Include="TopPanel\TopPanelListButton_1V.xaml.vb">
|
||||||
<DependentUpon>TopPanelListButton_1V.xaml</DependentUpon>
|
<DependentUpon>TopPanelListButton_1V.xaml</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
<Compile Include="TopPanel\TopPanelListV.xaml.vb">
|
<Compile Include="TopPanel\TopPanelListV.xaml.vb">
|
||||||
<DependentUpon>TopPanelListV.xaml</DependentUpon>
|
<DependentUpon>TopPanelListV.xaml</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
|
<Compile Include="TopPanel\TopPanelOfficeListButtonV.xaml.vb">
|
||||||
|
<DependentUpon>TopPanelOfficeListButtonV.xaml</DependentUpon>
|
||||||
|
</Compile>
|
||||||
<Compile Include="TopPanel\TopPanelV.xaml.vb">
|
<Compile Include="TopPanel\TopPanelV.xaml.vb">
|
||||||
<DependentUpon>TopPanelV.xaml</DependentUpon>
|
<DependentUpon>TopPanelV.xaml</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
@@ -215,6 +266,7 @@
|
|||||||
</Compile>
|
</Compile>
|
||||||
<Compile Include="TopPanel\TopPanelVM.vb" />
|
<Compile Include="TopPanel\TopPanelVM.vb" />
|
||||||
<Compile Include="Utility\AssLogM.vb" />
|
<Compile Include="Utility\AssLogM.vb" />
|
||||||
|
<Compile Include="Utility\ColorScriptM.vb" />
|
||||||
<Compile Include="Utility\EstCalc.vb" />
|
<Compile Include="Utility\EstCalc.vb" />
|
||||||
<Compile Include="Utility\GeomEntityColors.vb" />
|
<Compile Include="Utility\GeomEntityColors.vb" />
|
||||||
<Compile Include="Utility\Map.vb" />
|
<Compile Include="Utility\Map.vb" />
|
||||||
@@ -226,6 +278,7 @@
|
|||||||
<Compile Include="Constants\ConstIni.vb" />
|
<Compile Include="Constants\ConstIni.vb" />
|
||||||
<Compile Include="MainWindow\MainWindowM.vb" />
|
<Compile Include="MainWindow\MainWindowM.vb" />
|
||||||
<Compile Include="Utility\PartSolidM.vb" />
|
<Compile Include="Utility\PartSolidM.vb" />
|
||||||
|
<Compile Include="Utility\RegexM.vb" />
|
||||||
<Compile Include="Utility\SolidManagerM.vb" />
|
<Compile Include="Utility\SolidManagerM.vb" />
|
||||||
<Compile Include="ViewPanelProspective\ViewPanelProspectiveV.xaml.vb">
|
<Compile Include="ViewPanelProspective\ViewPanelProspectiveV.xaml.vb">
|
||||||
<DependentUpon>ViewPanelProspectiveV.xaml</DependentUpon>
|
<DependentUpon>ViewPanelProspectiveV.xaml</DependentUpon>
|
||||||
@@ -331,6 +384,10 @@
|
|||||||
<SubType>Designer</SubType>
|
<SubType>Designer</SubType>
|
||||||
<Generator>MSBuild:Compile</Generator>
|
<Generator>MSBuild:Compile</Generator>
|
||||||
</Page>
|
</Page>
|
||||||
|
<Page Include="TopPanel\TopPanelInfoParametricV.xaml">
|
||||||
|
<SubType>Designer</SubType>
|
||||||
|
<Generator>MSBuild:Compile</Generator>
|
||||||
|
</Page>
|
||||||
<Page Include="TopPanel\TopPanelListButton_1V.xaml">
|
<Page Include="TopPanel\TopPanelListButton_1V.xaml">
|
||||||
<SubType>Designer</SubType>
|
<SubType>Designer</SubType>
|
||||||
<Generator>MSBuild:Compile</Generator>
|
<Generator>MSBuild:Compile</Generator>
|
||||||
@@ -339,6 +396,10 @@
|
|||||||
<SubType>Designer</SubType>
|
<SubType>Designer</SubType>
|
||||||
<Generator>MSBuild:Compile</Generator>
|
<Generator>MSBuild:Compile</Generator>
|
||||||
</Page>
|
</Page>
|
||||||
|
<Page Include="TopPanel\TopPanelOfficeListButtonV.xaml">
|
||||||
|
<SubType>Designer</SubType>
|
||||||
|
<Generator>MSBuild:Compile</Generator>
|
||||||
|
</Page>
|
||||||
<Page Include="TopPanel\TopPanelV.xaml">
|
<Page Include="TopPanel\TopPanelV.xaml">
|
||||||
<SubType>Designer</SubType>
|
<SubType>Designer</SubType>
|
||||||
<Generator>MSBuild:Compile</Generator>
|
<Generator>MSBuild:Compile</Generator>
|
||||||
@@ -415,10 +476,12 @@
|
|||||||
<LastGenOutput>Resources.Designer.vb</LastGenOutput>
|
<LastGenOutput>Resources.Designer.vb</LastGenOutput>
|
||||||
<CustomToolNamespace>My.Resources</CustomToolNamespace>
|
<CustomToolNamespace>My.Resources</CustomToolNamespace>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
|
<None Include="My Project\app.manifest" />
|
||||||
<None Include="My Project\Settings.settings">
|
<None Include="My Project\Settings.settings">
|
||||||
<Generator>SettingsSingleFileGenerator</Generator>
|
<Generator>SettingsSingleFileGenerator</Generator>
|
||||||
<LastGenOutput>Settings.Designer.vb</LastGenOutput>
|
<LastGenOutput>Settings.Designer.vb</LastGenOutput>
|
||||||
</None>
|
</None>
|
||||||
|
<None Include="packages.config" />
|
||||||
<Resource Include="Resources\EgalwareLogo.ico" />
|
<Resource Include="Resources\EgalwareLogo.ico" />
|
||||||
<Resource Include="Resources\Fonts\Roboto-Light.ttf" />
|
<Resource Include="Resources\Fonts\Roboto-Light.ttf" />
|
||||||
<Resource Include="Resources\Fonts\Roboto-Regular.ttf" />
|
<Resource Include="Resources\Fonts\Roboto-Regular.ttf" />
|
||||||
@@ -518,7 +581,18 @@
|
|||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Resource Include="Resources\EgtMessageBox\Warning.png" />
|
<Resource Include="Resources\EgtMessageBox\Warning.png" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup />
|
<ItemGroup>
|
||||||
|
<BootstrapperPackage Include=".NETFramework,Version=v4.7.2">
|
||||||
|
<Visible>False</Visible>
|
||||||
|
<ProductName>Microsoft .NET Framework 4.7.2 %28x86 e x64%29</ProductName>
|
||||||
|
<Install>true</Install>
|
||||||
|
</BootstrapperPackage>
|
||||||
|
<BootstrapperPackage Include="Microsoft.Net.Framework.3.5.SP1">
|
||||||
|
<Visible>False</Visible>
|
||||||
|
<ProductName>.NET Framework 3.5 SP1</ProductName>
|
||||||
|
<Install>false</Install>
|
||||||
|
</BootstrapperPackage>
|
||||||
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Resource Include="Resources\GridViewPanel\ZoomAll.png" />
|
<Resource Include="Resources\GridViewPanel\ZoomAll.png" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|||||||
@@ -0,0 +1,50 @@
|
|||||||
|
Imports EgtUILib
|
||||||
|
|
||||||
|
Public Class ExtremityVM
|
||||||
|
Inherits SceneUserControlVM
|
||||||
|
|
||||||
|
#Region "CONSTRUCTOR"
|
||||||
|
|
||||||
|
Public Sub New()
|
||||||
|
MyBase.New()
|
||||||
|
Title = EGT_ADDCONSTRAINT.ToUpper()
|
||||||
|
|
||||||
|
DirectCast(Map.refSceneButtonVM.m_ExtremityUC, SceneUserControlV).Preview.Visibility = Visibility.Hidden
|
||||||
|
DirectCast(Map.refSceneButtonVM.m_ExtremityUC, SceneUserControlV).Annulla.Visibility = Visibility.Hidden
|
||||||
|
|
||||||
|
LoadParamList()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
#End Region ' Constructor
|
||||||
|
|
||||||
|
#Region "METHODS"
|
||||||
|
|
||||||
|
Public Overrides Sub LoadParamList()
|
||||||
|
' Scegli quale estremità vincolare
|
||||||
|
AddGenericParam(New _TextBlockParam(EGT_MESSAGE, EgtMsg(110047), ParamType.STR))
|
||||||
|
Dim ExtremityOptionList As New List(Of ParamCmBx)({New ParamCmBx("Start"),
|
||||||
|
New ParamCmBx("End")})
|
||||||
|
' Estremità
|
||||||
|
AddGenericParam(New _ComboBoxParam(EgtMsg(110046), ExtremityOptionList, 0, Visibility.Visible))
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Overrides Sub Conferma()
|
||||||
|
LoadEditParametric()
|
||||||
|
Close()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Overrides Sub ShowPreview()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Overrides Sub Annulla()
|
||||||
|
Close()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub Close()
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_ExtremityUC)
|
||||||
|
SolidManagerM.ManageUndoRedo()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
#End Region ' Methods
|
||||||
|
|
||||||
|
End Class
|
||||||
@@ -0,0 +1,48 @@
|
|||||||
|
Imports EgtUILib
|
||||||
|
|
||||||
|
Public Class LengthVM
|
||||||
|
Inherits SceneUserControlVM
|
||||||
|
|
||||||
|
#Region "CONSTRUCTOR"
|
||||||
|
|
||||||
|
Public Sub New()
|
||||||
|
MyBase.New()
|
||||||
|
Title = EGT_ADDCONSTRAINT.ToUpper()
|
||||||
|
|
||||||
|
DirectCast(Map.refSceneButtonVM.m_LengthUC, SceneUserControlV).Preview.Visibility = Visibility.Hidden
|
||||||
|
DirectCast(Map.refSceneButtonVM.m_LengthUC, SceneUserControlV).Annulla.Visibility = Visibility.Hidden
|
||||||
|
|
||||||
|
LoadParamList()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
#End Region ' Constructor
|
||||||
|
|
||||||
|
#Region "METHODS"
|
||||||
|
|
||||||
|
Public Overrides Sub LoadParamList()
|
||||||
|
' Inserisci Lunghezza
|
||||||
|
AddGenericParam(New _TextBlockParam(EGT_MESSAGE, EgtMsg(110045), ParamType.STR))
|
||||||
|
' Lunghezza
|
||||||
|
AddGenericParam(New _TextBoxParam(EgtMsg(110044), 0, ParamType.DOUB, Visibility.Visible, True))
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Overrides Sub Conferma()
|
||||||
|
LoadEditParametric()
|
||||||
|
Close()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Overrides Sub ShowPreview()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Overrides Sub Annulla()
|
||||||
|
Close()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub Close()
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_LengthUC)
|
||||||
|
SolidManagerM.ManageUndoRedo()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
#End Region ' Methods
|
||||||
|
|
||||||
|
End Class
|
||||||
+24
-1
@@ -49,6 +49,8 @@ Public Class MoveVM
|
|||||||
Title = EGT_MOVE.ToUpper()
|
Title = EGT_MOVE.ToUpper()
|
||||||
LoadParamList()
|
LoadParamList()
|
||||||
Stage = If(Map.refSceneHostVM.m_nIdPart = GDB_ID.NULL, MoveStage.SelectPart, MoveStage.InsertMovement)
|
Stage = If(Map.refSceneHostVM.m_nIdPart = GDB_ID.NULL, MoveStage.SelectPart, MoveStage.InsertMovement)
|
||||||
|
ActivateButton()
|
||||||
|
RemoveAllUC()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
#End Region ' Contructor
|
#End Region ' Contructor
|
||||||
@@ -56,7 +58,7 @@ Public Class MoveVM
|
|||||||
#Region "METHODS"
|
#Region "METHODS"
|
||||||
|
|
||||||
Public Overrides Sub LoadParamList()
|
Public Overrides Sub LoadParamList()
|
||||||
ParamList.Add(New _TextBlockParam("Messaggio", MsgList(Stage), ParamType.STR, Visibility.Visible))
|
ParamList.Add(New _TextBlockParam(EGT_MESSAGE, MsgList(Stage), ParamType.STR, Visibility.Visible))
|
||||||
ParamList.Add(New _TextBoxParam("X", "0", ParamType.LEN, Visibility.Visible))
|
ParamList.Add(New _TextBoxParam("X", "0", ParamType.LEN, Visibility.Visible))
|
||||||
ParamList.Add(New _TextBoxParam("Y", "0", ParamType.LEN, Visibility.Visible))
|
ParamList.Add(New _TextBoxParam("Y", "0", ParamType.LEN, Visibility.Visible))
|
||||||
ParamList.Add(New _TextBoxParam("Z", "0", ParamType.LEN, Visibility.Visible))
|
ParamList.Add(New _TextBoxParam("Z", "0", ParamType.LEN, Visibility.Visible))
|
||||||
@@ -212,6 +214,27 @@ Public Class MoveVM
|
|||||||
SolidManagerM.ManageUndoRedo()
|
SolidManagerM.ManageUndoRedo()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
Private Sub ActivateButton()
|
||||||
|
' Disattivo pulsante Rotate
|
||||||
|
DirectCast(Map.refSceneButtonVM.GetButton(EGT_ROTATE), _ToggleButton).IsChecked = False
|
||||||
|
' Disattivo pulsante Pair
|
||||||
|
DirectCast(Map.refSceneButtonVM.GetButton(EGT_PAIR), _ToggleButton).IsChecked = False
|
||||||
|
' Attivo pulsante Move
|
||||||
|
DirectCast(Map.refSceneButtonVM.GetButton(EGT_MOVE), _ToggleButton).IsChecked = True
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub RemoveAllUC()
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_AngleUC)
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_EditPanelUC)
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_EditParametricUC)
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_ExtremityUC)
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_LengthUC)
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_NewPanelUC)
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_PairUC)
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_ParametricCompoUC)
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_RotateUC)
|
||||||
|
End Sub
|
||||||
|
|
||||||
#End Region ' Methods
|
#End Region ' Methods
|
||||||
|
|
||||||
End Class
|
End Class
|
||||||
|
|||||||
@@ -15,7 +15,7 @@ Imports System.Windows
|
|||||||
<Assembly: AssemblyDescription("EgtStone3D Debug 32 bit")>
|
<Assembly: AssemblyDescription("EgtStone3D Debug 32 bit")>
|
||||||
<Assembly: AssemblyCompany("Egalware s.r.l.")>
|
<Assembly: AssemblyCompany("Egalware s.r.l.")>
|
||||||
<Assembly: AssemblyProduct("EgtStone3D")>
|
<Assembly: AssemblyProduct("EgtStone3D")>
|
||||||
<Assembly: AssemblyCopyright("Copyright © 2024")>
|
<Assembly: AssemblyCopyright("Copyright © 2025")>
|
||||||
<Assembly: AssemblyTrademark("")>
|
<Assembly: AssemblyTrademark("")>
|
||||||
<Assembly: ComVisible(false)>
|
<Assembly: ComVisible(false)>
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,79 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<assembly manifestVersion="1.0" xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||||
|
<assemblyIdentity version="1.0.0.0" name="MyApplication.app"/>
|
||||||
|
<trustInfo xmlns="urn:schemas-microsoft-com:asm.v2">
|
||||||
|
<security>
|
||||||
|
<requestedPrivileges xmlns="urn:schemas-microsoft-com:asm.v3">
|
||||||
|
<!-- Opzioni manifesto di Controllo dell'account utente
|
||||||
|
Per modificare il livello di Controllo dell'account utente di Windows, sostituire il
|
||||||
|
nodo requestedExecutionLevel con uno dei seguenti.
|
||||||
|
|
||||||
|
<requestedExecutionLevel level="asInvoker" uiAccess="false" />
|
||||||
|
<requestedExecutionLevel level="requireAdministrator" uiAccess="false" />
|
||||||
|
<requestedExecutionLevel level="highestAvailable" uiAccess="false" />
|
||||||
|
|
||||||
|
Se si specifica l'elemento requestedExecutionLevel, la funzionalità Virtualizzazione file system e registro di sistema verrà disabilitata.
|
||||||
|
Rimuovere questo elemento se l'applicazione richiede questa virtualizzazione per
|
||||||
|
compatibilità con le versioni precedenti.
|
||||||
|
-->
|
||||||
|
<requestedExecutionLevel level="asInvoker" uiAccess="false" />
|
||||||
|
</requestedPrivileges>
|
||||||
|
</security>
|
||||||
|
</trustInfo>
|
||||||
|
|
||||||
|
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
|
||||||
|
<application>
|
||||||
|
<!-- Elenco delle versioni di Windows in cui è stata testata questa applicazione e
|
||||||
|
per cui è stato previsto l'uso. Rimuovere il commento dagli elementi appropriati per
|
||||||
|
fare in modo che Windows selezioni automaticamente l'ambiente più compatibile. -->
|
||||||
|
|
||||||
|
<!-- Windows Vista -->
|
||||||
|
<!--<supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}" />-->
|
||||||
|
|
||||||
|
<!-- Windows 7 -->
|
||||||
|
<!--<supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}" />-->
|
||||||
|
|
||||||
|
<!-- Windows 8 -->
|
||||||
|
<!--<supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}" />-->
|
||||||
|
|
||||||
|
<!-- Windows 8.1 -->
|
||||||
|
<!--<supportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}" />-->
|
||||||
|
|
||||||
|
<!-- Windows 10 -->
|
||||||
|
<!--<supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}" />-->
|
||||||
|
|
||||||
|
</application>
|
||||||
|
</compatibility>
|
||||||
|
|
||||||
|
<!-- Indica che l'applicazione è sensibile ai valori DPI e non verrà scalata automaticamente da Windows in caso di
|
||||||
|
valori DPI maggiori. Le applicazioni Windows Presentation Foundation (WPF) sono automaticamente sensibili ai valori DPI, pertanto non è necessario
|
||||||
|
acconsentire esplicitamente. Con le applicazioni Windows Forms destinate a .NET Framework 4.6 per cui è stato acconsentito esplicitamente a questa impostazione,
|
||||||
|
è anche necessario impostare 'EnableWindowsFormsHighDpiAutoResizing' su 'true' nel relativo file app.config.
|
||||||
|
|
||||||
|
Imposta l'applicazione in modo riconosca i percorsi lunghi. Vedere https://docs.microsoft.com/windows/win32/fileio/maximum-file-path-limitation -->
|
||||||
|
<!--
|
||||||
|
<application xmlns="urn:schemas-microsoft-com:asm.v3">
|
||||||
|
<windowsSettings>
|
||||||
|
<dpiAware xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">true</dpiAware>
|
||||||
|
<longPathAware xmlns="http://schemas.microsoft.com/SMI/2016/WindowsSettings">true</longPathAware>
|
||||||
|
</windowsSettings>
|
||||||
|
</application>
|
||||||
|
-->
|
||||||
|
|
||||||
|
<!-- Abilita i temi per finestre di dialogo e controlli comuni di Windows (Windows XP e versioni successive) -->
|
||||||
|
<!--
|
||||||
|
<dependency>
|
||||||
|
<dependentAssembly>
|
||||||
|
<assemblyIdentity
|
||||||
|
type="win32"
|
||||||
|
name="Microsoft.Windows.Common-Controls"
|
||||||
|
version="6.0.0.0"
|
||||||
|
processorArchitecture="*"
|
||||||
|
publicKeyToken="6595b64144ccf1df"
|
||||||
|
language="*"
|
||||||
|
/>
|
||||||
|
</dependentAssembly>
|
||||||
|
</dependency>
|
||||||
|
-->
|
||||||
|
|
||||||
|
</assembly>
|
||||||
+25
-1
@@ -75,6 +75,9 @@ Public Class PairVM
|
|||||||
If EgtLuaSetGlobBoolVar("ASS.bSaveTemp", bSaveTemp) Then AssLog("ASS.bSaveTemp = " & bSaveTemp.ToString)
|
If EgtLuaSetGlobBoolVar("ASS.bSaveTemp", bSaveTemp) Then AssLog("ASS.bSaveTemp = " & bSaveTemp.ToString)
|
||||||
|
|
||||||
LoadParamList()
|
LoadParamList()
|
||||||
|
|
||||||
|
ActivateButton()
|
||||||
|
RemoveAllUC()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
#End Region ' Constructor
|
#End Region ' Constructor
|
||||||
@@ -82,7 +85,7 @@ Public Class PairVM
|
|||||||
#Region "METHODS"
|
#Region "METHODS"
|
||||||
|
|
||||||
Public Overrides Sub LoadParamList()
|
Public Overrides Sub LoadParamList()
|
||||||
AddGenericParam(New _TextBlockParam("Messaggio", MsgList(0), ParamType.STR, Visibility.Visible))
|
AddGenericParam(New _TextBlockParam(EGT_MESSAGE, MsgList(0), ParamType.STR, Visibility.Visible))
|
||||||
Dim PairOptionList As New List(Of ParamCmBx)({New ParamCmBx("Start-Start"), New ParamCmBx("Start-End"), New ParamCmBx("End-Start"),
|
Dim PairOptionList As New List(Of ParamCmBx)({New ParamCmBx("Start-Start"), New ParamCmBx("Start-End"), New ParamCmBx("End-Start"),
|
||||||
New ParamCmBx("End-End"), New ParamCmBx("Middle-Middle")})
|
New ParamCmBx("End-End"), New ParamCmBx("Middle-Middle")})
|
||||||
AddGenericParam(New _ComboBoxParam("PairOption", PairOptionList, 1, Visibility.Collapsed))
|
AddGenericParam(New _ComboBoxParam("PairOption", PairOptionList, 1, Visibility.Collapsed))
|
||||||
@@ -185,6 +188,27 @@ NoSecondLine:
|
|||||||
Map.refSceneHostVM.m_nTransfNum += nTransf
|
Map.refSceneHostVM.m_nTransfNum += nTransf
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
Private Sub ActivateButton()
|
||||||
|
' Disattivo pulsante Rotate
|
||||||
|
DirectCast(Map.refSceneButtonVM.GetButton(EGT_ROTATE), _ToggleButton).IsChecked = False
|
||||||
|
' Attivo pulsante Pair
|
||||||
|
DirectCast(Map.refSceneButtonVM.GetButton(EGT_PAIR), _ToggleButton).IsChecked = True
|
||||||
|
' Disattivo pulsante Move
|
||||||
|
DirectCast(Map.refSceneButtonVM.GetButton(EGT_MOVE), _ToggleButton).IsChecked = False
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub RemoveAllUC()
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_AngleUC)
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_EditPanelUC)
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_EditParametricUC)
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_ExtremityUC)
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_LengthUC)
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_MoveUC)
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_NewPanelUC)
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_ParametricCompoUC)
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_RotateUC)
|
||||||
|
End Sub
|
||||||
|
|
||||||
#End Region ' Methods
|
#End Region ' Methods
|
||||||
|
|
||||||
#Region "EVENTS"
|
#Region "EVENTS"
|
||||||
|
|||||||
+175
-47
@@ -5,6 +5,25 @@ Public Class EditPanelVM
|
|||||||
|
|
||||||
#Region "FIELDS & PROPERTIES"
|
#Region "FIELDS & PROPERTIES"
|
||||||
|
|
||||||
|
Private Enum ParamEnum
|
||||||
|
MSG_ISTRUZ = 0
|
||||||
|
PARAG_PANEL = 1
|
||||||
|
PANEL_H = 2
|
||||||
|
PANEL_TH = 3
|
||||||
|
PANEL_J = 4
|
||||||
|
PARAG_BOTTOM = 5
|
||||||
|
BOTTOM_TH = 6
|
||||||
|
BOTTOM_ALPHA = 7
|
||||||
|
BOTTOM_DEPTH = 8
|
||||||
|
BOTTOM_HOLE_TYPE = 9
|
||||||
|
BOTTOM_HOLE_X = 10
|
||||||
|
BOTTOM_HOLE_Y = 11
|
||||||
|
BOTTOM_DIAM = 12
|
||||||
|
BOTTOM_HOLE_DIMX = 13
|
||||||
|
BOTTOM_HOLE_DIMY = 14
|
||||||
|
EDIT_NEIGH = 15
|
||||||
|
End Enum
|
||||||
|
|
||||||
Private ReadOnly m_MsgList As New List(Of String)({TopBar_Msg_Stg0, TopBar_Msg_Stg1, TopBar_Msg_Stg2, Msg_Paragraph1, Msg_Paragraph2})
|
Private ReadOnly m_MsgList As New List(Of String)({TopBar_Msg_Stg0, TopBar_Msg_Stg1, TopBar_Msg_Stg2, Msg_Paragraph1, Msg_Paragraph2})
|
||||||
Public ReadOnly Property MsgList As List(Of String)
|
Public ReadOnly Property MsgList As List(Of String)
|
||||||
Get
|
Get
|
||||||
@@ -19,7 +38,8 @@ Public Class EditPanelVM
|
|||||||
End Get
|
End Get
|
||||||
Set(value As EditPanelStage)
|
Set(value As EditPanelStage)
|
||||||
m_Stage = value
|
m_Stage = value
|
||||||
DirectCast(ParamList(0), _TextBlockParam).MsgValue = MsgList(m_Stage)
|
DirectCast(ParamList(ParamEnum.MSG_ISTRUZ), _TextBlockParam).MsgValue = MsgList(m_Stage)
|
||||||
|
ChangeTextColor()
|
||||||
End Set
|
End Set
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
@@ -40,7 +60,7 @@ Public Class EditPanelVM
|
|||||||
Return m_nIdPart
|
Return m_nIdPart
|
||||||
End Get
|
End Get
|
||||||
Set(value As Integer)
|
Set(value As Integer)
|
||||||
If m_nIdPart <> GDB_ID.NULL Then SceneCmd.DeselectAll()
|
SceneCmd.DeselectAll()
|
||||||
m_nIdPart = value
|
m_nIdPart = value
|
||||||
Stage = EditPanelStage.InsertNewParam
|
Stage = EditPanelStage.InsertNewParam
|
||||||
' devo capire che tipo di pezzo sto modificando
|
' devo capire che tipo di pezzo sto modificando
|
||||||
@@ -52,7 +72,7 @@ Public Class EditPanelVM
|
|||||||
Select Case PartType
|
Select Case PartType
|
||||||
Case PartType.Panel
|
Case PartType.Panel
|
||||||
UpdatePanelInfoFromPart(m_nIdPart)
|
UpdatePanelInfoFromPart(m_nIdPart)
|
||||||
Case PartType.Sink
|
Case PartType.Sink, PartType.SinkSplitBottom
|
||||||
Dim bIsBottom As Boolean = False
|
Dim bIsBottom As Boolean = False
|
||||||
EgtGetInfo(m_nIdPart, "Bottom", bIsBottom)
|
EgtGetInfo(m_nIdPart, "Bottom", bIsBottom)
|
||||||
If bIsBottom Then
|
If bIsBottom Then
|
||||||
@@ -75,21 +95,25 @@ Public Class EditPanelVM
|
|||||||
Return EgtMsg(110040) ' Seleziona il Part che vuoi modificare
|
Return EgtMsg(110040) ' Seleziona il Part che vuoi modificare
|
||||||
End Get
|
End Get
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
Public ReadOnly Property TopBar_Msg_Stg1 As String
|
Public ReadOnly Property TopBar_Msg_Stg1 As String
|
||||||
Get
|
Get
|
||||||
Return EgtMsg(110041) ' Inserisci i nuovi parametri
|
Return EgtMsg(110041) ' Inserisci i nuovi parametri
|
||||||
End Get
|
End Get
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
Public ReadOnly Property TopBar_Msg_Stg2 As String
|
Public ReadOnly Property TopBar_Msg_Stg2 As String
|
||||||
Get
|
Get
|
||||||
Return EgtMsg(110042) ' Conferma, modifica con altri parametri o annulla
|
Return EgtMsg(110042) ' Conferma, modifica con altri parametri o annulla
|
||||||
End Get
|
End Get
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
Public ReadOnly Property Msg_Paragraph1 As String
|
Public ReadOnly Property Msg_Paragraph1 As String
|
||||||
Get
|
Get
|
||||||
Return EgtMsg(110038) ' Frontalino
|
Return EgtMsg(110038) ' Frontalino
|
||||||
End Get
|
End Get
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
Public ReadOnly Property Msg_Paragraph2 As String
|
Public ReadOnly Property Msg_Paragraph2 As String
|
||||||
Get
|
Get
|
||||||
Return EgtMsg(110039) ' Fondo
|
Return EgtMsg(110039) ' Fondo
|
||||||
@@ -105,12 +129,13 @@ Public Class EditPanelVM
|
|||||||
Public Sub New()
|
Public Sub New()
|
||||||
MyBase.New()
|
MyBase.New()
|
||||||
Title = "Modifica Paretina".ToUpper()
|
Title = "Modifica Paretina".ToUpper()
|
||||||
|
LoadParamList()
|
||||||
|
|
||||||
If Map.refSceneHostVM.m_nIdPart <> GDB_ID.NULL Then
|
If Map.refSceneHostVM.m_nIdPart <> GDB_ID.NULL Then
|
||||||
nIdPart = Map.refSceneHostVM.m_nIdPart
|
nIdPart = Map.refSceneHostVM.m_nIdPart
|
||||||
Stage = EditPanelStage.InsertNewParam
|
Stage = EditPanelStage.InsertNewParam
|
||||||
End If
|
End If
|
||||||
|
|
||||||
LoadParamList()
|
|
||||||
UpdatePanelInfoFromPart(m_nIdPart)
|
UpdatePanelInfoFromPart(m_nIdPart)
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
@@ -122,58 +147,130 @@ Public Class EditPanelVM
|
|||||||
If nIdPart = GDB_ID.NULL Then Return
|
If nIdPart = GDB_ID.NULL Then Return
|
||||||
Dim dH As Double = 100
|
Dim dH As Double = 100
|
||||||
EgtGetInfo(nIdPart, "H", dH)
|
EgtGetInfo(nIdPart, "H", dH)
|
||||||
DirectCast(ParamList(2), _TextBoxParam).sValue = dH.ToString()
|
DirectCast(ParamList(ParamEnum.PANEL_H), _TextBoxParam).sValue = dH.ToString()
|
||||||
Dim dTh As Double = 10
|
Dim dTh As Double = 10
|
||||||
EgtGetInfo(nIdPart, "Th", dTh)
|
EgtGetInfo(nIdPart, "Th", dTh)
|
||||||
DirectCast(ParamList(3), _TextBoxParam).sValue = dTh.ToString()
|
DirectCast(ParamList(ParamEnum.PANEL_TH), _TextBoxParam).sValue = dTh.ToString()
|
||||||
Dim nJunctionType As Integer
|
Dim nJunctionType As Integer
|
||||||
EgtGetInfo(nIdPart, "JunctionType", nJunctionType)
|
EgtGetInfo(nIdPart, "JunctionType", nJunctionType)
|
||||||
DirectCast(ParamList(4), _ComboBoxParam).IndexSelParamCmBx = nJunctionType - 1
|
DirectCast(ParamList(ParamEnum.PANEL_J), _ComboBoxParam).IndexSelParamCmBx = nJunctionType - 1
|
||||||
|
If PartType = PartType.Sink Or PartType = PartType.SinkSplitBottom Then
|
||||||
|
' recupero un pezzo bottom
|
||||||
|
Dim bIsBottom As Boolean = False
|
||||||
|
EgtGetInfo(nIdPart, "Bottom", bIsBottom)
|
||||||
|
Dim nBottomId As Integer = nIdPart
|
||||||
|
If Not bIsBottom Then
|
||||||
|
Dim nWaterfallId As Integer = nIdPart
|
||||||
|
Dim sPartChildName As String = String.Empty
|
||||||
|
EgtGetInfo(nWaterfallId, "A3", sPartChildName)
|
||||||
|
nBottomId = EgtGetFirstNameInGroup(GDB_ID.ROOT, sPartChildName)
|
||||||
|
End If
|
||||||
|
|
||||||
|
Dim dDiam As Double = 0
|
||||||
|
EgtGetInfo(nBottomId, "HoleDiam", dDiam)
|
||||||
|
If dDiam < EPS_SMALL Then
|
||||||
|
DirectCast(ParamList(ParamEnum.BOTTOM_HOLE_TYPE), _ComboBoxParam).IndexSelParamCmBx = 0
|
||||||
|
Dim dDimX As Double = 0
|
||||||
|
Dim dDimY As Double = 0
|
||||||
|
EgtGetInfo(nBottomId, "HoleDimX", dDimX)
|
||||||
|
DirectCast(ParamList(ParamEnum.BOTTOM_HOLE_DIMX), _TextBoxParam).sValue = dDimX.ToString()
|
||||||
|
EgtGetInfo(nBottomId, "HoleDimY", dDimY)
|
||||||
|
DirectCast(ParamList(ParamEnum.BOTTOM_HOLE_DIMY), _TextBoxParam).sValue = dDimY.ToString()
|
||||||
|
Else
|
||||||
|
DirectCast(ParamList(ParamEnum.BOTTOM_HOLE_TYPE), _ComboBoxParam).IndexSelParamCmBx = 1
|
||||||
|
EgtGetInfo(nBottomId, "HoleDiam", dDiam)
|
||||||
|
DirectCast(ParamList(ParamEnum.BOTTOM_DIAM), _TextBoxParam).sValue = dDiam.ToString()
|
||||||
|
End If
|
||||||
|
Dim dPosX As Double = 0
|
||||||
|
Dim dPosY As Double = 0
|
||||||
|
EgtGetInfo(nBottomId, "HolePosX", dPosX)
|
||||||
|
DirectCast(ParamList(ParamEnum.BOTTOM_HOLE_X), _TextBoxParam).sValue = dPosX.ToString()
|
||||||
|
EgtGetInfo(nBottomId, "HolePosY", dPosY)
|
||||||
|
DirectCast(ParamList(ParamEnum.BOTTOM_HOLE_Y), _TextBoxParam).sValue = dPosY.ToString()
|
||||||
|
|
||||||
|
Dim dDepth As Double = 0
|
||||||
|
EgtGetInfo(nBottomId, "Depth", dDepth)
|
||||||
|
DirectCast(ParamList(ParamEnum.BOTTOM_DEPTH), _TextBoxParam).sValue = dDepth.ToString()
|
||||||
|
End If
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub UpdateParameterListShown()
|
Private Sub UpdateParameterListShown()
|
||||||
'' dalle info leggo se l'oggetto è una paretina o una buca
|
'' dalle info leggo se l'oggetto è una paretina o una buca
|
||||||
If PartType = PartType.TopKitchen Then
|
If PartType = PartType.TopKitchen Then
|
||||||
'ParamList(3).nVisibility = Visibility.Collapsed
|
'ParamList(ParamEnum.PANEL_TH).nVisibility = Visibility.Collapsed
|
||||||
'ParamList(4).nVisibility = Visibility.Collapsed
|
'ParamList(ParamEnum.PANEL_J).nVisibility = Visibility.Collapsed
|
||||||
|
|
||||||
'ParamList(5).nVisibility = Visibility.Visible
|
'ParamList(ParamEnum.PARAG_BOTTOM).nVisibility = Visibility.Visible
|
||||||
'ParamList(6).nVisibility = Visibility.Visible
|
'ParamList(ParamEnum.BOTTOM_TH).nVisibility = Visibility.Visible
|
||||||
'ParamList(7).nVisibility = Visibility.Visible
|
'ParamList(ParamEnum.BOTTOM_ALPHA).nVisibility = Visibility.Visible
|
||||||
'ParamList(8).nVisibility = Visibility.Visible
|
'ParamList(ParamEnum.BOTTOM_DIAM).nVisibility = Visibility.Visible
|
||||||
'ParamList(9).nVisibility = Visibility.Visible
|
'ParamList(ParamEnum.EDIT_NEIGH).nVisibility = Visibility.Visible
|
||||||
|
|
||||||
|
ElseIf PartType = PartType.SinkSplitBottom Then
|
||||||
|
ParamList(ParamEnum.PARAG_PANEL).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.PANEL_H).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.PANEL_TH).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.PANEL_J).nVisibility = Visibility.Collapsed
|
||||||
|
|
||||||
|
ParamList(ParamEnum.PARAG_BOTTOM).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_TH).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_ALPHA).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_DEPTH).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_TYPE).nVisibility = Visibility.Visible
|
||||||
|
DirectCast(ParamList(ParamEnum.BOTTOM_HOLE_TYPE), _ComboBoxParam).IndexSelParamCmBx = 0
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_X).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_Y).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_DIAM).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_DIMX).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_DIMY).nVisibility = Visibility.Visible
|
||||||
|
|
||||||
|
ParamList(ParamEnum.EDIT_NEIGH).nVisibility = Visibility.Collapsed
|
||||||
ElseIf PartType = PartType.Sink Then
|
ElseIf PartType = PartType.Sink Then
|
||||||
ParamList(1).nVisibility = Visibility.Visible
|
|
||||||
ParamList(2).nVisibility = Visibility.Visible
|
|
||||||
ParamList(3).nVisibility = Visibility.Visible
|
|
||||||
ParamList(4).nVisibility = Visibility.Collapsed
|
|
||||||
|
|
||||||
ParamList(5).nVisibility = Visibility.Visible
|
|
||||||
ParamList(6).nVisibility = Visibility.Visible
|
|
||||||
ParamList(7).nVisibility = Visibility.Visible
|
|
||||||
ParamList(8).nVisibility = Visibility.Visible
|
|
||||||
|
|
||||||
ParamList(9).nVisibility = Visibility.Collapsed
|
ParamList(ParamEnum.PARAG_PANEL).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.PANEL_H).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.PANEL_TH).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.PANEL_J).nVisibility = Visibility.Collapsed
|
||||||
|
|
||||||
|
ParamList(ParamEnum.PARAG_BOTTOM).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_TH).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_ALPHA).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_DEPTH).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_TYPE).nVisibility = Visibility.Visible
|
||||||
|
DirectCast(ParamList(ParamEnum.BOTTOM_HOLE_TYPE), _ComboBoxParam).IndexSelParamCmBx = 1
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_X).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_Y).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_DIAM).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_DIMX).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_DIMY).nVisibility = Visibility.Collapsed
|
||||||
|
|
||||||
|
ParamList(ParamEnum.EDIT_NEIGH).nVisibility = Visibility.Collapsed
|
||||||
ElseIf PartType = PartType.Panel Then
|
ElseIf PartType = PartType.Panel Then
|
||||||
ParamList(1).nVisibility = Visibility.Collapsed
|
ParamList(ParamEnum.PARAG_PANEL).nVisibility = Visibility.Collapsed
|
||||||
ParamList(2).nVisibility = Visibility.Visible
|
ParamList(ParamEnum.PANEL_H).nVisibility = Visibility.Visible
|
||||||
ParamList(3).nVisibility = Visibility.Visible
|
ParamList(ParamEnum.PANEL_TH).nVisibility = Visibility.Visible
|
||||||
ParamList(4).nVisibility = Visibility.Visible
|
ParamList(ParamEnum.PANEL_J).nVisibility = Visibility.Visible
|
||||||
|
|
||||||
ParamList(5).nVisibility = Visibility.Collapsed
|
ParamList(ParamEnum.PARAG_BOTTOM).nVisibility = Visibility.Collapsed
|
||||||
ParamList(6).nVisibility = Visibility.Collapsed
|
ParamList(ParamEnum.BOTTOM_TH).nVisibility = Visibility.Collapsed
|
||||||
ParamList(7).nVisibility = Visibility.Collapsed
|
ParamList(ParamEnum.BOTTOM_ALPHA).nVisibility = Visibility.Collapsed
|
||||||
ParamList(8).nVisibility = Visibility.Collapsed
|
ParamList(ParamEnum.BOTTOM_DEPTH).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_TYPE).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_X).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_Y).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_DIAM).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_DIMX).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_DIMY).nVisibility = Visibility.Collapsed
|
||||||
|
|
||||||
ParamList(9).nVisibility = Visibility.Visible
|
ParamList(ParamEnum.EDIT_NEIGH).nVisibility = Visibility.Visible
|
||||||
End If
|
End If
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Public Overrides Sub LoadParamList()
|
Public Overrides Sub LoadParamList()
|
||||||
AddGenericParam(New _TextBlockParam("Messaggio", MsgList(0), ParamType.STR, Visibility.Visible))
|
AddGenericParam(New _TextBlockParam(EGT_MESSAGE, MsgList(0), ParamType.STR, Visibility.Visible))
|
||||||
' sezione paretina
|
' sezione paretina
|
||||||
AddGenericParam(New _TextBlockParam("Messaggio", MsgList(3), ParamType.STR, Visibility.Collapsed))
|
AddGenericParam(New _TextBlockParam(EGT_MESSAGE, MsgList(3), ParamType.STR, Visibility.Collapsed))
|
||||||
Dim dH As Double = 200
|
Dim dH As Double = 200
|
||||||
AddGenericParam(New _TextBoxParam("Altezza", dH, ParamType.LEN, Visibility.Visible))
|
AddGenericParam(New _TextBoxParam("Altezza", dH, ParamType.LEN, Visibility.Visible))
|
||||||
Dim dTh As Double = 20
|
Dim dTh As Double = 20
|
||||||
@@ -183,10 +280,17 @@ Public Class EditPanelVM
|
|||||||
AddGenericParam(New _ComboBoxParam("Tipo Giunzione", JunctionTypeList, nJunctionType))
|
AddGenericParam(New _ComboBoxParam("Tipo Giunzione", JunctionTypeList, nJunctionType))
|
||||||
|
|
||||||
' sezione fondello
|
' sezione fondello
|
||||||
AddGenericParam(New _TextBlockParam("Messaggio", MsgList(4), ParamType.STR, Visibility.Collapsed))
|
AddGenericParam(New _TextBlockParam(EGT_MESSAGE, MsgList(4), ParamType.STR, Visibility.Collapsed))
|
||||||
AddGenericParam(New _TextBoxParam("Spessore", 10, ParamType.LEN, Visibility.Collapsed))
|
AddGenericParam(New _TextBoxParam("Spessore", 10, ParamType.LEN, Visibility.Collapsed))
|
||||||
AddGenericParam(New _TextBoxParam("Inclinazione", 0.1, ParamType.DOUB, Visibility.Collapsed))
|
AddGenericParam(New _TextBoxParam("Inclinazione", 0.1, ParamType.DOUB, Visibility.Collapsed))
|
||||||
|
AddGenericParam(New _TextBoxParam("Profondità", 0.1, ParamType.LEN, Visibility.Collapsed))
|
||||||
|
Dim HoleType As New List(Of ParamCmBx)({New ParamCmBx("Fessura"), New ParamCmBx("Foro")})
|
||||||
|
AddGenericParam(New _ComboBoxParam("TipoBuco", HoleType, 0, Visibility.Collapsed))
|
||||||
|
AddGenericParam(New _TextBoxParam("Posizione X foro", 50, ParamType.LEN, Visibility.Collapsed))
|
||||||
|
AddGenericParam(New _TextBoxParam("Posizione Y foro", 50, ParamType.LEN, Visibility.Collapsed))
|
||||||
AddGenericParam(New _TextBoxParam("Diametro foro", 30, ParamType.LEN, Visibility.Collapsed))
|
AddGenericParam(New _TextBoxParam("Diametro foro", 30, ParamType.LEN, Visibility.Collapsed))
|
||||||
|
AddGenericParam(New _TextBoxParam("Dimensione X foro", 25, ParamType.LEN, Visibility.Collapsed))
|
||||||
|
AddGenericParam(New _TextBoxParam("Dimensione Y foro", 25, ParamType.LEN, Visibility.Collapsed))
|
||||||
|
|
||||||
' checkbox
|
' checkbox
|
||||||
AddGenericParam(New _CheckBoxParam("ModificaAdiacenti", "Modifica anche altre paretine dello stesso tipo", Visibility.Visible))
|
AddGenericParam(New _CheckBoxParam("ModificaAdiacenti", "Modifica anche altre paretine dello stesso tipo", Visibility.Visible))
|
||||||
@@ -204,6 +308,8 @@ Public Class EditPanelVM
|
|||||||
' in base al tipo di pezzo che sto modificando chiamo la funzione corrispondente
|
' in base al tipo di pezzo che sto modificando chiamo la funzione corrispondente
|
||||||
Select Case PartType
|
Select Case PartType
|
||||||
Case PartType.Sink
|
Case PartType.Sink
|
||||||
|
EditSink()
|
||||||
|
Case PartType.SinkSplitBottom
|
||||||
EditSinkWithSplitBottom()
|
EditSinkWithSplitBottom()
|
||||||
Case PartType.Panel
|
Case PartType.Panel
|
||||||
EditPanel(nIdPart)
|
EditPanel(nIdPart)
|
||||||
@@ -238,11 +344,19 @@ Public Class EditPanelVM
|
|||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Public Function GetPartType()
|
Public Function GetPartType()
|
||||||
|
' controllo se è un lavandino con fondo unico
|
||||||
Dim bIsSink As Boolean = False
|
Dim bIsSink As Boolean = False
|
||||||
EgtGetInfo(m_nIdPart, "Sink", bIsSink)
|
EgtGetInfo(m_nIdPart, "Sink", bIsSink)
|
||||||
If bIsSink Then
|
If bIsSink Then
|
||||||
Return PartType.Sink
|
Return PartType.Sink
|
||||||
End If
|
End If
|
||||||
|
' controllo se è un lavandino con fondo splittato
|
||||||
|
Dim bIsSinkSplitBottom As Boolean = False
|
||||||
|
EgtGetInfo(m_nIdPart, "SinkSplitBottom", bIsSinkSplitBottom)
|
||||||
|
If bIsSinkSplitBottom Then
|
||||||
|
Return PartType.SinkSplitBottom
|
||||||
|
End If
|
||||||
|
' sennò è una paretina o un piano cucina
|
||||||
Dim sPair As String = String.Empty
|
Dim sPair As String = String.Empty
|
||||||
EgtGetInfo(m_nIdPart, "PairMyRef", sPair)
|
EgtGetInfo(m_nIdPart, "PairMyRef", sPair)
|
||||||
Dim bIsPanel As Boolean = sPair <> String.Empty
|
Dim bIsPanel As Boolean = sPair <> String.Empty
|
||||||
@@ -255,11 +369,11 @@ Public Class EditPanelVM
|
|||||||
|
|
||||||
Private Sub SetVariablesAndRecreate(nEdgeId As Integer)
|
Private Sub SetVariablesAndRecreate(nEdgeId As Integer)
|
||||||
If EgtLuaSetGlobIntVar("TOOL.nEdgeId", nEdgeId) Then AssLog("TOOL.nEdgeId = " & nEdgeId.ToString())
|
If EgtLuaSetGlobIntVar("TOOL.nEdgeId", nEdgeId) Then AssLog("TOOL.nEdgeId = " & nEdgeId.ToString())
|
||||||
Dim nJunctionType = DirectCast(ParamList(4), _ComboBoxParam).IndexSelParamCmBx + 1 ' in Lua l'enum è 1-based
|
Dim nJunctionType = DirectCast(ParamList(ParamEnum.PANEL_J), _ComboBoxParam).IndexSelParamCmBx + 1 ' in Lua l'enum è 1-based
|
||||||
If EgtLuaSetGlobIntVar("TOOL.nJunctionType", nJunctionType) Then AssLog("TOOL.nJunctionType = " & nJunctionType.ToString())
|
If EgtLuaSetGlobIntVar("TOOL.nJunctionType", nJunctionType) Then AssLog("TOOL.nJunctionType = " & nJunctionType.ToString())
|
||||||
Dim dTh As Double = DirectCast(ParamList(3), _TextBoxParam).GetValue()
|
Dim dTh As Double = DirectCast(ParamList(ParamEnum.PANEL_TH), _TextBoxParam).GetValue()
|
||||||
If EgtLuaSetGlobNumVar("TOOL.dTh", dTh) Then AssLog("TOOL.dTh = " & dTh.ToString())
|
If EgtLuaSetGlobNumVar("TOOL.dTh", dTh) Then AssLog("TOOL.dTh = " & dTh.ToString())
|
||||||
Dim dH As Double = DirectCast(ParamList(2), _TextBoxParam).GetValue()
|
Dim dH As Double = DirectCast(ParamList(ParamEnum.PANEL_H), _TextBoxParam).GetValue()
|
||||||
If EgtLuaSetGlobNumVar("TOOL.dH", dH) Then AssLog("TOOL.dH = " & dH.ToString())
|
If EgtLuaSetGlobNumVar("TOOL.dH", dH) Then AssLog("TOOL.dH = " & dH.ToString())
|
||||||
Dim bPrev As Boolean = True
|
Dim bPrev As Boolean = True
|
||||||
If EgtLuaSetGlobBoolVar("TOOL.bPrev", bPrev) Then AssLog("TOOL.bPrev = true")
|
If EgtLuaSetGlobBoolVar("TOOL.bPrev", bPrev) Then AssLog("TOOL.bPrev = true")
|
||||||
@@ -296,7 +410,7 @@ Public Class EditPanelVM
|
|||||||
' setto i parametri che ha scelto l'utente
|
' setto i parametri che ha scelto l'utente
|
||||||
SetVariablesAndRecreate(nEdgeId)
|
SetVariablesAndRecreate(nEdgeId)
|
||||||
' se la checkbox per la modifica delle paretine dello stesso tipo, sullo stesso loop, è checkata allora scorro il loop e continuo a chiamare la ricreazione
|
' se la checkbox per la modifica delle paretine dello stesso tipo, sullo stesso loop, è checkata allora scorro il loop e continuo a chiamare la ricreazione
|
||||||
If DirectCast(ParamList(9), _CheckBoxParam).IsChecked Then
|
If DirectCast(ParamList(ParamEnum.EDIT_NEIGH), _CheckBoxParam).IsChecked Then
|
||||||
' scorro i next e prev modificando anche le paretine adiacenti con le stesse modifiche
|
' scorro i next e prev modificando anche le paretine adiacenti con le stesse modifiche
|
||||||
' facendo attenzione a non entrare in un loop
|
' facendo attenzione a non entrare in un loop
|
||||||
Dim sCurrPartName As String = String.Empty
|
Dim sCurrPartName As String = String.Empty
|
||||||
@@ -348,7 +462,11 @@ Public Class EditPanelVM
|
|||||||
Return NeighList
|
Return NeighList
|
||||||
End Function
|
End Function
|
||||||
|
|
||||||
Private Sub EditSinkBottom(PartList As List(Of Integer))
|
Private Sub EditSink()
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub EditSplitBottom(PartList As List(Of Integer))
|
||||||
Dim lEdgeList As New List(Of Integer)
|
Dim lEdgeList As New List(Of Integer)
|
||||||
For Each nPart As Integer In PartList
|
For Each nPart As Integer In PartList
|
||||||
Dim nOutLay As Integer = EgtGetFirstNameInGroup(nPart, "OutLoop")
|
Dim nOutLay As Integer = EgtGetFirstNameInGroup(nPart, "OutLoop")
|
||||||
@@ -359,12 +477,20 @@ Public Class EditPanelVM
|
|||||||
For i As Integer = 1 To lEdgeList.Count
|
For i As Integer = 1 To lEdgeList.Count
|
||||||
EgtLuaSetGlobIntVar("TOOL.tbIdEdges." & i.ToString(), lEdgeList(i - 1).ToString())
|
EgtLuaSetGlobIntVar("TOOL.tbIdEdges." & i.ToString(), lEdgeList(i - 1).ToString())
|
||||||
Next
|
Next
|
||||||
Dim dTh As Double = DirectCast(ParamList(6), _TextBoxParam).GetValue()
|
Dim dTh As Double = DirectCast(ParamList(ParamEnum.BOTTOM_TH), _TextBoxParam).GetValue()
|
||||||
EgtLuaSetGlobNumVar("TOOL.dTh", dTh)
|
EgtLuaSetGlobNumVar("TOOL.dTh", dTh)
|
||||||
Dim dDiam As Double = DirectCast(ParamList(8), _TextBoxParam).GetValue()
|
Dim dDiam As Double = DirectCast(ParamList(ParamEnum.BOTTOM_DIAM), _TextBoxParam).GetValue()
|
||||||
EgtLuaSetGlobNumVar("TOOL.dDiamBore", dDiam)
|
EgtLuaSetGlobNumVar("TOOL.dDiamBore", dDiam)
|
||||||
Dim dAng As Double = DirectCast(ParamList(7), _TextBoxParam).GetValue()
|
Dim dDepth As Double = DirectCast(ParamList(ParamEnum.BOTTOM_DEPTH), _TextBoxParam).GetValue()
|
||||||
EgtLuaSetGlobNumVar("TOOL.dSlopeAng", dAng)
|
EgtLuaSetGlobNumVar("TOOL.dDepth", dDepth)
|
||||||
|
Dim dPosX As Double = DirectCast(ParamList(ParamEnum.BOTTOM_HOLE_X), _TextBoxParam).GetValue()
|
||||||
|
EgtLuaSetGlobNumVar("TOOL.dHoleX", dPosX)
|
||||||
|
Dim dPosY As Double = DirectCast(ParamList(ParamEnum.BOTTOM_HOLE_Y), _TextBoxParam).GetValue()
|
||||||
|
EgtLuaSetGlobNumVar("TOOL.dHoleY", dPosY)
|
||||||
|
Dim dDimX As Double = DirectCast(ParamList(ParamEnum.BOTTOM_HOLE_DIMX), _TextBoxParam).GetValue()
|
||||||
|
EgtLuaSetGlobNumVar("TOOL.dHoleDimX", dDimX)
|
||||||
|
Dim dDimY As Double = DirectCast(ParamList(ParamEnum.BOTTOM_HOLE_DIMY), _TextBoxParam).GetValue()
|
||||||
|
EgtLuaSetGlobNumVar("TOOL.dHoleDimY", dDimY)
|
||||||
EgtLuaCallFunction("TOOL.CreateSplitBottom")
|
EgtLuaCallFunction("TOOL.CreateSplitBottom")
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
@@ -381,16 +507,16 @@ Public Class EditPanelVM
|
|||||||
nWaterfallId = EgtGetFirstNameInGroup(GDB_ID.ROOT, sPartDest)
|
nWaterfallId = EgtGetFirstNameInGroup(GDB_ID.ROOT, sPartDest)
|
||||||
End If
|
End If
|
||||||
' modifico i frontalini
|
' modifico i frontalini
|
||||||
DirectCast(ParamList(9), _CheckBoxParam).IsChecked = True
|
DirectCast(ParamList(ParamEnum.EDIT_NEIGH), _CheckBoxParam).IsChecked = True
|
||||||
EditPanel(nWaterfallId)
|
EditPanel(nWaterfallId)
|
||||||
' recupero la lista degli id dei frontalini
|
' recupero la lista degli id dei frontalini
|
||||||
Dim WaterfallList As List(Of Integer) = GetNeighbours(nWaterfallId)
|
Dim WaterfallList As List(Of Integer) = GetNeighbours(nWaterfallId)
|
||||||
' modifico i pezzi dello split bottom
|
' modifico i pezzi dello split bottom
|
||||||
EditSinkBottom(WaterfallList)
|
EditSplitBottom(WaterfallList)
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Public Sub SelectPartOrPartsToEdit()
|
Public Sub SelectPartOrPartsToEdit()
|
||||||
If PartType = PartType.Sink Then
|
If PartType = PartType.Sink Or PartType = PartType.SinkSplitBottom Then
|
||||||
Dim bBottom As Boolean = False
|
Dim bBottom As Boolean = False
|
||||||
EgtGetInfo(nIdPart, "Bottom", bBottom)
|
EgtGetInfo(nIdPart, "Bottom", bBottom)
|
||||||
Dim BottomList As List(Of Integer)
|
Dim BottomList As List(Of Integer)
|
||||||
@@ -419,7 +545,9 @@ Public Class EditPanelVM
|
|||||||
Dim PartSolidSel As PartSolidM = GetPartSolid(nIdPart)
|
Dim PartSolidSel As PartSolidM = GetPartSolid(nIdPart)
|
||||||
PartSolidSel.SelectSinglePart()
|
PartSolidSel.SelectSinglePart()
|
||||||
End If
|
End If
|
||||||
|
EgtDraw()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
#End Region ' Methods
|
#End Region ' Methods
|
||||||
|
|
||||||
End Class
|
End Class
|
||||||
|
|||||||
@@ -0,0 +1,300 @@
|
|||||||
|
Imports EgtUILib
|
||||||
|
Imports EgtWPFLib5
|
||||||
|
|
||||||
|
Public Class EditParametricVM
|
||||||
|
Inherits SceneUserControlVM
|
||||||
|
|
||||||
|
#Region "FIELDS & PROPERTIES"
|
||||||
|
|
||||||
|
Private Enum ParamEnum As Integer
|
||||||
|
TOP_MSG = 0
|
||||||
|
CHK_PNT = 1
|
||||||
|
CHK_LEN = 2
|
||||||
|
CHK_DIR = 3
|
||||||
|
End Enum
|
||||||
|
|
||||||
|
Private bReadyForLinks As Boolean = False
|
||||||
|
|
||||||
|
Private ReadOnly m_MsgList As New List(Of String)({TopBar_Msg_Stg0, TopBar_Msg_Stg1, TopBar_Msg_Stg2})
|
||||||
|
Public ReadOnly Property MsgList As List(Of String)
|
||||||
|
Get
|
||||||
|
Return m_MsgList
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Private m_Stage As EditParametricStage = EditParametricStage.SelectPart
|
||||||
|
Private Property Stage As EditParametricStage
|
||||||
|
Get
|
||||||
|
Return m_Stage
|
||||||
|
End Get
|
||||||
|
Set(value As EditParametricStage)
|
||||||
|
m_Stage = value
|
||||||
|
DirectCast(ParamList(0), _TextBlockParam).MsgValue = MsgList(m_Stage)
|
||||||
|
ChangeTextColor()
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
' id del part selezionato per essere modificato
|
||||||
|
Private m_nId1 As Integer = GDB_ID.NULL
|
||||||
|
Public Property nId1 As Integer
|
||||||
|
Get
|
||||||
|
Return m_nId1
|
||||||
|
End Get
|
||||||
|
Set(value As Integer)
|
||||||
|
If m_nId1 <> GDB_ID.NULL Then SceneCmd.DeselectAll()
|
||||||
|
m_nId1 = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
' punto selezionato sulla prima linea
|
||||||
|
Private m_FirstPoint As New Point3d
|
||||||
|
Public Property FirstPoint As Point3d
|
||||||
|
Get
|
||||||
|
Return m_FirstPoint
|
||||||
|
End Get
|
||||||
|
Set(value As Point3d)
|
||||||
|
m_FirstPoint = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
' parametro del punto sulla prima linea
|
||||||
|
Private m_dUFirst As Double
|
||||||
|
Public Property dUFirst As Double
|
||||||
|
Get
|
||||||
|
Return m_dUFirst
|
||||||
|
End Get
|
||||||
|
Set(value As Double)
|
||||||
|
m_dUFirst = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
' id del secondo part, a cui voglio vincolare il primo
|
||||||
|
Private m_nId2 As Integer = GDB_ID.NULL
|
||||||
|
Public Property nId2 As Integer
|
||||||
|
Get
|
||||||
|
Return m_nId2
|
||||||
|
End Get
|
||||||
|
Set(value As Integer)
|
||||||
|
If m_nId2 <> GDB_ID.NULL Then SceneCmd.DeselectAll()
|
||||||
|
m_nId2 = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
' punto selezionato sulla seconda linea
|
||||||
|
Private m_SecondPoint As New Point3d
|
||||||
|
Public Property SecondPoint As Point3d
|
||||||
|
Get
|
||||||
|
Return m_SecondPoint
|
||||||
|
End Get
|
||||||
|
Set(value As Point3d)
|
||||||
|
m_SecondPoint = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
' parametro del punto sulla seconda linea
|
||||||
|
Private m_dUSecond As Double
|
||||||
|
Public Property dUSecond As Double
|
||||||
|
Get
|
||||||
|
Return m_dUSecond
|
||||||
|
End Get
|
||||||
|
Set(value As Double)
|
||||||
|
m_dUSecond = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
' sottocurva sulla prima curva selezionata
|
||||||
|
Private m_nSubCrv1 As Integer
|
||||||
|
Public Property nSubCrv1 As Integer
|
||||||
|
Get
|
||||||
|
Return m_nSubCrv1
|
||||||
|
End Get
|
||||||
|
Set(value As Integer)
|
||||||
|
m_nSubCrv1 = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
' sottocurva sull'ultima curva selezionata
|
||||||
|
Private m_nSubCrv2 As Integer
|
||||||
|
Public Property nSubCrv2 As Integer
|
||||||
|
Get
|
||||||
|
Return m_nSubCrv2
|
||||||
|
End Get
|
||||||
|
Set(value As Integer)
|
||||||
|
m_nSubCrv2 = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
#Region "Messages"
|
||||||
|
|
||||||
|
Public ReadOnly Property TopBar_Msg_Stg0 As String
|
||||||
|
Get
|
||||||
|
Return EgtMsg(110040) ' Seleziona l'oggetto di cui vuoi modificare il vincolo
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Public ReadOnly Property TopBar_Msg_Stg1 As String
|
||||||
|
Get
|
||||||
|
Return EgtMsg(110041) ' Seleziona l'oggetto a cui vuoi vincolare il precedente
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Public ReadOnly Property TopBar_Msg_Stg2 As String
|
||||||
|
Get
|
||||||
|
Return EgtMsg(110042) '
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
|
#End Region ' Messages
|
||||||
|
|
||||||
|
#End Region ' Fields & Properties
|
||||||
|
|
||||||
|
#Region "CONSTRUCTOR"
|
||||||
|
|
||||||
|
Public Sub New()
|
||||||
|
MyBase.New()
|
||||||
|
Title = "Modifica Contorno Pezzo".ToUpper()
|
||||||
|
|
||||||
|
Dim Dir_Vein3D As String = String.Empty
|
||||||
|
Dim Path_Parametric As String = String.Empty
|
||||||
|
' carico il file LUA con tutte le funzioni di gestione parametrico
|
||||||
|
GetMainPrivateProfileString(K_VEIND3D, VEIND3D_DIR, "", Dir_Vein3D)
|
||||||
|
' Path del lua da utilizzare
|
||||||
|
GetMainPrivateProfileString(K_VEIND3D, "Parametric2D", "", Path_Parametric)
|
||||||
|
' avvio il file OperationOnSolid.lua
|
||||||
|
Dim sLuaPath As String = Dir_Vein3D & Path_Parametric
|
||||||
|
EgtLuaExecFile(sLuaPath)
|
||||||
|
|
||||||
|
LoadParamList()
|
||||||
|
Map.refSceneHostVM.m_SelType = GDB_TY.CRV_LINE
|
||||||
|
EgtSetView(VT.TOP)
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
#End Region ' Constructor
|
||||||
|
|
||||||
|
#Region "METHODS"
|
||||||
|
|
||||||
|
Public Overrides Sub LoadParamList()
|
||||||
|
AddGenericParam(New _TextBlockParam(EGT_MESSAGE, MsgList(0), ParamType.STR, Visibility.Visible))
|
||||||
|
' checkbox
|
||||||
|
AddGenericParam(New _CheckBoxParam("Vincolo Punto", "Punto Start Vincolato", Visibility.Visible))
|
||||||
|
AddGenericParam(New _CheckBoxParam("Vincolo Lunghezza", "Lunghezza Vincolata", Visibility.Visible))
|
||||||
|
AddGenericParam(New _CheckBoxParam("Vincolo Direzione", "Direzione Vincolata", Visibility.Visible))
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Overrides Sub Conferma()
|
||||||
|
' Eseguo la giunzione di due pezzi
|
||||||
|
LinksEnt()
|
||||||
|
' Unisco in una compo
|
||||||
|
EgtLuaExecLine("PAR.JointLine()")
|
||||||
|
' chiudo lo user control
|
||||||
|
Close()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Overrides Sub Annulla()
|
||||||
|
' Ripristino il primo stato
|
||||||
|
UndoLinksEnt()
|
||||||
|
' chiudo lo user control
|
||||||
|
Close()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Overrides Sub ShowPreview()
|
||||||
|
LinksEnt()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub Close()
|
||||||
|
SolidManagerM.ResetOperationMarks(Map.refSceneHostVM.m_nIdPart)
|
||||||
|
EgtDraw()
|
||||||
|
Dim Btn As SceneBtn = Map.refSceneButtonVM.GetButton(EGT_EDIT_PARAMETRIC)
|
||||||
|
If TypeOf (Btn) Is _ToggleButton Then
|
||||||
|
DirectCast(Btn, _ToggleButton).IsChecked = False
|
||||||
|
Else
|
||||||
|
EgtOutLog("CONFIG ERR: Il pulsante di Edit Panel è stato definito come Button anziché ToggleButton")
|
||||||
|
End If
|
||||||
|
' rimuovo lo UC dalla griglia
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_EditParametricUC)
|
||||||
|
SolidManagerM.ManageUndoRedo()
|
||||||
|
' resetto la tabella globale del parametric
|
||||||
|
EgtLuaResetGlobVar("PAR")
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub LinksEnt()
|
||||||
|
' Unisco le due entità ricevute
|
||||||
|
If bReadyForLinks Then
|
||||||
|
EgtLuaExecLine("PAR.LinksLine()")
|
||||||
|
Else
|
||||||
|
EgtOutLog("Errore nella definizione dei pezzi da unire")
|
||||||
|
End If
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub UndoLinksEnt()
|
||||||
|
' Riposiziono prima entità
|
||||||
|
EgtLuaExecLine("PAR.UndoLinksLine()")
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub ResetEnt()
|
||||||
|
' Ripulisco la tabelle e il disegno
|
||||||
|
EgtLuaExecLine("PAR.Reset()")
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Sub ShowFirstCurrPoint()
|
||||||
|
' Info primo punto
|
||||||
|
EgtLuaSetGlobIntVar("PAR.nId1", m_nId1)
|
||||||
|
EgtLuaSetGlobPointVar("PAR.Pt1", m_FirstPoint)
|
||||||
|
EgtLuaSetGlobNumVar("PAR.dU1", m_dUFirst)
|
||||||
|
EgtLuaSetGlobNumVar("PAR.nSubCrv1", m_nSubCrv1)
|
||||||
|
' Disegno l'entità selezionata
|
||||||
|
bReadyForLinks = EgtLuaExecLine("PAR.DrawFirstPoint()")
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Sub ShowSecondCurrPoint()
|
||||||
|
' Info secondo punto
|
||||||
|
EgtLuaSetGlobIntVar("PAR.nId2", m_nId2)
|
||||||
|
EgtLuaSetGlobPointVar("PAR.Pt2", m_SecondPoint)
|
||||||
|
EgtLuaSetGlobNumVar("PAR.dU2", m_dUSecond)
|
||||||
|
EgtLuaSetGlobNumVar("PAR.nSubCrv2", m_nSubCrv2)
|
||||||
|
' Disegno l'entità selezionata
|
||||||
|
bReadyForLinks = bReadyForLinks And EgtLuaExecLine("PAR.DrawSecondPoint()")
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
|
||||||
|
Private Sub ConstraintLenght()
|
||||||
|
' Lunghezza segmento
|
||||||
|
EgtLuaSetGlobNumVar("PAR.Len", 450.25)
|
||||||
|
' Fisso la lunghezza del segmento
|
||||||
|
EgtLuaExecLine("PAR.LinearDimension()")
|
||||||
|
' Rappresento la quotatura
|
||||||
|
EgtLuaExecLine("PAR.DrawLinearDimension()")
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub ConstraintDirection()
|
||||||
|
' Lunghezza segmento
|
||||||
|
EgtLuaSetGlobNumVar("PAR.Ang", 45.5)
|
||||||
|
' Fisso la lunghezza del segmento
|
||||||
|
EgtLuaExecLine("PAR.AngularDimension()")
|
||||||
|
' Rappresento la quotatura
|
||||||
|
EgtLuaExecLine("PAR.DrawAngularDimension()")
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
#End Region ' Methods
|
||||||
|
|
||||||
|
#Region "EVENTS"
|
||||||
|
|
||||||
|
Public Overrides Sub OnCheckboxCheckedChanged(sender As Object, checkedState As Boolean)
|
||||||
|
Dim CheckBox As _CheckBoxParam = DirectCast(sender, _CheckBoxParam)
|
||||||
|
Select Case CheckBox.Name
|
||||||
|
Case "Vincolo Punto"
|
||||||
|
'LinksEnt()
|
||||||
|
Case "Vincolo Lunghezza"
|
||||||
|
ConstraintLenght()
|
||||||
|
Reset()
|
||||||
|
Case "Vincolo Direzione"
|
||||||
|
ConstraintDirection()
|
||||||
|
End Select
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Overrides Sub OnComboboxSelectionChanged(sender As Object, Selection As ParamCmBx)
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
#End Region ' Events
|
||||||
|
|
||||||
|
End Class
|
||||||
@@ -1,135 +0,0 @@
|
|||||||
Imports EgtUILib
|
|
||||||
Public Class EditTopKitchenVM
|
|
||||||
Inherits SceneUserControlVM
|
|
||||||
|
|
||||||
#Region "FIELDS & PROPERTIES"
|
|
||||||
|
|
||||||
Private ReadOnly m_MsgList As New List(Of String)({TopBar_Msg_Stg0, TopBar_Msg_Stg1, TopBar_Msg_Stg2, Msg_Paragraph1, Msg_Paragraph2})
|
|
||||||
Public ReadOnly Property MsgList As List(Of String)
|
|
||||||
Get
|
|
||||||
Return m_MsgList
|
|
||||||
End Get
|
|
||||||
End Property
|
|
||||||
|
|
||||||
Private m_Stage As EditTopKStage = EditTopKStage.SelectPart
|
|
||||||
Private Property Stage As EditTopKStage
|
|
||||||
Get
|
|
||||||
Return m_Stage
|
|
||||||
End Get
|
|
||||||
Set(value As EditTopKStage)
|
|
||||||
m_Stage = value
|
|
||||||
DirectCast(ParamList(0), _TextBlockParam).MsgValue = MsgList(m_Stage)
|
|
||||||
End Set
|
|
||||||
End Property
|
|
||||||
|
|
||||||
' id del part selezionato per essere modificato
|
|
||||||
Private m_nIdPart As Integer = GDB_ID.NULL
|
|
||||||
Public Property nIdPart As Integer
|
|
||||||
Get
|
|
||||||
Return m_nIdPart
|
|
||||||
End Get
|
|
||||||
Set(value As Integer)
|
|
||||||
If m_nIdPart <> GDB_ID.NULL Then SceneCmd.DeselectAll()
|
|
||||||
m_nIdPart = value
|
|
||||||
End Set
|
|
||||||
End Property
|
|
||||||
|
|
||||||
#Region "Messages"
|
|
||||||
|
|
||||||
Public ReadOnly Property TopBar_Msg_Stg0 As String
|
|
||||||
Get
|
|
||||||
Return EgtMsg(110040) ' Seleziona il Part che vuoi modificare
|
|
||||||
End Get
|
|
||||||
End Property
|
|
||||||
Public ReadOnly Property TopBar_Msg_Stg1 As String
|
|
||||||
Get
|
|
||||||
Return EgtMsg(110041) ' Inserisci i nuovi parametri
|
|
||||||
End Get
|
|
||||||
End Property
|
|
||||||
Public ReadOnly Property TopBar_Msg_Stg2 As String
|
|
||||||
Get
|
|
||||||
Return EgtMsg(110042) ' Conferma, modifica con altri parametri o annulla
|
|
||||||
End Get
|
|
||||||
End Property
|
|
||||||
Public ReadOnly Property Msg_Paragraph1 As String
|
|
||||||
Get
|
|
||||||
Return EgtMsg(110038) ' Frontalino
|
|
||||||
End Get
|
|
||||||
End Property
|
|
||||||
Public ReadOnly Property Msg_Paragraph2 As String
|
|
||||||
Get
|
|
||||||
Return EgtMsg(110039) ' Fondo
|
|
||||||
End Get
|
|
||||||
End Property
|
|
||||||
|
|
||||||
#End Region ' Messages
|
|
||||||
|
|
||||||
#End Region ' Fields & Properties
|
|
||||||
|
|
||||||
#Region "CONSTRUCTOR"
|
|
||||||
|
|
||||||
Public Sub New()
|
|
||||||
MyBase.New()
|
|
||||||
Title = "Modifica Contorno Pezzo".ToUpper()
|
|
||||||
If Map.refSceneHostVM.m_nIdPart <> GDB_ID.NULL Then
|
|
||||||
nIdPart = Map.refSceneHostVM.m_nIdPart
|
|
||||||
Stage = EditTopKStage.SelectEdge
|
|
||||||
End If
|
|
||||||
|
|
||||||
LoadParamList()
|
|
||||||
End Sub
|
|
||||||
|
|
||||||
#End Region ' Constructor
|
|
||||||
|
|
||||||
#Region "METHODS"
|
|
||||||
Public Overrides Sub LoadParamList()
|
|
||||||
AddGenericParam(New _TextBlockParam("Messaggio", MsgList(0), ParamType.STR, Visibility.Visible))
|
|
||||||
' sezione paretina
|
|
||||||
AddGenericParam(New _TextBlockParam("Messaggio", MsgList(3), ParamType.STR, Visibility.Collapsed))
|
|
||||||
Dim dH As Double = 200
|
|
||||||
AddGenericParam(New _TextBoxParam("Altezza", dH, ParamType.LEN, Visibility.Visible))
|
|
||||||
Dim dTh As Double = 20
|
|
||||||
AddGenericParam(New _TextBoxParam("Spessore", dTh, ParamType.LEN, Visibility.Visible))
|
|
||||||
Dim nJunctionType As Integer = 0
|
|
||||||
Dim JunctionTypeList As New List(Of ParamCmBx)({New ParamCmBx("Trim Start"), New ParamCmBx("Trim End"), New ParamCmBx("Angle"), New ParamCmBx("Trim Both")})
|
|
||||||
AddGenericParam(New _ComboBoxParam("Tipo Giunzione", JunctionTypeList, nJunctionType))
|
|
||||||
|
|
||||||
' sezione fondello
|
|
||||||
AddGenericParam(New _TextBlockParam("Messaggio", MsgList(4), ParamType.STR, Visibility.Collapsed))
|
|
||||||
AddGenericParam(New _TextBoxParam("Spessore", 10, ParamType.LEN, Visibility.Collapsed))
|
|
||||||
AddGenericParam(New _TextBoxParam("Inclinazione", 0.1, ParamType.DOUB, Visibility.Collapsed))
|
|
||||||
AddGenericParam(New _TextBoxParam("Diametro foro", 30, ParamType.LEN, Visibility.Collapsed))
|
|
||||||
|
|
||||||
' checkbox
|
|
||||||
AddGenericParam(New _CheckBoxParam("ModificaAdiacenti", "Modifica anche altre paretine dello stesso tipo", Visibility.Visible))
|
|
||||||
End Sub
|
|
||||||
|
|
||||||
Public Overrides Sub Conferma()
|
|
||||||
' aggiorno la lista dei partSolid
|
|
||||||
SolidManagerM.CreatePartSolid()
|
|
||||||
' chiudo lo user control
|
|
||||||
Close()
|
|
||||||
End Sub
|
|
||||||
|
|
||||||
Public Overrides Sub Annulla()
|
|
||||||
Map.refSceneHostVM.m_nIdPart = GDB_ID.NULL
|
|
||||||
SceneCmd.DeselectAll()
|
|
||||||
' chiudo lo user control
|
|
||||||
Close()
|
|
||||||
End Sub
|
|
||||||
|
|
||||||
Private Sub Close()
|
|
||||||
SolidManagerM.ResetOperationMarks(Map.refSceneHostVM.m_nIdPart)
|
|
||||||
EgtDraw()
|
|
||||||
Dim Btn As SceneBtn = Map.refSceneButtonVM.GetButton(EGT_EDIT_PANEL)
|
|
||||||
If TypeOf (Btn) Is _ToggleButton Then
|
|
||||||
DirectCast(Btn, _ToggleButton).IsChecked = False
|
|
||||||
Else
|
|
||||||
EgtOutLog("CONFIG ERR: Il pulsante di Edit Panel è stato definito come Button anziché ToggleButton")
|
|
||||||
End If
|
|
||||||
' rimuovo lo UC dalla griglia
|
|
||||||
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_EditPanelUC)
|
|
||||||
SolidManagerM.ManageUndoRedo()
|
|
||||||
End Sub
|
|
||||||
#End Region
|
|
||||||
End Class
|
|
||||||
+237
-64
@@ -5,6 +5,26 @@ Public Class NewPanelVM
|
|||||||
|
|
||||||
#Region "FIELDS & PROPERTIES"
|
#Region "FIELDS & PROPERTIES"
|
||||||
|
|
||||||
|
Private Enum ParamEnum
|
||||||
|
MSG_ISTRUZ = 0
|
||||||
|
TY_PANEL = 1
|
||||||
|
PARAG_PANEL = 2
|
||||||
|
PANEL_H = 3
|
||||||
|
PANEL_TH = 4
|
||||||
|
PANEL_J = 5
|
||||||
|
PARAG_BOTTOM = 6
|
||||||
|
BOTTOM_H = 7
|
||||||
|
BOTTOM_TH = 8
|
||||||
|
BOTTOM_DEPTH = 9
|
||||||
|
BOTTOM_HOLE_X = 10
|
||||||
|
BOTTOM_HOLE_Y = 11
|
||||||
|
BOTTOM_HOLE_TYPE = 12
|
||||||
|
BOTTOM_DIAM = 13
|
||||||
|
BOTTOM_HOLE_DIMX = 14
|
||||||
|
BOTTOM_HOLE_DIMY = 15
|
||||||
|
BOTTOM_ALPHA = 16
|
||||||
|
End Enum
|
||||||
|
|
||||||
Private ReadOnly m_MsgList As New List(Of String)({TopBar_Msg_Stg0, TopBar_Msg_Stg1, TopBar_Msg_Stg2})
|
Private ReadOnly m_MsgList As New List(Of String)({TopBar_Msg_Stg0, TopBar_Msg_Stg1, TopBar_Msg_Stg2})
|
||||||
Public ReadOnly Property MsgList As List(Of String)
|
Public ReadOnly Property MsgList As List(Of String)
|
||||||
Get
|
Get
|
||||||
@@ -19,7 +39,7 @@ Public Class NewPanelVM
|
|||||||
End Get
|
End Get
|
||||||
Set(value As NewPanelStage)
|
Set(value As NewPanelStage)
|
||||||
m_Stage = value
|
m_Stage = value
|
||||||
DirectCast(ParamList(0), _TextBlockParam).MsgValue = MsgList(m_Stage)
|
DirectCast(ParamList(ParamEnum.MSG_ISTRUZ), _TextBlockParam).MsgValue = MsgList(m_Stage)
|
||||||
End Set
|
End Set
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
@@ -30,17 +50,25 @@ Public Class NewPanelVM
|
|||||||
Return EgtMsg(110030) ' Clicca sull'edge di un pezzo per aggiungere una paretina del tipo selezionato
|
Return EgtMsg(110030) ' Clicca sull'edge di un pezzo per aggiungere una paretina del tipo selezionato
|
||||||
End Get
|
End Get
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
Public ReadOnly Property TopBar_Msg_Stg1 As String
|
Public ReadOnly Property TopBar_Msg_Stg1 As String
|
||||||
Get
|
Get
|
||||||
Return EgtMsg(110038) ' frontalino
|
Return EgtMsg(110038) ' frontalino
|
||||||
End Get
|
End Get
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
Public ReadOnly Property TopBar_Msg_Stg2 As String
|
Public ReadOnly Property TopBar_Msg_Stg2 As String
|
||||||
Get
|
Get
|
||||||
Return EgtMsg(110039) ' fondo
|
Return EgtMsg(110039) ' fondo
|
||||||
End Get
|
End Get
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
|
Public ReadOnly Property TopBar_Msg_Bottom As String
|
||||||
|
Get
|
||||||
|
Return EgtMsg(110043) ' seleziona le paretine che fanno da contorno al fondo che vuoi creare
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
#End Region ' Messages
|
#End Region ' Messages
|
||||||
|
|
||||||
#End Region ' Fields & Properties
|
#End Region ' Fields & Properties
|
||||||
@@ -60,22 +88,30 @@ Public Class NewPanelVM
|
|||||||
#Region "METHODS"
|
#Region "METHODS"
|
||||||
|
|
||||||
Public Overrides Sub LoadParamList()
|
Public Overrides Sub LoadParamList()
|
||||||
AddGenericParam(New _TextBlockParam("Messaggio", MsgList(0), ParamType.STR, Visibility.Visible))
|
AddGenericParam(New _TextBlockParam(EGT_MESSAGE, MsgList(0), ParamType.STR, Visibility.Visible))
|
||||||
Dim PanelType As New List(Of ParamCmBx)({New ParamCmBx("Alzatina"), New ParamCmBx("Frontalino"), New ParamCmBx("SplitBottom"), New ParamCmBx("Tappa Buca")})
|
Dim PanelType As New List(Of ParamCmBx)({New ParamCmBx(EGT_SPLASHTOP), New ParamCmBx(EGT_WATERFALL), New ParamCmBx(EGT_SPLITBOTTOM),
|
||||||
|
New ParamCmBx(EGT_SINK_SPLITBOTTOM), New ParamCmBx(EGT_SINK), New ParamCmBx(EGT_BOTTOM)})
|
||||||
AddGenericParam(New _ComboBoxParam("TipoParetina", PanelType, 0, Visibility.Visible))
|
AddGenericParam(New _ComboBoxParam("TipoParetina", PanelType, 0, Visibility.Visible))
|
||||||
' sezione paretina
|
' sezione paretina
|
||||||
AddGenericParam(New _TextBlockParam("Messaggio", MsgList(1), ParamType.STR, Visibility.Collapsed))
|
AddGenericParam(New _TextBlockParam(EGT_MESSAGE, MsgList(1), ParamType.STR, Visibility.Collapsed))
|
||||||
AddGenericParam(New _TextBoxParam("Altezza", 100, ParamType.LEN, Visibility.Visible))
|
AddGenericParam(New _TextBoxParam("Altezza", 100, ParamType.LEN, Visibility.Visible))
|
||||||
AddGenericParam(New _TextBoxParam("Spessore", 10, ParamType.LEN, Visibility.Visible))
|
AddGenericParam(New _TextBoxParam("Spessore", 10, ParamType.LEN, Visibility.Visible))
|
||||||
Dim JunctionType As New List(Of ParamCmBx)({New ParamCmBx("Trim Start"), New ParamCmBx("Trim End"), New ParamCmBx("Trim Angled")})
|
Dim JunctionType As New List(Of ParamCmBx)({New ParamCmBx("Trim Start"), New ParamCmBx("Trim End"), New ParamCmBx("Trim Angled")})
|
||||||
AddGenericParam(New _ComboBoxParam("TipoGiunzione", JunctionType, 0, Visibility.Visible))
|
AddGenericParam(New _ComboBoxParam("TipoGiunzione", JunctionType, 0, Visibility.Visible))
|
||||||
|
|
||||||
' sezione fondello
|
' sezione fondello
|
||||||
AddGenericParam(New _TextBlockParam("Messaggio", MsgList(2), ParamType.STR, Visibility.Collapsed))
|
AddGenericParam(New _TextBlockParam(EGT_MESSAGE, MsgList(2), ParamType.STR, Visibility.Collapsed))
|
||||||
AddGenericParam(New _TextBoxParam("Altezza", 100, ParamType.LEN, Visibility.Collapsed))
|
AddGenericParam(New _TextBoxParam("Altezza", 100, ParamType.LEN, Visibility.Collapsed))
|
||||||
AddGenericParam(New _TextBoxParam("Spessore", 10, ParamType.LEN, Visibility.Collapsed))
|
AddGenericParam(New _TextBoxParam("Spessore", 10, ParamType.LEN, Visibility.Collapsed))
|
||||||
AddGenericParam(New _TextBoxParam("Inclinazione", 0.1, ParamType.DOUB, Visibility.Collapsed))
|
AddGenericParam(New _TextBoxParam("Profondità", 1, ParamType.LEN, Visibility.Collapsed))
|
||||||
|
AddGenericParam(New _TextBoxParam("Posizione X foro", 50, ParamType.LEN, Visibility.Collapsed))
|
||||||
|
AddGenericParam(New _TextBoxParam("Posizione Y foro", 50, ParamType.LEN, Visibility.Collapsed))
|
||||||
|
Dim HoleType As New List(Of ParamCmBx)({New ParamCmBx("Fessura"), New ParamCmBx("Foro")})
|
||||||
|
AddGenericParam(New _ComboBoxParam("TipoBuco", HoleType, 0, Visibility.Collapsed))
|
||||||
AddGenericParam(New _TextBoxParam("Diametro foro", 30, ParamType.LEN, Visibility.Collapsed))
|
AddGenericParam(New _TextBoxParam("Diametro foro", 30, ParamType.LEN, Visibility.Collapsed))
|
||||||
|
AddGenericParam(New _TextBoxParam("Dimensione X foro", 25, ParamType.LEN, Visibility.Collapsed))
|
||||||
|
AddGenericParam(New _TextBoxParam("Dimensione Y foro", 25, ParamType.LEN, Visibility.Collapsed))
|
||||||
|
AddGenericParam(New _TextBoxParam("Inclinazione", 2, ParamType.DOUB, Visibility.Collapsed))
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Public Sub AdvanceStage()
|
Public Sub AdvanceStage()
|
||||||
@@ -89,56 +125,143 @@ Public Class NewPanelVM
|
|||||||
Public Overrides Sub OnComboboxSelectionChanged(sender As Object, Selection As ParamCmBx)
|
Public Overrides Sub OnComboboxSelectionChanged(sender As Object, Selection As ParamCmBx)
|
||||||
' quando viene selezionato lo split bottom devo mostrare le opzioni per il fondello
|
' quando viene selezionato lo split bottom devo mostrare le opzioni per il fondello
|
||||||
If DirectCast(sender, _ComboBoxParam).Name = "TipoParetina" Then
|
If DirectCast(sender, _ComboBoxParam).Name = "TipoParetina" Then
|
||||||
If DirectCast(Selection, ParamCmBx).Name = "SplitBottom" Then
|
Dim sType As String = DirectCast(Selection, ParamCmBx).Name
|
||||||
ParamList(3).nVisibility = Visibility.Collapsed
|
If sType = EGT_SPLITBOTTOM Then
|
||||||
ParamList(4).nVisibility = Visibility.Collapsed
|
DirectCast(Map.refSceneButtonVM.m_NewPanelUC, SceneUserControlV).Preview.Visibility = Visibility.Visible
|
||||||
ParamList(5).nVisibility = Visibility.Collapsed
|
|
||||||
|
|
||||||
ParamList(6).nVisibility = Visibility.Visible
|
ParamList(ParamEnum.PANEL_H).nVisibility = Visibility.Collapsed
|
||||||
ParamList(7).nVisibility = Visibility.Visible
|
ParamList(ParamEnum.PANEL_TH).nVisibility = Visibility.Collapsed
|
||||||
ParamList(8).nVisibility = Visibility.Visible
|
ParamList(ParamEnum.PANEL_J).nVisibility = Visibility.Collapsed
|
||||||
ParamList(9).nVisibility = Visibility.Visible
|
|
||||||
ParamList(10).nVisibility = Visibility.Visible
|
ParamList(ParamEnum.PARAG_BOTTOM).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_H).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_TH).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_DEPTH).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_TYPE).nVisibility = Visibility.Visible
|
||||||
|
DirectCast(ParamList(ParamEnum.BOTTOM_HOLE_TYPE), _ComboBoxParam).IndexSelParamCmBx = 0
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_X).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_Y).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_DIAM).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_DIMX).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_DIMY).nVisibility = Visibility.Visible
|
||||||
Map.refSceneHostVM.m_SelType = GDB_TY.SRF_MESH
|
Map.refSceneHostVM.m_SelType = GDB_TY.SRF_MESH
|
||||||
'DirectCast(Map.refSceneButtonV.m_PanelUC, SceneUserControlV).Preview.Visibility = Visibility.Visible
|
ElseIf sType = EGT_SINK_SPLITBOTTOM Then
|
||||||
ElseIf DirectCast(Selection, ParamCmBx).Name = "Tappa Buca" Then
|
DirectCast(Map.refSceneButtonVM.m_NewPanelUC, SceneUserControlV).Preview.Visibility = Visibility.Visible
|
||||||
ParamList(2).nVisibility = Visibility.Visible
|
|
||||||
ParamList(3).nVisibility = Visibility.Visible
|
|
||||||
ParamList(4).nVisibility = Visibility.Visible
|
|
||||||
ParamList(5).nVisibility = Visibility.Visible
|
|
||||||
|
|
||||||
ParamList(6).nVisibility = Visibility.Visible
|
DirectCast(ParamList(ParamEnum.PANEL_J), _ComboBoxParam).IndexSelParamCmBx = 2
|
||||||
ParamList(7).nVisibility = Visibility.Visible
|
ParamList(ParamEnum.PARAG_PANEL).nVisibility = Visibility.Visible
|
||||||
ParamList(8).nVisibility = Visibility.Visible
|
ParamList(ParamEnum.PANEL_H).nVisibility = Visibility.Visible
|
||||||
ParamList(9).nVisibility = Visibility.Visible
|
ParamList(ParamEnum.PANEL_TH).nVisibility = Visibility.Visible
|
||||||
ParamList(10).nVisibility = Visibility.Visible
|
ParamList(ParamEnum.PANEL_J).nVisibility = Visibility.Visible
|
||||||
|
|
||||||
|
ParamList(ParamEnum.PARAG_BOTTOM).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_H).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_TH).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_DEPTH).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_TYPE).nVisibility = Visibility.Visible
|
||||||
|
DirectCast(ParamList(ParamEnum.BOTTOM_HOLE_TYPE), _ComboBoxParam).IndexSelParamCmBx = 0
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_X).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_Y).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_DIAM).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_DIMX).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_DIMY).nVisibility = Visibility.Visible
|
||||||
Map.refSceneHostVM.m_SelType = GDB_TY.CRV_LINE
|
Map.refSceneHostVM.m_SelType = GDB_TY.CRV_LINE
|
||||||
Else
|
ElseIf sType = EGT_SINK Then
|
||||||
ParamList(2).nVisibility = Visibility.Collapsed
|
DirectCast(Map.refSceneButtonVM.m_NewPanelUC, SceneUserControlV).Preview.Visibility = Visibility.Visible
|
||||||
ParamList(3).nVisibility = Visibility.Visible
|
|
||||||
ParamList(4).nVisibility = Visibility.Visible
|
DirectCast(ParamList(ParamEnum.PANEL_J), _ComboBoxParam).IndexSelParamCmBx = 2
|
||||||
ParamList(5).nVisibility = Visibility.Visible
|
ParamList(ParamEnum.PARAG_PANEL).nVisibility = Visibility.Visible
|
||||||
If DirectCast(Selection, ParamCmBx).Name = "Alzatina" Then
|
ParamList(ParamEnum.PANEL_H).nVisibility = Visibility.Visible
|
||||||
DirectCast(ParamList(5), _ComboBoxParam).IndexSelParamCmBx = 0
|
ParamList(ParamEnum.PANEL_TH).nVisibility = Visibility.Visible
|
||||||
ElseIf DirectCast(Selection, ParamCmBx).Name = "Frontalino" Then
|
ParamList(ParamEnum.PANEL_J).nVisibility = Visibility.Visible
|
||||||
DirectCast(ParamList(5), _ComboBoxParam).IndexSelParamCmBx = 2
|
|
||||||
|
ParamList(ParamEnum.PARAG_BOTTOM).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_H).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_TH).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_DEPTH).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_TYPE).nVisibility = Visibility.Visible
|
||||||
|
DirectCast(ParamList(ParamEnum.BOTTOM_HOLE_TYPE), _ComboBoxParam).IndexSelParamCmBx = 1
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_X).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_Y).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_DIAM).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_DIMX).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_DIMY).nVisibility = Visibility.Collapsed
|
||||||
|
Map.refSceneHostVM.m_SelType = GDB_TY.CRV_LINE
|
||||||
|
ElseIf sType = EGT_SPLASHTOP Or sType = EGT_WATERFALL Then
|
||||||
|
DirectCast(Map.refSceneButtonVM.m_NewPanelUC, SceneUserControlV).Preview.Visibility = Visibility.Hidden
|
||||||
|
|
||||||
|
ParamList(ParamEnum.PARAG_PANEL).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.PANEL_H).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.PANEL_TH).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.PANEL_J).nVisibility = Visibility.Visible
|
||||||
|
If DirectCast(Selection, ParamCmBx).Name = EGT_SPLASHTOP Then
|
||||||
|
DirectCast(ParamList(ParamEnum.PANEL_J), _ComboBoxParam).IndexSelParamCmBx = 0
|
||||||
|
ElseIf DirectCast(Selection, ParamCmBx).Name = EGT_WATERFALL Then
|
||||||
|
DirectCast(ParamList(ParamEnum.PANEL_J), _ComboBoxParam).IndexSelParamCmBx = 2
|
||||||
End If
|
End If
|
||||||
|
|
||||||
ParamList(6).nVisibility = Visibility.Collapsed
|
ParamList(ParamEnum.PARAG_BOTTOM).nVisibility = Visibility.Collapsed
|
||||||
ParamList(7).nVisibility = Visibility.Collapsed
|
ParamList(ParamEnum.BOTTOM_H).nVisibility = Visibility.Collapsed
|
||||||
ParamList(8).nVisibility = Visibility.Collapsed
|
ParamList(ParamEnum.BOTTOM_TH).nVisibility = Visibility.Collapsed
|
||||||
ParamList(9).nVisibility = Visibility.Collapsed
|
ParamList(ParamEnum.BOTTOM_DEPTH).nVisibility = Visibility.Collapsed
|
||||||
ParamList(10).nVisibility = Visibility.Collapsed
|
ParamList(ParamEnum.BOTTOM_HOLE_TYPE).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_X).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_Y).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_DIAM).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_DIMX).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_DIMY).nVisibility = Visibility.Collapsed
|
||||||
Map.refSceneHostVM.m_SelType = GDB_TY.CRV_LINE
|
Map.refSceneHostVM.m_SelType = GDB_TY.CRV_LINE
|
||||||
'DirectCast(Map.refSceneButtonV.m_PanelUC, SceneUserControlV).Preview.Visibility = Visibility.Hidden
|
ElseIf sType = EGT_BOTTOM Then
|
||||||
|
DirectCast(Map.refSceneButtonVM.m_NewPanelUC, SceneUserControlV).Preview.Visibility = Visibility.Visible
|
||||||
|
|
||||||
|
DirectCast(ParamList(ParamEnum.MSG_ISTRUZ), _TextBlockParam).MsgValue = TopBar_Msg_Bottom
|
||||||
|
ParamList(ParamEnum.PARAG_PANEL).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.PANEL_H).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.PANEL_TH).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.PANEL_J).nVisibility = Visibility.Collapsed
|
||||||
|
|
||||||
|
ParamList(ParamEnum.PARAG_BOTTOM).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_H).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_TH).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_DEPTH).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_TYPE).nVisibility = Visibility.Visible
|
||||||
|
DirectCast(ParamList(ParamEnum.BOTTOM_HOLE_TYPE), _ComboBoxParam).IndexSelParamCmBx = 1
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_X).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_Y).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_DIAM).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_DIMX).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_DIMY).nVisibility = Visibility.Collapsed
|
||||||
|
|
||||||
|
Map.refSceneHostVM.m_SelType = GDB_TY.SRF_MESH
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
|
||||||
|
If DirectCast(sender, _ComboBoxParam).Name = "TipoBuco" Then
|
||||||
|
Dim sType As String = DirectCast(Selection, ParamCmBx).Name
|
||||||
|
If sType = EGT_SLOT Then
|
||||||
|
ParamList(ParamEnum.BOTTOM_DIAM).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_DIMX).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_DIMY).nVisibility = Visibility.Visible
|
||||||
|
ElseIf sType = EGT_BORE Then
|
||||||
|
ParamList(ParamEnum.BOTTOM_DIAM).nVisibility = Visibility.Visible
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_DIMX).nVisibility = Visibility.Collapsed
|
||||||
|
ParamList(ParamEnum.BOTTOM_HOLE_DIMY).nVisibility = Visibility.Collapsed
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Public Overrides Sub Conferma()
|
Public Overrides Sub Conferma()
|
||||||
|
''debug
|
||||||
|
'DirectCast(ParamList(ParamEnum.PANEL_J), _ComboBoxParam).IndexSelParamCmBx = 2
|
||||||
|
'AddWaterfallAndSplitBottom(105)
|
||||||
|
''debug
|
||||||
|
|
||||||
' se sono in modalità fondello allora devo creare il pezzo
|
' se sono in modalità fondello allora devo creare il pezzo
|
||||||
If DirectCast(ParamList(1), _ComboBoxParam).SelParamCmBx.Name = "SplitBottom" Then
|
Dim sType As String = DirectCast(ParamList(ParamEnum.TY_PANEL), _ComboBoxParam).SelParamCmBx.Name
|
||||||
|
If sType = EGT_SPLITBOTTOM Then
|
||||||
AddSplitBottom(Map.refSceneHostVM.m_PanelPartList)
|
AddSplitBottom(Map.refSceneHostVM.m_PanelPartList)
|
||||||
|
ElseIf sType = EGT_BOTTOM Then
|
||||||
|
AddBottom(Map.refSceneHostVM.m_PanelPartList)
|
||||||
End If
|
End If
|
||||||
' resetto la lista dei part selezionati per la creazione di uno splitBottom
|
' resetto la lista dei part selezionati per la creazione di uno splitBottom
|
||||||
Map.refSceneHostVM.m_PanelPartList.Clear()
|
Map.refSceneHostVM.m_PanelPartList.Clear()
|
||||||
@@ -149,10 +272,14 @@ Public Class NewPanelVM
|
|||||||
Close()
|
Close()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
Public Overrides Sub ShowPreview()
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
|
||||||
Private Sub Close()
|
Private Sub Close()
|
||||||
SolidManagerM.ResetOperationMarks(Map.refSceneHostVM.m_nIdPart)
|
SolidManagerM.ResetOperationMarks(Map.refSceneHostVM.m_nIdPart)
|
||||||
EgtDraw()
|
EgtDraw()
|
||||||
Dim Btn As SceneBtn = Map.refSceneButtonVM.GetButton(EGT_PANEL)
|
Dim Btn As SceneBtn = Map.refSceneButtonVM.GetButton(EGT_ADD_PANEL)
|
||||||
If TypeOf (Btn) Is _ToggleButton Then
|
If TypeOf (Btn) Is _ToggleButton Then
|
||||||
DirectCast(Btn, _ToggleButton).IsChecked = False
|
DirectCast(Btn, _ToggleButton).IsChecked = False
|
||||||
Else
|
Else
|
||||||
@@ -167,18 +294,20 @@ Public Class NewPanelVM
|
|||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Public Sub AddPanel(nId As Integer)
|
Public Sub AddPanel(nId As Integer)
|
||||||
Dim ComboBoxParam As _ComboBoxParam = DirectCast(ParamList(1), _ComboBoxParam)
|
Dim ComboBoxParam As _ComboBoxParam = DirectCast(ParamList(ParamEnum.TY_PANEL), _ComboBoxParam)
|
||||||
If ComboBoxParam.SelParamCmBx.Name = "Alzatina" Then
|
If ComboBoxParam.SelParamCmBx.Name = EGT_SPLASHTOP Then
|
||||||
AddSplashTop(nId)
|
AddSplashTop(nId)
|
||||||
ElseIf ComboBoxParam.SelParamCmBx.Name = "Frontalino" Then
|
ElseIf ComboBoxParam.SelParamCmBx.Name = EGT_WATERFALL Then
|
||||||
AddWaterfall(nId)
|
AddWaterfall(nId)
|
||||||
ElseIf ComboBoxParam.SelParamCmBx.Name = "Tappa Buca" Then
|
ElseIf ComboBoxParam.SelParamCmBx.Name = EGT_SINK Then
|
||||||
AddWaterfallAndBottom(nId)
|
AddWaterfallAndBottom(nId)
|
||||||
|
ElseIf ComboBoxParam.SelParamCmBx.Name = EGT_SINK_SPLITBOTTOM Then
|
||||||
|
AddWaterfallAndSplitBottom(nId)
|
||||||
End If
|
End If
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Public Function GetPanelType()
|
Public Function GetPanelType()
|
||||||
Return DirectCast(ParamList(1), _ComboBoxParam).SelParamCmBx.Name
|
Return DirectCast(ParamList(ParamEnum.TY_PANEL), _ComboBoxParam).SelParamCmBx.Name
|
||||||
End Function
|
End Function
|
||||||
|
|
||||||
Private Sub AddSplashTop(nId As Integer)
|
Private Sub AddSplashTop(nId As Integer)
|
||||||
@@ -189,14 +318,14 @@ Public Class NewPanelVM
|
|||||||
' setto le variabili per l'alzatina
|
' setto le variabili per l'alzatina
|
||||||
Dim dAngAlzatina As Double = 90
|
Dim dAngAlzatina As Double = 90
|
||||||
If EgtLuaSetGlobNumVar("TOOL.dPairAng", dAngAlzatina) Then AssLog("TOOL.dPairAng = " & dAngAlzatina.ToString())
|
If EgtLuaSetGlobNumVar("TOOL.dPairAng", dAngAlzatina) Then AssLog("TOOL.dPairAng = " & dAngAlzatina.ToString())
|
||||||
Dim nJunctionType As Integer = DirectCast(ParamList(5), _ComboBoxParam).IndexSelParamCmBx + 1
|
Dim nJunctionType As Integer = DirectCast(ParamList(ParamEnum.PANEL_J), _ComboBoxParam).IndexSelParamCmBx + 1
|
||||||
If EgtLuaSetGlobIntVar("TOOL.nJunctionType", nJunctionType) Then AssLog("TOOL.nJunctionType = " & nJunctionType.ToString())
|
If EgtLuaSetGlobIntVar("TOOL.nJunctionType", nJunctionType) Then AssLog("TOOL.nJunctionType = " & nJunctionType.ToString())
|
||||||
Dim bOnLoop As Boolean = False
|
Dim bOnLoop As Boolean = False
|
||||||
If EgtLuaSetGlobBoolVar("TOOL.bOnLoop", bOnLoop) Then AssLog("TOOL.bOnLoop = false")
|
If EgtLuaSetGlobBoolVar("TOOL.bOnLoop", bOnLoop) Then AssLog("TOOL.bOnLoop = false")
|
||||||
Dim bInsideLoop As Boolean = True
|
Dim bInsideLoop As Boolean = True
|
||||||
If EgtLuaSetGlobBoolVar("TOOL.bInsideLoop", bInsideLoop) Then AssLog("TOOL.bInsideLoop = true")
|
If EgtLuaSetGlobBoolVar("TOOL.bInsideLoop", bInsideLoop) Then AssLog("TOOL.bInsideLoop = true")
|
||||||
' setto le varibili generiche per il pezzo
|
' setto le varibili generiche per il pezzo
|
||||||
Dim dTh As Double = DirectCast(ParamList(4), _TextBoxParam).GetValue()
|
Dim dTh As Double = DirectCast(ParamList(ParamEnum.PANEL_TH), _TextBoxParam).GetValue()
|
||||||
If EgtLuaSetGlobNumVar("TOOL.dTh", dTh) Then AssLog("TOOL.dTh = " & dTh.ToString())
|
If EgtLuaSetGlobNumVar("TOOL.dTh", dTh) Then AssLog("TOOL.dTh = " & dTh.ToString())
|
||||||
Dim dH As Double = DirectCast(ParamList(3), _TextBoxParam).GetValue()
|
Dim dH As Double = DirectCast(ParamList(3), _TextBoxParam).GetValue()
|
||||||
If EgtLuaSetGlobNumVar("TOOL.dH", dH) Then AssLog("TOOL.dH = " & dH.ToString())
|
If EgtLuaSetGlobNumVar("TOOL.dH", dH) Then AssLog("TOOL.dH = " & dH.ToString())
|
||||||
@@ -205,7 +334,7 @@ Public Class NewPanelVM
|
|||||||
' chiamo la funzione per la creazione
|
' chiamo la funzione per la creazione
|
||||||
If EgtLuaCallFunction("TOOL.CreateParetinaFull") Then AssLog("TOOL.CreateParetinaFull()")
|
If EgtLuaCallFunction("TOOL.CreateParetinaFull") Then AssLog("TOOL.CreateParetinaFull()")
|
||||||
End Sub
|
End Sub
|
||||||
Private Sub AddWaterfall(nId As Integer, Optional sInfoKey As String = "", Optional bInfoValue As Boolean = False)
|
Private Sub AddWaterfall(nId As Integer, Optional sInfoKey As String = "", Optional sInfoValue As String = "")
|
||||||
Dim nPartId As Integer = EgtGetParent(EgtGetParent(nId))
|
Dim nPartId As Integer = EgtGetParent(EgtGetParent(nId))
|
||||||
' setto l'indice del lato e il parent
|
' setto l'indice del lato e il parent
|
||||||
If EgtLuaSetGlobIntVar("TOOL.nEdgeId", nId) Then AssLog("TOOL.nEdgeId = " & nId.ToString())
|
If EgtLuaSetGlobIntVar("TOOL.nEdgeId", nId) Then AssLog("TOOL.nEdgeId = " & nId.ToString())
|
||||||
@@ -213,14 +342,14 @@ Public Class NewPanelVM
|
|||||||
' setto le variabili per il frontalino
|
' setto le variabili per il frontalino
|
||||||
Dim dAngFrontalino As Double = -90
|
Dim dAngFrontalino As Double = -90
|
||||||
If EgtLuaSetGlobNumVar("TOOL.dPairAng", dAngFrontalino) Then AssLog("TOOL.dPairAng = " & dAngFrontalino.ToString())
|
If EgtLuaSetGlobNumVar("TOOL.dPairAng", dAngFrontalino) Then AssLog("TOOL.dPairAng = " & dAngFrontalino.ToString())
|
||||||
Dim nJunctionType As Integer = DirectCast(ParamList(5), _ComboBoxParam).IndexSelParamCmBx + 1
|
Dim nJunctionType As Integer = DirectCast(ParamList(ParamEnum.PANEL_J), _ComboBoxParam).IndexSelParamCmBx + 1
|
||||||
If EgtLuaSetGlobIntVar("TOOL.nJunctionType", nJunctionType) Then AssLog("TOOL.nJunctionType = " & nJunctionType.ToString())
|
If EgtLuaSetGlobIntVar("TOOL.nJunctionType", nJunctionType) Then AssLog("TOOL.nJunctionType = " & nJunctionType.ToString())
|
||||||
Dim bOnLoop As Boolean = True
|
Dim bOnLoop As Boolean = True
|
||||||
If EgtLuaSetGlobBoolVar("TOOL.bOnLoop", bOnLoop) Then AssLog("TOOL.bOnLoop = false")
|
If EgtLuaSetGlobBoolVar("TOOL.bOnLoop", bOnLoop) Then AssLog("TOOL.bOnLoop = false")
|
||||||
Dim bInsideLoop As Boolean = True
|
Dim bInsideLoop As Boolean = True
|
||||||
If EgtLuaSetGlobBoolVar("TOOL.bInsideLoop", bInsideLoop) Then AssLog("TOOL.bInsideLoop = true")
|
If EgtLuaSetGlobBoolVar("TOOL.bInsideLoop", bInsideLoop) Then AssLog("TOOL.bInsideLoop = true")
|
||||||
' setto le varibili generiche per il pezzo
|
' setto le varibili generiche per il pezzo
|
||||||
Dim dTh As Double = DirectCast(ParamList(4), _TextBoxParam).GetValue()
|
Dim dTh As Double = DirectCast(ParamList(ParamEnum.PANEL_TH), _TextBoxParam).GetValue()
|
||||||
If EgtLuaSetGlobNumVar("TOOL.dTh", dTh) Then AssLog("TOOL.dTh = " & dTh.ToString())
|
If EgtLuaSetGlobNumVar("TOOL.dTh", dTh) Then AssLog("TOOL.dTh = " & dTh.ToString())
|
||||||
Dim dH As Double = DirectCast(ParamList(3), _TextBoxParam).GetValue()
|
Dim dH As Double = DirectCast(ParamList(3), _TextBoxParam).GetValue()
|
||||||
If EgtLuaSetGlobNumVar("TOOL.dH", dH) Then AssLog("TOOL.dH = " & dH.ToString())
|
If EgtLuaSetGlobNumVar("TOOL.dH", dH) Then AssLog("TOOL.dH = " & dH.ToString())
|
||||||
@@ -229,13 +358,13 @@ Public Class NewPanelVM
|
|||||||
' se presente setto l'info addizionale
|
' se presente setto l'info addizionale
|
||||||
If sInfoKey <> String.Empty Then
|
If sInfoKey <> String.Empty Then
|
||||||
If EgtLuaSetGlobStringVar("TOOL.tbInfo.InfoKey", sInfoKey) Then AssLog("TOOL.InfoKey = " & sInfoKey)
|
If EgtLuaSetGlobStringVar("TOOL.tbInfo.InfoKey", sInfoKey) Then AssLog("TOOL.InfoKey = " & sInfoKey)
|
||||||
If EgtLuaSetGlobBoolVar("TOOL.tbInfo.InfoValue", bInfoValue) Then AssLog("TOOL.InfoKey = " & (bInfoValue.ToString()).ToLower())
|
If EgtLuaSetGlobStringVar("TOOL.tbInfo.InfoValue", sInfoValue) Then AssLog("TOOL.sInfoValue = " & sInfoValue)
|
||||||
End If
|
End If
|
||||||
' chiamo la funzione per la creazione
|
' chiamo la funzione per la creazione
|
||||||
If EgtLuaCallFunction("TOOL.CreateParetinaFull") Then AssLog("TOOL.CreateParetinaFull()")
|
If EgtLuaCallFunction("TOOL.CreateParetinaFull") Then AssLog("TOOL.CreateParetinaFull()")
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub AddSplitBottom(PartList As List(Of Integer), Optional sInfoKey As String = "", Optional bInfoValue As Boolean = False)
|
Private Sub AddSplitBottom(PartList As List(Of Integer), Optional sInfoKey As String = "", Optional sInfoValue As String = "")
|
||||||
If PartList.Count = 0 Then
|
If PartList.Count = 0 Then
|
||||||
Close()
|
Close()
|
||||||
Return
|
Return
|
||||||
@@ -250,26 +379,70 @@ Public Class NewPanelVM
|
|||||||
For i As Integer = 1 To lEdgeList.Count
|
For i As Integer = 1 To lEdgeList.Count
|
||||||
EgtLuaSetGlobIntVar("TOOL.tbIdEdges." & i.ToString(), lEdgeList(i - 1).ToString())
|
EgtLuaSetGlobIntVar("TOOL.tbIdEdges." & i.ToString(), lEdgeList(i - 1).ToString())
|
||||||
Next
|
Next
|
||||||
Dim dTh As Double = DirectCast(ParamList(8), _TextBoxParam).GetValue()
|
Dim dTh As Double = DirectCast(ParamList(ParamEnum.BOTTOM_TH), _TextBoxParam).GetValue()
|
||||||
EgtLuaSetGlobNumVar("TOOL.dTh", dTh)
|
EgtLuaSetGlobNumVar("TOOL.dTh", dTh)
|
||||||
Dim dDiam As Double = DirectCast(ParamList(10), _TextBoxParam).GetValue()
|
Dim dDepth As Double = DirectCast(ParamList(ParamEnum.BOTTOM_DEPTH), _TextBoxParam).GetValue()
|
||||||
EgtLuaSetGlobNumVar("TOOL.dDiamBore", dDiam)
|
EgtLuaSetGlobNumVar("TOOL.dDepth", dDepth)
|
||||||
Dim dAng As Double = DirectCast(ParamList(9), _TextBoxParam).GetValue()
|
Dim dPosX As Double = DirectCast(ParamList(ParamEnum.BOTTOM_HOLE_X), _TextBoxParam).GetValue()
|
||||||
EgtLuaSetGlobNumVar("TOOL.dSlopeAng", dAng)
|
EgtLuaSetGlobNumVar("TOOL.dHoleX", dPosX)
|
||||||
|
Dim dPosY As Double = DirectCast(ParamList(ParamEnum.BOTTOM_HOLE_Y), _TextBoxParam).GetValue()
|
||||||
|
EgtLuaSetGlobNumVar("TOOL.dHoleY", dPosY)
|
||||||
|
Dim dDimX As Double = DirectCast(ParamList(ParamEnum.BOTTOM_HOLE_DIMX), _TextBoxParam).GetValue()
|
||||||
|
EgtLuaSetGlobNumVar("TOOL.dHoleDimX", dDimX)
|
||||||
|
Dim dDimY As Double = DirectCast(ParamList(ParamEnum.BOTTOM_HOLE_DIMY), _TextBoxParam).GetValue()
|
||||||
|
EgtLuaSetGlobNumVar("TOOL.dHoleDimY", dDimY)
|
||||||
' se presente setto l'info addizionale
|
' se presente setto l'info addizionale
|
||||||
If sInfoKey <> String.Empty Then
|
If sInfoKey <> String.Empty Then
|
||||||
If EgtLuaSetGlobStringVar("TOOL.tbInfo.InfoKey", sInfoKey) Then AssLog("TOOL.InfoKey = " & sInfoKey)
|
If EgtLuaSetGlobStringVar("TOOL.tbInfo.InfoKey", sInfoKey) Then AssLog("TOOL.InfoKey = " & sInfoKey)
|
||||||
If EgtLuaSetGlobBoolVar("TOOL.tbInfo.InfoValue", bInfoValue) Then AssLog("TOOL.InfoKey = " & (bInfoValue.ToString()).ToLower())
|
If EgtLuaSetGlobStringVar("TOOL.tbInfo.InfoValue", sInfoValue) Then AssLog("TOOL.InfoValue = " & sInfoValue)
|
||||||
End If
|
End If
|
||||||
EgtLuaCallFunction("TOOL.CreateSplitBottom")
|
EgtLuaCallFunction("TOOL.CreateSplitBottom")
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub AddWaterfallAndBottom(nId As Integer)
|
Private Sub AddBottom(PartList As List(Of Integer), Optional sInfoKey As String = "", Optional sInfoValue As String = "")
|
||||||
|
If PartList.Count = 0 Then
|
||||||
|
Close()
|
||||||
|
Return
|
||||||
|
End If
|
||||||
|
Dim lEdgeList As New List(Of Integer)
|
||||||
|
For Each nPart As Integer In PartList
|
||||||
|
Dim nOutLay As Integer = EgtGetFirstNameInGroup(nPart, "OutLoop")
|
||||||
|
Dim nEdge As Integer = EgtGetFirstNameInGroup(nOutLay, "A3")
|
||||||
|
lEdgeList.Add(nEdge)
|
||||||
|
Next
|
||||||
|
|
||||||
|
For i As Integer = 1 To lEdgeList.Count
|
||||||
|
EgtLuaSetGlobIntVar("TOOL.tbIdEdges." & i.ToString(), lEdgeList(i - 1).ToString())
|
||||||
|
Next
|
||||||
|
Dim dTh As Double = DirectCast(ParamList(ParamEnum.BOTTOM_TH), _TextBoxParam).GetValue()
|
||||||
|
EgtLuaSetGlobNumVar("TOOL.dTh", dTh)
|
||||||
|
Dim dDiam As Double = DirectCast(ParamList(ParamEnum.BOTTOM_DIAM), _TextBoxParam).GetValue()
|
||||||
|
If dDiam < 1 Then dDiam = 30
|
||||||
|
EgtLuaSetGlobNumVar("TOOL.dDiamBore", dDiam)
|
||||||
|
Dim dX As Double = DirectCast(ParamList(ParamEnum.BOTTOM_HOLE_X), _TextBoxParam).GetValue()
|
||||||
|
If dX < dDiam Then dX = dDiam + 10
|
||||||
|
EgtLuaSetGlobNumVar("TOOL.dHoleX", dX)
|
||||||
|
Dim dY As Double = DirectCast(ParamList(ParamEnum.BOTTOM_HOLE_Y), _TextBoxParam).GetValue()
|
||||||
|
If dY < dDiam Then dY = dDiam + 10
|
||||||
|
EgtLuaSetGlobNumVar("TOOL.dHoleY", dY)
|
||||||
|
' se presente setto l'info addizionale
|
||||||
|
If sInfoKey <> String.Empty Then
|
||||||
|
If EgtLuaSetGlobStringVar("TOOL.tbInfo.InfoKey", sInfoKey) Then AssLog("TOOL.InfoKey = " & sInfoKey)
|
||||||
|
If EgtLuaSetGlobStringVar("TOOL.tbInfo.InfoValue", sInfoValue) Then AssLog("TOOL.InfoKey = " & sInfoValue)
|
||||||
|
End If
|
||||||
|
EgtLuaCallFunction("TOOL.CreateBottom")
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub AddWaterfallAndBottom(nId)
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub AddWaterfallAndSplitBottom(nId As Integer)
|
||||||
Dim nInLoopLay As Integer = EgtGetParent(nId)
|
Dim nInLoopLay As Integer = EgtGetParent(nId)
|
||||||
Dim nEdges As Integer = EgtGetGroupObjs(nInLoopLay)
|
Dim nEdges As Integer = EgtGetGroupObjs(nInLoopLay)
|
||||||
Dim nEdge As Integer = EgtGetFirstInGroup(nInLoopLay)
|
Dim nEdge As Integer = EgtGetFirstInGroup(nInLoopLay)
|
||||||
While nEdge <> GDB_ID.NULL
|
While nEdge <> GDB_ID.NULL
|
||||||
AddWaterfall(nEdge, "Sink", True)
|
AddWaterfall(nEdge, "SinkSplitBottom", "1")
|
||||||
nEdge = EgtGetNext(nEdge)
|
nEdge = EgtGetNext(nEdge)
|
||||||
End While
|
End While
|
||||||
' recupero le info dei part creati come frontalini dalle info del Parent
|
' recupero le info dei part creati come frontalini dalle info del Parent
|
||||||
@@ -299,7 +472,7 @@ Public Class NewPanelVM
|
|||||||
WaterFallList.Add(EgtGetFirstNameInGroup(GDB_ID.ROOT, sPartName))
|
WaterFallList.Add(EgtGetFirstNameInGroup(GDB_ID.ROOT, sPartName))
|
||||||
Next
|
Next
|
||||||
' ora che ho la lista dei frontalini posso creare lo split bottom
|
' ora che ho la lista dei frontalini posso creare lo split bottom
|
||||||
AddSplitBottom(WaterFallList, "Sink", True)
|
AddSplitBottom(WaterFallList, "SinkSplitBottom", "1")
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
#End Region ' Methods
|
#End Region ' Methods
|
||||||
|
|||||||
@@ -1,4 +1,3 @@
|
|||||||
Imports EgtUILib.EgtInterface
|
Module PanelManagerM
|
||||||
Module PanelManagerM
|
|
||||||
|
|
||||||
End Module
|
End Module
|
||||||
|
|||||||
@@ -13,5 +13,8 @@
|
|||||||
<RadioButton Content="{Binding Parametrico_Msg}"
|
<RadioButton Content="{Binding Parametrico_Msg}"
|
||||||
Command="{Binding ParametricoCmd}"
|
Command="{Binding ParametricoCmd}"
|
||||||
Style="{StaticResource Parametrico_ToggleButton}"/>
|
Style="{StaticResource Parametrico_ToggleButton}"/>
|
||||||
|
<RadioButton Content="{Binding Office_Msg}"
|
||||||
|
Command="{Binding OfficeCmd}"
|
||||||
|
Style="{StaticResource Office_ToggleButton}"/>
|
||||||
|
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
|
|||||||
@@ -38,11 +38,18 @@ Public Class ProjManagerVM
|
|||||||
End Get
|
End Get
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
|
Public ReadOnly Property Office_Msg
|
||||||
|
Get
|
||||||
|
Return EgtMsg(110036).ToUpper() ' Office
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
#End Region ' Messages
|
#End Region ' Messages
|
||||||
|
|
||||||
' Definizione Comandi
|
' Definizione Comandi
|
||||||
Private m_HomeCmd As ICommand
|
Private m_HomeCmd As ICommand
|
||||||
Private m_ParametricoCmd As ICommand
|
Private m_ParametricoCmd As ICommand
|
||||||
|
Private m_OfficeCmd As ICommand
|
||||||
Private m_NewFileCmd As ICommand
|
Private m_NewFileCmd As ICommand
|
||||||
Private m_OpenFileCmd As ICommand
|
Private m_OpenFileCmd As ICommand
|
||||||
Private m_SaveFileCmd As ICommand
|
Private m_SaveFileCmd As ICommand
|
||||||
@@ -112,6 +119,23 @@ Public Class ProjManagerVM
|
|||||||
|
|
||||||
#End Region ' ParametricoCmd
|
#End Region ' ParametricoCmd
|
||||||
|
|
||||||
|
#Region "OfficeCmd"
|
||||||
|
|
||||||
|
Public ReadOnly Property OfficeCmd As ICommand
|
||||||
|
Get
|
||||||
|
If IsNothing(m_OfficeCmd) Then
|
||||||
|
m_OfficeCmd = New Command(AddressOf Office)
|
||||||
|
End If
|
||||||
|
Return m_OfficeCmd
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Private Sub Office()
|
||||||
|
Map.refTopPanelVM.SetSelTopOption(TopPanelVM.TopOption.OFFICE)
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
#End Region ' OfficeCmd
|
||||||
|
|
||||||
#Region "NewFileCmd"
|
#Region "NewFileCmd"
|
||||||
|
|
||||||
Public ReadOnly Property NewFileCmd As ICommand
|
Public ReadOnly Property NewFileCmd As ICommand
|
||||||
|
|||||||
+25
-1
@@ -83,6 +83,9 @@ Public Class RotateVM
|
|||||||
|
|
||||||
LoadParamList()
|
LoadParamList()
|
||||||
Stage = If(Map.refSceneHostVM.m_nIdPart = GDB_ID.NULL, RotateStage.SelectPart, RotateStage.SelectAxis)
|
Stage = If(Map.refSceneHostVM.m_nIdPart = GDB_ID.NULL, RotateStage.SelectPart, RotateStage.SelectAxis)
|
||||||
|
|
||||||
|
ActivateButton()
|
||||||
|
RemoveAllUC()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
#End Region ' Constructor
|
#End Region ' Constructor
|
||||||
@@ -90,7 +93,7 @@ Public Class RotateVM
|
|||||||
#Region "METHODS"
|
#Region "METHODS"
|
||||||
|
|
||||||
Public Overrides Sub LoadParamList()
|
Public Overrides Sub LoadParamList()
|
||||||
AddGenericParam(New _TextBlockParam("Messaggio", MsgList(Stage), ParamType.STR))
|
AddGenericParam(New _TextBlockParam(EGT_MESSAGE, MsgList(Stage), ParamType.STR))
|
||||||
' Angolo
|
' Angolo
|
||||||
AddGenericParam(New _TextBoxParam(EgtMsg(110006), 0, ParamType.DOUB, Visibility.Visible, False))
|
AddGenericParam(New _TextBoxParam(EgtMsg(110006), 0, ParamType.DOUB, Visibility.Visible, False))
|
||||||
End Sub
|
End Sub
|
||||||
@@ -178,6 +181,27 @@ Public Class RotateVM
|
|||||||
EgtDraw()
|
EgtDraw()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
Private Sub ActivateButton()
|
||||||
|
' Attivo pulsante Rotate
|
||||||
|
DirectCast(Map.refSceneButtonVM.GetButton(EGT_ROTATE), _ToggleButton).IsChecked = True
|
||||||
|
' Disattivo pulsante Pair
|
||||||
|
DirectCast(Map.refSceneButtonVM.GetButton(EGT_PAIR), _ToggleButton).IsChecked = False
|
||||||
|
' Disattivo pulsante Move
|
||||||
|
DirectCast(Map.refSceneButtonVM.GetButton(EGT_MOVE), _ToggleButton).IsChecked = False
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub RemoveAllUC()
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_AngleUC)
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_EditPanelUC)
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_EditParametricUC)
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_ExtremityUC)
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_LengthUC)
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_MoveUC)
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_NewPanelUC)
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_ParametricCompoUC)
|
||||||
|
Map.refSceneButtonVM.RemoveUC(Map.refSceneButtonVM.m_PairUC)
|
||||||
|
End Sub
|
||||||
|
|
||||||
#End Region ' Methods
|
#End Region ' Methods
|
||||||
|
|
||||||
End Class
|
End Class
|
||||||
|
|||||||
+1
-4
@@ -1,7 +1,4 @@
|
|||||||
Imports System.ComponentModel
|
Public Class SVGV
|
||||||
Imports System.Windows.Forms
|
|
||||||
|
|
||||||
Public Class SVGV
|
|
||||||
|
|
||||||
#Region "FIELDS & PROPERTIES"
|
#Region "FIELDS & PROPERTIES"
|
||||||
|
|
||||||
|
|||||||
@@ -14,6 +14,7 @@
|
|||||||
|
|
||||||
<!--TOP-->
|
<!--TOP-->
|
||||||
<ItemsControl ItemsSource="{Binding TopListBtn}"
|
<ItemsControl ItemsSource="{Binding TopListBtn}"
|
||||||
|
Visibility="Collapsed"
|
||||||
Style="{StaticResource TopList_ItemsControl}">
|
Style="{StaticResource TopList_ItemsControl}">
|
||||||
<ItemsControl.ItemsPanel>
|
<ItemsControl.ItemsPanel>
|
||||||
<ItemsPanelTemplate>
|
<ItemsPanelTemplate>
|
||||||
@@ -124,6 +125,7 @@
|
|||||||
|
|
||||||
<!--LEFT colonna 1-->
|
<!--LEFT colonna 1-->
|
||||||
<ItemsControl ItemsSource="{Binding LeftListBtn}"
|
<ItemsControl ItemsSource="{Binding LeftListBtn}"
|
||||||
|
Visibility="Collapsed"
|
||||||
Style="{StaticResource LeftList_ItemsControl}">
|
Style="{StaticResource LeftList_ItemsControl}">
|
||||||
<ItemsControl.ItemsPanel>
|
<ItemsControl.ItemsPanel>
|
||||||
<ItemsPanelTemplate>
|
<ItemsPanelTemplate>
|
||||||
|
|||||||
@@ -10,24 +10,16 @@
|
|||||||
Me.DataContext = Map.refSceneButtonVM
|
Me.DataContext = Map.refSceneButtonVM
|
||||||
SolidManagerM.ManageUndoRedo()
|
SolidManagerM.ManageUndoRedo()
|
||||||
Map.SetRefSceneButtonV(Me)
|
Map.SetRefSceneButtonV(Me)
|
||||||
AddHandler Me.Loaded, AddressOf SceneButtonV_Loaded
|
AddHandler Me.SizeChanged, AddressOf SceneButtonV_Sizing
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
#End Region ' Constructor
|
#End Region ' Constructor
|
||||||
|
|
||||||
#Region "METHODS"
|
|
||||||
|
|
||||||
Public Sub Sizing()
|
|
||||||
Me.Width = Map.refMainWindowV.ActualWidth
|
|
||||||
Me.Height = Map.refMainWindowV.ActualHeight
|
|
||||||
End Sub
|
|
||||||
|
|
||||||
#End Region ' Methods
|
|
||||||
|
|
||||||
#Region "Events"
|
#Region "Events"
|
||||||
|
|
||||||
Private Sub SceneButtonV_Loaded(sender As Object, e As RoutedEventArgs)
|
Public Sub SceneButtonV_Sizing()
|
||||||
Sizing()
|
Me.Width = Map.refMainWindowV.ActualWidth
|
||||||
|
Me.Height = Map.refMainWindowV.ActualHeight
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
#End Region ' Events
|
#End Region ' Events
|
||||||
|
|||||||
@@ -9,6 +9,8 @@ Public Class SceneButtonVM
|
|||||||
Public Shared m_nIndexList As Integer = 0
|
Public Shared m_nIndexList As Integer = 0
|
||||||
Public Shared m_nIndexList_1 As Integer = 0
|
Public Shared m_nIndexList_1 As Integer = 0
|
||||||
Public Shared m_nIndexList_2 As Integer = 0
|
Public Shared m_nIndexList_2 As Integer = 0
|
||||||
|
Public Shared m_nIndexList_3 As Integer = 0
|
||||||
|
Public Shared m_nIndexList_4 As Integer = 0
|
||||||
|
|
||||||
Public m_SelOptionUC As SelOptionV
|
Public m_SelOptionUC As SelOptionV
|
||||||
Public m_SceneUserControlV As SceneUserControlV
|
Public m_SceneUserControlV As SceneUserControlV
|
||||||
@@ -17,8 +19,11 @@ Public Class SceneButtonVM
|
|||||||
Public m_MoveUC As SceneUserControlV
|
Public m_MoveUC As SceneUserControlV
|
||||||
Public m_NewPanelUC As SceneUserControlV
|
Public m_NewPanelUC As SceneUserControlV
|
||||||
Public m_EditPanelUC As SceneUserControlV
|
Public m_EditPanelUC As SceneUserControlV
|
||||||
Public m_EditTopKUC As SceneUserControlV
|
Public m_EditParametricUC As SceneUserControlV
|
||||||
Public m_ParametricCompoUC As SceneUserControlV
|
Public m_ParametricCompoUC As SceneUserControlV
|
||||||
|
Public m_LengthUC As SceneUserControlV
|
||||||
|
Public m_AngleUC As SceneUserControlV
|
||||||
|
Public m_ExtremityUC As SceneUserControlV
|
||||||
|
|
||||||
Private m_TopListBtn As New List(Of SceneBtn)
|
Private m_TopListBtn As New List(Of SceneBtn)
|
||||||
Public Property TopListBtn As List(Of SceneBtn)
|
Public Property TopListBtn As List(Of SceneBtn)
|
||||||
@@ -90,6 +95,26 @@ Public Class SceneButtonVM
|
|||||||
End Set
|
End Set
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
|
Private m_InfoListBtn As New List(Of GroupSceneBtn)
|
||||||
|
Public Property InfoListBtn As List(Of GroupSceneBtn)
|
||||||
|
Get
|
||||||
|
Return m_InfoListBtn
|
||||||
|
End Get
|
||||||
|
Set(value As List(Of GroupSceneBtn))
|
||||||
|
m_InfoListBtn = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Private m_TopPanelOfficeListBtn As New List(Of GroupSceneBtn)
|
||||||
|
Public Property TopPanelOfficeListBtn As List(Of GroupSceneBtn)
|
||||||
|
Get
|
||||||
|
Return m_TopPanelOfficeListBtn
|
||||||
|
End Get
|
||||||
|
Set(value As List(Of GroupSceneBtn))
|
||||||
|
m_TopPanelOfficeListBtn = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
Friend Enum TopPanel As Integer
|
Friend Enum TopPanel As Integer
|
||||||
TOP_PANEL = 0
|
TOP_PANEL = 0
|
||||||
TOP_PANEL_1 = 1
|
TOP_PANEL_1 = 1
|
||||||
@@ -116,8 +141,7 @@ Public Class SceneButtonVM
|
|||||||
Sub New()
|
Sub New()
|
||||||
Map.SetRefSceneButtonVM(Me)
|
Map.SetRefSceneButtonVM(Me)
|
||||||
LoadButtons()
|
LoadButtons()
|
||||||
LoadGroupButtons(TOPPANELLIST_BTN, m_TopPanelListGroupBtn)
|
LoadListButtons()
|
||||||
LoadGroupButtons("ParametricListBtn", m_ParametricListGroupBtn)
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
#End Region ' Constructor
|
#End Region ' Constructor
|
||||||
@@ -135,6 +159,13 @@ Public Class SceneButtonVM
|
|||||||
SetButtonsLocation(BOTTOMCENTERLIST_BTN, m_BottomCenterListBtn)
|
SetButtonsLocation(BOTTOMCENTERLIST_BTN, m_BottomCenterListBtn)
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
Private Sub LoadListButtons()
|
||||||
|
LoadGroupButtons(TOPPANELLIST_BTN, m_TopPanelListGroupBtn)
|
||||||
|
LoadGroupButtons(PARAMETRICLIST_BTN, m_ParametricListGroupBtn)
|
||||||
|
LoadGroupButtons(INFOLLIST_BTN, m_InfoListBtn)
|
||||||
|
LoadGroupButtons(TOPPANELOFFICELIST_BTN, m_TopPanelOfficeListBtn)
|
||||||
|
End Sub
|
||||||
|
|
||||||
Private Sub LoadGroupButtons(NameList As String, GroupSceneBtnList As List(Of GroupSceneBtn))
|
Private Sub LoadGroupButtons(NameList As String, GroupSceneBtnList As List(Of GroupSceneBtn))
|
||||||
Dim Index As Integer = 1
|
Dim Index As Integer = 1
|
||||||
Dim SubTitle As String = String.Empty
|
Dim SubTitle As String = String.Empty
|
||||||
@@ -183,6 +214,9 @@ Public Class SceneButtonVM
|
|||||||
SetButtonsLocation(PositionList, LocalListSceneBtn)
|
SetButtonsLocation(PositionList, LocalListSceneBtn)
|
||||||
GetMainPrivateProfileString(PositionList, ConstEgtStone3D.SUBTITLE, "", SubTitle)
|
GetMainPrivateProfileString(PositionList, ConstEgtStone3D.SUBTITLE, "", SubTitle)
|
||||||
Title = SplitSubTitle(SubTitle)
|
Title = SplitSubTitle(SubTitle)
|
||||||
|
For Each ItemLocalList As SceneBtn In LocalListSceneBtn
|
||||||
|
ItemLocalList.Name = SplitSubTitle(ItemLocalList.Name)
|
||||||
|
Next
|
||||||
ListGroupBtn.Add(New GroupSceneBtn(LocalListSceneBtn, Title))
|
ListGroupBtn.Add(New GroupSceneBtn(LocalListSceneBtn, Title))
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
@@ -206,6 +240,12 @@ Public Class SceneButtonVM
|
|||||||
Btn = m_LeftListBtn.FirstOrDefault(Function(x) x.Flag = Flag)
|
Btn = m_LeftListBtn.FirstOrDefault(Function(x) x.Flag = Flag)
|
||||||
If Not IsNothing(Btn) Then Return Btn
|
If Not IsNothing(Btn) Then Return Btn
|
||||||
Btn = m_BottomCenterListBtn.FirstOrDefault(Function(x) x.Flag = Flag)
|
Btn = m_BottomCenterListBtn.FirstOrDefault(Function(x) x.Flag = Flag)
|
||||||
|
If IsNothing(Btn) Then
|
||||||
|
For Each ItemPanelList As GroupSceneBtn In m_TopPanelListGroupBtn
|
||||||
|
Btn = ItemPanelList.TopPanelListBtn.FirstOrDefault(Function(x) x.Flag = Flag)
|
||||||
|
If Not IsNothing(Btn) Then Exit For
|
||||||
|
Next
|
||||||
|
End If
|
||||||
Return Btn
|
Return Btn
|
||||||
End Function
|
End Function
|
||||||
|
|
||||||
@@ -214,8 +254,10 @@ Public Class SceneButtonVM
|
|||||||
For IndexTitle As Integer = 0 To subTitleList.Count - 1
|
For IndexTitle As Integer = 0 To subTitleList.Count - 1
|
||||||
If IsNumeric(subTitleList(IndexTitle)) AndAlso Not EgtMsg(subTitleList(IndexTitle)).StartsWith("Msg") Then
|
If IsNumeric(subTitleList(IndexTitle)) AndAlso Not EgtMsg(subTitleList(IndexTitle)).StartsWith("Msg") Then
|
||||||
Return EgtMsg(subTitleList(IndexTitle))
|
Return EgtMsg(subTitleList(IndexTitle))
|
||||||
Else
|
ElseIf IndexTitle > 1 Then
|
||||||
Return subTitleList(IndexTitle + 1)
|
Return subTitleList(IndexTitle + 1)
|
||||||
|
Else
|
||||||
|
Return subTitleList(IndexTitle)
|
||||||
End If
|
End If
|
||||||
Next
|
Next
|
||||||
Return String.Empty
|
Return String.Empty
|
||||||
@@ -231,12 +273,12 @@ Public Class SceneButtonVM
|
|||||||
If Not IsNothing(m_MoveUC) Then RemoveUC(m_MoveUC)
|
If Not IsNothing(m_MoveUC) Then RemoveUC(m_MoveUC)
|
||||||
If Not IsNothing(m_NewPanelUC) Then RemoveUC(m_NewPanelUC)
|
If Not IsNothing(m_NewPanelUC) Then RemoveUC(m_NewPanelUC)
|
||||||
If Not IsNothing(m_EditPanelUC) Then RemoveUC(m_EditPanelUC)
|
If Not IsNothing(m_EditPanelUC) Then RemoveUC(m_EditPanelUC)
|
||||||
If Not IsNothing(m_EditTopKUC) Then RemoveUC(m_EditTopKUC)
|
If Not IsNothing(m_EditParametricUC) Then RemoveUC(m_EditParametricUC)
|
||||||
If Not IsNothing(m_ParametricCompoUC) Then RemoveUC(m_ParametricCompoUC)
|
If Not IsNothing(m_ParametricCompoUC) Then RemoveUC(m_ParametricCompoUC)
|
||||||
Grid.SetColumn(SceneUC, 0)
|
Grid.SetColumn(SceneUC, 0)
|
||||||
Grid.SetRow(SceneUC, 0)
|
Grid.SetRow(SceneUC, 0)
|
||||||
Grid.SetColumnSpan(SceneUC, 2)
|
Grid.SetColumnSpan(SceneUC, 2)
|
||||||
Grid.SetRowSpan(SceneUC, 5)
|
Grid.SetRowSpan(SceneUC, 10)
|
||||||
Map.refSceneButtonV.MainGrid.Children.Add(SceneUC)
|
Map.refSceneButtonV.MainGrid.Children.Add(SceneUC)
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
@@ -468,6 +510,9 @@ Module SceneCmd
|
|||||||
Map.refSceneButtonVM.m_ParametricCompoUC.DataContext = LocalParametricCompo
|
Map.refSceneButtonVM.m_ParametricCompoUC.DataContext = LocalParametricCompo
|
||||||
Map.refSceneButtonVM.LoadUC(Map.refSceneButtonVM.m_ParametricCompoUC)
|
Map.refSceneButtonVM.LoadUC(Map.refSceneButtonVM.m_ParametricCompoUC)
|
||||||
bNewParametricExsists = True
|
bNewParametricExsists = True
|
||||||
|
SolidManagerM.CreatePartSolid()
|
||||||
|
Else
|
||||||
|
EgtOutLog("La chiamata del lua '" & Flag & "' non è andata a buon fine")
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
Return bNewParametricExsists
|
Return bNewParametricExsists
|
||||||
@@ -506,7 +551,9 @@ Module SceneCmd
|
|||||||
ImportLoop()
|
ImportLoop()
|
||||||
Case EGT_CREATE_SOLID_LOOP
|
Case EGT_CREATE_SOLID_LOOP
|
||||||
SolidManagerM.CreateSolidFromLoops(Map.refSceneHostVM.m_nIdPart)
|
SolidManagerM.CreateSolidFromLoops(Map.refSceneHostVM.m_nIdPart)
|
||||||
Case EGT_PANEL
|
Case EGT_CREATE_ALL_SOLIDS
|
||||||
|
SolidManagerM.CreateAllSolids()
|
||||||
|
Case EGT_ADD_PANEL
|
||||||
If IsNothing(Map.refSceneButtonVM.m_NewPanelUC) Then Map.refSceneButtonVM.m_NewPanelUC = New SceneUserControlV
|
If IsNothing(Map.refSceneButtonVM.m_NewPanelUC) Then Map.refSceneButtonVM.m_NewPanelUC = New SceneUserControlV
|
||||||
Map.refSceneButtonVM.m_NewPanelUC.DataContext = New NewPanelVM()
|
Map.refSceneButtonVM.m_NewPanelUC.DataContext = New NewPanelVM()
|
||||||
Map.refSceneButtonVM.LoadUC(Map.refSceneButtonVM.m_NewPanelUC)
|
Map.refSceneButtonVM.LoadUC(Map.refSceneButtonVM.m_NewPanelUC)
|
||||||
@@ -521,10 +568,22 @@ Module SceneCmd
|
|||||||
If IsNothing(Map.refSceneButtonVM.m_EditPanelUC) Then Map.refSceneButtonVM.m_EditPanelUC = New SceneUserControlV
|
If IsNothing(Map.refSceneButtonVM.m_EditPanelUC) Then Map.refSceneButtonVM.m_EditPanelUC = New SceneUserControlV
|
||||||
Map.refSceneButtonVM.m_EditPanelUC.DataContext = New EditPanelVM()
|
Map.refSceneButtonVM.m_EditPanelUC.DataContext = New EditPanelVM()
|
||||||
Map.refSceneButtonVM.LoadUC(Map.refSceneButtonVM.m_EditPanelUC)
|
Map.refSceneButtonVM.LoadUC(Map.refSceneButtonVM.m_EditPanelUC)
|
||||||
Case EGT_EDIT_TOPK
|
Case EGT_EDIT_PARAMETRIC
|
||||||
If IsNothing(Map.refSceneButtonVM.m_EditTopKUC) Then Map.refSceneButtonVM.m_EditTopKUC = New SceneUserControlV
|
If IsNothing(Map.refSceneButtonVM.m_EditParametricUC) Then Map.refSceneButtonVM.m_EditParametricUC = New SceneUserControlV
|
||||||
Map.refSceneButtonVM.m_EditTopKUC.DataContext = New EditTopKitchenVM()
|
Map.refSceneButtonVM.m_EditParametricUC.DataContext = New EditParametricVM()
|
||||||
Map.refSceneButtonVM.LoadUC(Map.refSceneButtonVM.m_EditTopKUC)
|
Map.refSceneButtonVM.LoadUC(Map.refSceneButtonVM.m_EditParametricUC)
|
||||||
|
Case EGT_LENGHT
|
||||||
|
If IsNothing(Map.refSceneButtonVM.m_LengthUC) Then Map.refSceneButtonVM.m_LengthUC = New SceneUserControlV
|
||||||
|
Map.refSceneButtonVM.m_LengthUC.DataContext = New LengthVM()
|
||||||
|
Map.refSceneButtonVM.LoadUC(Map.refSceneButtonVM.m_LengthUC)
|
||||||
|
Case EGT_ANGLE
|
||||||
|
If IsNothing(Map.refSceneButtonVM.m_AngleUC) Then Map.refSceneButtonVM.m_AngleUC = New SceneUserControlV
|
||||||
|
Map.refSceneButtonVM.m_AngleUC.DataContext = New AngleVM()
|
||||||
|
Map.refSceneButtonVM.LoadUC(Map.refSceneButtonVM.m_AngleUC)
|
||||||
|
Case EGT_EXTREMITY
|
||||||
|
If IsNothing(Map.refSceneButtonVM.m_ExtremityUC) Then Map.refSceneButtonVM.m_ExtremityUC = New SceneUserControlV
|
||||||
|
Map.refSceneButtonVM.m_ExtremityUC.DataContext = New ExtremityVM()
|
||||||
|
Map.refSceneButtonVM.LoadUC(Map.refSceneButtonVM.m_ExtremityUC)
|
||||||
Case Else
|
Case Else
|
||||||
EgtOutLog("La chiamata del metodo '" & Flag & "' non è andata a buon fine")
|
EgtOutLog("La chiamata del metodo '" & Flag & "' non è andata a buon fine")
|
||||||
bNewMethodsExsists = False
|
bNewMethodsExsists = False
|
||||||
|
|||||||
@@ -462,7 +462,7 @@ Public Class MySceneHostVM
|
|||||||
UpdateUI(Me, False)
|
UpdateUI(Me, False)
|
||||||
Cursor.Current = Cursors.Default
|
Cursor.Current = Cursors.Default
|
||||||
' Result handling
|
' Result handling
|
||||||
Map.refSceneHostVM.OnSavedProject(Me, sCurrFile, bOk)
|
If EgtGetFileType(sCurrFile) <> FT.LUA Then Map.refSceneHostVM.OnSavedProject(Me, sCurrFile, bOk)
|
||||||
Return bOk
|
Return bOk
|
||||||
End If
|
End If
|
||||||
End Function
|
End Function
|
||||||
@@ -965,13 +965,14 @@ Line1:
|
|||||||
Continue While
|
Continue While
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If Map.refSceneButtonVM.IsTgBtnChecked(EGT_PANEL) Then
|
If Map.refSceneButtonVM.IsTgBtnChecked(EGT_ADD_PANEL) Then
|
||||||
Dim sPanelType = DirectCast(Map.refSceneButtonVM.m_NewPanelUC.DataContext, NewPanelVM).GetPanelType()
|
Dim sPanelType = DirectCast(Map.refSceneButtonVM.m_NewPanelUC.DataContext, NewPanelVM).GetPanelType()
|
||||||
If sPanelType = "Alzatina" Or sPanelType = "Frontalino" Or sPanelType = "Tappa Buca" Then
|
If sPanelType = EGT_SPLASHTOP Or sPanelType = EGT_WATERFALL Or sPanelType = EGT_SINK Or sPanelType = EGT_SINK_SPLITBOTTOM Then
|
||||||
If EgtGetType(nId) = GDB_TY.CRV_LINE Then
|
If EgtGetType(nId) = GDB_TY.CRV_LINE Then
|
||||||
Dim sLayName As String = String.Empty
|
Dim sLayName As String = String.Empty
|
||||||
EgtGetName(EgtGetParent(nId), sLayName)
|
EgtGetName(EgtGetParent(nId), sLayName)
|
||||||
If sPanelType = "Alzatina" Or sPanelType = "Frontalino" Or (sPanelType = "Tappa Buca" And sLayName = "InLoop") Then
|
If sPanelType = EGT_SPLASHTOP Or sPanelType = EGT_WATERFALL Or
|
||||||
|
((sPanelType = EGT_SINK Or sPanelType = EGT_SINK_SPLITBOTTOM) And sLayName = "InLoop") Then
|
||||||
Dim sEdgeName As String = String.Empty
|
Dim sEdgeName As String = String.Empty
|
||||||
EgtGetName(nId, sEdgeName)
|
EgtGetName(nId, sEdgeName)
|
||||||
If sEdgeName.Length > 0 Then
|
If sEdgeName.Length > 0 Then
|
||||||
@@ -983,7 +984,7 @@ Line1:
|
|||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
ElseIf sPanelType = "SplitBottom" Then
|
ElseIf sPanelType = EGT_SPLITBOTTOM Or sPanelType = EGT_BOTTOM Then
|
||||||
Dim nPanelPart As Integer = nPartId
|
Dim nPanelPart As Integer = nPartId
|
||||||
If sName = "SOLID" Then
|
If sName = "SOLID" Then
|
||||||
EgtGetInfo(nPartId, "Parent", nPanelPart)
|
EgtGetInfo(nPartId, "Parent", nPanelPart)
|
||||||
@@ -1007,9 +1008,54 @@ Line1:
|
|||||||
End If
|
End If
|
||||||
|
|
||||||
If Map.refSceneButtonVM.IsTgBtnChecked(EGT_EDIT_PANEL) Then
|
If Map.refSceneButtonVM.IsTgBtnChecked(EGT_EDIT_PANEL) Then
|
||||||
Dim PartSolidId As Integer = nPartId
|
Dim PartSolidSel As PartSolidM = SolidManagerM.GetPartSolid(nPartId)
|
||||||
If sName = "SOLID" Then EgtGetInfo(nPartId, "Parent", PartSolidId)
|
DirectCast(Map.refSceneButtonVM.m_EditPanelUC.DataContext, EditPanelVM).nIdPart = PartSolidSel.PartId
|
||||||
DirectCast(Map.refSceneButtonVM.m_EditPanelUC.DataContext, EditPanelVM).nIdPart = PartSolidId
|
End If
|
||||||
|
|
||||||
|
If Map.refSceneButtonVM.IsTgBtnChecked(EGT_EDIT_PARAMETRIC) Then
|
||||||
|
If EgtGetType(nId) = GDB_TY.CRV_LINE Or EgtGetType(nId) = GDB_TY.CRV_COMPO Or EgtGetType(nId) = GDB_TY.CRV_ARC Then
|
||||||
|
Dim refEditParametricVM As EditParametricVM = DirectCast(Map.refSceneButtonVM.m_EditParametricUC.DataContext, EditParametricVM)
|
||||||
|
' recupero la sottocurva e il punto selezionato sulla curva
|
||||||
|
Dim nSubCurve As Integer = GDB_ID.NULL
|
||||||
|
Dim ptSelected As New Point3d
|
||||||
|
EgtGetPointFromSelect(nId, e.Location, ptSelected, nSubCurve)
|
||||||
|
Dim ptOnCurve As New Point3d
|
||||||
|
EgtNearPoint(nId, ptSelected, ptOnCurve)
|
||||||
|
Dim ptStart As New Point3d
|
||||||
|
Dim ptEnd As New Point3d
|
||||||
|
EgtAtParamPoint(nId, nSubCurve, GDB_RT.GLOB, ptStart)
|
||||||
|
EgtAtParamPoint(nId, nSubCurve + 1, GDB_RT.GLOB, ptEnd)
|
||||||
|
Dim dU As Double = 0
|
||||||
|
If Point3d.Dist(ptStart, ptOnCurve) <= Point3d.Dist(ptEnd, ptOnCurve) Then
|
||||||
|
ptOnCurve = ptStart
|
||||||
|
dU = nSubCurve
|
||||||
|
Else
|
||||||
|
ptOnCurve = ptEnd
|
||||||
|
dU = nSubCurve + 1
|
||||||
|
End If
|
||||||
|
' al primo passaggio seleziono un punto della prima linea
|
||||||
|
If refEditParametricVM.nId1 = GDB_ID.NULL Or refEditParametricVM.nId1 = nId Then
|
||||||
|
' salvo l'id della linea
|
||||||
|
refEditParametricVM.nId1 = nId
|
||||||
|
refEditParametricVM.dUFirst = dU
|
||||||
|
refEditParametricVM.FirstPoint = ptOnCurve
|
||||||
|
refEditParametricVM.nSubCrv1 = nSubCurve
|
||||||
|
refEditParametricVM.ShowFirstCurrPoint()
|
||||||
|
' al secondo passaggio selezion il punto sulla seconda linea
|
||||||
|
ElseIf refEditParametricVM.nId2 = GDB_ID.NULL Or refEditParametricVM.nId2 = nId Then
|
||||||
|
' salvo l'id della linea
|
||||||
|
refEditParametricVM.nId2 = nId
|
||||||
|
refEditParametricVM.dUSecond = dU
|
||||||
|
refEditParametricVM.SecondPoint = ptOnCurve
|
||||||
|
refEditParametricVM.nSubCrv2 = nSubCurve
|
||||||
|
refEditParametricVM.ShowSecondCurrPoint()
|
||||||
|
End If
|
||||||
|
ElseIf EgtGetType(nId) = GDB_TY.EXT_DIMENSION Then
|
||||||
|
' Modifico la lunghezza del segemnto
|
||||||
|
End If
|
||||||
|
' passo al prossimo id
|
||||||
|
nId = EgtGetNextObjInSelWin()
|
||||||
|
Continue While
|
||||||
End If
|
End If
|
||||||
|
|
||||||
' selezione semplice
|
' selezione semplice
|
||||||
@@ -1124,7 +1170,6 @@ Line1:
|
|||||||
Else
|
Else
|
||||||
PartSolidIdToSel.SelectPart()
|
PartSolidIdToSel.SelectPart()
|
||||||
End If
|
End If
|
||||||
|
|
||||||
'End If
|
'End If
|
||||||
' Se deselezione da eseguire
|
' Se deselezione da eseguire
|
||||||
ElseIf m_nIdToDesel <> GDB_ID.NULL Then
|
ElseIf m_nIdToDesel <> GDB_ID.NULL Then
|
||||||
|
|||||||
@@ -104,6 +104,12 @@ Public Class SceneUserControlVM
|
|||||||
m_Color_Timer.Start()
|
m_Color_Timer.Start()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
Public Sub LoadEditParametric()
|
||||||
|
If IsNothing(Map.refSceneButtonVM.m_EditParametricUC) Then Map.refSceneButtonVM.m_EditParametricUC = New SceneUserControlV
|
||||||
|
Map.refSceneButtonVM.m_EditParametricUC.DataContext = New EditParametricVM()
|
||||||
|
Map.refSceneButtonVM.LoadUC(Map.refSceneButtonVM.m_EditParametricUC)
|
||||||
|
End Sub
|
||||||
|
|
||||||
#End Region ' Methods
|
#End Region ' Methods
|
||||||
|
|
||||||
#Region "EVENTS"
|
#Region "EVENTS"
|
||||||
@@ -174,6 +180,8 @@ Public Class SceneUserControlVM
|
|||||||
|
|
||||||
End Class
|
End Class
|
||||||
|
|
||||||
|
' ------------------------------ _GENERICPARAM ------------------------------
|
||||||
|
|
||||||
Public Class GenericParam
|
Public Class GenericParam
|
||||||
Inherits VMBase
|
Inherits VMBase
|
||||||
|
|
||||||
@@ -245,6 +253,8 @@ Public Class GenericParam
|
|||||||
|
|
||||||
End Class
|
End Class
|
||||||
|
|
||||||
|
' ------------------------------ _TEXTBOX ------------------------------
|
||||||
|
|
||||||
Public Class _TextBoxParam
|
Public Class _TextBoxParam
|
||||||
Inherits GenericParam
|
Inherits GenericParam
|
||||||
|
|
||||||
@@ -287,6 +297,8 @@ Public Class _TextBoxParam
|
|||||||
|
|
||||||
End Class
|
End Class
|
||||||
|
|
||||||
|
' ------------------------------ _TEXTBLOCK ------------------------------
|
||||||
|
|
||||||
Public Class _TextBlockParam
|
Public Class _TextBlockParam
|
||||||
Inherits GenericParam
|
Inherits GenericParam
|
||||||
|
|
||||||
@@ -327,6 +339,8 @@ Public Class _TextBlockParam
|
|||||||
|
|
||||||
End Class
|
End Class
|
||||||
|
|
||||||
|
' ------------------------------ _COMBOBOX ------------------------------
|
||||||
|
|
||||||
Public Class _ComboBoxParam
|
Public Class _ComboBoxParam
|
||||||
Inherits GenericParam
|
Inherits GenericParam
|
||||||
|
|
||||||
@@ -410,6 +424,8 @@ Public Class ParamCmBx
|
|||||||
|
|
||||||
End Class
|
End Class
|
||||||
|
|
||||||
|
' ------------------------------ _CHECKBOX ------------------------------
|
||||||
|
|
||||||
Public Class _CheckBoxParam
|
Public Class _CheckBoxParam
|
||||||
Inherits GenericParam
|
Inherits GenericParam
|
||||||
|
|
||||||
|
|||||||
@@ -7,6 +7,8 @@
|
|||||||
Icon="/Resources/EgalwareLogo.ico"
|
Icon="/Resources/EgalwareLogo.ico"
|
||||||
WindowStartupLocation="CenterOwner"
|
WindowStartupLocation="CenterOwner"
|
||||||
PreviewKeyDown="EgtMainWindow_PreviewKeyDown"
|
PreviewKeyDown="EgtMainWindow_PreviewKeyDown"
|
||||||
|
xmlns:AVALON="http://icsharpcode.net/sharpdevelop/avalonedit"
|
||||||
|
xmlns:EgtSTONE3D="clr-namespace:EgtStone3D"
|
||||||
Style="{StaticResource ScriptWindowV_Window}">
|
Style="{StaticResource ScriptWindowV_Window}">
|
||||||
<Grid>
|
<Grid>
|
||||||
<Grid.RowDefinitions>
|
<Grid.RowDefinitions>
|
||||||
@@ -26,26 +28,6 @@
|
|||||||
<ComboBox ItemsSource="{Binding FontSizeList}"
|
<ComboBox ItemsSource="{Binding FontSizeList}"
|
||||||
SelectedItem="{Binding SelFontSize}"
|
SelectedItem="{Binding SelFontSize}"
|
||||||
Style="{StaticResource ScriptWindow_CmBx}"/>
|
Style="{StaticResource ScriptWindow_CmBx}"/>
|
||||||
<Button Content="CT"
|
|
||||||
Command="ApplicationCommands.Cut"
|
|
||||||
CommandTarget="{Binding ElementName=sNameFile_RichTxBx}"
|
|
||||||
Style="{StaticResource ScriptWindow_Btn}"/>
|
|
||||||
<Button Content="CP"
|
|
||||||
Command="ApplicationCommands.Copy"
|
|
||||||
CommandTarget="{Binding ElementName=sNameFile_RichTxBx}"
|
|
||||||
Style="{StaticResource ScriptWindow_Btn}"/>
|
|
||||||
<Button Content="P"
|
|
||||||
Command="ApplicationCommands.Paste"
|
|
||||||
CommandTarget="{Binding ElementName=sNameFile_RichTxBx}"
|
|
||||||
Style="{StaticResource ScriptWindow_Btn}"/>
|
|
||||||
<Button Content="U"
|
|
||||||
Command="ApplicationCommands.Undo"
|
|
||||||
CommandTarget="{Binding ElementName=sNameFile_RichTxBx}"
|
|
||||||
Style="{StaticResource ScriptWindow_Btn}"/>
|
|
||||||
<Button Content="R"
|
|
||||||
Command="ApplicationCommands.Redo"
|
|
||||||
CommandTarget="{Binding ElementName=sNameFile_RichTxBx}"
|
|
||||||
Style="{StaticResource ScriptWindowEnd_Btn}"/>
|
|
||||||
|
|
||||||
<Separator Style="{StaticResource Script_Separator}"/>
|
<Separator Style="{StaticResource Script_Separator}"/>
|
||||||
|
|
||||||
@@ -56,72 +38,26 @@
|
|||||||
<Separator Style="{StaticResource Script_Separator}"/>
|
<Separator Style="{StaticResource Script_Separator}"/>
|
||||||
|
|
||||||
<ToggleButton Content="B"
|
<ToggleButton Content="B"
|
||||||
Command="EditingCommands.ToggleBold"
|
Command="{Binding BoldCmd}"
|
||||||
CommandTarget="{Binding ElementName=sNameFile_RichTxBx}"
|
|
||||||
IsChecked="{Binding BoldIsChecked}"
|
IsChecked="{Binding BoldIsChecked}"
|
||||||
Style="{StaticResource General_ToogleButton}"/>
|
Style="{StaticResource General_ToogleButton}"/>
|
||||||
<ToggleButton Content="IT"
|
<ToggleButton Content="IT"
|
||||||
Command="EditingCommands.ToggleItalic"
|
Command="{Binding ItalicCmd}"
|
||||||
CommandTarget="{Binding ElementName=sNameFile_RichTxBx}"
|
|
||||||
IsChecked="{Binding ItalicIsChecked}"
|
IsChecked="{Binding ItalicIsChecked}"
|
||||||
Style="{StaticResource General_ToogleButton}"/>
|
Style="{StaticResource General_ToogleButton}"/>
|
||||||
<ToggleButton Content="U"
|
<ToggleButton Content="U"
|
||||||
Command="EditingCommands.ToggleUnderline"
|
Command="{Binding UnderlineCmd}"
|
||||||
CommandTarget="{Binding ElementName=sNameFile_RichTxBx}"
|
|
||||||
IsChecked="{Binding UnderlineChecked}"
|
IsChecked="{Binding UnderlineChecked}"
|
||||||
Style="{StaticResource General_ToogleButton}"/>
|
Style="{StaticResource General_ToogleButton}"/>
|
||||||
|
|
||||||
<Separator Style="{StaticResource Script_Separator}"/>
|
<Separator Style="{StaticResource Script_Separator}"/>
|
||||||
|
|
||||||
<ToggleButton Command="EditingCommands.AlignLeft"
|
|
||||||
CommandTarget="{Binding ElementName=sNameFile_RichTxBx}"
|
|
||||||
IsChecked="{Binding LeftIsChecked}"
|
|
||||||
Style="{StaticResource ScriptToggleButton}">
|
|
||||||
<EgtStone3D:SVGV FileSource="{Binding FileAlignLeftSVG, UpdateSourceTrigger=PropertyChanged}"/>
|
|
||||||
</ToggleButton>
|
|
||||||
<ToggleButton Command="EditingCommands.AlignCenter"
|
|
||||||
CommandTarget="{Binding ElementName=sNameFile_RichTxBx}"
|
|
||||||
IsChecked="{Binding CenterIsChecked}"
|
|
||||||
Style="{StaticResource ScriptToggleButton1}">
|
|
||||||
<EgtStone3D:SVGV FileSource="{Binding FileAlignCenterSVG, UpdateSourceTrigger=PropertyChanged}"/>
|
|
||||||
</ToggleButton>
|
|
||||||
<ToggleButton Command="EditingCommands.AlignJustify"
|
|
||||||
CommandTarget="{Binding ElementName=sNameFile_RichTxBx}"
|
|
||||||
IsChecked="{Binding JustifyIsChecked}"
|
|
||||||
Style="{StaticResource ScriptToggleButton1}">
|
|
||||||
<EgtStone3D:SVGV FileSource="{Binding FileAlignJustifySVG, UpdateSourceTrigger=PropertyChanged}"/>
|
|
||||||
</ToggleButton>
|
|
||||||
|
|
||||||
<Separator Style="{StaticResource Script_Separator}"/>
|
|
||||||
|
|
||||||
<Button Content="II"
|
|
||||||
Command="EditingCommands.IncreaseIndentation"
|
|
||||||
CommandTarget="{Binding ElementName=sNameFile_RichTxBx}"
|
|
||||||
Style="{StaticResource ScriptWindow_Btn}"/>
|
|
||||||
<Button Content="DE"
|
|
||||||
Command="EditingCommands.DecreaseIndentation"
|
|
||||||
CommandTarget="{Binding ElementName=sNameFile_RichTxBx}"
|
|
||||||
Style="{StaticResource ScriptWindowEnd_Btn}"/>
|
|
||||||
</WrapPanel>
|
</WrapPanel>
|
||||||
|
|
||||||
</Border>
|
</Border>
|
||||||
<!--<TextBox Grid.Row="1"
|
<AVALON:TextEditor Grid.Row="2"
|
||||||
Height="300"
|
Name="LuaEditor"
|
||||||
AcceptsReturn="True"
|
TextChanged="LuaEditor_TextChanged"
|
||||||
TextWrapping="Wrap"
|
EgtSTONE3D:TextEditorHelper.Text="{Binding sScriptText}"
|
||||||
Text="{Binding sRichTextParagraph}"
|
Style="{StaticResource ScriptTextEditor}"/>
|
||||||
Style="{StaticResource Script_TxBx}"/>-->
|
|
||||||
<RichTextBox Grid.Row="2"
|
|
||||||
Name="sNameFile_RichTxBx"
|
|
||||||
TextChanged="sNameFile_RichTxBx_TextChanged"
|
|
||||||
PreviewKeyDown="sNameFile_RichTxBx_PreviewKeyDown"
|
|
||||||
Style="{StaticResource Script_RichTxBx}">
|
|
||||||
<FlowDocument Name="FDocumentFile">
|
|
||||||
<Paragraph>
|
|
||||||
<Run Text="{Binding sRichTextParagraph, Mode=TwoWay}"/>
|
|
||||||
</Paragraph>
|
|
||||||
</FlowDocument>
|
|
||||||
</RichTextBox>
|
|
||||||
<Grid Grid.Row="3"
|
<Grid Grid.Row="3"
|
||||||
Style="{StaticResource SceneUserControl_Grid}">
|
Style="{StaticResource SceneUserControl_Grid}">
|
||||||
<Grid.ColumnDefinitions>
|
<Grid.ColumnDefinitions>
|
||||||
|
|||||||
@@ -1,4 +1,6 @@
|
|||||||
Public Class ScriptWindowV
|
Imports ICSharpCode.AvalonEdit
|
||||||
|
|
||||||
|
Public Class ScriptWindowV
|
||||||
|
|
||||||
#Region "CONSTRUCTOR"
|
#Region "CONSTRUCTOR"
|
||||||
|
|
||||||
@@ -21,18 +23,75 @@
|
|||||||
End If
|
End If
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub sNameFile_RichTxBx_TextChanged(sender As Object, e As TextChangedEventArgs)
|
Private Sub LuaEditor_TextChanged(sender As Object, e As EventArgs)
|
||||||
Map.refScriptWindowVM.ChangeTextColor()
|
Map.refScriptWindowVM.SetColorScriptText()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub sNameFile_RichTxBx_SelectionChanged(sender As Object, e As RoutedEventArgs)
|
#End Region ' Events
|
||||||
If Not IsNothing(Map.refScriptWindowVM) Then Map.refScriptWindowVM.SetToolbar()
|
|
||||||
|
End Class
|
||||||
|
|
||||||
|
Public Class TextEditorHelper
|
||||||
|
|
||||||
|
#Region "FIELDS & PROPERTIES"
|
||||||
|
|
||||||
|
' Registra la proprietà di dipendenza
|
||||||
|
Public Shared ReadOnly TextProperty As DependencyProperty = DependencyProperty.RegisterAttached(
|
||||||
|
"Text",
|
||||||
|
GetType(String),
|
||||||
|
GetType(TextEditorHelper),
|
||||||
|
New FrameworkPropertyMetadata(Nothing, FrameworkPropertyMetadataOptions.BindsTwoWayByDefault, AddressOf OnTextChanged)
|
||||||
|
)
|
||||||
|
|
||||||
|
#End Region ' Fields & Properties
|
||||||
|
|
||||||
|
#Region "METHODS"
|
||||||
|
|
||||||
|
' Getter per la proprietà
|
||||||
|
Public Shared Function GetText(editor As TextEditor) As String
|
||||||
|
Return CType(editor.GetValue(TextProperty), String)
|
||||||
|
End Function
|
||||||
|
|
||||||
|
' Setter per la proprietà
|
||||||
|
Public Shared Sub SetText(editor As TextEditor, value As String)
|
||||||
|
editor.SetValue(TextProperty, value)
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub sNameFile_RichTxBx_PreviewKeyDown(sender As Object, e As KeyEventArgs)
|
#End Region ' Methods
|
||||||
If e.Key = Key.Enter Then
|
|
||||||
Map.refScriptWindowVM.InsertText(sNameFile_RichTxBx, vbCrLf)
|
#Region "EVENTS"
|
||||||
e.Handled = True
|
|
||||||
|
' Callback per quando cambia la proprietà
|
||||||
|
Private Shared Sub OnTextChanged(d As DependencyObject, e As DependencyPropertyChangedEventArgs)
|
||||||
|
Dim editor = TryCast(d, TextEditor)
|
||||||
|
If editor IsNot Nothing Then
|
||||||
|
' Rimuovi temporaneamente l'evento TextChanged
|
||||||
|
RemoveHandler editor.TextChanged, AddressOf EditorTextChanged
|
||||||
|
|
||||||
|
' Usa editor.Document per modificare il testo in modo sicuro
|
||||||
|
editor.BeginChange()
|
||||||
|
Try
|
||||||
|
Dim newText As String = If(e.NewValue, String.Empty).ToString()
|
||||||
|
If editor.Document.Text <> newText Then
|
||||||
|
editor.Document.Text = newText
|
||||||
|
End If
|
||||||
|
Finally
|
||||||
|
editor.EndChange() ' Conclude l'operazione di modifica
|
||||||
|
End Try
|
||||||
|
|
||||||
|
' Riattacca l'evento TextChanged
|
||||||
|
AddHandler editor.TextChanged, AddressOf EditorTextChanged
|
||||||
|
End If
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
' Evento per aggiornare la proprietà di dipendenza quando il testo cambia
|
||||||
|
Private Shared Sub EditorTextChanged(sender As Object, e As EventArgs)
|
||||||
|
Dim editor = TryCast(sender, TextEditor)
|
||||||
|
If editor IsNot Nothing Then
|
||||||
|
Dim currentText = GetText(editor)
|
||||||
|
If editor.Document.Text <> currentText Then
|
||||||
|
SetText(editor, editor.Document.Text)
|
||||||
|
End If
|
||||||
End If
|
End If
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
|||||||
+514
-385
File diff suppressed because it is too large
Load Diff
@@ -71,7 +71,7 @@ Public Class SecondaryWindowV
|
|||||||
Application.Current.MainWindow.InvalidateVisual()
|
Application.Current.MainWindow.InvalidateVisual()
|
||||||
End If
|
End If
|
||||||
If Not IsNothing(Map.refSceneButtonV) Then
|
If Not IsNothing(Map.refSceneButtonV) Then
|
||||||
Map.refSceneButtonV.Sizing()
|
Map.refSceneButtonV.SceneButtonV_Sizing()
|
||||||
End If
|
End If
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
|||||||
@@ -32,6 +32,7 @@
|
|||||||
</DataTemplate>
|
</DataTemplate>
|
||||||
<DataTemplate DataType="{x:Type EgtStone3D:_ToggleButton}">
|
<DataTemplate DataType="{x:Type EgtStone3D:_ToggleButton}">
|
||||||
<ToggleButton Command="{Binding CmdBtn}"
|
<ToggleButton Command="{Binding CmdBtn}"
|
||||||
|
ToolTip="{Binding Name}"
|
||||||
IsChecked="{Binding IsChecked}"
|
IsChecked="{Binding IsChecked}"
|
||||||
Style="{DynamicResource SceneToggleButton}">
|
Style="{DynamicResource SceneToggleButton}">
|
||||||
<EgtStone3D:SVGV FileSource="{Binding Img, UpdateSourceTrigger=PropertyChanged}"/>
|
<EgtStone3D:SVGV FileSource="{Binding Img, UpdateSourceTrigger=PropertyChanged}"/>
|
||||||
|
|||||||
@@ -0,0 +1,31 @@
|
|||||||
|
<Grid x:Class="TopPanelInfoParametricV"
|
||||||
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||||
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||||
|
xmlns:EgtStone3D="clr-namespace:EgtStone3D">
|
||||||
|
<Grid.RowDefinitions>
|
||||||
|
<RowDefinition Height="1*"/>
|
||||||
|
</Grid.RowDefinitions>
|
||||||
|
|
||||||
|
<ItemsControl ItemsSource="{Binding TopPanelListBtn}"
|
||||||
|
Style="{DynamicResource TopList_ItemsControl}">
|
||||||
|
<ItemsControl.ItemsPanel>
|
||||||
|
<ItemsPanelTemplate>
|
||||||
|
<WrapPanel Style="{StaticResource TopPanelWnd_WrapPanel}"/>
|
||||||
|
</ItemsPanelTemplate>
|
||||||
|
</ItemsControl.ItemsPanel>
|
||||||
|
<ItemsControl.Resources>
|
||||||
|
<DataTemplate DataType="{x:Type EgtStone3D:_Button}">
|
||||||
|
<Button ToolTip="{Binding Name}"
|
||||||
|
IsEnabled="{Binding IsEnabled}"
|
||||||
|
Command="{Binding CmdBtn}"
|
||||||
|
Style="{StaticResource SceneButton2}">
|
||||||
|
<StackPanel Style="{StaticResource TopPanel_StackPanel}">
|
||||||
|
<EgtStone3D:SVGV FileSource="{Binding Img}" Height="50"/>
|
||||||
|
<TextBlock Text="{Binding Name}"
|
||||||
|
Style="{StaticResource TopPanel_TxBl}"/>
|
||||||
|
</StackPanel>
|
||||||
|
</Button>
|
||||||
|
</DataTemplate>
|
||||||
|
</ItemsControl.Resources>
|
||||||
|
</ItemsControl>
|
||||||
|
</Grid>
|
||||||
@@ -0,0 +1,24 @@
|
|||||||
|
Public Class TopPanelInfoParametricV
|
||||||
|
|
||||||
|
#Region "FIELDS & PROPERTIES"
|
||||||
|
|
||||||
|
Private m_SceneButtonVM As SceneButtonVM
|
||||||
|
|
||||||
|
#End Region ' Fields & Properties
|
||||||
|
|
||||||
|
#Region "CONSTRUCTOR"
|
||||||
|
|
||||||
|
Sub New()
|
||||||
|
|
||||||
|
' La chiamata è richiesta dalla finestra di progettazione.
|
||||||
|
InitializeComponent()
|
||||||
|
|
||||||
|
' Aggiungere le eventuali istruzioni di inizializzazione dopo la chiamata a InitializeComponent().
|
||||||
|
m_SceneButtonVM = Map.refSceneButtonVM
|
||||||
|
Me.DataContext = m_SceneButtonVM.InfoListBtn(SceneButtonVM.m_nIndexList_3)
|
||||||
|
SceneButtonVM.m_nIndexList_3 += 1
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
#End Region ' Constructor
|
||||||
|
|
||||||
|
End Class
|
||||||
@@ -10,7 +10,7 @@
|
|||||||
Style="{DynamicResource TopList_ItemsControl}">
|
Style="{DynamicResource TopList_ItemsControl}">
|
||||||
<ItemsControl.ItemsPanel>
|
<ItemsControl.ItemsPanel>
|
||||||
<ItemsPanelTemplate>
|
<ItemsPanelTemplate>
|
||||||
<WrapPanel Orientation="Horizontal"/>
|
<WrapPanel Style="{StaticResource TopPanel_WrapPanel}"/>
|
||||||
</ItemsPanelTemplate>
|
</ItemsPanelTemplate>
|
||||||
</ItemsControl.ItemsPanel>
|
</ItemsControl.ItemsPanel>
|
||||||
<ItemsControl.Resources>
|
<ItemsControl.Resources>
|
||||||
@@ -18,8 +18,7 @@
|
|||||||
<Button ToolTip="{Binding Name}"
|
<Button ToolTip="{Binding Name}"
|
||||||
IsEnabled="{Binding IsEnabled}"
|
IsEnabled="{Binding IsEnabled}"
|
||||||
Command="{Binding CmdBtn}"
|
Command="{Binding CmdBtn}"
|
||||||
Height="65" Width="100" BorderThickness="0" Background="Transparent" Margin="3,0,0,0">
|
Style="{StaticResource SceneButton2}">
|
||||||
<!--<Image Source="{Binding Img}"/>-->
|
|
||||||
<StackPanel Style="{StaticResource TopPanel_StackPanel}">
|
<StackPanel Style="{StaticResource TopPanel_StackPanel}">
|
||||||
<EgtStone3D:SVGV FileSource="{Binding Img}" Height="50"/>
|
<EgtStone3D:SVGV FileSource="{Binding Img}" Height="50"/>
|
||||||
<TextBlock Text="{Binding Name}"
|
<TextBlock Text="{Binding Name}"
|
||||||
@@ -29,10 +28,9 @@
|
|||||||
</DataTemplate>
|
</DataTemplate>
|
||||||
<DataTemplate DataType="{x:Type EgtStone3D:_ToggleButton}">
|
<DataTemplate DataType="{x:Type EgtStone3D:_ToggleButton}">
|
||||||
<ToggleButton ToolTip="{Binding Name}"
|
<ToggleButton ToolTip="{Binding Name}"
|
||||||
Command="{Binding CmdBtn}" Background="Transparent"
|
Command="{Binding CmdBtn}"
|
||||||
IsChecked="{Binding IsChecked}" Margin="3,0,0,0"
|
IsChecked="{Binding IsChecked}"
|
||||||
Height="65" Width="65" BorderThickness="0">
|
Style="{StaticResource SceneToggleButton2}">
|
||||||
<!--<Image Source="{Binding Img}"/>-->
|
|
||||||
<StackPanel Style="{StaticResource TopPanel_StackPanel}">
|
<StackPanel Style="{StaticResource TopPanel_StackPanel}">
|
||||||
<EgtStone3D:SVGV FileSource="{Binding Img}" Height="50"/>
|
<EgtStone3D:SVGV FileSource="{Binding Img}" Height="50"/>
|
||||||
<TextBlock Text="{Binding Name}"
|
<TextBlock Text="{Binding Name}"
|
||||||
|
|||||||
@@ -0,0 +1,36 @@
|
|||||||
|
<Grid x:Class="TopPanelOfficeListButtonV"
|
||||||
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||||
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||||
|
xmlns:EgtStone3D="clr-namespace:EgtStone3D">
|
||||||
|
<Grid.RowDefinitions>
|
||||||
|
<RowDefinition Height="Auto"/>
|
||||||
|
<RowDefinition Height="1*"/>
|
||||||
|
</Grid.RowDefinitions>
|
||||||
|
|
||||||
|
<ItemsControl ItemsSource="{Binding TopPanelListBtn}"
|
||||||
|
Style="{DynamicResource TopList_ItemsControl}">
|
||||||
|
<ItemsControl.ItemsPanel>
|
||||||
|
<ItemsPanelTemplate>
|
||||||
|
<WrapPanel Style="{StaticResource TopPanelWnd_WrapPanel}"/>
|
||||||
|
</ItemsPanelTemplate>
|
||||||
|
</ItemsControl.ItemsPanel>
|
||||||
|
<ItemsControl.Resources>
|
||||||
|
<DataTemplate DataType="{x:Type EgtStone3D:_Button}">
|
||||||
|
<Button ToolTip="{Binding Name}"
|
||||||
|
IsEnabled="{Binding IsEnabled}"
|
||||||
|
Command="{Binding CmdBtn}"
|
||||||
|
Style="{StaticResource SceneButton2}">
|
||||||
|
<StackPanel Style="{StaticResource TopPanel_StackPanel}">
|
||||||
|
<EgtStone3D:SVGV FileSource="{Binding Img}" Height="40"/>
|
||||||
|
<TextBlock Text="{Binding Name}"
|
||||||
|
Style="{StaticResource TopPanel_TxBl}"/>
|
||||||
|
</StackPanel>
|
||||||
|
</Button>
|
||||||
|
</DataTemplate>
|
||||||
|
</ItemsControl.Resources>
|
||||||
|
</ItemsControl>
|
||||||
|
|
||||||
|
<TextBlock Grid.Row="1"
|
||||||
|
Text="{Binding SubTitle}"
|
||||||
|
Style="{StaticResource TopPanel_TxBl}"/>
|
||||||
|
</Grid>
|
||||||
@@ -0,0 +1,24 @@
|
|||||||
|
Public Class TopPanelOfficeListButtonV
|
||||||
|
|
||||||
|
#Region "FIELDS & PROPERTIES"
|
||||||
|
|
||||||
|
Private m_SceneButtonVM As SceneButtonVM
|
||||||
|
|
||||||
|
#End Region ' Fields & Properties
|
||||||
|
|
||||||
|
#Region "CONSTRUCTOR"
|
||||||
|
|
||||||
|
Sub New()
|
||||||
|
|
||||||
|
' La chiamata è richiesta dalla finestra di progettazione.
|
||||||
|
InitializeComponent()
|
||||||
|
|
||||||
|
' Aggiungere le eventuali istruzioni di inizializzazione dopo la chiamata a InitializeComponent().
|
||||||
|
m_SceneButtonVM = Map.refSceneButtonVM
|
||||||
|
Me.DataContext = m_SceneButtonVM.TopPanelOfficeListBtn(SceneButtonVM.m_nIndexList_4)
|
||||||
|
SceneButtonVM.m_nIndexList_4 += 1
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
#End Region ' Constructor
|
||||||
|
|
||||||
|
End Class
|
||||||
+61
-4
@@ -30,10 +30,12 @@
|
|||||||
<EgtStone3D:TopPanelHomeV DataContext="{StaticResource TopPanelVM}"/>
|
<EgtStone3D:TopPanelHomeV DataContext="{StaticResource TopPanelVM}"/>
|
||||||
<Separator Grid.Column="1"
|
<Separator Grid.Column="1"
|
||||||
Style="{StaticResource TopPanel_Separator}"/>
|
Style="{StaticResource TopPanel_Separator}"/>
|
||||||
<EgtStone3D:TopPanelViewV Grid.Column="2" DataContext="{StaticResource TopPanelVM}"/>
|
<EgtStone3D:TopPanelViewV Grid.Column="2"
|
||||||
|
DataContext="{StaticResource TopPanelVM}"/>
|
||||||
<Separator Grid.Column="3"
|
<Separator Grid.Column="3"
|
||||||
Style="{StaticResource TopPanel_Separator}"/>
|
Style="{StaticResource TopPanel_Separator}"/>
|
||||||
<EgtStone3D:TopPanelViewProspectiveV Grid.Column="4" DataContext="{StaticResource TopPanelVM}"/>
|
<EgtStone3D:TopPanelViewProspectiveV Grid.Column="4"
|
||||||
|
DataContext="{StaticResource TopPanelVM}"/>
|
||||||
<Separator Grid.Column="5"
|
<Separator Grid.Column="5"
|
||||||
Style="{StaticResource TopPanel_Separator}"/>
|
Style="{StaticResource TopPanel_Separator}"/>
|
||||||
<EgtStone3D:GridPaneV Grid.Column="6"
|
<EgtStone3D:GridPaneV Grid.Column="6"
|
||||||
@@ -58,10 +60,24 @@
|
|||||||
</ItemsControl>
|
</ItemsControl>
|
||||||
<Button Grid.Column="9"
|
<Button Grid.Column="9"
|
||||||
Command="{Binding ScriptFileCmd}"
|
Command="{Binding ScriptFileCmd}"
|
||||||
|
Tag="{Binding}"
|
||||||
|
IsEnabled="{Binding IsEnableScriptBtn}"
|
||||||
Style="{DynamicResource ProjManager_Btn}">
|
Style="{DynamicResource ProjManager_Btn}">
|
||||||
|
<Button.ContextMenu>
|
||||||
|
<ContextMenu ItemsSource="{Binding FileLuaNames}"
|
||||||
|
Style="{StaticResource EgtStone3D_ContextMenu}">
|
||||||
|
<ContextMenu.Resources>
|
||||||
|
<Style TargetType="{x:Type MenuItem}" BasedOn="{StaticResource EgtStone3D_MenuItem}">
|
||||||
|
<Setter Property="Command"
|
||||||
|
Value="{Binding PlacementTarget.Tag.OpenFileLuaCommand, RelativeSource={RelativeSource Mode=FindAncestor, AncestorType=ContextMenu}}"/>
|
||||||
|
<Setter Property="CommandParameter" Value="{Binding}"/>
|
||||||
|
</Style>
|
||||||
|
</ContextMenu.Resources>
|
||||||
|
</ContextMenu>
|
||||||
|
</Button.ContextMenu>
|
||||||
<StackPanel Style="{StaticResource TopPanel_StackPanel}">
|
<StackPanel Style="{StaticResource TopPanel_StackPanel}">
|
||||||
<EgtStone3D:SVGV Height="50" FileSource="{Binding FileScriptSVG, UpdateSourceTrigger=PropertyChanged}"/>
|
<EgtStone3D:SVGV Height="50" FileSource="{Binding FileScriptSVG, UpdateSourceTrigger=PropertyChanged}"/>
|
||||||
<TextBlock Text="Script File"
|
<TextBlock Text="{Binding Script_Msg}"
|
||||||
Style="{StaticResource TopPanel_TxBl}"/>
|
Style="{StaticResource TopPanel_TxBl}"/>
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</Button>
|
</Button>
|
||||||
@@ -70,7 +86,8 @@
|
|||||||
<TabItem Header="{Binding Parametrico_Msg}">
|
<TabItem Header="{Binding Parametrico_Msg}">
|
||||||
<Grid Style="{StaticResource TopPanel_Grid}">
|
<Grid Style="{StaticResource TopPanel_Grid}">
|
||||||
<Grid.ColumnDefinitions>
|
<Grid.ColumnDefinitions>
|
||||||
<ColumnDefinition Width="1*"/>
|
<ColumnDefinition Width="Auto"/>
|
||||||
|
<ColumnDefinition Width="Auto"/>
|
||||||
</Grid.ColumnDefinitions>
|
</Grid.ColumnDefinitions>
|
||||||
<ItemsControl ItemsSource="{Binding ParametricListGroupBtn}">
|
<ItemsControl ItemsSource="{Binding ParametricListGroupBtn}">
|
||||||
<ItemsControl.ItemsPanel>
|
<ItemsControl.ItemsPanel>
|
||||||
@@ -87,6 +104,46 @@
|
|||||||
</DataTemplate>
|
</DataTemplate>
|
||||||
</ItemsControl.Resources>
|
</ItemsControl.Resources>
|
||||||
</ItemsControl>
|
</ItemsControl>
|
||||||
|
<ItemsControl Grid.Column="1"
|
||||||
|
ItemsSource="{Binding InfoListBtn}">
|
||||||
|
<ItemsControl.ItemsPanel>
|
||||||
|
<ItemsPanelTemplate>
|
||||||
|
<WrapPanel Style="{StaticResource TopPanel_WrapPanel}"/>
|
||||||
|
</ItemsPanelTemplate>
|
||||||
|
</ItemsControl.ItemsPanel>
|
||||||
|
<ItemsControl.Resources>
|
||||||
|
<DataTemplate DataType="{x:Type EgtStone3D:GroupSceneBtn}">
|
||||||
|
<StackPanel Style="{StaticResource SceneButtonH_StackPanel}">
|
||||||
|
<EgtStone3D:TopPanelInfoParametricV/>
|
||||||
|
<Separator Style="{StaticResource TopPanel_Separator}"/>
|
||||||
|
</StackPanel>
|
||||||
|
</DataTemplate>
|
||||||
|
</ItemsControl.Resources>
|
||||||
|
</ItemsControl>
|
||||||
|
</Grid>
|
||||||
|
</TabItem>
|
||||||
|
<TabItem Header="{Binding Office_Msg}">
|
||||||
|
<Grid Style="{StaticResource TopPanel_Grid}">
|
||||||
|
<Grid.ColumnDefinitions>
|
||||||
|
<ColumnDefinition Width="Auto"/>
|
||||||
|
<ColumnDefinition Width="Auto"/>
|
||||||
|
</Grid.ColumnDefinitions>
|
||||||
|
<ItemsControl ItemsSource="{Binding TopPanelOfficeListBtn}">
|
||||||
|
<ItemsControl.ItemsPanel>
|
||||||
|
<ItemsPanelTemplate>
|
||||||
|
<WrapPanel Style="{StaticResource TopPanel_WrapPanel}"/>
|
||||||
|
</ItemsPanelTemplate>
|
||||||
|
</ItemsControl.ItemsPanel>
|
||||||
|
<ItemsControl.Resources>
|
||||||
|
<DataTemplate DataType="{x:Type EgtStone3D:GroupSceneBtn}">
|
||||||
|
<StackPanel Style="{StaticResource SceneButtonH_StackPanel}">
|
||||||
|
<EgtStone3D:TopPanelOfficeListButtonV/>
|
||||||
|
</StackPanel>
|
||||||
|
</DataTemplate>
|
||||||
|
</ItemsControl.Resources>
|
||||||
|
</ItemsControl>
|
||||||
|
<Separator Grid.Column="1"
|
||||||
|
Style="{StaticResource TopPanel_Separator}"/>
|
||||||
</Grid>
|
</Grid>
|
||||||
</TabItem>
|
</TabItem>
|
||||||
</TabControl>
|
</TabControl>
|
||||||
|
|||||||
+111
-2
@@ -12,6 +12,7 @@ Public Class TopPanelVM
|
|||||||
Friend Enum TopOption As Integer
|
Friend Enum TopOption As Integer
|
||||||
OPTIONS = 0
|
OPTIONS = 0
|
||||||
PARAMETRICO = 1
|
PARAMETRICO = 1
|
||||||
|
OFFICE = 2
|
||||||
End Enum
|
End Enum
|
||||||
|
|
||||||
Private m_SelTopOption As TopOption = TopOption.OPTIONS
|
Private m_SelTopOption As TopOption = TopOption.OPTIONS
|
||||||
@@ -141,6 +142,18 @@ Public Class TopPanelVM
|
|||||||
End Get
|
End Get
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
|
Public ReadOnly Property InfoListBtn As List(Of GroupSceneBtn)
|
||||||
|
Get
|
||||||
|
Return Map.refSceneButtonVM.InfoListBtn
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Public ReadOnly Property TopPanelOfficeListBtn As List(Of GroupSceneBtn)
|
||||||
|
Get
|
||||||
|
Return Map.refSceneButtonVM.TopPanelOfficeListBtn
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
Private m_FileScriptSVG As String = String.Empty
|
Private m_FileScriptSVG As String = String.Empty
|
||||||
Public Property FileScriptSVG As String
|
Public Property FileScriptSVG As String
|
||||||
Get
|
Get
|
||||||
@@ -156,6 +169,28 @@ Public Class TopPanelVM
|
|||||||
NotifyPropertyChanged(NameOf(FileScriptSVG))
|
NotifyPropertyChanged(NameOf(FileScriptSVG))
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
Private m_FileLuaNames As New ObservableCollection(Of String)
|
||||||
|
Public Property FileLuaNames As ObservableCollection(Of String)
|
||||||
|
Get
|
||||||
|
Return m_FileLuaNames
|
||||||
|
End Get
|
||||||
|
Set(value As ObservableCollection(Of String))
|
||||||
|
m_FileLuaNames = value
|
||||||
|
NotifyPropertyChanged(NameOf(FileLuaNames))
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Private m_bIsEnableScriptBtn As Boolean = True
|
||||||
|
Public ReadOnly Property IsEnableScriptBtn As Boolean
|
||||||
|
Get
|
||||||
|
Return m_bIsEnableScriptBtn
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
Public Sub SetIsEnableScriptBtn(value As Boolean)
|
||||||
|
m_bIsEnableScriptBtn = value
|
||||||
|
NotifyPropertyChanged(NameOf(IsEnableScriptBtn))
|
||||||
|
End Sub
|
||||||
|
|
||||||
#Region "Messages"
|
#Region "Messages"
|
||||||
|
|
||||||
Public ReadOnly Property NewFile_Msg
|
Public ReadOnly Property NewFile_Msg
|
||||||
@@ -188,6 +223,12 @@ Public Class TopPanelVM
|
|||||||
End Get
|
End Get
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
|
Public ReadOnly Property Script_Msg
|
||||||
|
Get
|
||||||
|
Return EgtMsg(110076) ' Script File
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
#End Region ' Messages
|
#End Region ' Messages
|
||||||
|
|
||||||
' Definizione Comandi
|
' Definizione Comandi
|
||||||
@@ -200,6 +241,7 @@ Public Class TopPanelVM
|
|||||||
Private m_cmdShowPopUpProspectiveCmd As ICommand
|
Private m_cmdShowPopUpProspectiveCmd As ICommand
|
||||||
Private m_cmdOpenMruFile As ICommand
|
Private m_cmdOpenMruFile As ICommand
|
||||||
Private m_cmdScriptFileCmd As ICommand
|
Private m_cmdScriptFileCmd As ICommand
|
||||||
|
Private m_cmdOpenFileLua As ICommand
|
||||||
|
|
||||||
#End Region ' Fields & Properties
|
#End Region ' Fields & Properties
|
||||||
|
|
||||||
@@ -212,6 +254,7 @@ Public Class TopPanelVM
|
|||||||
m_MruImportFiles.Init(S_MRUIMPORTFILES, 8)
|
m_MruImportFiles.Init(S_MRUIMPORTFILES, 8)
|
||||||
SetFileSourceSVG(Map.refMainWindowVM.MainWindowM.sResourcesDir & "\test.svg")
|
SetFileSourceSVG(Map.refMainWindowVM.MainWindowM.sResourcesDir & "\test.svg")
|
||||||
SetFileScriptSVG(Map.refMainWindowVM.MainWindowM.sResourcesDir & "\ScriptLua.svg")
|
SetFileScriptSVG(Map.refMainWindowVM.MainWindowM.sResourcesDir & "\ScriptLua.svg")
|
||||||
|
GetFileLuaList()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
#End Region ' Constructor
|
#End Region ' Constructor
|
||||||
@@ -250,9 +293,50 @@ Public Class TopPanelVM
|
|||||||
SetProspectiveView_Msg("▼" & EgtMsg(110027)) ' Vista Prospettica
|
SetProspectiveView_Msg("▼" & EgtMsg(110027)) ' Vista Prospettica
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
Private Sub Get_ReadFile(fileName As String)
|
||||||
|
Map.refScriptWindowVM.sNameFile = Path.GetFileNameWithoutExtension(fileName)
|
||||||
|
Map.refScriptWindowVM.sScriptText = File.ReadAllText(fileName, Encoding.UTF8)
|
||||||
|
End Sub
|
||||||
|
|
||||||
Private Sub GetFile()
|
Private Sub GetFile()
|
||||||
If File.Exists(Map.refMainWindowVM.MainWindowM.sTempDir & "\" & "Prova.lua") Then Map.refScriptWindowVM.sNameFile = Path.GetFileNameWithoutExtension(Map.refMainWindowVM.MainWindowM.sTempDir & "\" & "Prova.lua")
|
' Verifica se la cartella esiste
|
||||||
If File.Exists(Map.refMainWindowVM.MainWindowM.sTempDir & "\" & "Prova.lua") Then Map.refScriptWindowVM.sRichTextParagraph = File.ReadAllText(Map.refMainWindowVM.MainWindowM.sTempDir & "\" & "Prova.lua", Encoding.UTF8)
|
If Directory.Exists(Map.refMainWindowVM.MainWindowM.sTempDir) Then
|
||||||
|
' Recupero tutti i nomi dei file nella cartella
|
||||||
|
Dim fileNames() As String = Directory.GetFiles(Map.refMainWindowVM.MainWindowM.sTempDir, "*.lua")
|
||||||
|
If fileNames.Length > 0 Then
|
||||||
|
' Recupero il file con l'ultima modifica
|
||||||
|
Dim lastModifyFile As New FileInfo(fileNames(0))
|
||||||
|
For Each fileName As String In fileNames
|
||||||
|
Dim fileInfo As New FileInfo(fileName)
|
||||||
|
If fileInfo.LastWriteTime >= lastModifyFile.LastWriteTime Then
|
||||||
|
lastModifyFile = fileInfo
|
||||||
|
Get_ReadFile(fileName)
|
||||||
|
End If
|
||||||
|
Next
|
||||||
|
ElseIf fileNames.Length = 0 Then
|
||||||
|
If EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(110078), EgtMsg(110077), MessageBoxButton.OK, MessageBoxImage.Information) = MessageBoxResult.OK Then
|
||||||
|
Dim OpenDialog As New EgtManageFileDialogV(Application.Current.MainWindow, New EgtManageFileDialogVM()) With {
|
||||||
|
.Title = EgtMsg(110015), ' Importa
|
||||||
|
.Filter = "lua files (*.lua)|*.lua",
|
||||||
|
.FilterIndex = 1,
|
||||||
|
.Mode = 1
|
||||||
|
}
|
||||||
|
If Not OpenDialog.ShowDialog() = Windows.Forms.DialogResult.OK Then Return
|
||||||
|
If String.IsNullOrEmpty(OpenDialog.FileName) Then Return
|
||||||
|
Get_ReadFile(OpenDialog.FileName)
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub GetFileLuaList()
|
||||||
|
If Directory.Exists(Map.refMainWindowVM.MainWindowM.sTempDir) Then
|
||||||
|
' Recupera tutti i nomi dei file nella cartella
|
||||||
|
Dim fileNames() As String = Directory.GetFiles(Map.refMainWindowVM.MainWindowM.sTempDir, "*.lua")
|
||||||
|
For Each fileName As String In fileNames
|
||||||
|
m_FileLuaNames.Add(fileName)
|
||||||
|
Next
|
||||||
|
End If
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
#End Region ' Methods
|
#End Region ' Methods
|
||||||
@@ -446,10 +530,35 @@ Public Class TopPanelVM
|
|||||||
}
|
}
|
||||||
GetFile()
|
GetFile()
|
||||||
ScriptWindow.Show()
|
ScriptWindow.Show()
|
||||||
|
SetIsEnableScriptBtn(False)
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
#End Region ' ScriptFileCmd
|
#End Region ' ScriptFileCmd
|
||||||
|
|
||||||
|
#Region "OpenFileLuaCommand"
|
||||||
|
|
||||||
|
Public ReadOnly Property OpenFileLuaCommand As ICommand
|
||||||
|
Get
|
||||||
|
If m_cmdOpenFileLua Is Nothing Then
|
||||||
|
m_cmdOpenFileLua = New Command(AddressOf OpenFileLua)
|
||||||
|
End If
|
||||||
|
Return m_cmdOpenFileLua
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Public Sub OpenFileLua(ByVal param As Object)
|
||||||
|
Dim fileName = DirectCast(param, String)
|
||||||
|
Dim ScriptWindow As New ScriptWindowV With {
|
||||||
|
.DataContext = New ScriptWindowVM,
|
||||||
|
.Owner = Application.Current.MainWindow
|
||||||
|
}
|
||||||
|
Get_ReadFile(fileName)
|
||||||
|
ScriptWindow.Show()
|
||||||
|
SetIsEnableScriptBtn(False)
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
#End Region ' OpenFileLuaCommand
|
||||||
|
|
||||||
#End Region ' Commands
|
#End Region ' Commands
|
||||||
|
|
||||||
End Class
|
End Class
|
||||||
|
|||||||
@@ -0,0 +1,19 @@
|
|||||||
|
Module ColorScriptM
|
||||||
|
|
||||||
|
#Region "FIELDS & PROPERTIES"
|
||||||
|
|
||||||
|
' Definire i colori come variabili statiche
|
||||||
|
Public ReadOnly KeywordColor As System.Windows.Media.Color = System.Windows.Media.Color.FromRgb(45, 122, 214)
|
||||||
|
Public ReadOnly CommentColor As System.Windows.Media.Color = System.Windows.Media.Color.FromRgb(94, 153, 62)
|
||||||
|
Public ReadOnly ValueColor As System.Windows.Media.Color = System.Windows.Media.Color.FromRgb(78, 201, 176)
|
||||||
|
Public ReadOnly EgtColor As System.Windows.Media.Color = System.Windows.Media.Color.FromRgb(220, 220, 170)
|
||||||
|
Public ReadOnly InfoColor As System.Windows.Media.Color = System.Windows.Media.Color.FromRgb(206, 145, 120)
|
||||||
|
Public ReadOnly FunctionColor As System.Windows.Media.Color = System.Windows.Media.Color.FromRgb(204, 153, 255)
|
||||||
|
Public ReadOnly BracketColor As System.Windows.Media.Color = System.Windows.Media.Color.FromRgb(255, 200, 20)
|
||||||
|
Public ReadOnly TextColor As System.Windows.Media.Color = System.Windows.Media.Color.FromRgb(104, 205, 254)
|
||||||
|
Public ReadOnly NumberColor As System.Windows.Media.Color = System.Windows.Media.Color.FromRgb(167, 206, 155)
|
||||||
|
Public ReadOnly FreeColor As System.Windows.Media.Color = System.Windows.Media.Color.FromRgb(105, 205, 254)
|
||||||
|
|
||||||
|
#End Region ' Fields & Properties
|
||||||
|
|
||||||
|
End Module
|
||||||
@@ -4,7 +4,8 @@
|
|||||||
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
|
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
|
||||||
xmlns:EgtFloating="clr-namespace:EgtWPFLib5.EgtFloating;assembly=EgtWPFLib5"
|
xmlns:EgtFloating="clr-namespace:EgtWPFLib5.EgtFloating;assembly=EgtWPFLib5"
|
||||||
xmlns:sys="clr-namespace:System;assembly=mscorlib"
|
xmlns:sys="clr-namespace:System;assembly=mscorlib"
|
||||||
xmlns:Themes="clr-namespace:Microsoft.Windows.Themes;assembly=PresentationFramework.Aero2">
|
xmlns:Themes="clr-namespace:Microsoft.Windows.Themes;assembly=PresentationFramework.Aero2"
|
||||||
|
xmlns:AVALON="http://icsharpcode.net/sharpdevelop/avalonedit">
|
||||||
|
|
||||||
<!--#region
|
<!--#region
|
||||||
Assign a Key to every Panel ViewModel to use
|
Assign a Key to every Panel ViewModel to use
|
||||||
@@ -57,6 +58,9 @@
|
|||||||
<SolidColorBrush x:Key="EgtStone3D_Silver" Color="#BFBFBF"/>
|
<SolidColorBrush x:Key="EgtStone3D_Silver" Color="#BFBFBF"/>
|
||||||
<SolidColorBrush x:Key="EgtStone3D_Gold" Color="#FFD700"/>
|
<SolidColorBrush x:Key="EgtStone3D_Gold" Color="#FFD700"/>
|
||||||
<SolidColorBrush x:Key="EgtStone3D_Scorpion" Color="#606060"/>
|
<SolidColorBrush x:Key="EgtStone3D_Scorpion" Color="#606060"/>
|
||||||
|
<SolidColorBrush x:Key="EgtStone3D_Tundora" Color="#404040"/>
|
||||||
|
<SolidColorBrush x:Key="EgtStone3D_PaleSky" Color="#6E7681"/>
|
||||||
|
<SolidColorBrush x:Key="EgtStone3D_MineShaft" Color="#1F1F1F"/>
|
||||||
|
|
||||||
<Color x:Key="EgalwareTransparent_Color">Transparent</Color>
|
<Color x:Key="EgalwareTransparent_Color">Transparent</Color>
|
||||||
<Color x:Key="EgalwareBlue1_Color">#4D84C4</Color>
|
<Color x:Key="EgalwareBlue1_Color">#4D84C4</Color>
|
||||||
@@ -92,6 +96,9 @@
|
|||||||
<Color x:Key="EgtStone3D_Silver_Color">#BFBFBF</Color>
|
<Color x:Key="EgtStone3D_Silver_Color">#BFBFBF</Color>
|
||||||
<Color x:Key="EgtStone3D_Gold_Color">#FFD700</Color>
|
<Color x:Key="EgtStone3D_Gold_Color">#FFD700</Color>
|
||||||
<Color x:Key="EgalwareScorpion_Color">#606060</Color>
|
<Color x:Key="EgalwareScorpion_Color">#606060</Color>
|
||||||
|
<Color x:Key="EgalwareTundora_Color">#404040</Color>
|
||||||
|
<Color x:Key="EgalwarePaleSky_Color">#6E7681</Color>
|
||||||
|
<Color x:Key="EgalwareMineShaft_Color">#1F1F1F</Color>
|
||||||
|
|
||||||
<!--#endregion Colori Predefiniti-->
|
<!--#endregion Colori Predefiniti-->
|
||||||
|
|
||||||
@@ -228,6 +235,14 @@
|
|||||||
<Setter Property="Width" Value="35"/>
|
<Setter Property="Width" Value="35"/>
|
||||||
</Style>
|
</Style>
|
||||||
|
|
||||||
|
<Style x:Key="SceneButton2" TargetType="{x:Type Button}" BasedOn="{StaticResource {x:Type Button}}">
|
||||||
|
<Setter Property="Background" Value="{StaticResource EgalwareTransparent}"/>
|
||||||
|
<Setter Property="BorderThickness" Value="0"/>
|
||||||
|
<Setter Property="Margin" Value="3,0,0,0"/>
|
||||||
|
<Setter Property="Height" Value="65"/>
|
||||||
|
<Setter Property="Width" Value="100"/>
|
||||||
|
</Style>
|
||||||
|
|
||||||
<ControlTemplate x:Key="Button.HalfRoundButton" TargetType="{x:Type Button}">
|
<ControlTemplate x:Key="Button.HalfRoundButton" TargetType="{x:Type Button}">
|
||||||
<Border x:Name="border" CornerRadius="4,4,0,0" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" SnapsToDevicePixels="true">
|
<Border x:Name="border" CornerRadius="4,4,0,0" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" SnapsToDevicePixels="true">
|
||||||
<ContentPresenter x:Name="contentPresenter" Focusable="False" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}" RecognizesAccessKey="True" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}"/>
|
<ContentPresenter x:Name="contentPresenter" Focusable="False" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}" RecognizesAccessKey="True" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}"/>
|
||||||
@@ -515,6 +530,18 @@
|
|||||||
</Style.Triggers>
|
</Style.Triggers>
|
||||||
</Style>
|
</Style>
|
||||||
|
|
||||||
|
<Style x:Key="Office_ToggleButton" TargetType="{x:Type ToggleButton}" BasedOn="{StaticResource ProjManager_ToogleButton}">
|
||||||
|
<Setter Property="Height" Value="24"/>
|
||||||
|
<Setter Property="Width" Value="64"/>
|
||||||
|
<Setter Property="BorderThickness" Value="0"/>
|
||||||
|
<Setter Property="Margin" Value="5,5,5,0"/>
|
||||||
|
<Style.Triggers>
|
||||||
|
<Trigger Property="IsChecked" Value="True">
|
||||||
|
<Setter Property="TextBlock.FontWeight" Value="ExtraBold"/>
|
||||||
|
</Trigger>
|
||||||
|
</Style.Triggers>
|
||||||
|
</Style>
|
||||||
|
|
||||||
<Style x:Key="SceneToggleButton" TargetType="{x:Type ToggleButton}" BasedOn="{StaticResource General_ToogleButton}">
|
<Style x:Key="SceneToggleButton" TargetType="{x:Type ToggleButton}" BasedOn="{StaticResource General_ToogleButton}">
|
||||||
<Setter Property="Background" Value="{StaticResource EgalwareTransparent}"/>
|
<Setter Property="Background" Value="{StaticResource EgalwareTransparent}"/>
|
||||||
<Setter Property="BorderBrush" Value="{StaticResource EgalwareTransparent}"/>
|
<Setter Property="BorderBrush" Value="{StaticResource EgalwareTransparent}"/>
|
||||||
@@ -534,6 +561,15 @@
|
|||||||
<Setter Property="Height" Value="35"/>
|
<Setter Property="Height" Value="35"/>
|
||||||
<Setter Property="Width" Value="35"/>
|
<Setter Property="Width" Value="35"/>
|
||||||
</Style>
|
</Style>
|
||||||
|
|
||||||
|
<Style x:Key="SceneToggleButton2" TargetType="{x:Type ToggleButton}" BasedOn="{StaticResource General_ToogleButton}">
|
||||||
|
<Setter Property="Background" Value="{StaticResource EgalwareTransparent}"/>
|
||||||
|
<Setter Property="BorderBrush" Value="{StaticResource EgalwareTransparent}"/>
|
||||||
|
<Setter Property="BorderThickness" Value="0"/>
|
||||||
|
<Setter Property="Margin" Value="3,0,0,0"/>
|
||||||
|
<Setter Property="Height" Value="65"/>
|
||||||
|
<Setter Property="Width" Value="65"/>
|
||||||
|
</Style>
|
||||||
|
|
||||||
<Style x:Key="ScriptToggleButton" TargetType="{x:Type ToggleButton}" BasedOn="{StaticResource General_ToogleButton}">
|
<Style x:Key="ScriptToggleButton" TargetType="{x:Type ToggleButton}" BasedOn="{StaticResource General_ToogleButton}">
|
||||||
<Setter Property="Background" Value="{StaticResource EgalwareTransparent}"/>
|
<Setter Property="Background" Value="{StaticResource EgalwareTransparent}"/>
|
||||||
@@ -926,8 +962,8 @@
|
|||||||
</Style>
|
</Style>
|
||||||
|
|
||||||
<Style x:Key="ScriptWindowV_Window" TargetType="{x:Type EgtWPFLib5:EgtMainWindow}" BasedOn="{StaticResource Dialog_Window}">
|
<Style x:Key="ScriptWindowV_Window" TargetType="{x:Type EgtWPFLib5:EgtMainWindow}" BasedOn="{StaticResource Dialog_Window}">
|
||||||
<Setter Property="Width" Value="600"/>
|
<Setter Property="Width" Value="900"/>
|
||||||
<Setter Property="Height" Value="700"/>
|
<Setter Property="Height" Value="800"/>
|
||||||
</Style>
|
</Style>
|
||||||
|
|
||||||
<!--#endregion EgtCustomWindowStyle-->
|
<!--#endregion EgtCustomWindowStyle-->
|
||||||
@@ -1124,7 +1160,7 @@
|
|||||||
</Style>
|
</Style>
|
||||||
|
|
||||||
<Style x:Key="SceneUserControl_TxBl" TargetType="{x:Type TextBlock}">
|
<Style x:Key="SceneUserControl_TxBl" TargetType="{x:Type TextBlock}">
|
||||||
<Setter Property="TextWrapping" Value="Wrap"/>
|
<Setter Property="TextWrapping" Value="WrapWithOverflow"/>
|
||||||
<Setter Property="Margin" Value="10,0,10,0"/>
|
<Setter Property="Margin" Value="10,0,10,0"/>
|
||||||
</Style>
|
</Style>
|
||||||
|
|
||||||
@@ -1175,7 +1211,7 @@
|
|||||||
<Setter Property="Height" Value="22"/>
|
<Setter Property="Height" Value="22"/>
|
||||||
<Setter Property="FontSize" Value="12"/>
|
<Setter Property="FontSize" Value="12"/>
|
||||||
<Setter Property="Padding" Value="5"/>
|
<Setter Property="Padding" Value="5"/>
|
||||||
<Setter Property="FontFamily" Value="/Resources/Fonts/#Roboto"/>
|
<!--<Setter Property="FontFamily" Value="/Resources/Fonts/#Roboto"/>-->
|
||||||
<Setter Property="FontWeight" Value="Normal"/>
|
<Setter Property="FontWeight" Value="Normal"/>
|
||||||
</Style>
|
</Style>
|
||||||
|
|
||||||
@@ -1669,7 +1705,7 @@
|
|||||||
|
|
||||||
<Style x:Key="TopPanelButton_ItemsControl" TargetType="{x:Type ItemsControl}">
|
<Style x:Key="TopPanelButton_ItemsControl" TargetType="{x:Type ItemsControl}">
|
||||||
<Setter Property="DockPanel.Dock" Value="Top"/>
|
<Setter Property="DockPanel.Dock" Value="Top"/>
|
||||||
<Setter Property="HorizontalAlignment" Value="Left"/>
|
<Setter Property="HorizontalAlignment" Value="Center"/>
|
||||||
<Setter Property="Margin" Value="-10,10,0,0"/>
|
<Setter Property="Margin" Value="-10,10,0,0"/>
|
||||||
</Style>
|
</Style>
|
||||||
|
|
||||||
@@ -1688,7 +1724,7 @@
|
|||||||
<Style x:Key="RightList_ItemsControl" TargetType="{x:Type ItemsControl}">
|
<Style x:Key="RightList_ItemsControl" TargetType="{x:Type ItemsControl}">
|
||||||
<Setter Property="DockPanel.Dock" Value="Right"/>
|
<Setter Property="DockPanel.Dock" Value="Right"/>
|
||||||
<Setter Property="HorizontalAlignment" Value="Right"/>
|
<Setter Property="HorizontalAlignment" Value="Right"/>
|
||||||
<Setter Property="Margin" Value="0,-30,4,0"/>
|
<Setter Property="Margin" Value="0,10,4,0"/>
|
||||||
</Style>
|
</Style>
|
||||||
|
|
||||||
<Style x:Key="LeftList_ItemsControl" TargetType="{x:Type ItemsControl}">
|
<Style x:Key="LeftList_ItemsControl" TargetType="{x:Type ItemsControl}">
|
||||||
@@ -1800,7 +1836,29 @@
|
|||||||
</Style.Resources>
|
</Style.Resources>
|
||||||
</Style>
|
</Style>
|
||||||
|
|
||||||
|
<Style x:Key="CellDataGrid_CustomHighLight" TargetType="{x:Type DataGridCell}">
|
||||||
|
<Setter Property="BorderBrush" Value="LightGray" />
|
||||||
|
<Style.Triggers>
|
||||||
|
<Trigger Property="IsSelected" Value="True">
|
||||||
|
<Setter Property="BorderThickness" Value="2,2,2,2" />
|
||||||
|
<Setter Property="BorderBrush" Value="Cyan" />
|
||||||
|
<Setter Property="Padding" Value="0,0,0,0" />
|
||||||
|
<Setter Property="Margin" Value="-2,0,-2,0" />
|
||||||
|
<Setter Property="FontWeight" Value="Bold" />
|
||||||
|
<Setter Property="Foreground" Value="Blue" />
|
||||||
|
</Trigger>
|
||||||
|
</Style.Triggers>
|
||||||
|
<Style.Resources>
|
||||||
|
<SolidColorBrush x:Key="{x:Static SystemColors.HighlightBrushKey}" Color="Transparent" />
|
||||||
|
<SolidColorBrush x:Key="{x:Static SystemColors.HighlightTextBrushKey}" Color="Black" />
|
||||||
|
<SolidColorBrush x:Key="{x:Static SystemColors.InactiveSelectionHighlightBrushKey}" Color="Transparent" />
|
||||||
|
<SolidColorBrush x:Key="{x:Static SystemColors.InactiveSelectionHighlightTextBrushKey}" Color="Black" />
|
||||||
|
</Style.Resources>
|
||||||
|
</Style>
|
||||||
|
|
||||||
|
|
||||||
<Style x:Key="DataGrid_CustomHighLight" TargetType="{x:Type DataGrid}">
|
<Style x:Key="DataGrid_CustomHighLight" TargetType="{x:Type DataGrid}">
|
||||||
|
<Setter Property="BorderBrush" Value="LightGray" />
|
||||||
<Style.Resources>
|
<Style.Resources>
|
||||||
<Style TargetType="{x:Type DataGridCell}">
|
<Style TargetType="{x:Type DataGridCell}">
|
||||||
<Style.Triggers>
|
<Style.Triggers>
|
||||||
@@ -1844,8 +1902,8 @@
|
|||||||
<Setter Property="Foreground" Value="Gray"/>
|
<Setter Property="Foreground" Value="Gray"/>
|
||||||
<Setter Property="Cursor" Value="Hand"/>
|
<Setter Property="Cursor" Value="Hand"/>
|
||||||
<Setter Property="Padding" Value="1"/>
|
<Setter Property="Padding" Value="1"/>
|
||||||
<Setter Property="BorderThickness" Value="0 0 1 1"/>
|
<Setter Property="BorderThickness" Value="0,0,1,1"/>
|
||||||
<Setter Property="BorderBrush" Value="DarkGray"/>
|
<Setter Property="BorderBrush" Value="LightGray"/>
|
||||||
<Setter Property="HorizontalContentAlignment" Value="Center" />
|
<Setter Property="HorizontalContentAlignment" Value="Center" />
|
||||||
<Setter Property="TextBlock.TextAlignment" Value="Center" />
|
<Setter Property="TextBlock.TextAlignment" Value="Center" />
|
||||||
<Setter Property="VerticalContentAlignment" Value="Center" />
|
<Setter Property="VerticalContentAlignment" Value="Center" />
|
||||||
@@ -2395,6 +2453,10 @@
|
|||||||
<Setter Property="Margin" Value="5"/>
|
<Setter Property="Margin" Value="5"/>
|
||||||
</Style>
|
</Style>
|
||||||
|
|
||||||
|
<Style x:Key="TopPanelWnd_WrapPanel" TargetType="{x:Type WrapPanel}">
|
||||||
|
<Setter Property="Orientation" Value="Horizontal"/>
|
||||||
|
</Style>
|
||||||
|
|
||||||
<!--#endregion WrapPanelStyle-->
|
<!--#endregion WrapPanelStyle-->
|
||||||
|
|
||||||
<!-- ______________________________________________________________________________________________________________________________________________ -->
|
<!-- ______________________________________________________________________________________________________________________________________________ -->
|
||||||
@@ -2665,8 +2727,9 @@
|
|||||||
|
|
||||||
<Style x:Key="SceneUserControl_UserControl" TargetType="{x:Type UserControl}">
|
<Style x:Key="SceneUserControl_UserControl" TargetType="{x:Type UserControl}">
|
||||||
<Setter Property="Background" Value="{StaticResource EgalwareTransparent}"/>
|
<Setter Property="Background" Value="{StaticResource EgalwareTransparent}"/>
|
||||||
<Setter Property="Width" Value="420"/>
|
<Setter Property="Width" Value="Auto"/>
|
||||||
<Setter Property="Height" Value="Auto"/>
|
<Setter Property="Height" Value="Auto"/>
|
||||||
|
<Setter Property="Margin" Value="10,10,0,0"/>
|
||||||
</Style>
|
</Style>
|
||||||
|
|
||||||
<!--#endregion UserControlStyle-->
|
<!--#endregion UserControlStyle-->
|
||||||
@@ -3003,24 +3066,22 @@
|
|||||||
|
|
||||||
<!-- ______________________________________________________________________________________________________________________________________________ -->
|
<!-- ______________________________________________________________________________________________________________________________________________ -->
|
||||||
|
|
||||||
<!--#region RichTextBoxStyle-->
|
<!--#region TextEditorStyle-->
|
||||||
|
|
||||||
<Style x:Key="Script_RichTxBx" TargetType="{x:Type RichTextBox}">
|
<Style x:Key="ScriptTextEditor" TargetType="{x:Type AVALON:TextEditor}">
|
||||||
<Setter Property="Background" Value="{StaticResource EgalwareTransparent}"/>
|
<Setter Property="Background" Value="{StaticResource EgtStone3D_MineShaft}"/>
|
||||||
<Setter Property="Foreground" Value="{DynamicResource BaseTextBox.Static.Foreground}"/>
|
<Setter Property="Foreground" Value="{StaticResource EgtStone3D_Alto}"/>
|
||||||
<Setter Property="AcceptsReturn" Value="True"/>
|
<Setter Property="LineNumbersForeground" Value="{StaticResource EgtStone3D_PaleSky}"/>
|
||||||
<Setter Property="AcceptsTab" Value="True"/>
|
<Setter Property="ShowLineNumbers" Value="True"/>
|
||||||
<!--<Setter Property="FontFamily" Value="/Resources/Fonts/#Roboto"/>-->
|
<Setter Property="SyntaxHighlighting" Value="Lua"/>
|
||||||
<Setter Property="FontWeight" Value="Medium"/>
|
<Setter Property="HorizontalAlignment" Value="Stretch"/>
|
||||||
<Setter Property="Block.LineHeight" Value="1"/>
|
<Setter Property="VerticalAlignment" Value="Stretch"/>
|
||||||
<Setter Property="Block.TextAlignment" Value="Left"/>
|
<Setter Property="HorizontalContentAlignment" Value="Left"/>
|
||||||
<Setter Property="TextOptions.TextFormattingMode" Value="Ideal"/>
|
<Setter Property="FontFamily" Value="Consolas"/>
|
||||||
<Setter Property="TextOptions.TextRenderingMode" Value="Aliased"/>
|
<Setter Property="FontSize" Value="14"/>
|
||||||
<Setter Property="VerticalScrollBarVisibility" Value="Auto"/>
|
|
||||||
<!--<Setter Property="FontSize" Value="12"/>-->
|
|
||||||
<Setter Property="Margin" Value="10"/>
|
<Setter Property="Margin" Value="10"/>
|
||||||
</Style>
|
</Style>
|
||||||
|
|
||||||
|
<!--#endregion TextEditorStyle-->
|
||||||
|
|
||||||
<!--#endregion RichTextBoxStyle-->
|
|
||||||
|
|
||||||
</ResourceDictionary>
|
</ResourceDictionary>
|
||||||
|
|||||||
@@ -0,0 +1,24 @@
|
|||||||
|
Imports System.Text.RegularExpressions
|
||||||
|
|
||||||
|
Module RegexM
|
||||||
|
|
||||||
|
#Region "FIELDS & PROPERTIES"
|
||||||
|
|
||||||
|
' Precompilare regex con ottimizzazione globale
|
||||||
|
Public ReadOnly KeywordRegex As New Regex("\b(?:local|end|if|then|else|for|while|do|return|true|nil|_ENV|_G)\b", RegexOptions.Compiled Or RegexOptions.CultureInvariant Or RegexOptions.IgnorePatternWhitespace)
|
||||||
|
Public ReadOnly ValueRegex As New Regex("\.(CMP_Draw|N1|V1|T1|Npar|Nome|INFO|WithInt|CMP|GLOB|ROOT)\b", RegexOptions.Compiled Or RegexOptions.CultureInvariant Or RegexOptions.IgnorePatternWhitespace)
|
||||||
|
Public ReadOnly FunctionRegex As New Regex("\bfunction\b", RegexOptions.Compiled Or RegexOptions.CultureInvariant Or RegexOptions.IgnorePatternWhitespace)
|
||||||
|
Public ReadOnly InfoRegex As New Regex("'([^']*)'", RegexOptions.Compiled Or RegexOptions.CultureInvariant Or RegexOptions.IgnorePatternWhitespace)
|
||||||
|
Public ReadOnly EgtRegex As New Regex("\b\w+(?=\s*\()", RegexOptions.Compiled Or RegexOptions.CultureInvariant Or RegexOptions.IgnorePatternWhitespace)
|
||||||
|
Public ReadOnly TextRegex As New Regex("\b\w+(?=\[)(?!.*[\(\{])", RegexOptions.Compiled Or RegexOptions.CultureInvariant Or RegexOptions.IgnorePatternWhitespace)
|
||||||
|
Public ReadOnly BracketRegex As New Regex("[()\[\]{}]", RegexOptions.Compiled Or RegexOptions.CultureInvariant Or RegexOptions.IgnorePatternWhitespace)
|
||||||
|
Public ReadOnly NumberRegex As New Regex("\b\d+\b", RegexOptions.Compiled Or RegexOptions.CultureInvariant Or RegexOptions.IgnorePatternWhitespace)
|
||||||
|
Public ReadOnly CommentRegex As New Regex("--.*$", RegexOptions.Compiled Or RegexOptions.CultureInvariant Or RegexOptions.IgnorePatternWhitespace)
|
||||||
|
Public ReadOnly FreeRegex As New Regex("\b[a-zA-Z_]\w*(?=\s*=\s*)", RegexOptions.Compiled Or RegexOptions.CultureInvariant Or RegexOptions.IgnorePatternWhitespace)
|
||||||
|
Public ReadOnly PointRegex As New Regex("\b(?!table\b)\w+(?=\.)", RegexOptions.Compiled Or RegexOptions.CultureInvariant Or RegexOptions.IgnorePatternWhitespace)
|
||||||
|
Public ReadOnly TableRegex As New Regex("\btable\b", RegexOptions.Compiled Or RegexOptions.CultureInvariant Or RegexOptions.IgnorePatternWhitespace)
|
||||||
|
Public ReadOnly EqualRegex As New Regex("\b\w+(?=\s=)", RegexOptions.Compiled Or RegexOptions.CultureInvariant Or RegexOptions.IgnorePatternWhitespace)
|
||||||
|
|
||||||
|
#End Region ' Fields & Properties
|
||||||
|
|
||||||
|
End Module
|
||||||
+52
-13
@@ -13,6 +13,13 @@ Module SolidManagerM
|
|||||||
|
|
||||||
#Region "METHODS"
|
#Region "METHODS"
|
||||||
|
|
||||||
|
Public Function ExistsPartSolid(nId As Integer) As PartSolidM
|
||||||
|
' cerco nella lista dei part quello con id uguale a nId, se non lo trovo allora nId era riferito ad un Part Solid
|
||||||
|
Dim PartSolid As PartSolidM = m_PartSolidList.FirstOrDefault(Function(x) x.PartId = nId)
|
||||||
|
If IsNothing(PartSolid) Then PartSolid = m_PartSolidList.FirstOrDefault(Function(x) x.PartSolidId = nId)
|
||||||
|
Return PartSolid
|
||||||
|
End Function
|
||||||
|
|
||||||
Public Function GetPartSolid(nId As Integer) As PartSolidM
|
Public Function GetPartSolid(nId As Integer) As PartSolidM
|
||||||
' se la lista non esiste la creo
|
' se la lista non esiste la creo
|
||||||
If m_PartSolidList.Count = 0 Then
|
If m_PartSolidList.Count = 0 Then
|
||||||
@@ -20,9 +27,8 @@ Module SolidManagerM
|
|||||||
End If
|
End If
|
||||||
' se l'id è negativo allora sto applicando un disaccoppiamento e mi basta rendere l'id positivo
|
' se l'id è negativo allora sto applicando un disaccoppiamento e mi basta rendere l'id positivo
|
||||||
If nId < 0 Then nId *= -1
|
If nId < 0 Then nId *= -1
|
||||||
' cerco nella lista dei part quello con id uguale a nId, se non lo trovo allora nId era riferito ad un Part Solid
|
' cerco se è già presente nella lista il corrispondete PartSolid
|
||||||
Dim PartSolid As PartSolidM = m_PartSolidList.FirstOrDefault(Function(x) x.PartId = nId)
|
Dim PartSolid As PartSolidM = ExistsPartSolid(nId)
|
||||||
If IsNothing(PartSolid) Then PartSolid = m_PartSolidList.FirstOrDefault(Function(x) x.PartSolidId = nId)
|
|
||||||
' se non l'ho trovato allora lo creo
|
' se non l'ho trovato allora lo creo
|
||||||
If IsNothing(PartSolid) Then AddPartSolid(nId, PartSolid)
|
If IsNothing(PartSolid) Then AddPartSolid(nId, PartSolid)
|
||||||
|
|
||||||
@@ -39,12 +45,15 @@ Module SolidManagerM
|
|||||||
End Function
|
End Function
|
||||||
|
|
||||||
Public Sub RefreshPartSolid(nPartId As Integer)
|
Public Sub RefreshPartSolid(nPartId As Integer)
|
||||||
Dim PartSolidSel As PartSolidM = GetPartSolid(nPartId)
|
Dim PartSolidSel As PartSolidM = ExistsPartSolid(nPartId)
|
||||||
' rimuovo il part solid associato a questo part
|
If Not IsNothing(PartSolidSel) Then
|
||||||
PartSolidSel.DeselectPart()
|
' rimuovo il part solid associato a questo part
|
||||||
m_PartSolidList.Remove(PartSolidSel)
|
PartSolidSel.DeselectPart()
|
||||||
|
m_PartSolidList.Remove(PartSolidSel)
|
||||||
|
End If
|
||||||
' lo ricreo
|
' lo ricreo
|
||||||
AddPartSolid(nPartId)
|
AddPartSolid(nPartId, PartSolidSel)
|
||||||
|
PartSolidSel.DeselectPart()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Public Sub ClearPartSolidList()
|
Public Sub ClearPartSolidList()
|
||||||
@@ -90,13 +99,18 @@ Module SolidManagerM
|
|||||||
nInLay = EgtGetNextName(nInLay, "InLoop")
|
nInLay = EgtGetNextName(nInLay, "InLoop")
|
||||||
End While
|
End While
|
||||||
|
|
||||||
' creo la superficie piana
|
' creo la superficie piana, se non è già presente
|
||||||
Dim nRegLay As Integer = EgtCreateGroup(nPart)
|
Dim nRegLay As Integer = EgtGetFirstNameInGroup(nPart, "Region")
|
||||||
EgtSetName(nRegLay, "Region")
|
If nRegLay = GDB_ID.NULL Then
|
||||||
EgtCreateSurfFlatRegion(nRegLay, nLoops.ToArray())
|
nRegLay = EgtCreateGroup(nPart)
|
||||||
|
EgtSetName(nRegLay, "Region")
|
||||||
|
EgtCreateSurfFlatRegion(nRegLay, nLoops.ToArray())
|
||||||
|
End If
|
||||||
' splitto le compo nei lati singoli
|
' splitto le compo nei lati singoli
|
||||||
For Each nLoopId In nLoops
|
For Each nLoopId In nLoops
|
||||||
EgtLuaExecLine("TOOL.ExplodeAndNameEdges(" & nLoopId.ToString & "," & "false" & ")")
|
If EgtGetType(nLoopId) = GDB_TY.CRV_COMPO Then
|
||||||
|
EgtLuaExecLine("TOOL.ExplodeAndNameEdges(" & nLoopId.ToString & "," & "false" & ")")
|
||||||
|
End If
|
||||||
Next
|
Next
|
||||||
|
|
||||||
' Assegno valori ai parametri per lua (appartengono alla tabella SLD)
|
' Assegno valori ai parametri per lua (appartengono alla tabella SLD)
|
||||||
@@ -114,6 +128,31 @@ Module SolidManagerM
|
|||||||
End If
|
End If
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
Public Sub CreateAllSolids()
|
||||||
|
' controllo se tutti i Part nel .vme hanno un corrispettiveo nella lista dei PartSolid, sennò la aggiorno
|
||||||
|
EgtSetCurrentContext(m_nVeinCtx)
|
||||||
|
Dim nPart As Integer = EgtGetFirstPart()
|
||||||
|
|
||||||
|
Dim dThick As Double = 20
|
||||||
|
EgtSetCurrentContext(m_nVeinCtx)
|
||||||
|
Dim IdFP As Integer = EgtGetFirstPart()
|
||||||
|
While IdFP <> GDB_ID.NULL
|
||||||
|
Dim bImport As Boolean = False
|
||||||
|
EgtGetInfo(IdFP, "Import", bImport)
|
||||||
|
Dim sName As String = String.Empty
|
||||||
|
EgtGetName(IdFP, sName)
|
||||||
|
' se il part non è un solido o una terna, creo il solido corrispondente, se non è già presente
|
||||||
|
If Not bImport And sName <> "SOLID" And sName <> "Terna" Then
|
||||||
|
CreateSolidFromLoops(IdFP)
|
||||||
|
End If
|
||||||
|
IdFP = EgtGetNextPart(IdFP)
|
||||||
|
End While
|
||||||
|
|
||||||
|
' aggiorno la lista dei part solid
|
||||||
|
CreatePartSolid()
|
||||||
|
EgtDraw()
|
||||||
|
End Sub
|
||||||
|
|
||||||
Public Sub UpdatePairInfo(nId1 As Integer, Optional nId2 As Integer = GDB_ID.NULL)
|
Public Sub UpdatePairInfo(nId1 As Integer, Optional nId2 As Integer = GDB_ID.NULL)
|
||||||
If EgtLuaSetGlobIntVar("ASS.nPartId", nId1) Then AssLog("ASS.nPartId = " & nId1.ToString)
|
If EgtLuaSetGlobIntVar("ASS.nPartId", nId1) Then AssLog("ASS.nPartId = " & nId1.ToString)
|
||||||
If EgtLuaSetGlobIntVar("ASS.nPartToPair", nId2) Then AssLog("ASS.nPartToPair = " & nId2.ToString)
|
If EgtLuaSetGlobIntVar("ASS.nPartToPair", nId2) Then AssLog("ASS.nPartToPair = " & nId2.ToString)
|
||||||
|
|||||||
@@ -0,0 +1,4 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<packages>
|
||||||
|
<package id="AvalonEdit" version="6.3.0.90" targetFramework="net472" />
|
||||||
|
</packages>
|
||||||
BIN
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,8 @@
|
|||||||
|
## About
|
||||||
|
|
||||||
|
Check out the [official documentation](http://avalonedit.net/documentation/) and the
|
||||||
|
[samples and articles wiki page](https://github.com/icsharpcode/AvalonEdit/wiki/Samples-and-Articles)
|
||||||
|
|
||||||
|
Make sure to try the AvalonEdit sample application in the repository - its project has additional documentation included.
|
||||||
|
|
||||||
|
OSS projects using AvalonEdit are listed on the repository main page.
|
||||||
Binary file not shown.
|
After Width: | Height: | Size: 2.4 KiB |
Binary file not shown.
File diff suppressed because it is too large
Load Diff
BIN
Binary file not shown.
+11284
File diff suppressed because it is too large
Load Diff
BIN
Binary file not shown.
+11284
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user