Compare commits

..

1 Commits

Author SHA1 Message Date
Emmanuele Sassi 25af98b6e8 - creazione StrategyWindow 2025-04-29 01:29:17 +02:00
417 changed files with 24528 additions and 18637 deletions
+1 -28
View File
@@ -229,6 +229,7 @@ Public Class BTLFeatureVM
' funzione che seleziona la feature nella geometria ' funzione che seleziona la feature nella geometria
Public Sub SelGeomFeature() Public Sub SelGeomFeature()
EgtDeselectAll()
SelGeomFeature(nFeatureId) SelGeomFeature(nFeatureId)
End Sub End Sub
@@ -255,34 +256,6 @@ Public Class BTLFeatureVM
End If End If
End Sub End Sub
' funzione che seleziona la feature nella geometria
Public Sub DeselGeomFeature()
DeselGeomFeature(nFeatureId)
End Sub
Private Sub DeselGeomFeature(nMyFeatureId As Integer)
EgtDeselectObj(nMyFeatureId)
Dim sVal As String = ""
If EgtGetInfo(nMyFeatureId, BTL_FTR_ADJID, sVal) Then
Dim vAdjId() As String = sVal.Split(","c)
For Each sAdjId In vAdjId
Dim nAdjId As Integer
If Integer.TryParse(sAdjId, nAdjId) Then
DeselGeomFeature(nMyFeatureId + nAdjId)
End If
Next
End If
If EgtGetInfo(nMyFeatureId, BTL_FTR_AUXID, sVal) Then
Dim vAuxId() As String = sVal.Split(","c)
For Each sAuxId In vAuxId
Dim nAuxId As Integer
If Integer.TryParse(sAuxId, nAuxId) Then
EgtDeselectObj(nMyFeatureId + nAuxId)
End If
Next
End If
End Sub
Public Overridable Sub RefreshFeature() Public Overridable Sub RefreshFeature()
End Sub End Sub
@@ -39,7 +39,12 @@
BindingColumns="{Binding BeamMachiningsColumns}" BindingColumns="{Binding BeamMachiningsColumns}"
AlternatingRowBackground="{StaticResource BeamWall_LinkWater}" AlternatingRowBackground="{StaticResource BeamWall_LinkWater}"
AlternationCount="2" AlternationCount="2"
ColumnHeaderStyle="{StaticResource Main_DataGridColumnHeader}" ColumnHeaderBackground="{StaticResource BeamWall_Teal}"
ColumnHeaderForeground="{StaticResource BeamWall_White}"
ColumnHeaderHorizontalContentAlignment="Center"
ColumnHeaderFontWeight="Bold"
ColumnHeaderFontSize="15"
ColumnHeaderPadding="0,2,0,2"
CellStyle="{StaticResource CellDataGrid_CustomHighLight}" CellStyle="{StaticResource CellDataGrid_CustomHighLight}"
Style="{StaticResource DataGrid_OnlyProd}"> Style="{StaticResource DataGrid_OnlyProd}">
+6 -13
View File
@@ -23,10 +23,6 @@ Public Module CalcIntegration
POINT_CLOUD = 5 POINT_CLOUD = 5
RAWPART = 6 RAWPART = 6
EDIT = 7 EDIT = 7
CHECKNOSIM = 8
TOPOLOGY = 9
OPENTOOLDB = 11 ' Non utilizzato
OPENMACHINIGDB = 12 ' Non utilizzato
End Enum End Enum
Private Structure MyProc Private Structure MyProc
@@ -164,7 +160,7 @@ Public Module CalcIntegration
nActProc += 1 nActProc += 1
End If End If
Else Else
If vBar(nCurrBar).nCmdType = CmdTypes.CHECK OrElse vBar(nCurrBar).nCmdType = CmdTypes.CHECKGEN OrElse vBar(nCurrBar).nCmdType = CmdTypes.CHECKNOSIM Then If vBar(nCurrBar).nCmdType = CmdTypes.CHECK OrElse vBar(nCurrBar).nCmdType = CmdTypes.CHECKGEN Then
RaiseEvent Calc_ProcessResult(Nothing, New CalcResultEventArgs(vBar(nCurrBar))) 'ProcessResults(vBar(nCurrBar)) RaiseEvent Calc_ProcessResult(Nothing, New CalcResultEventArgs(vBar(nCurrBar))) 'ProcessResults(vBar(nCurrBar))
ElseIf vBar(nCurrBar).nCmdType = CmdTypes.GENERATE Then ElseIf vBar(nCurrBar).nCmdType = CmdTypes.GENERATE Then
RaiseEvent Calc_ProcessResult(Nothing, New CalcResultEventArgs(vBar(nCurrBar))) 'ProcessResults(vBar(nCurrBar)) RaiseEvent Calc_ProcessResult(Nothing, New CalcResultEventArgs(vBar(nCurrBar))) 'ProcessResults(vBar(nCurrBar))
@@ -179,7 +175,7 @@ Public Module CalcIntegration
' se terminato con successo ' se terminato con successo
If vProc(j).Proc.ExitCode = 0 Then If vProc(j).Proc.ExitCode = 0 Then
' salvo il risultato ' salvo il risultato
If vBar(vProc(j).nBar).nCmdType = CmdTypes.CHECK OrElse vBar(vProc(j).nBar).nCmdType = CmdTypes.CHECKGEN OrElse vBar(vProc(j).nBar).nCmdType = CmdTypes.CHECKNOSIM Then If vBar(vProc(j).nBar).nCmdType = CmdTypes.CHECK OrElse vBar(vProc(j).nBar).nCmdType = CmdTypes.CHECKGEN Then
RaiseEvent Calc_ProcessResult(Nothing, New CalcResultEventArgs(vBar(vProc(j).nBar))) ' ProcessResults(vBar(vProc(j).nBar)) RaiseEvent Calc_ProcessResult(Nothing, New CalcResultEventArgs(vBar(vProc(j).nBar))) ' ProcessResults(vBar(vProc(j).nBar))
ElseIf vBar(vProc(j).nBar).nCmdType = CmdTypes.GENERATE Then ElseIf vBar(vProc(j).nBar).nCmdType = CmdTypes.GENERATE Then
RaiseEvent Calc_ProcessResult(Nothing, New CalcResultEventArgs(vBar(vProc(j).nBar))) ' ProcessResults(vBar(vProc(j).nBar)) RaiseEvent Calc_ProcessResult(Nothing, New CalcResultEventArgs(vBar(vProc(j).nBar))) ' ProcessResults(vBar(vProc(j).nBar))
@@ -201,7 +197,7 @@ Public Module CalcIntegration
' altrimenti (errore generico di esecuzione) ' altrimenti (errore generico di esecuzione)
Else Else
' salvo il risultato ' salvo il risultato
If vBar(vProc(j).nBar).nCmdType = CmdTypes.CHECK OrElse vBar(vProc(j).nBar).nCmdType = CmdTypes.CHECKGEN OrElse vBar(vProc(j).nBar).nCmdType = CmdTypes.CHECKNOSIM Then If vBar(vProc(j).nBar).nCmdType = CmdTypes.CHECK OrElse vBar(vProc(j).nBar).nCmdType = CmdTypes.CHECKGEN Then
RaiseEvent Calc_ProcessResult(Nothing, New CalcResultEventArgs(vBar(vProc(j).nBar))) ' ProcessResults(vBar(vProc(j).nBar)) RaiseEvent Calc_ProcessResult(Nothing, New CalcResultEventArgs(vBar(vProc(j).nBar))) ' ProcessResults(vBar(vProc(j).nBar))
ElseIf vBar(vProc(j).nBar).nCmdType = CmdTypes.GENERATE Then ElseIf vBar(vProc(j).nBar).nCmdType = CmdTypes.GENERATE Then
RaiseEvent Calc_ProcessResult(Nothing, New CalcResultEventArgs(vBar(vProc(j).nBar))) ' ProcessResults(vBar(vProc(j).nBar)) RaiseEvent Calc_ProcessResult(Nothing, New CalcResultEventArgs(vBar(vProc(j).nBar))) ' ProcessResults(vBar(vProc(j).nBar))
@@ -325,7 +321,7 @@ Public Module CalcIntegration
RaiseEvent Calc_Ended(Nothing, New CalcEndEventArgs(If(bIsSimulation And Not bIsSimulationVerifyed, CmdTypes.SIMULATE, CmdTypes.CHECKGEN), If(bAllKO, CalcEndEventArgs.Results.ERROR_, CalcEndEventArgs.Results.OK))) RaiseEvent Calc_Ended(Nothing, New CalcEndEventArgs(If(bIsSimulation And Not bIsSimulationVerifyed, CmdTypes.SIMULATE, CmdTypes.CHECKGEN), If(bAllKO, CalcEndEventArgs.Results.ERROR_, CalcEndEventArgs.Results.OK)))
End Sub End Sub
Public Function CreateNewProjectFromPart(nPartId As Integer, sProjDirPath As String) As String Private Function CreateNewProjectFromPart(nPartId As Integer, sProjDirPath As String) As String
' Aggiorno identificativi per segnalazione errori ' Aggiorno identificativi per segnalazione errori
UpdateCutIdAndTaskId(nPartId) UpdateCutIdAndTaskId(nPartId)
@@ -354,7 +350,7 @@ Public Module CalcIntegration
Return If(bOk, sPartFilePath, String.Empty) Return If(bOk, sPartFilePath, String.Empty)
End Function End Function
Public Function CreateNewProjectFromMachGroup(nMachGroupId As Integer, sProjDirPath As String, nGlobState As Integer) As String Private Function CreateNewProjectFromMachGroup(nMachGroupId As Integer, sProjDirPath As String, nGlobState As Integer) As String
' aggiorno cutid e taskid solo fuori dal supervisore o se pezzo ricalcolato ' aggiorno cutid e taskid solo fuori dal supervisore o se pezzo ricalcolato
If Not m_bIsSupervisor OrElse nGlobState = CalcStates.NOTCALCULATED Then If Not m_bIsSupervisor OrElse nGlobState = CalcStates.NOTCALCULATED Then
Dim DisableMgr As DisableModifiedMgr = Nothing Dim DisableMgr As DisableModifiedMgr = Nothing
@@ -393,12 +389,9 @@ Public Module CalcIntegration
Dim sMachGroupName As String = "" Dim sMachGroupName As String = ""
EgtGetMachGroupName(nMachGroupId, sMachGroupName) EgtGetMachGroupName(nMachGroupId, sMachGroupName)
Dim sMachGroupFilePath As String = sProjDirPath & "\" & sMachGroupName & ".bwe" Dim sMachGroupFilePath As String = sProjDirPath & "\" & sMachGroupName & ".bwe"
If EgtSaveMachGroupToFile(nMachGroupId, {EgtGetFirstNameInGroup(GDB_ID.ROOT, BTLINFO), EgtGetFirstNameInGroup(GDB_ID.ROOT, PROJECTINFO)}, sMachGroupFilePath, NGE.CMPTEXT) Then If EgtSaveObjToFile(nMachGroupId, sMachGroupFilePath, NGE.CMPTEXT) Then
Return sMachGroupFilePath Return sMachGroupFilePath
End If End If
'If EgtSaveObjToFile(nMachGroupId, sMachGroupFilePath, NGE.CMPTEXT) Then
' Return sMachGroupFilePath
'End If
Return String.Empty Return String.Empty
End Function End Function
@@ -119,12 +119,6 @@
</StackPanel> </StackPanel>
</Grid> </Grid>
</GroupBox> </GroupBox>
<UniformGrid Columns="2"
Margin="0,5,0,0">
<TextBlock Text="Importa BTL con verifica" VerticalAlignment="Center" Foreground="{StaticResource BeamWall_Corduroy}"/>
<CheckBox IsChecked="{Binding bVerifyImportBTL_IsChecked}"
Margin="0,5,0,0"/>
</UniformGrid>
</StackPanel> </StackPanel>
</Grid> </Grid>
-1
View File
@@ -120,7 +120,6 @@
Public Const PROJ As String = "PROJ" Public Const PROJ As String = "PROJ"
Public Const FILENAMESEPARATOR As Char = "^"c Public Const FILENAMESEPARATOR As Char = "^"c
Public Const BTLINFO As String = "BtlInfo" Public Const BTLINFO As String = "BtlInfo"
Public Const PROJECTINFO As String = "ProjectInfo"
' layer per assemblato ' layer per assemblato
Public Const ASSEBASE As String = "AsseBase" Public Const ASSEBASE As String = "AsseBase"
+8 -19
View File
@@ -28,7 +28,6 @@ Public Module ConstGen
' Pagine del programma ' Pagine del programma
Public Enum Pages As Integer Public Enum Pages As Integer
EMPTY = -1
VIEW = 0 VIEW = 0
MACHINING = 1 MACHINING = 1
SUPERVISOR = 2 SUPERVISOR = 2
@@ -36,7 +35,6 @@ Public Module ConstGen
INPUTS = 4 INPUTS = 4
OUTPUTS = 5 OUTPUTS = 5
ONLYPRODPAGE = 6 ONLYPRODPAGE = 6
CONFIGPROGRAM = 7
End Enum End Enum
' Abilitazioni licenza ' Abilitazioni licenza
@@ -57,7 +55,7 @@ Public Module ConstGen
End Enum End Enum
' File di log generale ' File di log generale
Public Const VWOPTGENLOG_FILE_NAME As String = "EgtBEAMWALL.OptimizerLog#.txt" Public Const VWOPTGENLOG_FILE_NAME As String = "EgtBEAMWALL.ViewerOptimizerLog#.txt"
Public Const SUPGENLOG_FILE_NAME As String = "EgtBEAMWALL.SupervisorLog#.txt" Public Const SUPGENLOG_FILE_NAME As String = "EgtBEAMWALL.SupervisorLog#.txt"
' Sottodirettorio di configurazione ' Sottodirettorio di configurazione
@@ -78,12 +76,14 @@ Public Module ConstGen
Public Const WAREHOUSE_DIR As String = "Warehouse" Public Const WAREHOUSE_DIR As String = "Warehouse"
' Sottodirettorio per lavorazioni travi ' Sottodirettorio per lavorazioni travi
Public Const BEAM_DIR As String = "Beam" Public Const BEAM_DIR As String = "Beam"
' Sottodirettorio per lavorazioni travi nuovo
Public Const BEAMNEW_DIR As String = "BeamNew"
' Sottodirettorio per lavorazioni pareti ' Sottodirettorio per lavorazioni pareti
Public Const WALL_DIR As String = "Wall" Public Const WALL_DIR As String = "Wall"
' Sottodirettorio per lavorazioni pareti nuovo ' Sottodirettorio per setup strategie
Public Const WALLNEW_DIR As String = "WallNew" Public Const AISETUP_DIR As String = "AISetup"
' Sottodirettorio per automarismo strategie
Public Const STRATEGIES_DIR As String = "Strategies"
' File contenente lista strategie per feature/topologia
Public Const AVAILABLESTRATEGYLIST_FILE As String = "AvailableStrategyList"
' Sottodirettorio di default per il salvataggio con nome ' Sottodirettorio di default per il salvataggio con nome
Public Const SAVE_DFL_NAMEDIR As String = "MyProjects" Public Const SAVE_DFL_NAMEDIR As String = "MyProjects"
' Sottodirettorio di default per le macchine ' Sottodirettorio di default per le macchine
@@ -96,16 +96,5 @@ Public Module ConstGen
Public Const ZEBRAPRINTER_EXE As String = "ZebraPrinterUtilitiesD32.exe" Public Const ZEBRAPRINTER_EXE As String = "ZebraPrinterUtilitiesD32.exe"
' Sottodirettorio di default per macro ' Sottodirettorio di default per macro
Public Const MACRO_DFL_DIR As String = "Macro" Public Const MACRO_DFL_DIR As String = "Macro"
' Sottodirettorio per setup strategie
Public Const AISETUP_DIR As String = "AISetup"
' Sottodirettorio per automatismo strategie
Public Const STRATEGIES_DIR As String = "Strategies"
' Sottodirettorio per automatismo strategie standard
Public Const STANDARD_DIR As String = "Standard"
' File contenente lista strategie per feature/topologia
Public Const AVAILABLESTRATEGYLIST_FILE As String = "AvailableStrategyList"
' File contente tutte le feature
Public Const CUSTOMERCONFIG_FILE As String = "CustomerConfig"
' File contenente i parametri generali
Public Const GENERALPARAMETERS_FILE As String = "GeneralParameters"
End Module End Module
-15
View File
@@ -35,8 +35,6 @@ Public Module ConstIni
Public Const K_FASTPRODUCE As String = "FastProduce" Public Const K_FASTPRODUCE As String = "FastProduce"
Public Const K_ADDPROJ As String = "AddProj" Public Const K_ADDPROJ As String = "AddProj"
Public Const K_PROJECTMODE As String = "ProjectMode" Public Const K_PROJECTMODE As String = "ProjectMode"
Public Const K_CAMEXEPATH As String = "CAMExePath"
Public Const K_PIPELUADIR As String = "PipeLuaDir"
Public Const K_SHOWBUILDING As String = "ShowBuilding" Public Const K_SHOWBUILDING As String = "ShowBuilding"
@@ -52,21 +50,14 @@ Public Module ConstIni
Public Const K_EXPORTBWE As String = "ExpBwe" Public Const K_EXPORTBWE As String = "ExpBwe"
Public Const S_BEAM As String = "Beam" Public Const S_BEAM As String = "Beam"
Public Const S_BEAMNEW As String = "BeamNew"
Public Const K_CALCPATH As String = "CalcPath" Public Const K_CALCPATH As String = "CalcPath"
Public Const K_BEAMBASEDIR As String = "BaseDir" Public Const K_BEAMBASEDIR As String = "BaseDir"
Public Const K_BEAMBWEEXEC As String = "BweExec" Public Const K_BEAMBWEEXEC As String = "BweExec"
Public Const S_WALL As String = "Wall" Public Const S_WALL As String = "Wall"
Public Const S_WALLNEW As String = "WallNew"
Public Const K_WALLBASEDIR As String = "BaseDir" Public Const K_WALLBASEDIR As String = "BaseDir"
Public Const K_WALLBWEEXEC As String = "BweExec" Public Const K_WALLBWEEXEC As String = "BweExec"
Public Const S_EXECGROUP As String = "ExecGroup"
Public Const K_ENVIRONMENT As String = "Environment"
Public Const K_PIPELUAFILE As String = "PipeLuaFile"
Public Const K_MAXCAMINSTANCES As String = "MaxCAMInstances"
Public Const S_MACHINELOGFILTER As String = "MachineLogFilters" Public Const S_MACHINELOGFILTER As String = "MachineLogFilters"
Public Const K_PARTEVENTTYPE As String = "PartEventType" Public Const K_PARTEVENTTYPE As String = "PartEventType"
Public Const K_ENTITYTYPE As String = "EntityType" Public Const K_ENTITYTYPE As String = "EntityType"
@@ -128,10 +119,4 @@ Public Module ConstIni
' Server Address ' Server Address
Public Const K_SERVERADDRESS As String = "ServerAddressRelease" Public Const K_SERVERADDRESS As String = "ServerAddressRelease"
Public Const K_BEAMWALL As String = "EgtBeamWall" Public Const K_BEAMWALL As String = "EgtBeamWall"
Public Const S_STRATEGY As String = "Strategy"
Public Const K_PARAMPASSWORD As String = "ParamPassword"
Public Const K_DEFAULTCONFIG As String = "DefaultConfiguration"
Public Const K_VERIFYIMPORTBTL As String = "VerifyImportBTL"
End Module End Module
+29 -1
View File
@@ -60,7 +60,7 @@
<HintPath>..\packages\Microsoft.Bcl.AsyncInterfaces.8.0.0\lib\net462\Microsoft.Bcl.AsyncInterfaces.dll</HintPath> <HintPath>..\packages\Microsoft.Bcl.AsyncInterfaces.8.0.0\lib\net462\Microsoft.Bcl.AsyncInterfaces.dll</HintPath>
</Reference> </Reference>
<Reference Include="Newtonsoft.Json, Version=13.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL"> <Reference Include="Newtonsoft.Json, Version=13.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<HintPath>..\packages\Newtonsoft.Json.13.0.4\lib\net45\Newtonsoft.Json.dll</HintPath> <HintPath>..\packages\Newtonsoft.Json.13.0.1\lib\net45\Newtonsoft.Json.dll</HintPath>
</Reference> </Reference>
<Reference Include="PresentationCore" /> <Reference Include="PresentationCore" />
<Reference Include="PresentationFramework" /> <Reference Include="PresentationFramework" />
@@ -137,6 +137,12 @@
<Compile Include="ConfigurationPage\Machine_ConfigurationPageV.xaml.vb"> <Compile Include="ConfigurationPage\Machine_ConfigurationPageV.xaml.vb">
<DependentUpon>Machine_ConfigurationPageV.xaml</DependentUpon> <DependentUpon>Machine_ConfigurationPageV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="ConfigurationPage\OnlyProdQParameter_ConfigurationPageV.xaml.vb">
<DependentUpon>OnlyProdQParameter_ConfigurationPageV.xaml</DependentUpon>
</Compile>
<Compile Include="ConfigurationPage\QParameter_ConfigurationPageV.xaml.vb">
<DependentUpon>QParameter_ConfigurationPageV.xaml</DependentUpon>
</Compile>
<Compile Include="Constants\ConstColumns.vb" /> <Compile Include="Constants\ConstColumns.vb" />
<Compile Include="Constants\ConstDataGridColumnsIni.vb" /> <Compile Include="Constants\ConstDataGridColumnsIni.vb" />
<Compile Include="Constants\ConstDims.vb" /> <Compile Include="Constants\ConstDims.vb" />
@@ -216,6 +222,12 @@
<Compile Include="OpenProjectFileDialog\OnlyProdOpenProjectFileDialogV.xaml.vb"> <Compile Include="OpenProjectFileDialog\OnlyProdOpenProjectFileDialogV.xaml.vb">
<DependentUpon>OnlyProdOpenProjectFileDialogV.xaml</DependentUpon> <DependentUpon>OnlyProdOpenProjectFileDialogV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="SetUpWindow\OnlyProdSetUpWindowV.xaml.vb">
<DependentUpon>OnlyProdSetUpWindowV.xaml</DependentUpon>
</Compile>
<Compile Include="ToolsDbWindow\OnlyProdToolDbWindowV.xaml.vb">
<DependentUpon>OnlyProdToolDbWindowV.xaml</DependentUpon>
</Compile>
<Compile Include="Utility\Configuration.vb" /> <Compile Include="Utility\Configuration.vb" />
<Compile Include="ProjectFileVM\ProdItem.vb" /> <Compile Include="ProjectFileVM\ProdItem.vb" />
<Compile Include="Utility\DimensionsIniFile.vb" /> <Compile Include="Utility\DimensionsIniFile.vb" />
@@ -314,6 +326,14 @@
<SubType>Designer</SubType> <SubType>Designer</SubType>
<Generator>XamlIntelliSenseFileGenerator</Generator> <Generator>XamlIntelliSenseFileGenerator</Generator>
</Page> </Page>
<Page Include="ConfigurationPage\OnlyProdQParameter_ConfigurationPageV.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Page Include="ConfigurationPage\QParameter_ConfigurationPageV.xaml">
<SubType>Designer</SubType>
<Generator>XamlIntelliSenseFileGenerator</Generator>
</Page>
<Page Include="EgtColorPicker\EgtColorPickerV.xaml"> <Page Include="EgtColorPicker\EgtColorPickerV.xaml">
<SubType>Designer</SubType> <SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
@@ -386,6 +406,14 @@
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="SetUpWindow\OnlyProdSetUpWindowV.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="ToolsDbWindow\OnlyProdToolDbWindowV.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="ViewPanel\ViewPanelV.xaml"> <Page Include="ViewPanel\ViewPanelV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
@@ -1,6 +1,20 @@
<DataGrid x:Class="EgtDataGrid" <DataGrid x:Class="EgtDataGrid"
x:Name="CurrDataGrid"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<DataGrid.ColumnHeaderStyle>
<Style TargetType="{x:Type DataGridColumnHeader}">
<EventSetter Event="SizeChanged" Handler="Cell_SizedChanged" />
<EventSetter Event="MouseRightButtonDown" Handler="Cell_MouseRightButtonDown" />
<!-- Propieta' Header DataGrid -->
<Setter Property="Background" Value="{Binding ColumnHeaderBackground, ElementName=CurrDataGrid}" />
<Setter Property="Foreground" Value="{Binding ColumnHeaderForeground, ElementName=CurrDataGrid}" />
<Setter Property="FontWeight" Value="{Binding ColumnHeaderFontWeight, ElementName=CurrDataGrid}" />
<Setter Property="FontSize" Value="{Binding ColumnHeaderFontSize, ElementName=CurrDataGrid}" />
<Setter Property="HorizontalContentAlignment" Value="{Binding ColumnHeaderHorizontalContentAlignment, ElementName=CurrDataGrid}" />
<Setter Property="Padding" Value="{Binding ColumnHeaderPadding, ElementName=CurrDataGrid}" />
</Style>
</DataGrid.ColumnHeaderStyle>
</DataGrid> </DataGrid>
+140 -101
View File
@@ -6,7 +6,6 @@ Imports System.Windows.Controls
Imports System.Windows.Controls.Primitives Imports System.Windows.Controls.Primitives
Imports System.Windows.Data Imports System.Windows.Data
Imports System.Windows.Media Imports System.Windows.Media
Imports System.Windows.Threading
Imports EgtUILib Imports EgtUILib
Imports EgtWPFLib5 Imports EgtWPFLib5
@@ -26,7 +25,6 @@ Public Class EgtDataGrid
Sub New() Sub New()
InitializeComponent() InitializeComponent()
AddHandler Columns.CollectionChanged, AddressOf Columns_CollectionChanged
End Sub End Sub
Public Shadows Property BindingColumns As ObservableCollection(Of EgtDataGridColumn) Public Shadows Property BindingColumns As ObservableCollection(Of EgtDataGridColumn)
@@ -72,78 +70,6 @@ Public Class EgtDataGrid
End If End If
End Sub End Sub
Private Sub Columns_CollectionChanged(sender As Object, e As NotifyCollectionChangedEventArgs)
If e.Action = NotifyCollectionChangedAction.Add Then
For Each newColumn As DataGridColumn In e.NewItems
Dispatcher.BeginInvoke(New Action(Sub()
HookHeaderForColumn(newColumn)
End Sub), DispatcherPriority.Loaded)
Next
ElseIf e.Action = NotifyCollectionChangedAction.Remove Then
For Each removedColumn As DataGridColumn In e.OldItems
Dispatcher.BeginInvoke(New Action(Sub()
UnhookHeaderForColumn(removedColumn)
End Sub), DispatcherPriority.Loaded)
Next
End If
End Sub
Private Sub HookHeaderForColumn(ByVal column As DataGridColumn)
Dim headersPresenter = FindVisualChild(Of DataGridColumnHeadersPresenter)(Me)
If headersPresenter Is Nothing Then Return
For Each header In FindVisualChildren(Of DataGridColumnHeader)(headersPresenter)
If header.Column Is column Then
AddHandler header.SizeChanged, AddressOf ColumnHeader_SizeChanged
AddHandler header.MouseRightButtonDown, AddressOf ColumnHeader_MouseRightButtonDown
Exit For
End If
Next
End Sub
Private Sub UnhookHeaderForColumn(ByVal column As DataGridColumn)
Dim headersPresenter = FindVisualChild(Of DataGridColumnHeadersPresenter)(Me)
If headersPresenter Is Nothing Then Return
For Each header In FindVisualChildren(Of DataGridColumnHeader)(headersPresenter)
If header.Column Is column Then
RemoveHandler header.SizeChanged, AddressOf ColumnHeader_SizeChanged
RemoveHandler header.MouseRightButtonDown, AddressOf ColumnHeader_MouseRightButtonDown
Exit For
End If
Next
End Sub
Private Function FindVisualChild(Of T As DependencyObject)(ByVal parent As DependencyObject) As T
Dim tChild As T = Nothing
For i As Integer = 0 To VisualTreeHelper.GetChildrenCount(parent) - 1
Dim child = VisualTreeHelper.GetChild(parent, i)
tChild = TryCast(child, T)
If tChild IsNot Nothing Then Return tChild
Dim result = FindVisualChild(Of T)(child)
If result IsNot Nothing Then Return result
Next
Return Nothing
End Function
Private Iterator Function FindVisualChildren(Of T As DependencyObject)(ByVal parent As DependencyObject) As IEnumerable(Of T)
Dim tChild As T = Nothing
For i As Integer = 0 To VisualTreeHelper.GetChildrenCount(parent) - 1
Dim child = VisualTreeHelper.GetChild(parent, i)
tChild = TryCast(child, T)
If tChild IsNot Nothing Then Yield tChild
For Each descendant In FindVisualChildren(Of T)(child)
Yield descendant
Next
Next
End Function
Private Sub collectionChanged(ByVal sender As Object, ByVal e As NotifyCollectionChangedEventArgs) Private Sub collectionChanged(ByVal sender As Object, ByVal e As NotifyCollectionChangedEventArgs)
Select Case e.Action Select Case e.Action
Case NotifyCollectionChangedAction.Add Case NotifyCollectionChangedAction.Add
@@ -152,11 +78,11 @@ Public Class EgtDataGrid
For Each one As EgtDataGridColumn In e.NewItems For Each one As EgtDataGridColumn In e.NewItems
Try Try
Dim col As DataGridColumn = Me.FindResource(one.Name) Dim col As DataGridColumn = CurrDataGrid.FindResource(one.Name)
one.InitColumn(col) one.InitColumn(col)
Me.Columns.Insert(e.NewStartingIndex, col) CurrDataGrid.Columns.Insert(e.NewStartingIndex, col)
If col.DisplayIndex <> e.NewStartingIndex Then If col.DisplayIndex <> e.NewStartingIndex Then
Me.Columns(e.NewStartingIndex).DisplayIndex = e.NewStartingIndex CurrDataGrid.Columns(e.NewStartingIndex).DisplayIndex = e.NewStartingIndex
End If End If
Catch ex As Exception Catch ex As Exception
MessageBox.Show(String.Format(EgtMsg(61883), one.Name, one.ParentDataGridName), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning) MessageBox.Show(String.Format(EgtMsg(61883), one.Name, one.ParentDataGridName), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning)
@@ -169,34 +95,34 @@ Public Class EgtDataGrid
If e.OldItems IsNot Nothing Then If e.OldItems IsNot Nothing Then
For Each one As EgtDataGridColumn In e.OldItems For Each one As EgtDataGridColumn In e.OldItems
Dim col As DataGridColumn = Me.FindResource(one.Name) Dim col As DataGridColumn = CurrDataGrid.FindResource(one.Name)
Me.Columns.Remove(col) CurrDataGrid.Columns.Remove(col)
Next Next
End If End If
Case NotifyCollectionChangedAction.Move Case NotifyCollectionChangedAction.Move
'Dim col As DataGridColumn = Me.FindResource(BindingColumns(e.OldStartingIndex)) 'Dim col As DataGridColumn = CurrDataGrid.FindResource(BindingColumns(e.OldStartingIndex))
'col.DisplayIndex = e.NewStartingIndex 'col.DisplayIndex = e.NewStartingIndex
Me.Columns.Move(e.OldStartingIndex, e.NewStartingIndex) CurrDataGrid.Columns.Move(e.OldStartingIndex, e.NewStartingIndex)
Me.Columns(e.NewStartingIndex).DisplayIndex = e.NewStartingIndex CurrDataGrid.Columns(e.NewStartingIndex).DisplayIndex = e.NewStartingIndex
'Dim x = Me.Columns(e.OldStartingIndex).DisplayIndex 'Dim x = CurrDataGrid.Columns(e.OldStartingIndex).DisplayIndex
Case NotifyCollectionChangedAction.Reset Case NotifyCollectionChangedAction.Reset
Me.Columns.Clear() CurrDataGrid.Columns.Clear()
If e.NewItems IsNot Nothing Then If e.NewItems IsNot Nothing Then
For Each one As DataGridColumn In e.NewItems For Each one As DataGridColumn In e.NewItems
Dim col As DataGridColumn = Me.FindResource(one) Dim col As DataGridColumn = CurrDataGrid.FindResource(one)
Me.Columns.Add(col) CurrDataGrid.Columns.Add(col)
Next Next
End If End If
Case NotifyCollectionChangedAction.Replace Case NotifyCollectionChangedAction.Replace
Dim col As DataGridColumn = Me.FindResource(e.NewItems(0)) Dim col As DataGridColumn = CurrDataGrid.FindResource(e.NewItems(0))
Me.Columns(e.NewStartingIndex) = col CurrDataGrid.Columns(e.NewStartingIndex) = col
End Select End Select
End Sub End Sub
Private Sub ColumnHeader_SizeChanged(sender As Object, e As SizeChangedEventArgs) Private Sub Cell_SizedChanged(sender As Object, e As SizeChangedEventArgs)
' ad ogni ridimensionamento della cella del ColumnHeader salvo le nuove dimensioni nell'ini ' ad ogni ridimensionamento della cella del ColumnHeader salvo le nuove dimensioni nell'ini
If Not IsNothing(e.OriginalSource.Column) AndAlso Not IsNothing(BindingColumns(e.OriginalSource.Column.DisplayIndex)) Then If Not IsNothing(e.OriginalSource.Column) AndAlso Not IsNothing(BindingColumns(e.OriginalSource.Column.DisplayIndex)) Then
' se la colonna corrente è Star ed è preceduta da una colonna Pixel non scrivo le modifiche ' se la colonna corrente è Star ed è preceduta da una colonna Pixel non scrivo le modifiche
@@ -206,17 +132,17 @@ Public Class EgtDataGrid
End If End If
End Sub End Sub
Private Sub DataGrid_SizedChanged(sender As Object, e As SizeChangedEventArgs) Handles Me.SizeChanged Private Sub DataGrid_SizedChanged(sender As Object, e As SizeChangedEventArgs) Handles CurrDataGrid.SizeChanged
' confronto la larghezza effettiva della EgtDataGrid con la somma delle larghezze delle colonne ' confronto la larghezza effettiva della EgtDataGrid con la somma delle larghezze delle colonne
UpdateColumnsWidth() UpdateColumnsWidth()
If BindingColumns.Count > 0 Then If BindingColumns.Count > 0 Then
If Me.ActualWidth - LASTCOLUMN_MINWIDTH > columnsWidth Then If CurrDataGrid.ActualWidth - LASTCOLUMN_MINWIDTH > columnsWidth Then
' nascondo la ScrollBar orizzontale e setto lo UnitType dell'ultima colonna visibile a Star ' nascondo la ScrollBar orizzontale e setto lo UnitType dell'ultima colonna visibile a Star
ScrollViewer.SetHorizontalScrollBarVisibility(Me, ScrollBarVisibility.Hidden) ScrollViewer.SetHorizontalScrollBarVisibility(CurrDataGrid, ScrollBarVisibility.Hidden)
BindingColumns.Last(Function(x) x.Visible = True).Width = New DataGridLength(1, DataGridLengthUnitType.Star) BindingColumns.Last(Function(x) x.Visible = True).Width = New DataGridLength(1, DataGridLengthUnitType.Star)
Else Else
' mostro la ScrollBar orizzontale e se UnitType delle colonne è Star lo setto a Pixel ' mostro la ScrollBar orizzontale e se UnitType delle colonne è Star lo setto a Pixel
ScrollViewer.SetHorizontalScrollBarVisibility(Me, ScrollBarVisibility.Visible) ScrollViewer.SetHorizontalScrollBarVisibility(CurrDataGrid, ScrollBarVisibility.Visible)
For Each bc In BindingColumns For Each bc In BindingColumns
If bc.Width.IsStar Then If bc.Width.IsStar Then
bc.Width = New DataGridLength(bc.ActualWidth, DataGridLengthUnitType.Pixel) bc.Width = New DataGridLength(bc.ActualWidth, DataGridLengthUnitType.Pixel)
@@ -244,7 +170,7 @@ Public Class EgtDataGrid
End If End If
End Sub End Sub
Private Sub ColumnHeader_MouseRightButtonDown(sender As Object, e As RoutedEventArgs) Private Sub Cell_MouseRightButtonDown(sender As Object, e As RoutedEventArgs)
Dim nDispIndex As Integer = sender.DisplayIndex Dim nDispIndex As Integer = sender.DisplayIndex
' creo il ContextMenu con gli item checkabili ' creo il ContextMenu con gli item checkabili
Dim cm As ContextMenu = New ContextMenu() Dim cm As ContextMenu = New ContextMenu()
@@ -328,12 +254,12 @@ Public Class EgtDataGrid
cm.IsOpen = True cm.IsOpen = True
End Sub End Sub
Private Sub CurrDataGrid_ColumnReordering(sender As Object, e As DataGridColumnEventArgs) Handles Me.ColumnReordering Private Sub CurrDataGrid_ColumnReordering(sender As Object, e As DataGridColumnEventArgs) Handles CurrDataGrid.ColumnReordering
' conservo il vecchio indice in modo da effettuare lo scambio in BindingColumns una volta riordinate graficamente ' conservo il vecchio indice in modo da effettuare lo scambio in BindingColumns una volta riordinate graficamente
OldIndex = e.Column.DisplayIndex OldIndex = e.Column.DisplayIndex
End Sub End Sub
Private Sub CurrDataGrid_ColumnReordered(sender As Object, e As DataGridColumnEventArgs) Handles Me.ColumnReordered Private Sub CurrDataGrid_ColumnReordered(sender As Object, e As DataGridColumnEventArgs) Handles CurrDataGrid.ColumnReordered
' scambio le colonne in BindingColumns ' scambio le colonne in BindingColumns
BindingColumns.Move(OldIndex, e.Column.DisplayIndex) BindingColumns.Move(OldIndex, e.Column.DisplayIndex)
' scrivo tutte le colonne interessate dallo spostamento ' scrivo tutte le colonne interessate dallo spostamento
@@ -389,12 +315,12 @@ Public Class EgtDataGrid
ResetSortDirections() ResetSortDirections()
End Sub End Sub
Private Sub CurrDataGrid_Loaded(sender As Object, e As RoutedEventArgs) Handles Me.Loaded Private Sub CurrDataGrid_Loaded(sender As Object, e As RoutedEventArgs) Handles CurrDataGrid.Loaded
' setto la SortDirection, se attiva, sulla colonna su cui è attiva ' setto la SortDirection, se attiva, sulla colonna su cui è attiva
Dim colIndex As Integer = 0 Dim colIndex As Integer = 0
For Each col In BindingColumns For Each col In BindingColumns
If col.SortDirection > 0 Then If col.SortDirection > 0 Then
Me.Items.SortDescriptions.Add(New SortDescription(Me.Columns(colIndex).SortMemberPath, col.SortDirection - 1)) CurrDataGrid.Items.SortDescriptions.Add(New SortDescription(CurrDataGrid.Columns(colIndex).SortMemberPath, col.SortDirection - 1))
Exit For Exit For
End If End If
colIndex += 1 colIndex += 1
@@ -407,7 +333,7 @@ Public Class EgtDataGrid
Next Next
End Sub End Sub
Private Sub CurrDataGrid_Sorting(sender As Object, e As DataGridSortingEventArgs) Handles Me.Sorting Private Sub CurrDataGrid_Sorting(sender As Object, e As DataGridSortingEventArgs) Handles CurrDataGrid.Sorting
' salvo la SortDirection corrente della colonna prima di resettarla per tutte le colonne ' salvo la SortDirection corrente della colonna prima di resettarla per tutte le colonne
Dim CurrSortDirection As ListSortDirection? = e.Column.SortDirection Dim CurrSortDirection As ListSortDirection? = e.Column.SortDirection
ResetSortDirections(True) ResetSortDirections(True)
@@ -430,16 +356,129 @@ Public Class EgtDataGrid
Next Next
Else Else
' altrimenti (caso ResetSort da ContextMenu) è necessatio un Clear più ampio e anche grafico ' altrimenti (caso ResetSort da ContextMenu) è necessatio un Clear più ampio e anche grafico
Me.Items.SortDescriptions.Clear() CurrDataGrid.Items.SortDescriptions.Clear()
For Each column In BindingColumns For Each column In BindingColumns
column.SortDirection = 0 column.SortDirection = 0
' resetto graficamente anche l'header della colonna ' resetto graficamente anche l'header della colonna
Me.Columns(column.DisplayIndex).SortDirection = Nothing CurrDataGrid.Columns(column.DisplayIndex).SortDirection = Nothing
Next Next
RaiseEvent ResetSort() RaiseEvent ResetSort()
End If End If
End Sub End Sub
#Region "COLUMN HEADER PROPERTY DATAGRID"
#Region "BACKGROUND HEADER"
Public Shared ReadOnly ColumnHeaderBackgroundProperty As DependencyProperty = DependencyProperty.Register("ColumnHeaderBackground",
GetType(Brush),
GetType(EgtDataGrid),
New FrameworkPropertyMetadata(SystemColors.ControlBrush))
Public Property ColumnHeaderBackground As Brush
Get
Return DirectCast(GetValue(ColumnHeaderBackgroundProperty), Brush)
End Get
Set(value As Brush)
SetValue(ColumnHeaderBackgroundProperty, value)
End Set
End Property
#End Region ' BackGround Heder
#Region "FOREGROUND HEADER"
Public Shared ReadOnly ColumnHeaderForegroundProperty As DependencyProperty = DependencyProperty.Register("ColumnHeaderForeground",
GetType(Brush),
GetType(EgtDataGrid),
New FrameworkPropertyMetadata(SystemColors.ControlTextBrush))
Public Property ColumnHeaderForeground As Brush
Get
Return DirectCast(GetValue(ColumnHeaderForegroundProperty), Brush)
End Get
Set(value As Brush)
SetValue(ColumnHeaderForegroundProperty, value)
End Set
End Property
#End Region ' Foreground Header
#Region "FONTWEIGHT HEADER"
Public Shared ReadOnly ColumnHeaderFontWeightProperty As DependencyProperty = DependencyProperty.Register("ColumnHeaderFontWeight",
GetType(FontWeight),
GetType(EgtDataGrid),
New FrameworkPropertyMetadata(FontWeights.Normal))
Public Property ColumnHeaderFontWeight As FontWeight
Get
Return DirectCast(GetValue(ColumnHeaderFontWeightProperty), FontWeight)
End Get
Set(value As FontWeight)
SetValue(ColumnHeaderFontWeightProperty, value)
End Set
End Property
#End Region ' FontWeight Header
#Region "FONTSIZE HEADER"
Public Shared ReadOnly ColumnHeaderFontSizeProperty As DependencyProperty = DependencyProperty.Register("ColumnHeaderFontSize",
GetType(Double),
GetType(EgtDataGrid),
New FrameworkPropertyMetadata(Convert.ToDouble(12)))
Public Property ColumnHeaderFontSize As Double
Get
Return DirectCast(GetValue(ColumnHeaderFontSizeProperty), Double)
End Get
Set(value As Double)
SetValue(ColumnHeaderFontSizeProperty, value)
End Set
End Property
#End Region ' FontSize Header
#Region "HORIZONTAKCONTENTALIGNMENT HEADER"
Public Shared ReadOnly ColumnHeaderHorizontalContentAlignmentProperty As DependencyProperty = DependencyProperty.Register("ColumnHeaderHorizontalContentAlignment",
GetType(HorizontalAlignment),
GetType(EgtDataGrid),
New FrameworkPropertyMetadata(HorizontalAlignment.Stretch))
Public Property ColumnHeaderHorizontalContentAlignment As HorizontalAlignment
Get
Return DirectCast(GetValue(ColumnHeaderHorizontalContentAlignmentProperty), HorizontalAlignment)
End Get
Set(value As HorizontalAlignment)
SetValue(ColumnHeaderHorizontalContentAlignmentProperty, value)
End Set
End Property
#End Region ' HorizontalContentAlignment Header
#Region "PADDING HEADER"
Public Shared ReadOnly ColumnHeaderPaddingProperty As DependencyProperty = DependencyProperty.Register("ColumnHeaderPadding",
GetType(Thickness),
GetType(EgtDataGrid),
New FrameworkPropertyMetadata(New Thickness(0)))
Public Property ColumnHeaderPadding As Thickness
Get
Return DirectCast(GetValue(ColumnHeaderPaddingProperty), Thickness)
End Get
Set(value As Thickness)
SetValue(ColumnHeaderPaddingProperty, value)
End Set
End Property
#End Region ' Padding Header
#End Region ' Column Header Property DataGrid
End Class End Class
Public Class EgtDataGridColumn Public Class EgtDataGridColumn
@@ -59,7 +59,12 @@ Public Module LoadingWndHelper
m_thread = New Thread(Sub() m_thread = New Thread(Sub()
m_LoadingWndVM = New Core.LoadingWndVM(nSteps, TotText, AddressOf LoadingCallback) m_LoadingWndVM = New Core.LoadingWndVM(nSteps, TotText, AddressOf LoadingCallback)
m_LoadingWndVM.UpdateProgress(m_CurrStep, m_StepText, m_nProgress, m_nNextProgress) m_LoadingWndVM.UpdateProgress(m_CurrStep, m_StepText, m_nProgress, m_nNextProgress)
Dim LoadingWnd As New OnlyProdLoadingWndV(Nothing, m_LoadingWndVM) Dim LoadingWnd As Object
If bOnlyProd Then
LoadingWnd = New OnlyProdLoadingWndV(Nothing, m_LoadingWndVM)
Else
LoadingWnd = New LoadingWndV(Nothing, m_LoadingWndVM)
End If
' posiziono la finestra ' posiziono la finestra
If WindowStartupLocation = Windows.WindowStartupLocation.CenterScreen Then If WindowStartupLocation = Windows.WindowStartupLocation.CenterScreen Then
LoadingWnd.WindowStartupLocation = Windows.WindowStartupLocation.CenterScreen LoadingWnd.WindowStartupLocation = Windows.WindowStartupLocation.CenterScreen
@@ -88,6 +88,7 @@ Public Class MyMachGroupPanelM
Return Nothing Return Nothing
End Function End Function
' funzione che restituisce solo i gruppi di lavorazione creati nel nesting ' funzione che restituisce solo i gruppi di lavorazione creati nel nesting
Public Shared Function UpdateFromNestingMyMachGroups(MachineList As List(Of Machine)) As List(Of MachGroupM) Public Shared Function UpdateFromNestingMyMachGroups(MachineList As List(Of Machine)) As List(Of MachGroupM)
Dim TempList As New List(Of MachGroupM) Dim TempList As New List(Of MachGroupM)
@@ -341,9 +342,7 @@ Public Class MyMachGroupPanelM
End Sub End Sub
Public Shared Sub SetDuploModified(nPartId As Integer) Public Shared Sub SetDuploModified(nPartId As Integer)
Dim nDuploCount As Integer = 0 If Configuration.bOnlyProd Then
EgtDuploCount(nPartId, nDuploCount)
If nDuploCount > 0 Then
' segno modificato e aggiorno duplo ' segno modificato e aggiorno duplo
EgtDuploSetModified(nPartId) EgtDuploSetModified(nPartId)
UpdateDuplo(nPartId) UpdateDuplo(nPartId)
@@ -354,6 +353,8 @@ Public Class MyMachGroupPanelM
For Each CurrMachGroup As MyMachGroupVM In DuploList For Each CurrMachGroup As MyMachGroupVM In DuploList
CurrMachGroup.RefreshMachGroup() CurrMachGroup.RefreshMachGroup()
Next Next
Else
EgtDuploSetModified(nPartId)
End If End If
End Sub End Sub
@@ -28,16 +28,16 @@
ToolTip="{Binding ToolDBToolTip}" ToolTip="{Binding ToolDBToolTip}"
Command="{Binding ToolDbCommand}" Command="{Binding ToolDbCommand}"
Style="{StaticResource GeneralConfigurationToolBar_TextButton}"/> Style="{StaticResource GeneralConfigurationToolBar_TextButton}"/>
<!--<Button Content="{Binding MachiningDbMsg}" <Button Content="{Binding MachiningDbMsg}"
Command="{Binding MachDbCommand}" Command="{Binding MachDbCommand}"
ToolTip="{Binding MachiningDbToolTip}" ToolTip="{Binding MachiningDbToolTip}"
Style="{StaticResource GeneralConfigurationToolBar_TextButton}" Width="100"/>--> Style="{StaticResource GeneralConfigurationToolBar_TextButton}" Width="100"/>
<Button Content="{Binding SetUpMsg}" <Button Content="{Binding SetUpMsg}"
Command="{Binding SetUpCommand}" Command="{Binding SetUpCommand}"
ToolTip="{Binding SetUpToolTip}" ToolTip="{Binding SetUpToolTip}"
Style="{StaticResource GeneralConfigurationToolBar_TextButton}" Style="{StaticResource GeneralConfigurationToolBar_TextButton}"
Visibility="{Binding SetUp_Visibility}"/> Visibility="{Binding SetUp_Visibility}"/>
<!--<Button ToolTip="{Binding BeamTable_ToolTip}" <Button ToolTip="{Binding BeamTable_ToolTip}"
Command="{Binding BeamTable_Command}" Command="{Binding BeamTable_Command}"
Visibility="{Binding BeamTable_Visibility}" Visibility="{Binding BeamTable_Visibility}"
Style="{StaticResource ToolBarWarehouse_Button}"> Style="{StaticResource ToolBarWarehouse_Button}">
@@ -48,7 +48,7 @@
Visibility="{Binding WallTable_Visibility}" Visibility="{Binding WallTable_Visibility}"
Style="{StaticResource ToolBarWarehouse_Button}"> Style="{StaticResource ToolBarWarehouse_Button}">
<Image Source="/Resources/Configuration/MachiningsTable.png" Stretch="Uniform"/> <Image Source="/Resources/Configuration/MachiningsTable.png" Stretch="Uniform"/>
</Button>--> </Button>
<Button Content="{Binding ParameterMachineMsg}" <Button Content="{Binding ParameterMachineMsg}"
ToolTip="{Binding ParameterMachineMsg}" ToolTip="{Binding ParameterMachineMsg}"
Command="{Binding ParameterMachine_Command}" Command="{Binding ParameterMachine_Command}"
@@ -90,7 +90,8 @@
</Grid> </Grid>
</GroupBox> </GroupBox>
<EgtBEAMWALL:EgtDataGrid Grid.Row="1" <EgtBEAMWALL:EgtDataGrid x:Name="MainDataGrid"
Grid.Row="1"
ItemsSource="{Binding ProjectList}" ItemsSource="{Binding ProjectList}"
SelectedItem="{Binding SelProject}" SelectedItem="{Binding SelProject}"
CanUserAddRows="False" CanUserAddRows="False"
@@ -103,6 +104,7 @@
Margin="5" Margin="5"
RowDetailsVisibilityMode="Visible" RowDetailsVisibilityMode="Visible"
CellEditEnding="MainDataGrid_CellEditEnding" CellEditEnding="MainDataGrid_CellEditEnding"
ColumnHeaderBackground="{x:Null}"
BindingColumns="{Binding ProdColumns}"> BindingColumns="{Binding ProdColumns}">
<DataGrid.Resources> <DataGrid.Resources>
<!-- ProdId --> <!-- ProdId -->
@@ -106,7 +106,12 @@
CellEditEnding="MainDataGrid_CellEditEnding" CellEditEnding="MainDataGrid_CellEditEnding"
AlternatingRowBackground="{StaticResource BeamWall_LinkWater}" AlternatingRowBackground="{StaticResource BeamWall_LinkWater}"
AlternationCount="2" AlternationCount="2"
ColumnHeaderStyle="{StaticResource Main_DataGridColumnHeader}" ColumnHeaderBackground="{StaticResource BeamWall_Teal}"
ColumnHeaderForeground="{StaticResource BeamWall_White}"
ColumnHeaderHorizontalContentAlignment="Center"
ColumnHeaderFontWeight="Bold"
ColumnHeaderFontSize="15"
ColumnHeaderPadding="0,2,0,2"
Style="{StaticResource DataGrid_OnlyProd}" Style="{StaticResource DataGrid_OnlyProd}"
CellStyle="{StaticResource CellDataGrid_CustomHighLight}"> CellStyle="{StaticResource CellDataGrid_CustomHighLight}">
<DataGrid.Resources> <DataGrid.Resources>
@@ -102,7 +102,12 @@
BindingColumns="{Binding ProjectColumns}" BindingColumns="{Binding ProjectColumns}"
AlternatingRowBackground="{StaticResource BeamWall_LinkWater}" AlternatingRowBackground="{StaticResource BeamWall_LinkWater}"
AlternationCount="2" AlternationCount="2"
ColumnHeaderStyle="{StaticResource Main_DataGridColumnHeader}" ColumnHeaderBackground="{StaticResource BeamWall_Teal}"
ColumnHeaderForeground="{StaticResource BeamWall_White}"
ColumnHeaderHorizontalContentAlignment="Center"
ColumnHeaderFontWeight="Bold"
ColumnHeaderFontSize="15"
ColumnHeaderPadding="0,2,0,2"
Style="{StaticResource DataGrid_OnlyProd}" Style="{StaticResource DataGrid_OnlyProd}"
CellStyle="{StaticResource CellDataGrid_CustomHighLight}"> CellStyle="{StaticResource CellDataGrid_CustomHighLight}">
<DataGrid.RowStyle> <DataGrid.RowStyle>
@@ -94,6 +94,7 @@
ScrollViewer.CanContentScroll="True" ScrollViewer.CanContentScroll="True"
ScrollViewer.VerticalScrollBarVisibility="Auto" ScrollViewer.VerticalScrollBarVisibility="Auto"
ScrollViewer.HorizontalScrollBarVisibility="Auto" ScrollViewer.HorizontalScrollBarVisibility="Auto"
ColumnHeaderBackground="{x:Null}"
Margin="5" Margin="5"
BindingColumns="{Binding ProjectColumns}"> BindingColumns="{Binding ProjectColumns}">
<DataGrid.Resources> <DataGrid.Resources>
@@ -0,0 +1,208 @@
<EgtWPFLib5:EgtCustomWindow x:Class="OnlyProdSetUpWindowV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
Title="{Binding TitleMsg}"
WindowStyle="None" ResizeMode="NoResize" TitleBarHeight="30" IsResizable="False"
IsMinimizable="False" WindowStartupLocation="CenterOwner" ShowInTaskbar="False"
CloseCommand="{Binding CloseSetUpCommand, Mode=OneWay, UpdateSourceTrigger=PropertyChanged}"
Style="{StaticResource OnlyProd_EgtCustomWindow}">
<EgtWPFLib5:EgtCustomWindow.Resources>
<Style x:Key="HorizontalScrollViewerItemsControlStyle" TargetType="{x:Type ItemsControl}">
<Setter Property="ItemsPanel">
<Setter.Value>
<ItemsPanelTemplate>
<WrapPanel Orientation="Vertical"/>
</ItemsPanelTemplate>
</Setter.Value>
</Setter>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type ItemsControl}">
<ScrollViewer HorizontalScrollBarVisibility="Auto" VerticalScrollBarVisibility="Disabled" >
<ItemsPresenter/>
</ScrollViewer>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</EgtWPFLib5:EgtCustomWindow.Resources>
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="3*"/>
</Grid.ColumnDefinitions>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="1*"/>
</Grid.RowDefinitions>
<UniformGrid Columns="4">
<Button Content="{Binding ApplyMsg}" Command="{Binding ApplyCommand}"
IsEnabled="{Binding IsEnabledApplyBtn}" Height="30"
Style="{StaticResource OnlyRightPanel_HalfRound_Button}"/>
<Button Content="{Binding ArchiveMsg}" Command="{Binding ArchiveCommand}" Height="30"
Style="{StaticResource OnlyRightPanel_HalfRound_Button}"/>
<Button Content="{Binding RetrievesMsg}" Command="{Binding RetrievesCommand}" Height="30"
CommandParameter="{Binding SelectedItem,ElementName=ToolsTreeView}"
Style="{StaticResource OnlyRightPanel_HalfRound_Button}"/>
<Button Content="{Binding AutomaticMsg}" Command="{Binding AutomaticCommand}" Height="30"
CommandParameter="{Binding SelectedItem,ElementName=ToolsTreeView}"
Style="{StaticResource OnlyRightPanel_HalfRound_Button}"/>
</UniformGrid>
<TreeView Grid.Row="1" Name="ToolsTreeView" ItemsSource="{Binding ToolsList}">
<TreeView.Style>
<Style TargetType="{x:Type TreeView}">
<Setter Property="Background">
<Setter.Value>
<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.35,0">
<GradientStop Color="{StaticResource BeamWall_Mercury_Color}" Offset="0"/>
<GradientStop Color="{StaticResource BeamWall_Concrete_Color}" Offset="0.45"/>
<GradientStop Color="{StaticResource BeamWall_White_Color}" Offset="1"/>
</LinearGradientBrush>
</Setter.Value>
</Setter>
</Style>
</TreeView.Style>
<TreeView.ItemContainerStyle>
<Style TargetType="{x:Type TreeViewItem}">
<Setter Property="IsSelected" Value="{Binding IsSelected, Mode=TwoWay}" />
<Setter Property="IsExpanded" Value="{Binding IsExpanded, Mode=TwoWay}" />
<EventSetter Event="MouseDoubleClick" Handler="Tool_DoubleClick"/>
</Style>
</TreeView.ItemContainerStyle>
<TreeView.Resources>
<HierarchicalDataTemplate DataType="{x:Type EgtWPFLib5:FamilyToolItem}" ItemsSource="{Binding Items}">
<Grid Height="20">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<Image Grid.Column="0" Source="{Binding PictureString}" Height="20" Width="20" Margin="0,0,5,0" />
<TextBlock Grid.Column="1" Text="{Binding Name}" FontSize="15" Margin="0,-2,5,0" VerticalAlignment="Center" />
<Ellipse Grid.Column="2" Height="10" Width="10" Fill="{Binding FamilyColor}" />
</Grid>
</HierarchicalDataTemplate>
<DataTemplate DataType="{x:Type EgtWPFLib5:ToolItem}">
<Grid Height="20" ToolTip="{Binding ToolTipMsg}">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<!--<Image Grid.Column="0" Source="{Binding PictureString}" Height="32" Margin="0,8,6,4" />-->
<TextBlock Grid.Column="1" Text="{Binding Name}" FontSize="15" Margin="0,-2,5,0" VerticalAlignment="Center" />
<Ellipse Grid.Column="2" Height="10" Width="10" Fill="{Binding ToolColor}" />
</Grid>
</DataTemplate>
</TreeView.Resources>
</TreeView>
</Grid>
<Grid Grid.Column="1">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions>
<Image Source="{Binding SetUpImage}" MaxWidth="300"/>
<ItemsControl Grid.Column="1" ItemsSource="{Binding PositionGroupList}"
Style="{DynamicResource HorizontalScrollViewerItemsControlStyle}">
<ItemsControl.ItemsPanel>
<ItemsPanelTemplate>
<StackPanel Orientation="Horizontal"/>
</ItemsPanelTemplate>
</ItemsControl.ItemsPanel>
<ItemsControl.ItemTemplate>
<DataTemplate>
<ItemsControl Grid.Column="1" ItemsSource="{Binding PositionList}" Margin="0,0,20,0">
<ItemsControl.ItemsPanel>
<ItemsPanelTemplate>
<WrapPanel Orientation="Vertical"/>
</ItemsPanelTemplate>
</ItemsControl.ItemsPanel>
<ItemsControl.ItemTemplate>
<DataTemplate>
<Grid Margin="5,5,15,5">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="30"/>
<ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions>
<TextBlock Text="{Binding TcPos}"/>
<ItemsControl Grid.Column="1" ItemsSource="{Binding ExitToolAssociationList}"
HorizontalAlignment="Left">
<ItemsControl.ItemsPanel>
<ItemsPanelTemplate>
<!--<WrapPanel Orientation="Horizontal" MaxWidth="200"/>-->
<UniformGrid Columns="1"/>
</ItemsPanelTemplate>
</ItemsControl.ItemsPanel>
<ItemsControl.ItemTemplate>
<DataTemplate>
<Grid Margin="10,0,0,5">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions>
<ToggleButton Content="{Binding ExitPar}" Name="ExitBtn"
CommandParameter="{Binding SelectedItem,ElementName=ToolsTreeView}"
IsChecked="{Binding IsOccupied}" Height="25" Width="25" Margin="0,0,5,0"
Command="{Binding SetUpToolCommand}"
IsEnabled="{Binding IsEnabledPos}"
Background="{Binding ExitBtnBackgroundCol}"/>
<Border x:Name="ToolBorder" Grid.Column="1" BorderBrush="#4D84C4"
BorderThickness="1" ToolTip="{Binding ToolTipMsg}">
<Border.Style>
<Style TargetType="{x:Type Border}">
<Setter Property="Visibility" Value="Hidden"/>
<Style.Triggers>
<DataTrigger Binding="{Binding ElementName=ExitBtn, Path=IsChecked}" Value="True">
<Setter Property="Visibility" Value="Visible"/>
</DataTrigger>
</Style.Triggers>
</Style>
</Border.Style>
<TextBlock Text="{Binding Tool.Name}" Margin="3"/>
</Border>
</Grid>
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>
</Grid>
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>
</Grid>
</Grid>
</EgtWPFLib5:EgtCustomWindow>
@@ -0,0 +1,31 @@
Imports EgtWPFLib5
Imports System.Windows.Controls
Imports System.Windows.Input
Public Class OnlyProdSetUpWindowV
Private WithEvents m_SetUpWindowVM As SetUpWindowVM
Sub New(Owner As System.Windows.Window, SetUpWindowVM As SetUpWindowVM)
MyBase.New(Owner)
' This call is required by the designer.
InitializeComponent()
Me.DataContext = SetUpWindowVM
' Assegno al riferimento locale al VM il VM preso dal DataContext
m_SetUpWindowVM = SetUpWindowVM
End Sub
Private Sub Tool_DoubleClick(sender As Object, e As MouseButtonEventArgs)
Dim TreeViewItem As TreeViewItem = DirectCast(sender, TreeViewItem)
If TypeOf TreeViewItem.DataContext Is ToolItem Then
Dim SelTool As ToolItem = DirectCast(TreeViewItem.DataContext, ToolItem)
m_SetUpWindowVM.ToolDoubleClick(SelTool)
e.Handled = True
End If
End Sub
Private Sub CloseWindow(bDialogResult As Boolean) Handles m_SetUpWindowVM.m_CloseWindow
Me.DialogResult = bDialogResult
End Sub
End Class
@@ -0,0 +1,138 @@
<EgtWPFLib5:EgtCustomWindow x:Class="OnlyProdToolDbWindowV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:sys="clr-namespace:System;assembly=mscorlib"
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
Title="{Binding Title}"
WindowStyle="None" ResizeMode="NoResize" TitleBarHeight="30" IsResizable="False"
IsMinimizable="False" WindowStartupLocation="CenterOwner" ShowInTaskbar="False"
CloseCommand="{Binding CloseToolsDbCommand,Mode=OneWay,UpdateSourceTrigger=PropertyChanged}"
CloseCommandParameter="{Binding Path=SelectedItem, ElementName=ToolsTreeView}"
Style="{StaticResource OnlyProd_EgtCustomWindow}">
<EgtWPFLib5:EgtCustomWindow.InputBindings>
<KeyBinding Key="Escape" Command="{Binding ReloadToolCommand}"
CommandParameter="{Binding Path=SelectedItem,ElementName=ToolsTreeView}"/>
</EgtWPFLib5:EgtCustomWindow.InputBindings>
<EgtWPFLib5:EgtCustomWindow.Resources>
<EgtWPFLib5:ToolDrawUUIDConverter x:Key="ToolDrawUUIDConverter"/>
<EgtWPFLib5:ErrorVisibilityConverter x:Key="ErrorVisibilityConverter"/>
</EgtWPFLib5:EgtCustomWindow.Resources>
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="0.75*"/>
<ColumnDefinition Width="2*"/>
<ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="10*"/>
<RowDefinition Height="Auto"/>
</Grid.RowDefinitions>
<UniformGrid Grid.Row="0" Columns="3">
<Button Content="{Binding NewMsg}" Command="{Binding NewCommand}"
CommandParameter="{Binding Path=SelectedItem, ElementName=ToolsTreeView}"
IsEnabled="{Binding IsEnabledNewBtn, Mode=OneWay}" Height="30"
Style="{StaticResource OnlyRightPanel_HalfRound_Button}"/>
<Button Content="{Binding SaveMsg}" Command="{Binding SaveCommand}"
CommandParameter="{Binding Path=SelectedItem, ElementName=ToolsTreeView}"
IsEnabled="{Binding IsEnabledSaveBtn, Mode=OneWay}" Height="30"
Style="{StaticResource OnlyRightPanel_HalfRound_Button}"/>
<Button Content="{Binding RemoveMsg}" Command="{Binding RemoveCommand}"
CommandParameter="{Binding Path=SelectedItem, ElementName=ToolsTreeView}"
IsEnabled="{Binding IsEnabledRemoveBtn, Mode=OneWay}" Height="30"
Style="{StaticResource OnlyRightPanel_HalfRound_Button}"/>
</UniformGrid>
<TreeView Name="ToolsTreeView" Grid.Row="1" ItemsSource="{Binding ToolsList}">
<TreeView.Style>
<Style TargetType="{x:Type TreeView}">
<Setter Property="Background">
<Setter.Value>
<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.35,0">
<GradientStop Color="{StaticResource BeamWall_Mercury_Color}" Offset="0"/>
<GradientStop Color="{StaticResource BeamWall_Concrete_Color}" Offset="0.45"/>
<GradientStop Color="{StaticResource BeamWall_White_Color}" Offset="1"/>
</LinearGradientBrush>
</Setter.Value>
</Setter>
</Style>
</TreeView.Style>
<TreeView.ItemContainerStyle>
<Style TargetType="{x:Type TreeViewItem}">
<Setter Property="IsSelected" Value="{Binding IsSelected, Mode=TwoWay}" />
<Setter Property="IsExpanded" Value="{Binding IsExpanded, Mode=TwoWay}" />
<Setter Property="IsEnabled" Value="{Binding IsEnabled, Mode=TwoWay}" />
</Style>
</TreeView.ItemContainerStyle>
<TreeView.Resources>
<HierarchicalDataTemplate DataType="{x:Type EgtWPFLib5:FamilyToolTreeViewItem}" ItemsSource="{Binding Items}">
<Grid Height="20">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions>
<Image Grid.Column="0" Source="{Binding PictureString}" Height="20" Width="20" Margin="0,0,5,0" />
<TextBlock Grid.Column="1" Text="{Binding Name}" FontSize="15" Margin="0,-2,5,0" VerticalAlignment="Center" />
</Grid>
</HierarchicalDataTemplate>
<DataTemplate DataType="{x:Type EgtWPFLib5:ToolTreeViewItem}">
<Grid Height="20">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions>
<!--<Image Grid.Column="0" Source="{Binding PictureString}" Height="32" Margin="0,8,6,4" />-->
<CheckBox Name="ActiveTxBx" Grid.Column="0" Height="15" Width="15" Margin="-15,0,5,0" VerticalContentAlignment="Center"
IsChecked="{Binding Active}"
Visibility="{Binding Path=DataContext.Active_Visibility,
RelativeSource={RelativeSource AncestorType={x:Type EgtWPFLib5:EgtCustomWindow}}}"/>
<TextBlock Grid.Column="1" Text="{Binding NamePar}" FontSize="15" Margin="0,-2,5,0" VerticalAlignment="Center" />
</Grid>
</DataTemplate>
</TreeView.Resources>
</TreeView>
<UniformGrid Grid.Row="2" Columns="3">
<Button Content="{Binding ImportMsg}"
Command="{Binding ImportCommand}"
IsEnabled="{Binding IsEnabledImpExpBtn, Mode=OneWay}"
Height="30"
Style="{StaticResource OnlyRightPanel_HalfRound_Button}"/>
<Button Content="{Binding ExportMsg}"
Command="{Binding ExportCommand}"
IsEnabled="{Binding IsEnabledImpExpBtn, Mode=OneWay}"
Height="30"
Style="{StaticResource OnlyRightPanel_HalfRound_Button}"/>
<Button Content="{Binding ResetMsg}"
Command="{Binding ReloadToolCommand}"
CommandParameter="{Binding Path=SelectedItem,ElementName=ToolsTreeView}"
Height="30"
Style="{StaticResource OnlyRightPanel_HalfRound_Button}"/>
</UniformGrid>
</Grid>
<ContentControl Content="{Binding Path=ParamPageV}" Grid.Column="1"/>
<!--ContentControl che ospita la scena restituita sotto forma di WindowsFormsHost-->
<ContentControl Content="{Binding ToolSceneHost}" Grid.Column="2"/>
</Grid>
</EgtWPFLib5:EgtCustomWindow>
@@ -0,0 +1,33 @@
Imports EgtWPFLib5
Imports System.Windows.Input
Imports EgtUILib
Public Class OnlyProdToolDbWindowV
Private WithEvents m_ToolDbWindowVM As ToolDbWindowVM
Sub New(Owner As System.Windows.Window, ToolDbWindowVM As ToolDbWindowVM)
MyBase.New(Owner)
' This call is required by the designer.
InitializeComponent()
Me.DataContext = ToolDbWindowVM
' Assegno al riferimento locale al VM il VM preso dal DataContext
m_ToolDbWindowVM = ToolDbWindowVM
End Sub
Private Sub ToolsDbView_Closed(bDialogResult As Boolean) Handles m_ToolDbWindowVM.m_CloseWindow
' Imposto contesto generale
EgtSetCurrentContext(ToolDbWindowVM.ProjectSceneContext)
' Cancello contesto di visualizzazione utensile
EgtDeleteContext(ToolDbWindowVM.ToolDbSceneContext)
Me.Close()
End Sub
Private Sub ToolsDbView_Closing(sender As Object, e As System.ComponentModel.CancelEventArgs) Handles Me.Closing
If (Keyboard.Modifiers And ModifierKeys.Alt) = ModifierKeys.Alt OrElse Keyboard.IsKeyDown(Key.F4) Then
e.Cancel = True
Return
End If
End Sub
End Class
+41
View File
@@ -6,6 +6,19 @@ Public Module Configuration
' Test per comunicazione ' Test per comunicazione
Public m_commLib As DataSyncro Public m_commLib As DataSyncro
''' <summary>
''' Flag per impostare la visualizzazione con la singola pagina
''' </summary>
Private m_bOnlyProd As Boolean
Public ReadOnly Property bOnlyProd As Boolean
Get
Return m_bOnlyProd
End Get
End Property
Public Sub SetOnlyProd(value As Boolean)
m_bOnlyProd = value
End Sub
''' <summary> ''' <summary>
''' Flag per visualizzare il pulsante Db Attrezzaggi ''' Flag per visualizzare il pulsante Db Attrezzaggi
''' </summary> ''' </summary>
@@ -67,6 +80,34 @@ Public Module Configuration
IniFile.m_sIniFile = m_sConfigDir & "\" & Core.ConstIni.INI_FILE_NAME IniFile.m_sIniFile = m_sConfigDir & "\" & Core.ConstIni.INI_FILE_NAME
End Sub End Sub
''' <summary>
''' Funzione per recuperare bOnlyProd
''' </summary>
''' <param name="Section">Sezione dove si trova la variabile che devo cercare</param>
''' <param name="Key">Variabile che sto cercando</param>
''' <param name="Path">Cartella dove e' presente il file ini</param>
''' <param name="Default_Value">Valore di defaul opzionabile</param>
''' <returns></returns>
Public Function Read_Value(Section As String, Key As String, Path As String, Optional Default_Value As String = "") As String
Dim Reader_Lines As String() = System.IO.File.ReadAllLines(Path)
Dim Current_Section As String = ""
For Each Reader_Line As String In Reader_Lines
If Reader_Line.StartsWith("[") AndAlso Reader_Line.EndsWith("]") Then
Current_Section = Reader_Line
ElseIf Current_Section.Equals($"[{Section}]") Then
Dim lineParts As String() = Reader_Line.Split({"="c}, 2)
If lineParts.Length >= 1 AndAlso lineParts(0) = Key Then
Return If(lineParts.Length >= 2, lineParts(1), Default_Value)
End If
End If
Next
Return Default_Value
End Function
''' <summary> ''' <summary>
''' Metodo che controlla la comunicazione server ''' Metodo che controlla la comunicazione server
''' </summary> ''' </summary>
+1 -1
View File
@@ -45,4 +45,4 @@ Public Class MyMachine
Return True Return True
End Function End Function
End Class End Class
+1 -1
View File
@@ -2,7 +2,7 @@
<packages> <packages>
<package id="EgwProxy.LiMan" version="1.0.2408.718" targetFramework="net472" /> <package id="EgwProxy.LiMan" version="1.0.2408.718" targetFramework="net472" />
<package id="Microsoft.Bcl.AsyncInterfaces" version="8.0.0" targetFramework="net472" /> <package id="Microsoft.Bcl.AsyncInterfaces" version="8.0.0" targetFramework="net472" />
<package id="Newtonsoft.Json" version="13.0.4" targetFramework="net472" /> <package id="Newtonsoft.Json" version="13.0.1" targetFramework="net472" />
<package id="RestSharp" version="111.2.0" targetFramework="net472" /> <package id="RestSharp" version="111.2.0" targetFramework="net472" />
<package id="System.Buffers" version="4.5.1" targetFramework="net472" /> <package id="System.Buffers" version="4.5.1" targetFramework="net472" />
<package id="System.Memory" version="4.5.5" targetFramework="net472" /> <package id="System.Memory" version="4.5.5" targetFramework="net472" />
@@ -71,7 +71,7 @@
<HintPath>..\packages\MySql.Data.EntityFramework.8.0.21\lib\net452\MySql.Data.EntityFramework.dll</HintPath> <HintPath>..\packages\MySql.Data.EntityFramework.8.0.21\lib\net452\MySql.Data.EntityFramework.dll</HintPath>
</Reference> </Reference>
<Reference Include="Newtonsoft.Json, Version=13.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL"> <Reference Include="Newtonsoft.Json, Version=13.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<HintPath>..\packages\Newtonsoft.Json.13.0.4\lib\net45\Newtonsoft.Json.dll</HintPath> <HintPath>..\packages\Newtonsoft.Json.13.0.1\lib\net45\Newtonsoft.Json.dll</HintPath>
</Reference> </Reference>
<Reference Include="NLog, Version=5.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL"> <Reference Include="NLog, Version=5.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
<HintPath>..\packages\NLog.5.0.1\lib\net46\NLog.dll</HintPath> <HintPath>..\packages\NLog.5.0.1\lib\net46\NLog.dll</HintPath>
+1 -1
View File
@@ -9,7 +9,7 @@
<package id="K4os.Hash.xxHash" version="1.0.8" targetFramework="net472" /> <package id="K4os.Hash.xxHash" version="1.0.8" targetFramework="net472" />
<package id="MySql.Data" version="8.0.21" targetFramework="net472" /> <package id="MySql.Data" version="8.0.21" targetFramework="net472" />
<package id="MySql.Data.EntityFramework" version="8.0.21" targetFramework="net472" /> <package id="MySql.Data.EntityFramework" version="8.0.21" targetFramework="net472" />
<package id="Newtonsoft.Json" version="13.0.4" targetFramework="net472" /> <package id="Newtonsoft.Json" version="13.0.1" targetFramework="net452" />
<package id="NLog" version="5.0.1" targetFramework="net472" /> <package id="NLog" version="5.0.1" targetFramework="net472" />
<package id="Portable.BouncyCastle" version="1.9.0" targetFramework="net472" /> <package id="Portable.BouncyCastle" version="1.9.0" targetFramework="net472" />
<package id="SSH.NET" version="2016.1.0" targetFramework="net472" /> <package id="SSH.NET" version="2016.1.0" targetFramework="net472" />
@@ -0,0 +1,18 @@
Public Class AddFeatureWndV
Private WithEvents m_AddFeatureWndVM As AddFeatureWndVM
Sub New(Owner As Window, AddFeatureWndVM As AddFeatureWndVM)
MyBase.New(Owner)
' This call is required by the designer.
InitializeComponent()
Me.DataContext = AddFeatureWndVM
' Assegno al riferimento locale al VM il VM preso dal DataContext
m_AddFeatureWndVM = AddFeatureWndVM
End Sub
Private Sub CloseWindow(bDialogResult As Boolean) Handles m_AddFeatureWndVM.m_CloseWindow
Me.DialogResult = bDialogResult
End Sub
End Class
@@ -2,119 +2,89 @@
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5" xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
xmlns:EgtBEAMWALL="clr-namespace:EgtBEAMWALL.Optimizer"
Style="{DynamicResource {x:Type EgtWPFLib5:EgtCustomWindow}}"
WindowStyle="None" ResizeMode="NoResize" WindowStyle="None" ResizeMode="NoResize"
SizeToContent="WidthAndHeight" SizeToContent="WidthAndHeight"
WindowStartupLocation="CenterOwner" WindowStartupLocation="CenterOwner"
IsClosable="False" IsClosable="False"
IsMinimizable="False" IsMinimizable="False"
IsResizable="False" IsResizable="False"
Title="AddProcess" Title="AddProcess">
Style="{StaticResource OnlyProd_EgtCustomWindow}"> <StackPanel Margin="5,5,5,0">
<TabControl SelectedIndex="{Binding SelGRPType}">
<Grid Margin="5"> <TabItem Header="L"/>
<Grid.ColumnDefinitions> <TabItem Header="T"/>
<ColumnDefinition Width="Auto"/> </TabControl>
<ColumnDefinition Width="1*"/> <Border Grid.Row="1"
<ColumnDefinition Width="Auto"/> BorderThickness="1"
</Grid.ColumnDefinitions> BorderBrush="DarkGray"
<Grid.RowDefinitions> Background="White"
<RowDefinition Height="Auto"/> Margin="0,-6,0,5">
<RowDefinition Height="1*"/> <Grid Margin="0,5,0,0">
<RowDefinition Height="Auto"/> <Grid.RowDefinitions>
</Grid.RowDefinitions> <RowDefinition Height="Auto"/>
<Border Background="{StaticResource BeamWall_Kashmir}" Margin="0,2,0,2" CornerRadius="4,0,0,4"> <RowDefinition Height="1*"/>
<TextBlock Text="{Binding Process_Msg}" <RowDefinition Height="Auto"/>
Style="{StaticResource ListTextBlock}"/> </Grid.RowDefinitions>
<Grid HorizontalAlignment="Center"
Grid.Row="0"
Margin="0,0,0,5">
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<TextBlock Text="Process"
Style="{StaticResource OptionTextBlock}"/>
<ComboBox ItemsSource="{Binding PRCList}"
SelectedItem="{Binding nSelPRC}"
Grid.Column="1"
DisplayMemberPath="ghDesc"
Width="200"
HorizontalAlignment="Left"
Style="{StaticResource FeatureComboBox}"/>
<TextBlock Text="Macro"
Grid.Row="1"
Margin="0,5,0,0"
Style="{StaticResource OptionTextBlock}"/>
<ComboBox ItemsSource="{Binding MacroCustomList}"
SelectedIndex="{Binding nSelMacroCustom}"
Grid.Row="1"
Grid.Column="1"
DisplayMemberPath="Name"
IsEnabled="{Binding MacroList_IsEnabled}"
Width="200"
Margin="0,5,0,0"
Style="{StaticResource FeatureComboBox}"/>
</Grid>
<Image Source="{Binding sDrawPath}"
Grid.Row="1"
Height="300"
Width="300"
Margin="5,0,5,5"/>
<Grid Grid.Row="2" Margin="0,0,0,5">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions>
<Button Content="Ok"
Command="{Binding Ok_Command}"
IsDefault="True"
Grid.Column="1"
Style="{StaticResource EgtWPFLib5_InputButton}"/>
<Button Content="Cancel"
IsCancel="True"
Grid.Column="3"
Style="{StaticResource EgtWPFLib5_InputButton}"/>
</Grid>
</Grid>
</Border> </Border>
<Border Grid.Row="1" </StackPanel>
Style="{StaticResource OnlyProdPage_Border}"
CornerRadius="4,0,0,4"
BorderThickness="2,2,0,2">
<ListBox Grid.Row="1"
ItemsSource="{Binding PRCListView}"
SelectedItem="{Binding nSelPRC}"
Style="{StaticResource NewAddFeature_ListBox}"
ItemContainerStyle="{StaticResource AlternationIndex_ListBoxItem}">
<ListBox.ItemTemplate>
<DataTemplate>
<TextBlock Text="{Binding ghDesc}"
ToolTip="{Binding ghDesc}"
TextAlignment="Justify"
Width="{Binding ActualWidth, RelativeSource={RelativeSource AncestorType={x:Type ListBox}}}"
Style="{StaticResource OptionTextBlock}"/>
</DataTemplate>
</ListBox.ItemTemplate>
</ListBox>
</Border>
<Border Grid.Column="1" Background="{StaticResource BeamWall_Kashmir}" Margin="0,2,0,2">
<TextBlock Grid.Column="1"
Text="{Binding Custom_Msg}"
Style="{StaticResource ListTextBlock}"/>
</Border>
<Border Grid.Row="1"
Grid.Column="1"
Style="{StaticResource OnlyProdPage_Border}"
CornerRadius="0"
BorderThickness="0,2,0,2">
<ListBox ItemsSource="{Binding MacroCustomList}"
SelectedIndex="{Binding nSelMacroCustom}"
Style="{StaticResource MacroCustom_ListBox}">
<ListBox.ItemsPanel>
<ItemsPanelTemplate>
<WrapPanel Style="{StaticResource MacroCustom_WrapPanel}"/>
</ItemsPanelTemplate>
</ListBox.ItemsPanel>
<ListBox.ItemTemplate>
<DataTemplate>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="1*"/>
</Grid.RowDefinitions>
<TextBlock Text="{Binding sMacroName}"
Style="{StaticResource Macro_TextBlock}"/>
<Image Grid.Row="1"
Source="{Binding sMacroDrawPath}"
Style="{StaticResource Macro_Image}"/>
</Grid>
</DataTemplate>
</ListBox.ItemTemplate>
</ListBox>
</Border>
<Border Grid.Column="2" Background="{StaticResource BeamWall_Kashmir}" Margin="0,2,0,2" Padding="0,10,0,10" CornerRadius="0,4,4,0">
<TextBlock
Text="{Binding Default_Msg}"
Style="{StaticResource ListTextBlock}"/>
</Border>
<Border Grid.Row="1"
Grid.Column="2"
Style="{StaticResource OnlyProdPage_Border}"
CornerRadius="0,4,4,0"
BorderThickness="0,2,2,2">
<ListBox ItemsSource="{Binding MacroDefaultList}"
SelectedIndex="{Binding nSelMacroDefault}"
Style="{StaticResource MacroDefault_ListBox}"
ItemContainerStyle="{StaticResource AlternationIndex_ListBoxItem}">
<ListBox.ItemTemplate>
<DataTemplate>
<TextBlock Text="{Binding sMacroName}"
TextAlignment="Justify"
Style="{StaticResource MacroDefault_TextBlock}"/>
</DataTemplate>
</ListBox.ItemTemplate>
</ListBox>
</Border>
<UniformGrid Columns="2"
Grid.Row="2"
Grid.ColumnSpan="3"
Margin="5">
<Button Content="{Binding OK_Msg}"
Command="{Binding Ok_Command}"
IsDefault="True"
Style="{StaticResource OnlyProdEgtWPFLib5_InputButton}"/>
<Button Content="{Binding Cancel_Msg}"
IsCancel="True"
Style="{StaticResource OnlyProdEgtWPFLib5_InputButton}"/>
</UniformGrid>
</Grid>
</EgtWPFLib5:EgtCustomWindow> </EgtWPFLib5:EgtCustomWindow>
@@ -98,7 +98,9 @@ Public Class AddFeatureWndVM
NotifyPropertyChanged(NameOf(sDrawPath)) NotifyPropertyChanged(NameOf(sDrawPath))
' carico eventuali file Macro ' carico eventuali file Macro
MacroCustomList.Clear() MacroCustomList.Clear()
MacroDefaultList.Clear() If Core.Configuration.bOnlyProd Then
MacroDefaultList.Clear()
End If
m_MacroFilePathList = New List(Of String) m_MacroFilePathList = New List(Of String)
m_MacroCustomFilePathList = New List(Of String) m_MacroCustomFilePathList = New List(Of String)
If Not IsNothing(nSelPRC) Then If Not IsNothing(nSelPRC) Then
@@ -109,7 +111,7 @@ Public Class AddFeatureWndVM
' ricavo lista file Macro Default ' ricavo lista file Macro Default
GetMacroListDefault(nGRPFromFileName, nPRCFromFileName, sMacroNameFromFileName, nIdMacroName) GetMacroListDefault(nGRPFromFileName, nPRCFromFileName, sMacroNameFromFileName, nIdMacroName)
' ricavo lista file Macro Custom ' ricavo lista file Macro Custom
GetMacroListCustom(nGRPFromFileName, nPRCFromFileName, sMacroNameFromFileName, nIdMacroName) If Core.Configuration.bOnlyProd Then GetMacroListCustom(nGRPFromFileName, nPRCFromFileName, sMacroNameFromFileName, nIdMacroName)
If MacroCustomList.Count > 0 Then If MacroCustomList.Count > 0 Then
MacroList_IsEnabled = True MacroList_IsEnabled = True
Else Else
@@ -209,34 +211,39 @@ Public Class AddFeatureWndVM
#Region "CONSTRUCTOR" #Region "CONSTRUCTOR"
Sub New() Sub New()
' carico lista process If Core.Configuration.bOnlyProd Then
Dim TempPRCList As New ObservableCollection(Of Integer) ' carico lista process
Dim TempPRCLList As New ObservableCollection(Of Integer) Dim TempPRCList As New ObservableCollection(Of Integer)
Dim TempPRCLTist As New ObservableCollection(Of Integer) Dim TempPRCLList As New ObservableCollection(Of Integer)
GetBeamPrivateProfileProcessList(0, TempPRCLList) Dim TempPRCLTist As New ObservableCollection(Of Integer)
GetBeamPrivateProfileProcessList(1, TempPRCLTist) GetBeamPrivateProfileProcessList(0, TempPRCLList)
' riporto le liste process in un unica lista GetBeamPrivateProfileProcessList(1, TempPRCLTist)
For Each PRCL In TempPRCLList ' riporto le liste process in un unica lista
TempPRCList.Add(PRCL) For Each PRCL In TempPRCLList
Next TempPRCList.Add(PRCL)
For Each PRCT In TempPRCLTist Next
TempPRCList.Add(PRCT) For Each PRCT In TempPRCLTist
Next TempPRCList.Add(PRCT)
m_PRCList.Clear() Next
' ciclo sulla lista process eliminado i doppi m_PRCList.Clear()
For Each PRC In TempPRCList.Distinct() ' ciclo sulla lista process eliminado i doppi
' leggo gruppi For Each PRC In TempPRCList.Distinct()
Dim GRPLList As New ObservableCollection(Of Integer) ' leggo gruppi
Dim GRPTList As New ObservableCollection(Of Integer) Dim GRPLList As New ObservableCollection(Of Integer)
GetBeamPrivateProfileGRPList(0, PRC, GRPLList) Dim GRPTList As New ObservableCollection(Of Integer)
GetBeamPrivateProfileGRPList(1, PRC, GRPTList) GetBeamPrivateProfileGRPList(0, PRC, GRPLList)
If GRPLList.Count > 0 Then m_PRCList.Add(New PRC(GRPLList(0), PRC, GetBeamPrivateProfileName(0, PRC))) GetBeamPrivateProfileGRPList(1, PRC, GRPTList)
If GRPTList.Count > 0 Then m_PRCList.Add(New PRC(GRPTList(0), PRC, GetBeamPrivateProfileName(1, PRC))) If GRPLList.Count > 0 Then m_PRCList.Add(New PRC(GRPLList(0), PRC, GetBeamPrivateProfileName(0, PRC)))
Next If GRPTList.Count > 0 Then m_PRCList.Add(New PRC(GRPTList(0), PRC, GetBeamPrivateProfileName(1, PRC)))
m_PRCListView = m_PRCList.OrderBy(Function(x) x.nPRC).ToList() Next
nSelPRC = m_PRCList(0) m_PRCListView = m_PRCList.OrderBy(Function(x) x.nPRC).ToList()
NotifyPropertyChanged(NameOf(PRCListView)) nSelPRC = m_PRCList(0)
NotifyPropertyChanged(NameOf(PRCList)) NotifyPropertyChanged(NameOf(PRCListView))
NotifyPropertyChanged(NameOf(PRCList))
Else
SelGRPType = 0
nSelPRC = PRCList(0)
End If
End Sub End Sub
#End Region ' CONSTRUCTOR #End Region ' CONSTRUCTOR
@@ -260,7 +267,11 @@ Public Class AddFeatureWndVM
sMacroNameFromFileName = DataFromFileName(1) sMacroNameFromFileName = DataFromFileName(1)
End If End If
If nGRPFromFileName = CalcBeamPrivateProfileGRP(nSelPRC.nGRP) AndAlso nPRCFromFileName = nSelPRC.nPRC Then If nGRPFromFileName = CalcBeamPrivateProfileGRP(nSelPRC.nGRP) AndAlso nPRCFromFileName = nSelPRC.nPRC Then
MacroCustomList.Add(New NewMacro(nIdMacroName, sMacroNameFromFileName, Map.refMainWindowVM.MainWindowM.sMacroCustomDir & "\Template\" & sMacroNameFromFileName & ".png")) If Core.Configuration.bOnlyProd Then
MacroCustomList.Add(New NewMacro(nIdMacroName, sMacroNameFromFileName, Map.refMainWindowVM.MainWindowM.sMacroCustomDir & "\Template\" & sMacroNameFromFileName & ".png"))
Else
MacroCustomList.Add(New IdNameStruct(nIdMacroName, sMacroNameFromFileName))
End If
m_MacroFilePathList.Add(File) m_MacroFilePathList.Add(File)
nIdMacroName += 1 nIdMacroName += 1
End If End If
@@ -374,12 +385,30 @@ Public Class PRC
End Get End Get
End Property End Property
' lista dei parametri Q della feature
Protected m_QBTLParamVMList As List(Of QBTLParamVM)
Public Property QBTLParamVMList As List(Of QBTLParamVM)
Get
Return m_QBTLParamVMList
End Get
Set(value As List(Of QBTLParamVM))
m_QBTLParamVMList = value
End Set
End Property
Sub New(GRP As Integer, PRC As Integer, Name As String) Sub New(GRP As Integer, PRC As Integer, Name As String)
m_nPRC = PRC m_nPRC = PRC
m_sName = Name m_sName = Name
m_nGRP = GRP m_nGRP = GRP
End Sub End Sub
Sub New(GRP As Integer, PRC As Integer, Name As String, QBTLParamList As List(Of QBTLParamVM))
m_nPRC = PRC
m_sName = Name
m_nGRP = GRP
m_QBTLParamVMList = QBTLParamList
End Sub
End Class End Class
Public Class NewMacro Public Class NewMacro
@@ -0,0 +1,120 @@
<EgtWPFLib5:EgtCustomWindow x:Class="NewAddFeatureWndV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
WindowStyle="None" ResizeMode="NoResize"
SizeToContent="WidthAndHeight"
WindowStartupLocation="CenterOwner"
IsClosable="False"
IsMinimizable="False"
IsResizable="False"
Title="AddProcess"
Style="{StaticResource OnlyProd_EgtCustomWindow}">
<Grid Margin="5">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="1*"/>
<RowDefinition Height="Auto"/>
</Grid.RowDefinitions>
<Border Background="{StaticResource BeamWall_Kashmir}" Margin="0,2,0,2" CornerRadius="4,0,0,4">
<TextBlock Text="{Binding Process_Msg}"
Style="{StaticResource ListTextBlock}"/>
</Border>
<Border Grid.Row="1"
Style="{StaticResource OnlyProdPage_Border}"
CornerRadius="4,0,0,4"
BorderThickness="2,2,0,2">
<ListBox Grid.Row="1"
ItemsSource="{Binding PRCListView}"
SelectedItem="{Binding nSelPRC}"
Style="{StaticResource NewAddFeature_ListBox}"
ItemContainerStyle="{StaticResource AlternationIndex_ListBoxItem}">
<ListBox.ItemTemplate>
<DataTemplate>
<TextBlock Text="{Binding ghDesc}"
ToolTip="{Binding ghDesc}"
TextAlignment="Justify"
Width="{Binding ActualWidth, RelativeSource={RelativeSource AncestorType={x:Type ListBox}}}"
Style="{StaticResource OptionTextBlock}"/>
</DataTemplate>
</ListBox.ItemTemplate>
</ListBox>
</Border>
<Border Grid.Column="1" Background="{StaticResource BeamWall_Kashmir}" Margin="0,2,0,2">
<TextBlock Grid.Column="1"
Text="{Binding Custom_Msg}"
Style="{StaticResource ListTextBlock}"/>
</Border>
<Border Grid.Row="1"
Grid.Column="1"
Style="{StaticResource OnlyProdPage_Border}"
CornerRadius="0"
BorderThickness="0,2,0,2">
<ListBox ItemsSource="{Binding MacroCustomList}"
SelectedIndex="{Binding nSelMacroCustom}"
Style="{StaticResource MacroCustom_ListBox}">
<ListBox.ItemsPanel>
<ItemsPanelTemplate>
<WrapPanel Style="{StaticResource MacroCustom_WrapPanel}"/>
</ItemsPanelTemplate>
</ListBox.ItemsPanel>
<ListBox.ItemTemplate>
<DataTemplate>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="1*"/>
</Grid.RowDefinitions>
<TextBlock Text="{Binding sMacroName}"
Style="{StaticResource Macro_TextBlock}"/>
<Image Grid.Row="1"
Source="{Binding sMacroDrawPath}"
Style="{StaticResource Macro_Image}"/>
</Grid>
</DataTemplate>
</ListBox.ItemTemplate>
</ListBox>
</Border>
<Border Grid.Column="2" Background="{StaticResource BeamWall_Kashmir}" Margin="0,2,0,2" Padding="0,10,0,10" CornerRadius="0,4,4,0">
<TextBlock
Text="{Binding Default_Msg}"
Style="{StaticResource ListTextBlock}"/>
</Border>
<Border Grid.Row="1"
Grid.Column="2"
Style="{StaticResource OnlyProdPage_Border}"
CornerRadius="0,4,4,0"
BorderThickness="0,2,2,2">
<ListBox ItemsSource="{Binding MacroDefaultList}"
SelectedIndex="{Binding nSelMacroDefault}"
Style="{StaticResource MacroDefault_ListBox}"
ItemContainerStyle="{StaticResource AlternationIndex_ListBoxItem}">
<ListBox.ItemTemplate>
<DataTemplate>
<TextBlock Text="{Binding sMacroName}"
TextAlignment="Justify"
Style="{StaticResource MacroDefault_TextBlock}"/>
</DataTemplate>
</ListBox.ItemTemplate>
</ListBox>
</Border>
<UniformGrid Columns="2"
Grid.Row="2"
Grid.ColumnSpan="3"
Margin="5">
<Button Content="{Binding OK_Msg}"
Command="{Binding Ok_Command}"
IsDefault="True"
Style="{StaticResource OnlyProdEgtWPFLib5_InputButton}"/>
<Button Content="{Binding Cancel_Msg}"
IsCancel="True"
Style="{StaticResource OnlyProdEgtWPFLib5_InputButton}"/>
</UniformGrid>
</Grid>
</EgtWPFLib5:EgtCustomWindow>
@@ -1,4 +1,4 @@
Public Class AddFeatureWndV Public Class NewAddFeatureWndV
Private WithEvents m_AddFeatureWndVM As AddFeatureWndVM Private WithEvents m_AddFeatureWndVM As AddFeatureWndVM
@@ -2,15 +2,15 @@
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5" xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
xmlns:EgtBEAMWALL="clr-namespace:EgtBEAMWALL.Optimizer"
Style="{DynamicResource {x:Type EgtWPFLib5:EgtCustomWindow}}"
WindowStyle="None" ResizeMode="NoResize" WindowStyle="None" ResizeMode="NoResize"
SizeToContent="WidthAndHeight" SizeToContent="WidthAndHeight"
WindowStartupLocation="CenterOwner" WindowStartupLocation="CenterOwner"
IsClosable="False" IsClosable="False"
IsMinimizable="False" IsMinimizable="False"
IsResizable="False" IsResizable="False"
Title="AddPartWndV" Title="AddPartWndV">
Style="{StaticResource OnlyProd_EgtCustomWindow}">
<Grid Margin="5,5,5,0"> <Grid Margin="5,5,5,0">
<Grid.RowDefinitions> <Grid.RowDefinitions>
<RowDefinition Height="Auto"/> <RowDefinition Height="Auto"/>
@@ -19,16 +19,17 @@
<RowDefinition Height="Auto"/> <RowDefinition Height="Auto"/>
</Grid.RowDefinitions> </Grid.RowDefinitions>
<Grid Style="{StaticResource OnlyProdAddPart_Grid}"> <Grid HorizontalAlignment="Center"
Margin="0,0,0,5">
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/> <ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/> <ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions> </Grid.ColumnDefinitions>
<TextBlock Text="Name" <TextBlock Text="Name"
Style="{StaticResource OptionTextBlock}"/> Style="{StaticResource OptionTextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1" <EgtWPFLib5:EgtTextBox Text="{Binding sNAM}"
Text="{Binding sNAM}" Grid.Column="1"
Style="{StaticResource NAM_TextBox}"/> Width="200"/>
</Grid> </Grid>
<Grid Grid.Row="1" <Grid Grid.Row="1"
Margin="0,0,0,5"> Margin="0,0,0,5">
@@ -40,15 +41,15 @@
</Grid.ColumnDefinitions> </Grid.ColumnDefinitions>
<TextBlock Text="Prod Number" <TextBlock Text="Prod Number"
Style="{StaticResource OptionTextBlock}"/> Style="{StaticResource OptionTextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1" <EgtWPFLib5:EgtTextBox Text="{Binding nPDN}"
Text="{Binding nPDN}" Grid.Column="1"
Style="{StaticResource Dimension_TextBox}"/> Width="45"/>
<TextBlock Grid.Column="2" <TextBlock Text="Count"
Text="Count" Grid.Column="2"
Style="{StaticResource OptionTextBlock}"/> Style="{StaticResource OptionTextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="3" <EgtWPFLib5:EgtTextBox Text="{Binding sCNT}"
Text="{Binding sCNT}" Grid.Column="3"
Style="{StaticResource Dimension_TextBox}"/> Width="45"/>
</Grid> </Grid>
<Grid Grid.Row="2" <Grid Grid.Row="2"
Margin="0,0,0,5"> Margin="0,0,0,5">
@@ -62,33 +63,41 @@
</Grid.ColumnDefinitions> </Grid.ColumnDefinitions>
<TextBlock Text="W" <TextBlock Text="W"
Style="{StaticResource OptionTextBlock}"/> Style="{StaticResource OptionTextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1" <EgtWPFLib5:EgtTextBox Text="{Binding sW}"
Text="{Binding sW}" Grid.Column="1"
Style="{StaticResource Dimension_TextBox}"/> Width="45"/>
<TextBlock Grid.Column="2" <TextBlock Text="H"
Text="H" Grid.Column="2"
Style="{StaticResource OptionTextBlock}"/> Style="{StaticResource OptionTextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="3" <EgtWPFLib5:EgtTextBox Text="{Binding sH}"
Text="{Binding sH}" Grid.Column="3"
Style="{StaticResource Dimension_TextBox}"/> Width="45"/>
<TextBlock Grid.Column="4" <TextBlock Text="L"
Text="L" Grid.Column="4"
Style="{StaticResource OptionTextBlock}"/> Style="{StaticResource OptionTextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="5" <EgtWPFLib5:EgtTextBox Text="{Binding sL}"
Text="{Binding sL}" Grid.Column="5"
Style="{StaticResource Dimension_TextBox}"/> Width="45"/>
</Grid> </Grid>
<UniformGrid Grid.Row="3" <Grid Grid.Row="3"
Columns="2" Margin="0,0,0,5">
Margin="0,5,0,5"> <Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions>
<Button Content="Ok" <Button Content="Ok"
Command="{Binding Ok_Command}" Command="{Binding Ok_Command}"
IsDefault="True" IsDefault="True"
Style="{StaticResource OnlyProdEgtWPFLib5_InputButton}"/> Grid.Column="1"
Style="{StaticResource EgtWPFLib5_InputButton}"/>
<Button Content="Cancel" <Button Content="Cancel"
IsCancel="True" IsCancel="True"
Style="{StaticResource OnlyProdEgtWPFLib5_InputButton}"/> Grid.Column="3"
</UniformGrid> Style="{StaticResource EgtWPFLib5_InputButton}"/>
</Grid>
</Grid> </Grid>
</EgtWPFLib5:EgtCustomWindow> </EgtWPFLib5:EgtCustomWindow>
@@ -0,0 +1,94 @@
<EgtWPFLib5:EgtCustomWindow x:Class="OnlyProdAddPartWndV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
WindowStyle="None" ResizeMode="NoResize"
SizeToContent="WidthAndHeight"
WindowStartupLocation="CenterOwner"
IsClosable="False"
IsMinimizable="False"
IsResizable="False"
Title="AddPartWndV"
Style="{StaticResource OnlyProd_EgtCustomWindow}">
<Grid Margin="5,5,5,0">
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
</Grid.RowDefinitions>
<Grid Style="{StaticResource OnlyProdAddPart_Grid}">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<TextBlock Text="Name"
Style="{StaticResource OptionTextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding sNAM}"
Style="{StaticResource NAM_TextBox}"/>
</Grid>
<Grid Grid.Row="1"
Margin="0,0,0,5">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<TextBlock Text="Prod Number"
Style="{StaticResource OptionTextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding nPDN}"
Style="{StaticResource Dimension_TextBox}"/>
<TextBlock Grid.Column="2"
Text="Count"
Style="{StaticResource OptionTextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="3"
Text="{Binding sCNT}"
Style="{StaticResource Dimension_TextBox}"/>
</Grid>
<Grid Grid.Row="2"
Margin="0,0,0,5">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<TextBlock Text="W"
Style="{StaticResource OptionTextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding sW}"
Style="{StaticResource Dimension_TextBox}"/>
<TextBlock Grid.Column="2"
Text="H"
Style="{StaticResource OptionTextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="3"
Text="{Binding sH}"
Style="{StaticResource Dimension_TextBox}"/>
<TextBlock Grid.Column="4"
Text="L"
Style="{StaticResource OptionTextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="5"
Text="{Binding sL}"
Style="{StaticResource Dimension_TextBox}"/>
</Grid>
<UniformGrid Grid.Row="3"
Columns="2"
Margin="0,5,0,5">
<Button Content="Ok"
Command="{Binding Ok_Command}"
IsDefault="True"
Style="{StaticResource OnlyProdEgtWPFLib5_InputButton}"/>
<Button Content="Cancel"
IsCancel="True"
Style="{StaticResource OnlyProdEgtWPFLib5_InputButton}"/>
</UniformGrid>
</Grid>
</EgtWPFLib5:EgtCustomWindow>
@@ -0,0 +1,18 @@
Public Class OnlyProdAddPartWndV
Private WithEvents m_AddPartWndVM As AddPartWndVM
Sub New(Owner As Window, AddPartWndVM As AddPartWndVM)
MyBase.New(Owner)
' This call is required by the designer.
InitializeComponent()
Me.DataContext = AddPartWndVM
' Assegno al riferimento locale al VM il VM preso dal DataContext
m_AddPartWndVM = AddPartWndVM
End Sub
Private Sub CloseWindow(bDialogResult As Boolean) Handles m_AddPartWndVM.m_CloseWindow
Me.DialogResult = bDialogResult
End Sub
End Class
@@ -2,14 +2,15 @@
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5" xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
xmlns:EgtBEAMWALL="clr-namespace:EgtBEAMWALL.Optimizer"
Style="{DynamicResource {x:Type EgtWPFLib5:EgtCustomWindow}}"
WindowStyle="None" ResizeMode="NoResize" WindowStyle="None" ResizeMode="NoResize"
SizeToContent="WidthAndHeight" SizeToContent="WidthAndHeight"
WindowStartupLocation="CenterOwner" WindowStartupLocation="CenterOwner"
IsClosable="False" IsClosable="False"
IsMinimizable="False" IsMinimizable="False"
IsResizable="False" IsResizable="False"
Title="AddRawPartWnd" Title="AddRawPartWnd">
Style="{StaticResource OnlyProd_EgtCustomWindow}">
<Grid Margin="5,5,5,0"> <Grid Margin="5,5,5,0">
<Grid.RowDefinitions> <Grid.RowDefinitions>
<RowDefinition Height="Auto"/> <RowDefinition Height="Auto"/>
@@ -20,10 +21,9 @@
SelectedItem="{Binding SelDimension}" SelectedItem="{Binding SelDimension}"
DisplayMemberPath="sDimension" DisplayMemberPath="sDimension"
Visibility="{Binding DimensionsList_Visibility}" Visibility="{Binding DimensionsList_Visibility}"
Margin="0,0,0,5" Margin="0,0,0,5"/>
Style="{StaticResource OnlyProd_ComboBox}"/> <ItemsControl ItemsSource="{Binding VariableList}"
<ItemsControl Grid.Row="1" Grid.Row="1">
ItemsSource="{Binding VariableList}">
<ItemsControl.ItemTemplate> <ItemsControl.ItemTemplate>
<DataTemplate> <DataTemplate>
<Grid Margin="0,0,0,5"> <Grid Margin="0,0,0,5">
@@ -34,27 +34,31 @@
<TextBlock Text="{Binding sMsg}" <TextBlock Text="{Binding sMsg}"
Style="{StaticResource OptionTextBlock}"/> Style="{StaticResource OptionTextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1" <EgtWPFLib5:EgtTextBox Text="{Binding sValue}"
Text="{Binding sValue}" Grid.Column="1"
Style="{StaticResource Value_TextBox}"/> Width="65"/>
</Grid> </Grid>
</DataTemplate> </DataTemplate>
</ItemsControl.ItemTemplate> </ItemsControl.ItemTemplate>
</ItemsControl> </ItemsControl>
<UniformGrid Grid.Row="2" <Grid Grid.Row="2"
Columns="2" Margin="0,0,0,5">
Margin="0,0,0,5"> <Grid.ColumnDefinitions>
<Button Grid.Column="1" <ColumnDefinition Width="1*"/>
Content="Ok" <ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions>
<Button Content="Ok"
Command="{Binding Ok_Command}" Command="{Binding Ok_Command}"
IsDefault="True" IsDefault="True"
Style="{StaticResource OnlyProdEgtWPFLib5_InputButton}" Grid.Column="1"
Margin="0,0,5,0"/> Style="{StaticResource EgtWPFLib5_InputButton}"/>
<Button Grid.Column="3" <Button Content="Cancel"
Content="Cancel"
IsCancel="True" IsCancel="True"
Style="{StaticResource OnlyProdEgtWPFLib5_InputButton}"/> Grid.Column="3"
</UniformGrid> Style="{StaticResource EgtWPFLib5_InputButton}"/>
</Grid>
</Grid> </Grid>
</EgtWPFLib5:EgtCustomWindow> </EgtWPFLib5:EgtCustomWindow>
@@ -0,0 +1,60 @@
<EgtWPFLib5:EgtCustomWindow x:Class="OnlyProdAddRawPartWndV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
WindowStyle="None" ResizeMode="NoResize"
SizeToContent="WidthAndHeight"
WindowStartupLocation="CenterOwner"
IsClosable="False"
IsMinimizable="False"
IsResizable="False"
Title="AddRawPartWnd"
Style="{StaticResource OnlyProd_EgtCustomWindow}">
<Grid Margin="5,5,5,0">
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
</Grid.RowDefinitions>
<ComboBox ItemsSource="{Binding DimensionsList}"
SelectedItem="{Binding SelDimension}"
DisplayMemberPath="sDimension"
Visibility="{Binding DimensionsList_Visibility}"
Margin="0,0,0,5"
Style="{StaticResource OnlyProd_ComboBox}"/>
<ItemsControl Grid.Row="1"
ItemsSource="{Binding VariableList}">
<ItemsControl.ItemTemplate>
<DataTemplate>
<Grid Margin="0,0,0,5">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<TextBlock Text="{Binding sMsg}"
Style="{StaticResource OptionTextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding sValue}"
Style="{StaticResource Value_TextBox}"/>
</Grid>
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>
<UniformGrid Grid.Row="2"
Columns="2"
Margin="0,0,0,5">
<Button Grid.Column="1"
Content="Ok"
Command="{Binding Ok_Command}"
IsDefault="True"
Style="{StaticResource OnlyProdEgtWPFLib5_InputButton}"
Margin="0,0,5,0"/>
<Button Grid.Column="3"
Content="Cancel"
IsCancel="True"
Style="{StaticResource OnlyProdEgtWPFLib5_InputButton}"/>
</UniformGrid>
</Grid>
</EgtWPFLib5:EgtCustomWindow>
@@ -0,0 +1,18 @@
Public Class OnlyProdAddRawPartWndV
Private WithEvents m_AddRawPartWndVM As AddRawPartWndVM
Sub New(Owner As Window, AddRawPartWndVM As AddRawPartWndVM)
MyBase.New(Owner)
' This call is required by the designer.
InitializeComponent()
Me.DataContext = AddRawPartWndVM
' Assegno al riferimento locale al VM il VM preso dal DataContext
m_AddRawPartWndVM = AddRawPartWndVM
End Sub
Private Sub CloseWindow(bDialogResult As Boolean) Handles m_AddRawPartWndVM.m_CloseWindow
Me.DialogResult = bDialogResult
End Sub
End Class
@@ -2,7 +2,7 @@
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5" xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
xmlns:OPTIMIZER="clr-namespace:EgtBEAMWALL.Optimizer" xmlns:EgtBEAMWALL="clr-namespace:EgtBEAMWALL.Optimizer"
xmlns:EgtBEAMWALLCORE="clr-namespace:EgtBEAMWALL.Core;assembly=EgtBEAMWALL.Core" xmlns:EgtBEAMWALLCORE="clr-namespace:EgtBEAMWALL.Core;assembly=EgtBEAMWALL.Core"
Style="{DynamicResource {x:Type EgtWPFLib5:EgtCustomWindow}}" Style="{DynamicResource {x:Type EgtWPFLib5:EgtCustomWindow}}"
WindowStyle="None" ResizeMode="NoResize" WindowStyle="None" ResizeMode="NoResize"
@@ -25,20 +25,21 @@
ScrollViewer.VerticalScrollBarVisibility="Auto" ScrollViewer.VerticalScrollBarVisibility="Auto"
ScrollViewer.HorizontalScrollBarVisibility="Auto" ScrollViewer.HorizontalScrollBarVisibility="Auto"
Margin="5" Margin="5"
ColumnHeaderBackground="{x:Null}"
BindingColumns="{Binding SectXMatColumns}"> BindingColumns="{Binding SectXMatColumns}">
<DataGrid.Resources> <DataGrid.Resources>
<!-- SectionXMaterial --> <!-- SectionXMaterial -->
<DataGridTextColumn x:Key="colSECTXMAT" Binding="{Binding sSectionXMaterial}"> <DataGridTextColumn x:Key="colSECTXMAT" Binding="{Binding sSectionXMaterial}">
<DataGridTextColumn.HeaderTemplate> <DataGridTextColumn.HeaderTemplate>
<DataTemplate> <DataTemplate>
<TextBlock Text="{Binding Path=DataContext.SectionXMaterial_Msg,RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:AddSectionXMaterialWndV}}}"/> <TextBlock Text="{Binding Path=DataContext.SectionXMaterial_Msg,RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:AddSectionXMaterialWndV}}}"/>
</DataTemplate> </DataTemplate>
</DataGridTextColumn.HeaderTemplate> </DataGridTextColumn.HeaderTemplate>
</DataGridTextColumn> </DataGridTextColumn>
<!-- Alias --> <!-- Alias -->
<DataGridTemplateColumn x:Key="colALIAS"> <DataGridTemplateColumn x:Key="colALIAS">
<DataGridTemplateColumn.Header> <DataGridTemplateColumn.Header>
<TextBlock Text="{Binding Path=DataContext.Alias_Msg,RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:AddSectionXMaterialWndV}}}"/> <TextBlock Text="{Binding Path=DataContext.Alias_Msg,RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:AddSectionXMaterialWndV}}}"/>
</DataGridTemplateColumn.Header> </DataGridTemplateColumn.Header>
<DataGridTemplateColumn.CellTemplate> <DataGridTemplateColumn.CellTemplate>
<DataTemplate> <DataTemplate>
@@ -52,7 +53,7 @@
<DataGridTextColumn x:Key="colW" Binding="{Binding sNewW}"> <DataGridTextColumn x:Key="colW" Binding="{Binding sNewW}">
<DataGridTextColumn.HeaderTemplate> <DataGridTextColumn.HeaderTemplate>
<DataTemplate> <DataTemplate>
<TextBlock Text="{Binding Path=DataContext.W_Msg,RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:AddSectionXMaterialWndV}}}"/> <TextBlock Text="{Binding Path=DataContext.W_Msg,RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:AddSectionXMaterialWndV}}}"/>
</DataTemplate> </DataTemplate>
</DataGridTextColumn.HeaderTemplate> </DataGridTextColumn.HeaderTemplate>
<DataGridTextColumn.CellStyle> <DataGridTextColumn.CellStyle>
@@ -65,7 +66,7 @@
<DataGridTextColumn x:Key="colL" Binding="{Binding sNewL}"> <DataGridTextColumn x:Key="colL" Binding="{Binding sNewL}">
<DataGridTextColumn.HeaderTemplate> <DataGridTextColumn.HeaderTemplate>
<DataTemplate> <DataTemplate>
<TextBlock Text="{Binding Path=DataContext.L_Msg,RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:AddSectionXMaterialWndV}}}"/> <TextBlock Text="{Binding Path=DataContext.L_Msg,RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:AddSectionXMaterialWndV}}}"/>
</DataTemplate> </DataTemplate>
</DataGridTextColumn.HeaderTemplate> </DataGridTextColumn.HeaderTemplate>
<DataGridTextColumn.CellStyle> <DataGridTextColumn.CellStyle>
@@ -77,7 +78,7 @@
<!-- Material --> <!-- Material -->
<DataGridTemplateColumn x:Key="colMATERIAL"> <DataGridTemplateColumn x:Key="colMATERIAL">
<DataGridTemplateColumn.Header> <DataGridTemplateColumn.Header>
<TextBlock Text="{Binding Path=DataContext.Material_Msg,RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:AddSectionXMaterialWndV}}}"/> <TextBlock Text="{Binding Path=DataContext.Material_Msg,RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:AddSectionXMaterialWndV}}}"/>
</DataGridTemplateColumn.Header> </DataGridTemplateColumn.Header>
<DataGridTemplateColumn.CellTemplate> <DataGridTemplateColumn.CellTemplate>
<DataTemplate> <DataTemplate>
@@ -91,7 +92,7 @@
<DataGridTextColumn x:Key="colQTY" Binding="{Binding sQuantity}"> <DataGridTextColumn x:Key="colQTY" Binding="{Binding sQuantity}">
<DataGridTextColumn.HeaderTemplate> <DataGridTextColumn.HeaderTemplate>
<DataTemplate> <DataTemplate>
<TextBlock Text="{Binding Path=DataContext.Quantity_Msg,RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:AddSectionXMaterialWndV}}}"/> <TextBlock Text="{Binding Path=DataContext.Quantity_Msg,RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:AddSectionXMaterialWndV}}}"/>
</DataTemplate> </DataTemplate>
</DataGridTextColumn.HeaderTemplate> </DataGridTextColumn.HeaderTemplate>
<DataGridTextColumn.CellStyle> <DataGridTextColumn.CellStyle>
@@ -232,7 +232,7 @@ Public Class AddSectionXMaterialWndVM
#End Region ' Cancel #End Region ' Cancel
#End Region ' COMMANDS #End Region ' CONSTRUCTOR
#Region "METHODS" #Region "METHODS"
+1 -8
View File
@@ -5,15 +5,8 @@
Protected Overrides Sub OnStartup(e As StartupEventArgs) Protected Overrides Sub OnStartup(e As StartupEventArgs)
MyBase.OnStartup(e) MyBase.OnStartup(e)
ShutdownMode = System.Windows.ShutdownMode.OnMainWindowClose ShutdownMode = System.Windows.ShutdownMode.OnMainWindowClose
If e.Args.Count = 0 Then
' creo finestra SplashScreen
Dim SplashScreen As New SplashScreenV
Me.MainWindow = SplashScreen
Me.MainWindow.Show()
MapV.SetRefSplashScreenV(SplashScreen)
End If
' Creo la View principale ' Creo la View principale
Me.MainWindow = New MainWindowV Me.MainWindow = New OnlyProdMainWindowV
' Mostro la View principale ' Mostro la View principale
Me.MainWindow.Show() Me.MainWindow.Show()
End Sub End Sub
+143 -157
View File
@@ -2,7 +2,7 @@
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5" xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
xmlns:OPTIMIZER="clr-namespace:EgtBEAMWALL.Optimizer" xmlns:EgtBEAMWALL="clr-namespace:EgtBEAMWALL.Optimizer"
WindowStyle="None" ResizeMode="NoResize" WindowStyle="None" ResizeMode="NoResize"
SizeToContent="WidthAndHeight" SizeToContent="WidthAndHeight"
WindowStartupLocation="CenterOwner" WindowStartupLocation="CenterOwner"
@@ -12,162 +12,148 @@
Title="BTLDataWndV" Title="BTLDataWndV"
Name="BTLDataWndV" Name="BTLDataWndV"
Style="{StaticResource OnlyProd_EgtCustomWindow}"> Style="{StaticResource OnlyProd_EgtCustomWindow}">
<UniformGrid Margin="5"
Columns="6" Rows="7">
<TabControl> <TextBlock Text="{Binding PROJNUM_MSG}"
<TabItem Header="Strategy"> Style="{StaticResource PartParam_TextBlock}"/>
<Grid> <EgtWPFLib5:EgtTextBox Grid.Column="1"
<Grid.RowDefinitions> Text="{Binding Tag.sPROJNUM, UpdateSourceTrigger=Explicit,
<RowDefinition Height="Auto"/> RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BTLDataWndV}}}"
<RowDefinition Height="1*"/> Style="{StaticResource PartParam_TextBox}"/>
</Grid.RowDefinitions> <TextBlock Text="{Binding PROJNAME_MSG}"
<ComboBox ItemsSource="{Binding StrategySetupList}" HorizontalAlignment="Center" Margin="0,10,0,10" Style="{StaticResource PartParam_TextBlock}"/>
SelectedItem="{Binding SelStrategySetup, UpdateSourceTrigger=PropertyChanged}" <EgtWPFLib5:EgtTextBox Grid.Column="1"
Style="{StaticResource Strategy_ComboBox}" /> Text="{Binding Tag.sPROJNAME, UpdateSourceTrigger=Explicit,
<Grid Grid.Row="1"> RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BTLDataWndV}}}"
<Grid.RowDefinitions> Style="{StaticResource PartParam_TextBox}"/>
<RowDefinition Height="Auto"/> <TextBlock Text="{Binding PROJPART_MSG}"
</Grid.RowDefinitions> Style="{StaticResource PartParam_TextBlock}"/>
<Grid.ColumnDefinitions> <EgtWPFLib5:EgtTextBox Grid.Column="1"
<ColumnDefinition Width="1*"/> Text="{Binding Tag.sPROJPART, UpdateSourceTrigger=Explicit,
<ColumnDefinition Width="Auto"/> RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BTLDataWndV}}}"
</Grid.ColumnDefinitions> Style="{StaticResource PartParam_TextBox}"/>
<OPTIMIZER:ProjectParametersV Grid.RowSpan="2" Margin="0,10,0,0" <TextBlock Text="{Binding PROJGUID_MSG}"
Tag="{Binding GeneralParametersList}" Style="{StaticResource PartParam_TextBlock}"/>
IsEnabled="{Binding GeneralParametersIsEnable}"/> <EgtWPFLib5:EgtTextBox Grid.Column="1"
<UniformGrid Rows="2" Grid.Column="1" Margin="0,0,5,0"> Text="{Binding Tag.sPROJGUID, UpdateSourceTrigger=Explicit,
<CheckBox IsChecked="{Binding bSaveGeneralParameters, UpdateSourceTrigger=PropertyChanged}" RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BTLDataWndV}}}"
Margin="10,10,0,0" VerticalAlignment="Top" HorizontalAlignment="Center" Style="{StaticResource PartParam_TextBox}"/>
Style="{StaticResource OnlyProdFeatureInPartInRawPartList_CheckBox}"/> <TextBlock Text="{Binding LISTNAME_MSG}"
<Button Command="{Binding Ok_Command}" VerticalAlignment="Bottom" Margin="0,0,0,5" Style="{StaticResource PartParam_TextBlock}"/>
ToolTip="{Binding SaveAsToolTip}" <EgtWPFLib5:EgtTextBox Grid.Column="1"
Style="{StaticResource SaveStrategy_Button}"> Text="{Binding Tag.sLISTNAME, UpdateSourceTrigger=Explicit,
<Image Source="/Resources/NewPage/Ok.png" Stretch="Uniform"/> RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BTLDataWndV}}}"
</Button> Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding CUSTOMER_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding Tag.sCUSTOMER, UpdateSourceTrigger=Explicit,
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BTLDataWndV}}}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding ARCHITECT_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding Tag.sARCHITECT, UpdateSourceTrigger=Explicit,
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BTLDataWndV}}}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding EDITOR_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding Tag.sEDITOR, UpdateSourceTrigger=Explicit,
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BTLDataWndV}}}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding DELIVDATE_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding Tag.sDELIVDATE, UpdateSourceTrigger=Explicit,
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BTLDataWndV}}}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding EXPDATE_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding Tag.sEXPDATE, UpdateSourceTrigger=Explicit,
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BTLDataWndV}}}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding EXPTIME_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding Tag.sEXPTIME, UpdateSourceTrigger=Explicit,
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BTLDataWndV}}}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding EXPRELEASE_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding Tag.sEXPRELEASE, UpdateSourceTrigger=Explicit,
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BTLDataWndV}}}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding LANGUAGE_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding Tag.sLANGUAGE, UpdateSourceTrigger=Explicit,
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BTLDataWndV}}}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding RANGE_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<ComboBox Grid.Column="1"
ItemsSource="{Binding RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BTLDataWndV}},
Path=Tag.ocRANGE,
Mode=OneWay}"
SelectedIndex="{Binding RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BTLDataWndV}},
Path=Tag.SelRANGE,
Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
Style="{StaticResource PartParam_ComboBox}"/>
<TextBlock Text="{Binding PROCESSINGQUALITY_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<ComboBox Grid.Column="1"
ItemsSource="{Binding RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BTLDataWndV}},
Path=Tag.ocPROCESSINGQUALITY,
Mode=OneWay}"
SelectedIndex="{Binding RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BTLDataWndV}},
Path=Tag.SelPROCESSINGQUALITY,
Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
Style="{StaticResource PartParam_ComboBox}"/>
<TextBlock Text="{Binding COMPUTERNAME_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding Tag.sCOMPUTERNAME, UpdateSourceTrigger=Explicit,
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BTLDataWndV}}}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding USER_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding Tag.sUSER, UpdateSourceTrigger=Explicit,
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BTLDataWndV}}}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding SRCFILE_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding Tag.sSRCFILE, UpdateSourceTrigger=Explicit,
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BTLDataWndV}}}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding EXPFILE_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding Tag.sEXPFILE, UpdateSourceTrigger=Explicit,
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BTLDataWndV}}}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding RECESS_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<ComboBox Grid.Column="1"
ItemsSource="{Binding RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BTLDataWndV}},
Path=Tag.ocRECESS,
Mode=OneWay}"
SelectedIndex="{Binding RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BTLDataWndV}},
Path=Tag.SelRECESS,
Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
Style="{StaticResource PartParam_ComboBox}"/>
<TextBlock Text="{Binding USERATTRIBUTE_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding Tag.sUSERATTRIBUTE, UpdateSourceTrigger=Explicit,
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BTLDataWndV}}}"
Style="{StaticResource PartParam_TextBox}"/>
</UniformGrid> </UniformGrid>
</Grid>
</Grid>
</TabItem>
<TabItem Header="BTL">
<UniformGrid Margin="5"
Columns="6" Rows="7">
<TextBlock Text="{Binding PROJNUM_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding sPROJNUM, UpdateSourceTrigger=Explicit}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding PROJNAME_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding sPROJNAME, UpdateSourceTrigger=Explicit}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding PROJPART_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding sPROJPART, UpdateSourceTrigger=Explicit}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding PROJGUID_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding sPROJGUID, UpdateSourceTrigger=Explicit}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding LISTNAME_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding sLISTNAME, UpdateSourceTrigger=Explicit}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding CUSTOMER_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding sCUSTOMER, UpdateSourceTrigger=Explicit}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding ARCHITECT_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding sARCHITECT, UpdateSourceTrigger=Explicit}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding EDITOR_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding sEDITOR, UpdateSourceTrigger=Explicit}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding DELIVDATE_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding sDELIVDATE, UpdateSourceTrigger=Explicit}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding EXPDATE_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding sEXPDATE, UpdateSourceTrigger=Explicit}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding EXPTIME_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding sEXPTIME, UpdateSourceTrigger=Explicit}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding EXPRELEASE_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding sEXPRELEASE, UpdateSourceTrigger=Explicit}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding LANGUAGE_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding sLANGUAGE, UpdateSourceTrigger=Explicit}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding RANGE_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<ComboBox Grid.Column="1"
ItemsSource="{Binding ocRANGE,
Mode=OneWay}"
SelectedIndex="{Binding SelRANGE,
Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
Style="{StaticResource PartParam_ComboBox}"/>
<TextBlock Text="{Binding PROCESSINGQUALITY_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<ComboBox Grid.Column="1"
ItemsSource="{Binding ocPROCESSINGQUALITY,
Mode=OneWay}"
SelectedIndex="{Binding SelPROCESSINGQUALITY,
Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
Style="{StaticResource PartParam_ComboBox}"/>
<TextBlock Text="{Binding COMPUTERNAME_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding sCOMPUTERNAME, UpdateSourceTrigger=Explicit}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding USER_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding sUSER, UpdateSourceTrigger=Explicit}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding SRCFILE_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding sSRCFILE, UpdateSourceTrigger=Explicit}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding EXPFILE_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding sEXPFILE, UpdateSourceTrigger=Explicit}"
Style="{StaticResource PartParam_TextBox}"/>
<TextBlock Text="{Binding RECESS_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<ComboBox Grid.Column="1"
ItemsSource="{Binding ocRECESS,
Mode=OneWay}"
SelectedIndex="{Binding SelRECESS,
Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
Style="{StaticResource PartParam_ComboBox}"/>
<TextBlock Text="{Binding USERATTRIBUTE_MSG}"
Style="{StaticResource PartParam_TextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="1"
Text="{Binding sUSERATTRIBUTE, UpdateSourceTrigger=Explicit}"
Style="{StaticResource PartParam_TextBox}"/>
</UniformGrid>
</TabItem>
</TabControl>
</EgtWPFLib5:EgtCustomWindow> </EgtWPFLib5:EgtCustomWindow>
@@ -7,6 +7,7 @@
' This call is required by the designer. ' This call is required by the designer.
InitializeComponent() InitializeComponent()
Me.DataContext = BTLDataWndVM Me.DataContext = BTLDataWndVM
Me.Tag = Map.refProjectVM.BTLStructureVM
' Assegno al riferimento locale al VM il VM preso dal DataContext ' Assegno al riferimento locale al VM il VM preso dal DataContext
m_BTLDataWndVM = BTLDataWndVM m_BTLDataWndVM = BTLDataWndVM
End Sub End Sub
@@ -1,442 +1,9 @@
Imports System.Collections.ObjectModel Imports EgtWPFLib5
Imports System.IO
Imports EgtBEAMWALL.Core
Imports EgtBEAMWALL.Optimizer.MainMenuVM
Imports EgtUILib Imports EgtUILib
Imports EgtWPFLib5
Imports Newtonsoft.Json
Public Class BTLDataWndVM Public Class BTLDataWndVM
Inherits VMBase Inherits VMBase
#Region "FIELDS & PROPERTIES"
Friend Event m_CloseWindow(bDialogResult As Boolean)
Private m_StrategySetupList As New ObservableCollection(Of String)
Public ReadOnly Property StrategySetupList As ObservableCollection(Of String)
Get
Return m_StrategySetupList
End Get
End Property
Private m_SelStrategySetup As String
Public Property SelStrategySetup As String
Get
Return m_SelStrategySetup
End Get
Set(value As String)
If m_SelStrategySetup <> value Then
EgtSetInfo(m_nBTLInfoLayerId, "AISETUP", value)
WriteMainPrivateProfileString(S_STRATEGY, K_DEFAULTCONFIG, value & ".json")
Map.refStrategyManagerVM.SelStrategySetup.sName = value
Map.refStrategyManagerVM.SelStrategySetup.Read()
Map.refProdManagerVM.Save()
End If
m_SelStrategySetup = value
NotifyPropertyChanged(NameOf(SelStrategySetup))
End Set
End Property
Private m_nBTLInfoLayerId As Integer = -1
Public ReadOnly Property nBTLInfoId As Integer
Get
Return m_nBTLInfoLayerId
End Get
End Property
Private m_GeneralParametersList As New ObservableCollection(Of ProjectParameters)
Public Property GeneralParametersList As ObservableCollection(Of ProjectParameters)
Get
Return m_GeneralParametersList
End Get
Set(value As ObservableCollection(Of ProjectParameters))
m_GeneralParametersList = value
NotifyPropertyChanged(NameOf(GeneralParametersList))
End Set
End Property
Private m_bSaveGeneralParameters As Boolean
Public Property bSaveGeneralParameters As Boolean
Get
Return m_bSaveGeneralParameters
End Get
Set(value As Boolean)
m_bSaveGeneralParameters = value
If m_bSaveGeneralParameters Then
SetGeneralParametersIsEnable(True)
Else
SetGeneralParametersIsEnable(False)
Dim sStrategiesDirPath As String = Map.refMainWindowVM.MainWindowM.GetStrategiesDirPath(Map.refStrategyManagerVM.SelStrategyType.Id)
Dim sGeneralParametersFilePath As String = sStrategiesDirPath & "\" & GENERALPARAMETERS_FILE & ".json"
If File.Exists(sGeneralParametersFilePath) Then
Dim sReadedFiles As String = File.ReadAllText(sGeneralParametersFilePath)
Dim JsonGeneralParametersList As List(Of JsonGeneralParameters) = JsonConvert.DeserializeObject(Of List(Of JsonGeneralParameters))(sReadedFiles)
m_GeneralParametersList = New ObservableCollection(Of ProjectParameters)((From JsonGeneralParameter In JsonGeneralParametersList
Select JsonGeneralParameter.Deserialize(Map.refStrategyManagerVM.SelStrategyType.Id)).ToList())
End If
End If
NotifyPropertyChanged(NameOf(bSaveGeneralParameters))
End Set
End Property
Friend Sub SetbSaveGeneralParameters(value As Boolean)
m_bSaveGeneralParameters = value
NotifyPropertyChanged(NameOf(bSaveGeneralParameters))
End Sub
Private m_GeneralParametersIsEnable As Boolean = False
Public ReadOnly Property GeneralParametersIsEnable As Boolean
Get
Return m_GeneralParametersIsEnable
End Get
End Property
Friend Sub SetGeneralParametersIsEnable(value As Boolean)
m_GeneralParametersIsEnable = value
NotifyPropertyChanged(NameOf(GeneralParametersIsEnable))
End Sub
#Region "Parametri generici"
Public m_sPROJNUM As String
Public Property sPROJNUM As String
Get
Return m_sPROJNUM
End Get
Set(value As String)
If EgtSetInfo(m_nBTLInfoLayerId, BTL_GEN_PROJNUM, value) Then
m_sPROJNUM = value
Else
NotifyPropertyChanged(NameOf(sPROJNUM))
End If
End Set
End Property
Public m_sPROJNAME As String
Public Property sPROJNAME As String
Get
Return m_sPROJNAME
End Get
Set(value As String)
If EgtSetInfo(m_nBTLInfoLayerId, BTL_GEN_PROJNAME, value) Then
m_sPROJNAME = value
Else
NotifyPropertyChanged(NameOf(sPROJNAME))
End If
End Set
End Property
Public m_sPROJPART As String
Public Property sPROJPART As String
Get
Return m_sPROJPART
End Get
Set(value As String)
If EgtSetInfo(m_nBTLInfoLayerId, BTL_GEN_PROJPART, value) Then
m_sPROJPART = value
Else
NotifyPropertyChanged(NameOf(sPROJPART))
End If
End Set
End Property
Public m_sPROJGUID As String
Public Property sPROJGUID As String
Get
Return m_sPROJGUID
End Get
Set(value As String)
If EgtSetInfo(m_nBTLInfoLayerId, BTL_GEN_PROJGUID, value) Then
m_sPROJGUID = value
Else
NotifyPropertyChanged(NameOf(sPROJGUID))
End If
End Set
End Property
Public m_nPROJTYPE As Integer
Public ReadOnly Property nPROJTYPE As BWType
Get
Select Case Map.refMainMenuVM.SelPage
Case Pages.ONLYPRODPAGE
Return Map.refProdManagerVM.nProdType
Case Else
Return BWType.NULL
End Select
End Get
End Property
Public m_sLISTNAME As String
Public Property sLISTNAME As String
Get
Return m_sLISTNAME
End Get
Set(value As String)
If EgtSetInfo(m_nBTLInfoLayerId, BTL_GEN_LISTNAME, value) Then
DbControllers.m_ProjController.UpdateListName(ProjectManagerVM.CurrProj.nProjId, value)
m_sLISTNAME = value
Else
NotifyPropertyChanged(NameOf(sLISTNAME))
End If
End Set
End Property
Public m_sCUSTOMER As String
Public Property sCUSTOMER As String
Get
Return m_sCUSTOMER
End Get
Set(value As String)
If EgtSetInfo(m_nBTLInfoLayerId, BTL_GEN_CUSTOMER, value) Then
m_sCUSTOMER = value
Else
NotifyPropertyChanged(NameOf(sCUSTOMER))
End If
End Set
End Property
Public m_sARCHITECT As String
Public Property sARCHITECT As String
Get
Return m_sARCHITECT
End Get
Set(value As String)
If EgtSetInfo(m_nBTLInfoLayerId, BTL_GEN_ARCHITECT, value) Then
m_sARCHITECT = value
Else
NotifyPropertyChanged(NameOf(sARCHITECT))
End If
End Set
End Property
Public m_sEDITOR As String
Public Property sEDITOR As String
Get
Return m_sEDITOR
End Get
Set(value As String)
If EgtSetInfo(m_nBTLInfoLayerId, BTL_GEN_EDITOR, value) Then
m_sEDITOR = value
Else
NotifyPropertyChanged(NameOf(sEDITOR))
End If
End Set
End Property
Public m_sDELIVDATE As String
Public Property sDELIVDATE As String
Get
Return m_sDELIVDATE
End Get
Set(value As String)
If EgtSetInfo(m_nBTLInfoLayerId, BTL_GEN_DELIVDATE, value) Then
m_sDELIVDATE = value
Else
NotifyPropertyChanged(NameOf(sDELIVDATE))
End If
End Set
End Property
Public m_sEXPDATE As String
Public Property sEXPDATE As String
Get
Return m_sEXPDATE
End Get
Set(value As String)
If EgtSetInfo(m_nBTLInfoLayerId, BTL_GEN_EXPDATE, value) Then
m_sEXPDATE = value
Else
NotifyPropertyChanged(NameOf(sEXPDATE))
End If
End Set
End Property
Public m_sEXPTIME As String
Public Property sEXPTIME As String
Get
Return m_sEXPTIME
End Get
Set(value As String)
If EgtSetInfo(m_nBTLInfoLayerId, BTL_GEN_EXPTIME, value) Then
m_sEXPTIME = value
Else
NotifyPropertyChanged(NameOf(sEXPTIME))
End If
End Set
End Property
Public m_sEXPRELEASE As String
Public Property sEXPRELEASE As String
Get
Return m_sEXPRELEASE
End Get
Set(value As String)
If EgtSetInfo(m_nBTLInfoLayerId, BTL_GEN_EXPRELEASE, value) Then
m_sEXPRELEASE = value
Else
NotifyPropertyChanged(NameOf(sEXPRELEASE))
End If
End Set
End Property
Public m_sLANGUAGE As String
Public Property sLANGUAGE As String
Get
Return m_sLANGUAGE
End Get
Set(value As String)
If EgtSetInfo(m_nBTLInfoLayerId, BTL_GEN_LANGUAGE, value) Then
m_sLANGUAGE = value
Else
NotifyPropertyChanged(NameOf(sLANGUAGE))
End If
End Set
End Property
Public m_ocRANGE As New List(Of Object)({New IdNameStruct(Range.STANDARD, EgtMsg(61710)),
New IdNameStruct(Range.EXTENDED, EgtMsg(61711))})
Public ReadOnly Property ocRANGE As List(Of Object)
Get
Return m_ocRANGE
End Get
End Property
Public m_SelRANGE As Integer
Public Property SelRANGE As Integer
Get
Return m_SelRANGE
End Get
Set(value As Integer)
Dim nValue As Integer = IdNameStruct.IdFromInd(value, ocRANGE)
Dim sValue As String = [Enum].GetName(GetType(Range), nValue)
If EgtSetInfo(m_nBTLInfoLayerId, BTL_GEN_RANGE, sValue) Then
m_SelRANGE = value
Else
NotifyPropertyChanged(NameOf(SelRANGE))
End If
End Set
End Property
Public m_ocPROCESSINGQUALITY As New List(Of Object)({New IdNameStruct(ProcessingQuality.AUTOMATIC, EgtMsg(61658)),
New IdNameStruct(ProcessingQuality.VISIBLE, EgtMsg(61659)),
New IdNameStruct(ProcessingQuality.FAST, EgtMsg(61660))})
Public ReadOnly Property ocPROCESSINGQUALITY As List(Of Object)
Get
Return m_ocPROCESSINGQUALITY
End Get
End Property
Public m_SelPROCESSINGQUALITY As Integer
Public Property SelPROCESSINGQUALITY As Integer
Get
Return m_SelPROCESSINGQUALITY
End Get
Set(value As Integer)
Dim nValue As Integer = IdNameStruct.IdFromInd(value, ocPROCESSINGQUALITY)
Dim sValue As String = [Enum].GetName(GetType(ProcessingQuality), nValue)
If EgtSetInfo(m_nBTLInfoLayerId, BTL_PRT_PROCESSINGQUALITY, sValue) Then
m_SelPROCESSINGQUALITY = value
Else
NotifyPropertyChanged(NameOf(SelPROCESSINGQUALITY))
End If
End Set
End Property
Public m_sCOMPUTERNAME As String
Public Property sCOMPUTERNAME As String
Get
Return m_sCOMPUTERNAME
End Get
Set(value As String)
If EgtSetInfo(m_nBTLInfoLayerId, BTL_GEN_COMPUTERNAME, value) Then
m_sCOMPUTERNAME = value
Else
NotifyPropertyChanged(NameOf(sCOMPUTERNAME))
End If
End Set
End Property
Public m_sUSER As String
Public Property sUSER As String
Get
Return m_sUSER
End Get
Set(value As String)
If EgtSetInfo(m_nBTLInfoLayerId, BTL_GEN_USER, value) Then
m_sUSER = value
Else
NotifyPropertyChanged(NameOf(sUSER))
End If
End Set
End Property
Public m_sSRCFILE As String
Public Property sSRCFILE As String
Get
Return m_sSRCFILE
End Get
Set(value As String)
If EgtSetInfo(m_nBTLInfoLayerId, BTL_GEN_SRCFILE, value) Then
m_sSRCFILE = value
Else
NotifyPropertyChanged(NameOf(sSRCFILE))
End If
End Set
End Property
Public m_sEXPFILE As String
Public Property sEXPFILE As String
Get
Return m_sEXPFILE
End Get
Set(value As String)
If EgtSetInfo(m_nBTLInfoLayerId, BTL_GEN_EXPFILE, value) Then
m_sEXPFILE = value
Else
NotifyPropertyChanged(NameOf(sEXPFILE))
End If
End Set
End Property
Public m_ocRECESS As New List(Of Object)({New IdNameStruct(Recess.AUTOMATIC, EgtMsg(61658)),
New IdNameStruct(Recess.MANUAL, EgtMsg(61661))})
Public ReadOnly Property ocRECESS As List(Of Object)
Get
Return m_ocRECESS
End Get
End Property
Public m_SelRECESS As Integer
Public Property SelRECESS As Integer
Get
Return m_SelRECESS
End Get
Set(value As Integer)
Dim nValue As Integer = IdNameStruct.IdFromInd(value, ocRECESS)
Dim sValue As String = [Enum].GetName(GetType(Recess), nValue)
If EgtSetInfo(m_nBTLInfoLayerId, BTL_PRT_RECESS, sValue) Then
m_SelRECESS = value
Else
NotifyPropertyChanged(NameOf(SelRECESS))
End If
End Set
End Property
Public m_sUSERATTRIBUTE As String
Public Property sUSERATTRIBUTE As String
Get
Return m_sUSERATTRIBUTE
End Get
Set(value As String)
If EgtSetInfo(m_nBTLInfoLayerId, BTL_GEN_USERATTRIBUTE, value) Then
m_sUSERATTRIBUTE = value
Else
NotifyPropertyChanged(NameOf(sUSERATTRIBUTE))
End If
End Set
End Property
#End Region ' Parametri generici
#Region "Messages" #Region "Messages"
Public ReadOnly Property PROJNUM_MSG As String Public ReadOnly Property PROJNUM_MSG As String
@@ -567,6 +134,10 @@ Public Class BTLDataWndVM
#End Region ' Messages #End Region ' Messages
#Region "FIELDS & PROPERTIES"
Friend Event m_CloseWindow(bDialogResult As Boolean)
' Definizione comandi ' Definizione comandi
Private m_cmdOk As ICommand Private m_cmdOk As ICommand
@@ -574,159 +145,12 @@ Public Class BTLDataWndVM
#Region "CONSTRUCTOR" #Region "CONSTRUCTOR"
Sub New(nProjId As Integer) Sub New()
' leggo cartella dei setup delle strategie
Dim AISetupDirPath As String = Map.refMainWindowVM.MainWindowM.GetAISetupDirPath(ProjectManagerVM.CurrProd.nType, True)
Dim AISetupPaths As String() = Directory.GetFiles(AISetupDirPath)
For Each AiSetup In AISetupPaths
m_StrategySetupList.Add(Path.GetFileNameWithoutExtension(AiSetup))
Next
' cerco tra i layer BTLInfo
Dim nCurrBTLInfoLayerId As Integer = EgtGetFirstNameInGroup(GDB_ID.ROOT, BTLINFO)
While nCurrBTLInfoLayerId <> GDB_ID.NULL
' verifico se il layer appartiene al ProjId
Dim nBTLInfoLayerProjId As Integer
EgtGetInfo(nCurrBTLInfoLayerId, BTL_PRT_PROJ, nBTLInfoLayerProjId)
If nBTLInfoLayerProjId = nProjId Then
m_nBTLInfoLayerId = nCurrBTLInfoLayerId
Exit While
End If
nCurrBTLInfoLayerId = EgtGetNextName(nCurrBTLInfoLayerId, BTLINFO)
End While
' leggo parametri Btl
ReadBtlParams()
'' leggo strategia
'EgtGetInfo(m_nBTLInfoLayerId, "AISETUP", m_SelStrategySetup)
' Controllo se presente file default config
Dim sDefaultConfigFile As String = String.Empty
Dim sTrimDefaultConfig As String = String.Empty
If GetMainPrivateProfileString(S_STRATEGY, K_DEFAULTCONFIG, "", sDefaultConfigFile) <> 0 Then
sTrimDefaultConfig = System.IO.Path.GetFileNameWithoutExtension(sDefaultConfigFile)
m_SelStrategySetup = sTrimDefaultConfig
EgtSetInfo(m_nBTLInfoLayerId, "AISETUP", m_SelStrategySetup)
End If
Dim sStrategiesDirPath As String = Map.refMainWindowVM.MainWindowM.GetStrategiesDirPath(Map.refStrategyManagerVM.SelStrategyType.Id)
Dim sGeneralParametersFilePath As String = sStrategiesDirPath & "\" & GENERALPARAMETERS_FILE & ".json"
If File.Exists(sGeneralParametersFilePath) Then
Dim sReadedFiles As String = File.ReadAllText(sGeneralParametersFilePath)
Dim JsonGeneralParametersList As List(Of JsonGeneralParameters) = JsonConvert.DeserializeObject(Of List(Of JsonGeneralParameters))(sReadedFiles)
m_GeneralParametersList = New ObservableCollection(Of ProjectParameters)((From JsonGeneralParameter In JsonGeneralParametersList
Select JsonGeneralParameter.Deserialize(Map.refStrategyManagerVM.SelStrategyType.Id)).ToList())
For Each GenericItem As ProjectParameters In m_GeneralParametersList
Select Case GenericItem.sMinUserLevel
Case UserLevel.ADVANCED
Map.refMainMenuVM.UserLevelGenericVisibility(GenericItem, If(Map.refMainMenuVM.UserAdmin_IsChecked, Visibility.Visible, Visibility.Collapsed))
Case Else
If Not Map.refMainMenuVM.UserAdmin_IsChecked Then
Map.refMainMenuVM.UserLevelGenericVisibility(GenericItem, If(GenericItem.sMinUserLevel = UserLevel.USER, Visibility.Visible, Visibility.Collapsed))
Map.refMainMenuVM.SetUnloackImage("pack://application:,,,/Resources/NewPage/padlock.png")
End If
End Select
Next
NotifyPropertyChanged(NameOf(GeneralParametersList))
End If
' Leggo info se presenti
Dim sInfo As String = String.Empty
For Each GeneralParameter In m_GeneralParametersList
Select Case GeneralParameter.GetType()
Case GetType(BooleanGenericParameter)
SetbSaveGeneralParameters(True)
SetGeneralParametersIsEnable(True)
Dim sTmpBoolValue As Boolean = DirectCast(GeneralParameter, BooleanGenericParameter).bValue
If Not EgtGetInfo(m_nBTLInfoLayerId, GeneralParameter.sNameNge, DirectCast(GeneralParameter, BooleanGenericParameter).bValue) Then
DirectCast(GeneralParameter, BooleanGenericParameter).bValue = sTmpBoolValue
SetbSaveGeneralParameters(False)
SetGeneralParametersIsEnable(False)
Return
End If
Case GetType(DoubleGenericParameter)
SetbSaveGeneralParameters(True)
SetGeneralParametersIsEnable(True)
Dim sTmpDoubleValue As String = DirectCast(GeneralParameter, DoubleGenericParameter).sValue
If Not EgtGetInfo(m_nBTLInfoLayerId, GeneralParameter.sNameNge, DirectCast(GeneralParameter, DoubleGenericParameter).sValue) Then
DirectCast(GeneralParameter, DoubleGenericParameter).sValue = sTmpDoubleValue
SetbSaveGeneralParameters(False)
SetGeneralParametersIsEnable(False)
Return
End If
Case GetType(ComboGenericParameter)
SetbSaveGeneralParameters(True)
SetGeneralParametersIsEnable(True)
Dim sTmpComboValue As String = DirectCast(GeneralParameter, ComboGenericParameter).SelValue.sValue
If Not EgtGetInfo(m_nBTLInfoLayerId, GeneralParameter.sNameNge, DirectCast(GeneralParameter, ComboGenericParameter).SelValue.sValue) Then
DirectCast(GeneralParameter, ComboGenericParameter).SelValue.sValue = sTmpComboValue
SetbSaveGeneralParameters(False)
SetGeneralParametersIsEnable(False)
Return
End If
Case GetType(StringGenericParameter)
SetbSaveGeneralParameters(True)
SetGeneralParametersIsEnable(True)
Dim sTmpStringValue As String = DirectCast(GeneralParameter, StringGenericParameter).sValue
If Not EgtGetInfo(m_nBTLInfoLayerId, GeneralParameter.sNameNge, DirectCast(GeneralParameter, StringGenericParameter).sValue) Then
DirectCast(GeneralParameter, StringGenericParameter).sValue = sTmpStringValue
SetbSaveGeneralParameters(False)
SetGeneralParametersIsEnable(False)
Return
End If
Case GetType(ListGenericParameter)
SetbSaveGeneralParameters(True)
SetGeneralParametersIsEnable(True)
For Each Item As ToolParameter In DirectCast(GeneralParameter, ListGenericParameter).ListValue
If Item.bIsActive Then
sInfo &= Item.sUUID & "," & Item.sName & ";"
Dim sTmpInfo As String = sInfo
If Not EgtGetInfo(m_nBTLInfoLayerId, GeneralParameter.sNameNge, sInfo) Then
sInfo = sTmpInfo
SetbSaveGeneralParameters(False)
SetGeneralParametersIsEnable(False)
Return
End If
End If
Next
End Select
Next
End Sub End Sub
#End Region ' CONSTRUCTOR #End Region ' CONSTRUCTOR
#Region "METHODS"
Private Sub ReadBtlParams()
EgtGetInfo(m_nBTLInfoLayerId, BTL_GEN_PROJNUM, m_sPROJNUM)
EgtGetInfo(m_nBTLInfoLayerId, BTL_GEN_PROJNAME, m_sPROJNAME)
EgtGetInfo(m_nBTLInfoLayerId, BTL_GEN_PROJPART, m_sPROJPART)
EgtGetInfo(m_nBTLInfoLayerId, BTL_GEN_PROJGUID, m_sPROJGUID)
EgtGetInfo(m_nBTLInfoLayerId, BTL_GEN_PROJTYPE, m_nPROJTYPE)
EgtGetInfo(m_nBTLInfoLayerId, BTL_GEN_LISTNAME, m_sLISTNAME)
EgtGetInfo(m_nBTLInfoLayerId, BTL_GEN_CUSTOMER, m_sCUSTOMER)
EgtGetInfo(m_nBTLInfoLayerId, BTL_GEN_ARCHITECT, m_sARCHITECT)
EgtGetInfo(m_nBTLInfoLayerId, BTL_GEN_EDITOR, m_sEDITOR)
EgtGetInfo(m_nBTLInfoLayerId, BTL_GEN_DELIVDATE, m_sDELIVDATE)
EgtGetInfo(m_nBTLInfoLayerId, BTL_GEN_EXPDATE, m_sEXPDATE)
EgtGetInfo(m_nBTLInfoLayerId, BTL_GEN_EXPTIME, m_sEXPTIME)
EgtGetInfo(m_nBTLInfoLayerId, BTL_GEN_EXPRELEASE, m_sEXPRELEASE)
EgtGetInfo(m_nBTLInfoLayerId, BTL_GEN_LANGUAGE, m_sLANGUAGE)
Dim sValue As String = String.Empty
EgtGetInfo(m_nBTLInfoLayerId, BTL_GEN_RANGE, sValue)
m_SelRANGE = IdNameStruct.IndFromId(IdNameStruct.IdFromName(sValue, ocRANGE), ocRANGE)
EgtGetInfo(m_nBTLInfoLayerId, BTL_PRT_PROCESSINGQUALITY, sValue)
m_SelPROCESSINGQUALITY = IdNameStruct.IndFromId(IdNameStruct.IdFromName(sValue, ocPROCESSINGQUALITY), ocPROCESSINGQUALITY)
EgtGetInfo(m_nBTLInfoLayerId, BTL_GEN_COMPUTERNAME, m_sCOMPUTERNAME)
EgtGetInfo(m_nBTLInfoLayerId, BTL_GEN_USER, m_sUSER)
EgtGetInfo(m_nBTLInfoLayerId, BTL_GEN_SRCFILE, m_sSRCFILE)
EgtGetInfo(m_nBTLInfoLayerId, BTL_GEN_EXPFILE, m_sEXPFILE)
EgtGetInfo(m_nBTLInfoLayerId, BTL_PRT_RECESS, sValue)
m_SelRECESS = IdNameStruct.IndFromId(IdNameStruct.IdFromName(sValue, ocRECESS), ocRECESS)
EgtGetInfo(m_nBTLInfoLayerId, BTL_GEN_USERATTRIBUTE, m_sUSERATTRIBUTE)
End Sub
#End Region ' METHODS
#Region "COMMANDS" #Region "COMMANDS"
#Region "Ok" #Region "Ok"
@@ -741,56 +165,6 @@ Public Class BTLDataWndVM
End Property End Property
Public Sub Ok() Public Sub Ok()
'' scrivo AISetup
'Dim sOldStrategySetup As String = ""
'EgtGetInfo(m_nBTLInfoLayerId, "AISETUP", sOldStrategySetup)
'If m_SelStrategySetup <> sOldStrategySetup Then
' EgtSetInfo(m_nBTLInfoLayerId, "AISETUP", m_SelStrategySetup)
'End If
Dim sInfo As String = String.Empty
If m_bSaveGeneralParameters Then
For Each GeneralParameter In GeneralParametersList
Select Case GeneralParameter.GetType()
Case GetType(BooleanGenericParameter)
EgtSetInfo(m_nBTLInfoLayerId, GeneralParameter.sNameNge, DirectCast(GeneralParameter, BooleanGenericParameter).bValue)
Case GetType(DoubleGenericParameter)
EgtSetInfo(m_nBTLInfoLayerId, GeneralParameter.sNameNge, DirectCast(GeneralParameter, DoubleGenericParameter).sValue)
Case GetType(ComboGenericParameter)
EgtSetInfo(m_nBTLInfoLayerId, GeneralParameter.sNameNge, DirectCast(GeneralParameter, ComboGenericParameter).SelValue.sValue)
Case GetType(StringGenericParameter)
EgtSetInfo(m_nBTLInfoLayerId, GeneralParameter.sNameNge, DirectCast(GeneralParameter, StringGenericParameter).sValue)
Case GetType(ListGenericParameter)
For Each Item As ToolParameter In DirectCast(GeneralParameter, ListGenericParameter).ListValue
If Item.bIsActive Then
sInfo &= Item.sUUID & "," & Item.sName & ";"
EgtSetInfo(m_nBTLInfoLayerId, GeneralParameter.sNameNge, sInfo)
End If
Next
End Select
Next
Else
For Each GeneralParameter In m_GeneralParametersList
Select Case GeneralParameter.GetType()
Case GetType(BooleanGenericParameter)
EgtRemoveInfo(m_nBTLInfoLayerId, GeneralParameter.sNameNge)
Case GetType(DoubleGenericParameter)
EgtRemoveInfo(m_nBTLInfoLayerId, GeneralParameter.sNameNge)
Case GetType(ComboGenericParameter)
EgtRemoveInfo(m_nBTLInfoLayerId, GeneralParameter.sNameNge)
Case GetType(StringGenericParameter)
EgtRemoveInfo(m_nBTLInfoLayerId, GeneralParameter.sNameNge)
Case GetType(ListGenericParameter)
For Each Item As ToolParameter In DirectCast(GeneralParameter, ListGenericParameter).ListValue
If Item.bIsActive Then
sInfo &= Item.sUUID & "," & Item.sName & ";"
EgtRemoveInfo(m_nBTLInfoLayerId, GeneralParameter.sNameNge)
End If
Next
End Select
Next
End If
Map.refProdManagerVM.Save()
RaiseEvent m_CloseWindow(True) RaiseEvent m_CloseWindow(True)
End Sub End Sub
@@ -1,49 +1,79 @@
<Border x:Class="BTLPartManagerV" <StackPanel x:Class="BTLPartManagerV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
DataContext="{StaticResource BTLPartManagerVM}" Orientation="Horizontal"
CornerRadius="5" HorizontalAlignment="Right"
BorderThickness="2" DataContext="{StaticResource BTLPartManagerVM}">
BorderBrush="{StaticResource BeamWall_Teal}"
Background="{StaticResource BeamWall_FountainBlue}"> <Button Command="{Binding NewRawPart_Command}"
Visibility="{Binding MachiningPage_Visibility}"
ToolTip="{Binding NewRawPart_ToolTip}"
IsEnabled="{Binding BTLPartManager_IsEnabled}"
Style="{StaticResource LeftPanel_Button}">
<Image Source="/Resources/LeftPanel/NewRawPart.png" Stretch="Uniform"/>
</Button>
<Button Command="{Binding NewRawPartLast_Command}"
Visibility="{Binding MachiningPage_Visibility}"
ToolTip="{Binding NewRawPartLast_ToolTip}"
IsEnabled="{Binding BTLPartManager_IsEnabled}"
Style="{StaticResource LeftPanel_Button}">
<Image Source="/Resources/LeftPanel/NewRawPartAuto.png" Stretch="Uniform"/>
</Button>
<Button Command="{Binding AddToRawPart_Command}"
Visibility="{Binding MachiningPage_Visibility}"
ToolTip="{Binding AddToRawPart_ToolTip}"
IsEnabled="{Binding BTLPartManager_IsEnabled}"
Style="{StaticResource LeftPanel_Button}">
<Image Source="/Resources/LeftPanel/AddToRawPart.png" Stretch="Uniform"/>
</Button>
<Button Command="{Binding CopyPart_Command}"
Visibility="{Binding ViewPage_Visibility}"
ToolTip="{Binding CopyPart_ToolTip}"
IsEnabled="{Binding CopyPart_IsEnabled}"
Style="{StaticResource LeftPanel_Button}">
<Image Source="/Resources/LeftPanel/CopyPart.png" Stretch="Uniform"/>
</Button>
<Button Command="{Binding AddPart_Command}"
Visibility="{Binding ViewPage_Visibility}"
ToolTip="{Binding AddPart_ToolTip}"
IsEnabled="{Binding BTLPartManager_IsEnabled}"
Style="{StaticResource LeftPanel_Button}">
<Image Source="/Resources/LeftPanel/AddPart.png" Stretch="Uniform"/>
</Button>
<Button Command="{Binding RemovePart_Command}"
Visibility="{Binding ViewPage_Visibility}"
ToolTip="{Binding RemovePart_ToolTip}"
IsEnabled="{Binding RemovePart_IsEnabled}"
Style="{StaticResource LeftPanel_Button}">
<Image Source="/Resources/LeftPanel/RemovePart.png" Stretch="Uniform"/>
</Button>
<Button Command="{Binding Invert_Command}"
Visibility="{Binding ViewPage_Visibility}"
ToolTip="{Binding InvertSx_ToolTip}"
IsEnabled="{Binding RotatePart_IsEnabled}"
Style="{StaticResource LeftPanel_Button}">
<Image Source="/Resources/PartManager/LeftInvert.png" Stretch="Uniform"/>
</Button>
<Button Command="{Binding Invert_Command}"
Visibility="{Binding ViewPage_Visibility}"
ToolTip="{Binding InvertDx_ToolTip}"
IsEnabled="{Binding RotatePart_IsEnabled}"
Style="{StaticResource LeftPanel_Button}">
<Image Source="/Resources/PartManager/RightInvert.png" Stretch="Uniform"/>
</Button>
<Button Command="{Binding BackRotation_Command}"
Visibility="{Binding ViewPage_Visibility}"
ToolTip="{Binding BackRotation_ToolTip}"
IsEnabled="{Binding RotatePart_IsEnabled}"
Style="{StaticResource LeftPanel_Button}">
<Image Source="/Resources/PartManager/LeftRotate.png" Stretch="Uniform"/>
</Button>
<Button Command="{Binding ForwardRotation_Command}"
Visibility="{Binding ViewPage_Visibility}"
ToolTip="{Binding ForwardRotation_ToolTip}"
IsEnabled="{Binding RotatePart_IsEnabled}"
Style="{StaticResource LeftPanel_Button}">
<Image Source="/Resources/PartManager/RightRotate.png" Stretch="Uniform"/>
</Button>
<StackPanel Orientation="Horizontal" </StackPanel>
Style="{StaticResource OnlyProdBTLPartManager_StackPanel}">
<Button Command="{Binding CopyPart_Command}"
Click="ClosePopUp_Click"
ToolTip="{Binding CopyPart_ToolTip}"
IsEnabled="{Binding CopyPart_IsEnabled}"
Style="{StaticResource OnlyProdLeftPanel_Button}">
<Image Source="/Resources/LeftPanel/CopyPart.png" Stretch="Uniform"/>
</Button>
<Button Command="{Binding RemovePart_Command}"
Click="ClosePopUp_Click"
ToolTip="{Binding RemovePart_ToolTip}"
IsEnabled="{Binding RemovePart_IsEnabled}"
Style="{StaticResource OnlyProdLeftPanel_Button}">
<Image Source="/Resources/NewPage/Remove.png" Stretch="Uniform"/>
</Button>
<Button ToolTip="{Binding Simulate_ToolTip}"
Click="ClosePopUp_Click"
Command="{Binding Simulate_Command}"
IsEnabled="{Binding Simulate_IsEnabled}"
Style="{StaticResource OnlyProdLeftPanel_Button}">
<Image Source="/Resources/CALCPanel/Simulate.png" Stretch="Uniform"/>
</Button>
<Button ToolTip="{Binding Edit_ToolTip}"
Click="ClosePopUp_Click"
Command="{Binding Edit_Command}"
IsEnabled="{Binding Edit_IsEnabled}"
Style="{StaticResource OnlyProdLeftPanel_Button}">
<Image Source="/Resources/CALCPanel/Edit.png" Stretch="Uniform"/>
</Button>
<Button Command="{Binding ResetCalc_Command}"
Click="ClosePopUp_Click"
ToolTip="{Binding ResetCalc_ToolTip}"
IsEnabled="{Binding CALCPanel_IsEnabled}"
Style="{StaticResource OnlyProdLeftPanel_Button}">
<Image Source="/Resources/CALCPanel/ResetCalc.png" Stretch="Uniform"/>
</Button>
</StackPanel>
</Border>
@@ -1,14 +1,3 @@
Public Class BTLPartManagerV Public Class BTLPartManagerV
Private Sub ClosePopUp_Click(sender As Object, e As RoutedEventArgs)
Dim Button As Button = DirectCast(sender, Button)
Dim StackPanel As StackPanel = DirectCast(Button.Parent, StackPanel)
Dim OnlyProdBTLPartManagerV As BTLPartManagerV = DirectCast(StackPanel.Parent, BTLPartManagerV)
Dim Popup As Primitives.Popup = DirectCast(OnlyProdBTLPartManagerV.Parent, Primitives.Popup)
If Not IsNothing(Popup) Then
Popup.IsOpen = False
End If
End Sub
End Class End Class
File diff suppressed because it is too large Load Diff
@@ -0,0 +1,84 @@
<StackPanel x:Class="OnlyProdBTLPartManagerV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
DataContext="{StaticResource BTLPartManagerVM}"
Style="{StaticResource OnlyProdBTLPartManager_StackPanel}">
<Button Command="{Binding CopyPart_Command}"
Visibility="{Binding ViewPage_Visibility}"
ToolTip="{Binding CopyPart_ToolTip}"
IsEnabled="{Binding CopyPart_IsEnabled}"
Style="{StaticResource OnlyProdLeftPanel_Button}">
<Image Source="/Resources/LeftPanel/CopyPart.png" Stretch="Uniform"/>
</Button>
<Button Command="{Binding RemovePart_Command}"
Visibility="{Binding ViewPage_Visibility}"
ToolTip="{Binding RemovePart_ToolTip}"
IsEnabled="{Binding RemovePart_IsEnabled}"
Style="{StaticResource OnlyProdLeftPanel_Button}">
<Image Source="/Resources/LeftPanel/RemovePart.png" Stretch="Uniform"/>
</Button>
<Button ToolTip="{Binding Simulate_ToolTip}"
Command="{Binding Simulate_Command}"
IsEnabled="{Binding Simulate_IsEnabled}"
Style="{StaticResource OnlyProdLeftPanel_Button}">
<Image Source="/Resources/CALCPanel/Simulate.png" Stretch="Uniform"/>
</Button>
<Button ToolTip="{Binding Edit_ToolTip}"
Command="{Binding Edit_Command}"
IsEnabled="{Binding Edit_IsEnabled}"
Visibility="{Binding Edit_Visibility}"
Style="{StaticResource OnlyProdLeftPanel_Button}">
<Image Source="/Resources/CALCPanel/Edit.png" Stretch="Uniform"/>
</Button>
<!--<Button Command="{Binding NewRawPart_Command}"
Visibility="{Binding MachiningPage_Visibility}"
ToolTip="{Binding NewRawPart_ToolTip}"
IsEnabled="{Binding BTLPartManager_IsEnabled}"
Style="{StaticResource OnlyProdLeftPanel_Button}">
<Image Source="/Resources/LeftPanel/NewRawPart.png" Stretch="Uniform"/>
</Button>
<Button Command="{Binding NewRawPartLast_Command}"
Visibility="{Binding MachiningPage_Visibility}"
ToolTip="{Binding NewRawPartLast_ToolTip}"
IsEnabled="{Binding BTLPartManager_IsEnabled}"
Style="{StaticResource OnlyProdLeftPanel_Button}">
<Image Source="/Resources/LeftPanel/NewRawPartAuto.png" Stretch="Uniform"/>
</Button>-->
<!--<Button Command="{Binding AddToRawPart_Command}"
Visibility="{Binding MachiningPage_Visibility}"
ToolTip="{Binding AddToRawPart_ToolTip}"
IsEnabled="{Binding BTLPartManager_IsEnabled}"
Style="{StaticResource OnlyProdLeftPanel_Button}">
<Image Source="/Resources/LeftPanel/AddToRawPart.png" Stretch="Uniform"/>
</Button>-->
<!--<Button Command="{Binding Invert_Command}"
Visibility="{Binding ViewPage_Visibility}"
ToolTip="{Binding InvertSx_ToolTip}"
IsEnabled="{Binding RotatePart_IsEnabled}"
Style="{StaticResource OnlyProdLeftPanel_Button}">
<Image Source="/Resources/PartManager/LeftInvert.png" Stretch="Uniform"/>
</Button>
<Button Command="{Binding Invert_Command}"
Visibility="{Binding ViewPage_Visibility}"
ToolTip="{Binding InvertDx_ToolTip}"
IsEnabled="{Binding RotatePart_IsEnabled}"
Style="{StaticResource OnlyProdLeftPanel_Button}">
<Image Source="/Resources/PartManager/RightInvert.png" Stretch="Uniform"/>
</Button>
<Button Command="{Binding BackRotation_Command}"
Visibility="{Binding ViewPage_Visibility}"
ToolTip="{Binding BackRotation_ToolTip}"
IsEnabled="{Binding RotatePart_IsEnabled}"
Style="{StaticResource OnlyProdLeftPanel_Button}">
<Image Source="/Resources/PartManager/LeftRotate.png" Stretch="Uniform"/>
</Button>
<Button Command="{Binding ForwardRotation_Command}"
Visibility="{Binding ViewPage_Visibility}"
ToolTip="{Binding ForwardRotation_ToolTip}"
IsEnabled="{Binding RotatePart_IsEnabled}"
Style="{StaticResource OnlyProdLeftPanel_Button}">
<Image Source="/Resources/PartManager/RightRotate.png" Stretch="Uniform"/>
</Button>-->
</StackPanel>
@@ -0,0 +1,3 @@
Public Class OnlyProdBTLPartManagerV
End Class
@@ -8,8 +8,6 @@ Imports EgtWPFLib5
Public Class BTLFeatureVM Public Class BTLFeatureVM
Inherits Core.BTLFeatureVM Inherits Core.BTLFeatureVM
#Region "FIELDS & PROPERTIES"
Public Property GRPList As ObservableCollection(Of Integer) Public Property GRPList As ObservableCollection(Of Integer)
Get Get
Return m_BTLFeatureM.GRPList Return m_BTLFeatureM.GRPList
@@ -152,6 +150,7 @@ Public Class BTLFeatureVM
End If End If
NotifyPropertyChanged(NameOf(nSelVARIANT)) NotifyPropertyChanged(NameOf(nSelVARIANT))
NotifyPropertyChanged(NameOf(PBTLParamVMList)) NotifyPropertyChanged(NameOf(PBTLParamVMList))
NotifyPropertyChanged(NameOf(QBTLParamVMList))
EgtDraw() EgtDraw()
End If End If
End Set End Set
@@ -162,16 +161,18 @@ Public Class BTLFeatureVM
m_BTLFeatureM.CreateFeatureParams(m_BTLFeatureM) m_BTLFeatureM.CreateFeatureParams(m_BTLFeatureM)
m_BTLFeatureM.SetDefaultValues() m_BTLFeatureM.SetDefaultValues()
CreatePBTLParamVMList() CreatePBTLParamVMList()
CreateQBTLParamVMList()
' aggiorno la feature con nuovo valore ' aggiorno la feature con nuovo valore
vPar = Nothing vPar = Nothing
sPar = Nothing sPar = Nothing
vParQ = Nothing vParQ = Nothing
m_BTLFeatureM.CalcParamArray(vPar, sPar, vParQ) m_BTLFeatureM.CalcParamArray(vPar, sPar, vParQ)
If value > 0 AndAlso IO.File.Exists(Map.refMainWindowVM.MainWindowM.sResourcesRoot & "\Features\" & sDescGRP & "." & sDES & ".png") Then '' imposto path disegno da mostrare in BottomPanel
Map.refPParameterListVM.SetCurrDraw(Map.refMainWindowVM.MainWindowM.sResourcesRoot & "\Features\" & sDescGRP & "." & sDES & ".png") 'If value > 0 AndAlso File.Exists(Map.refMainWindowVM.MainWindowM.sResourcesRoot & "\Features\" & sDescGRP & "." & sDES & ".png") Then
Else ' Map.refBottomPanelVM.SetCurrDraw(Map.refMainWindowVM.MainWindowM.sResourcesRoot & "\Features\" & sDescGRP & "." & sDES & ".png")
Map.refPParameterListVM.SetCurrDraw(Map.refMainWindowVM.MainWindowM.sResourcesRoot & "\Features\" & sDescGRP & ".png") 'Else
End If ' Map.refBottomPanelVM.SetCurrDraw(Map.refMainWindowVM.MainWindowM.sResourcesRoot & "\Features\" & sDescGRP & ".png")
'End If
End Sub End Sub
Public Property sPriority As String Public Property sPriority As String
@@ -185,8 +186,11 @@ Public Class BTLFeatureVM
m_BTLFeatureM.nPriority = nTemp m_BTLFeatureM.nPriority = nTemp
' setto feature da ricalcolare ' setto feature da ricalcolare
ResetCalcFeature() ResetCalcFeature()
' imposto modificato per copie ' se in View
MyMachGroupPanelM.SetDuploModified(m_BTLPartM.nPartId) If Map.refMainMenuVM.SelPage = Pages.VIEW OrElse Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE Then
' imposto modificato per copie
MyMachGroupPanelM.SetDuploModified(m_BTLPartM.nPartId)
End If
End If End If
End If End If
NotifyPropertyChanged(NameOf(sPriority)) NotifyPropertyChanged(NameOf(sPriority))
@@ -211,11 +215,16 @@ Public Class BTLFeatureVM
Set(value As Boolean) Set(value As Boolean)
Dim bShowSolid As Boolean = Map.refShowBeamPanelVM.ShowSolid_IsChecked Dim bShowSolid As Boolean = Map.refShowBeamPanelVM.ShowSolid_IsChecked
If value <> m_BTLFeatureM.bDO Then If value <> m_BTLFeatureM.bDO Then
'If Map.refMainMenuVM.SelPage = Pages.VIEW Then
' ' verifico se solido attivo
' If bShowSolid Then Map.refProjectVM.BTLStructureVM.ShowSolid(GDB_ID.NULL, False, False)
'End If
If EgtBeamEnableProcess(nFeatureId, value, Not m_bDO_MultipleUpdate) Then If EgtBeamEnableProcess(nFeatureId, value, Not m_bDO_MultipleUpdate) Then
m_BTLFeatureM.bDO = value m_BTLFeatureM.bDO = value
' setto feature da ricalcolare ' setto feature da ricalcolare
ResetCalcFeature() ResetCalcFeature()
If Not IsNothing(m_BTLPartM) Then ' se in View
If Map.refMainMenuVM.SelPage = Pages.VIEW OrElse (Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE AndAlso Not IsNothing(m_BTLPartM)) Then
MyMachGroupPanelM.SetDuploModified(m_BTLPartM.nPartId) MyMachGroupPanelM.SetDuploModified(m_BTLPartM.nPartId)
End If End If
NotifyPropertyChanged(NameOf(bDO)) NotifyPropertyChanged(NameOf(bDO))
@@ -224,6 +233,10 @@ Public Class BTLFeatureVM
Item.NotifyPropertyChanged(NameOf(Item.sMsg)) Item.NotifyPropertyChanged(NameOf(Item.sMsg))
Next Next
End If End If
'If Map.refMainMenuVM.SelPage = Pages.VIEW Then
' ' eventualmente ripristino solido
' If bShowSolid Then Map.refProjectVM.BTLStructureVM.ShowSolid(GDB_ID.NULL, True, False)
'End If
If Not m_bDO_MultipleUpdate Then EgtDraw() If Not m_bDO_MultipleUpdate Then EgtDraw()
' aggiorno stato abilitazione del bottone modifica free contour ' aggiorno stato abilitazione del bottone modifica free contour
Map.refFeatureManagerVM.SetEditIsEnabled() Map.refFeatureManagerVM.SetEditIsEnabled()
@@ -260,14 +273,39 @@ Public Class BTLFeatureVM
m_SelPBTLParam = value m_SelPBTLParam = value
If Not IsNothing(m_SelPBTLParam) Then If Not IsNothing(m_SelPBTLParam) Then
' imposto path disegno da mostrare in BottomPanel ' imposto path disegno da mostrare in BottomPanel
If Not IsNothing(Map.refProjectVM) Then 'If Not IsNothing(Map.refBottomPanelVM) Then
Map.refPParameterListVM.SetCurrDraw(m_SelPBTLParam.sDrawPath) ' Map.refBottomPanelVM.SetCurrDraw(m_SelPBTLParam.sDrawPath)
End If 'End If
End If End If
NotifyPropertyChanged(NameOf(SelPBTLParam)) NotifyPropertyChanged(NameOf(SelPBTLParam))
End Set End Set
End Property End Property
Private m_QBTLParamVMList As ObservableCollection(Of BTLParamVM)
Public Property QBTLParamVMList As ObservableCollection(Of BTLParamVM)
Get
Return m_QBTLParamVMList
End Get
Set(value As ObservableCollection(Of BTLParamVM))
m_QBTLParamVMList = value
End Set
End Property
Protected m_SelQParam As BTLParamVM
Public Property SelQBTLParam As BTLParamVM
Get
Return m_SelQParam
End Get
Set(value As BTLParamVM)
m_SelQParam = value
'If Not IsNothing(m_SelQParam) AndAlso Not IsNothing(Map.refBottomPanelVM) Then
' ' imposto path disegno da mostrare in BottomPanel
' Map.refBottomPanelVM.SetCurrDraw(m_SelQParam.sDrawPath)
'End If
NotifyPropertyChanged(NameOf(SelQBTLParam))
End Set
End Property
Public ReadOnly Property Edit_Visibility As Visibility Public ReadOnly Property Edit_Visibility As Visibility
Get Get
Return If(BTLFeatureM.IsFreeContour AndAlso Not Map.refFreeContourManagerVM.bIsActive, Visibility.Visible, Visibility.Collapsed) Return If(BTLFeatureM.IsFreeContour AndAlso Not Map.refFreeContourManagerVM.bIsActive, Visibility.Visible, Visibility.Collapsed)
@@ -311,15 +349,15 @@ Public Class BTLFeatureVM
Private m_cmdEditFeature As ICommand Private m_cmdEditFeature As ICommand
Private m_cmdStategyCmd As ICommand Private m_cmdStategyCmd As ICommand
#End Region ' FIELDS & PROPERTIES
#Region "CONSTRUCTOR" #Region "CONSTRUCTOR"
Sub New(BTLFeatureM As BTLFeatureM, BTLPartM As BTLPartM) Sub New(BTLFeatureM As BTLFeatureM, BTLPartM As BTLPartM)
m_BTLFeatureM = BTLFeatureM m_BTLFeatureM = BTLFeatureM
AddHandler m_BTLFeatureM.PBTLParamAdded, AddressOf OnPBTLParamAdded AddHandler m_BTLFeatureM.PBTLParamAdded, AddressOf OnPBTLParamAdded
AddHandler m_BTLFeatureM.QBTLParamAdded, AddressOf OnQBTLParamAdded
m_BTLPartM = BTLPartM m_BTLPartM = BTLPartM
CreatePBTLParamVMList() CreatePBTLParamVMList()
CreateQBTLParamVMList()
NotifyPropertyChanged(NameOf(Calc_Background)) NotifyPropertyChanged(NameOf(Calc_Background))
NotifyPropertyChanged(NameOf(CALC_ROT_Visibility)) NotifyPropertyChanged(NameOf(CALC_ROT_Visibility))
NotifyPropertyChanged(NameOf(CALC_ERR_Letter)) NotifyPropertyChanged(NameOf(CALC_ERR_Letter))
@@ -329,7 +367,10 @@ Public Class BTLFeatureVM
Sub New(BTLFeatureM As BTLFeatureM) Sub New(BTLFeatureM As BTLFeatureM)
m_BTLFeatureM = BTLFeatureM m_BTLFeatureM = BTLFeatureM
AddHandler m_BTLFeatureM.QBTLParamAdded, AddressOf OnQBTLParamAdded
m_BTLPartM = Nothing m_BTLPartM = Nothing
Dim Part As PartM = BTLFeatureM.ParentPart
If Part.nType = BWType.WALL Then CreateQBTLParamVMList()
NotifyPropertyChanged(NameOf(Calc_Background)) NotifyPropertyChanged(NameOf(Calc_Background))
NotifyPropertyChanged(NameOf(CALC_ROT_Visibility)) NotifyPropertyChanged(NameOf(CALC_ROT_Visibility))
NotifyPropertyChanged(NameOf(CALC_ERR_Letter)) NotifyPropertyChanged(NameOf(CALC_ERR_Letter))
@@ -353,11 +394,23 @@ Public Class BTLFeatureVM
End Sub End Sub
Private Sub CreateQBTLParamVMList()
Dim all As List(Of BTLParamVM) = (From BTLParamM In m_BTLFeatureM.GetQBTLParams()
Select New BTLParamVM(BTLParamM, m_BTLFeatureM)).ToList()
For Each BTLParamVM As BTLParamVM In all
AddHandler BTLParamVM.PropertyChanged, AddressOf OnQBTLParamVMPropertyChanged
Next
m_QBTLParamVMList = New ObservableCollection(Of BTLParamVM)(all)
AddHandler m_QBTLParamVMList.CollectionChanged, AddressOf OnQBTLParamVMListChanged
End Sub
' funzione che aggiorna lo stato, la rotazione e gli errori dopo calcolo ' funzione che aggiorna lo stato, la rotazione e gli errori dopo calcolo
Friend Sub CalcFeatureUpdate(nProgramPage As Integer, ERR As Integer, ROT As Integer, MSG As String) Friend Sub CalcFeatureUpdate(ERR As Integer, ROT As Integer, MSG As String)
EgtSetInfo(nFeatureId, If(nProgramPage = ProjectType.PROJ, ITG_PROJ_ERR, ITG_PROD_ERR), ERR, True) EgtSetInfo(nFeatureId, If(Map.refMainMenuVM.SelPage = Pages.VIEW, ITG_PROJ_ERR, ITG_PROD_ERR), ERR, True)
EgtSetInfo(nFeatureId, If(nProgramPage = ProjectType.PROJ, ITG_PROJ_MSG, ITG_PROD_MSG), MSG, True) EgtSetInfo(nFeatureId, If(Map.refMainMenuVM.SelPage = Pages.VIEW, ITG_PROJ_MSG, ITG_PROD_MSG), MSG, True)
EgtSetInfo(nFeatureId, If(nProgramPage = ProjectType.PROJ, ITG_PROJ_ROT, ITG_PROD_ROT), ROT, True) EgtSetInfo(nFeatureId, If(Map.refMainMenuVM.SelPage = Pages.VIEW, ITG_PROJ_ROT, ITG_PROD_ROT), ROT, True)
m_BTLFeatureM.nCALC_ERR = ERR m_BTLFeatureM.nCALC_ERR = ERR
m_BTLFeatureM.nCALC_ROT = ROT m_BTLFeatureM.nCALC_ROT = ROT
m_BTLFeatureM.sCALC_MSG = MSG m_BTLFeatureM.sCALC_MSG = MSG
@@ -441,6 +494,10 @@ Public Class BTLFeatureVM
DestBTLPart.NewProcId(), m_BTLFeatureM.frFRAME, vPar, sPar, vParQ, nCrvId, nCrv2Id) DestBTLPart.NewProcId(), m_BTLFeatureM.frFRAME, vPar, sPar, vParQ, nCrvId, nCrv2Id)
' se è stata creata ' se è stata creata
If nNewFeatureId <> GDB_ID.NULL Then If nNewFeatureId <> GDB_ID.NULL Then
' Riporto eventuali indicazioni di parametri Q custom
For Each QPar In QBTLParamVMList
If QPar.bCustom Then EgtSetInfo(nNewFeatureId, QPar.sName & "A", 1)
Next
' Riporto priority ' Riporto priority
EgtSetInfo(nNewFeatureId, BTL_FTR_PRIORITY, m_BTLFeatureM.nPriority) EgtSetInfo(nNewFeatureId, BTL_FTR_PRIORITY, m_BTLFeatureM.nPriority)
Dim NewFeat As BTLFeatureM = BTLFeatureM.CreateBTLFeature(m_BTLPartM, nNewFeatureId) Dim NewFeat As BTLFeatureM = BTLFeatureM.CreateBTLFeature(m_BTLPartM, nNewFeatureId)
@@ -565,48 +622,11 @@ Public Class BTLFeatureVM
End Property End Property
Public Sub Strategy() Public Sub Strategy()
Map.refProjectVM.SetSelManagerTab(ProjectVM.StrategyManagerTab.STRATEGYMANAGER) ' disattivo modalita' contorno libero
' Disabilito LeftPanel Map.refProjectVM.SetSelManagerTab(ProjectVM.ManagerTab.STRATEGYMANAGER)
Map.refProjectVM.SetOnlyProdLeftPanel_IsEnabled(False)
Map.refProjectVM.SetOnlyProdLeftPanel_Opacity(0.2)
Map.refForcedStrategyPanelVM.Init(BTLFeatureM)
End Sub End Sub
#End Region ' Strategy #End Region ' Cancel
#Region "Edit"
''' <summary>
''' Returns a command that do Open.
''' </summary>
Public ReadOnly Property EditFeature_Command As ICommand
Get
If m_cmdEditFeature Is Nothing Then
m_cmdEditFeature = New Command(AddressOf EditFeature)
End If
Return m_cmdEditFeature
End Get
End Property
''' <summary>
''' Execute the Open. This method is invoked by the OpenCommand.
''' </summary>
Friend Sub EditFeature()
If Not IsNothing(Map.refProjectVM.BTLStructureVM) AndAlso Not IsNothing(Map.refProjectVM.BTLStructureVM.SelBTLPart) AndAlso Not IsNothing(Map.refProjectVM.BTLStructureVM.SelBTLPart.SelBTLFeatureVM) Then
'Map.refForcedStrategyBTLVM.Init(Map.refProjectVM.BTLStructureVM.SelBTLPart.SelBTLFeatureVM.BTLFeatureM)
Map.refForcedStrategyPanelVM.Init(Map.refProjectVM.BTLStructureVM.SelBTLPart.SelBTLFeatureVM.BTLFeatureM)
End If
Map.refProjectVM.SetRawPartManagerVisibility(Visibility.Collapsed)
'Map.refProjectVM.SetStrategyManagerVisibility(Visibility.Visible)
Map.refProjectVM.SetSelManagerTab(ProjectVM.StrategyManagerTab.FEATUREMANAGERBTL)
Map.refProjectVM.SetSelFeatureManagerTab(ProjectVM.FeatureManagerTab.STRATEGYMANAGERBTL)
' Disabilito LeftPanel
Map.refProjectVM.SetOnlyProdLeftPanel_IsEnabled(False)
Map.refProjectVM.SetOnlyProdLeftPanel_Opacity(0.2)
End Sub
#End Region ' Edit
#End Region ' COMMANDS #End Region ' COMMANDS
@@ -616,6 +636,10 @@ Public Class BTLFeatureVM
Dim BTLParamVM As New BTLParamVM(e.NewBTLParam, m_BTLFeatureM) Dim BTLParamVM As New BTLParamVM(e.NewBTLParam, m_BTLFeatureM)
PBTLParamVMList.Add(BTLParamVM) PBTLParamVMList.Add(BTLParamVM)
End Sub End Sub
Private Sub OnQBTLParamAdded(sender As Object, e As BTLParamAddedEventArgs) Handles m_BTLFeatureM.QBTLParamAdded
Dim BTLParamVM As New BTLParamVM(e.NewBTLParam, m_BTLFeatureM)
QBTLParamVMList.Add(BTLParamVM)
End Sub
Private Sub OnPBTLParamVMListChanged(sender As Object, e As NotifyCollectionChangedEventArgs) Private Sub OnPBTLParamVMListChanged(sender As Object, e As NotifyCollectionChangedEventArgs)
If Not IsNothing(e.NewItems) AndAlso e.NewItems.Count > 0 Then If Not IsNothing(e.NewItems) AndAlso e.NewItems.Count > 0 Then
@@ -629,6 +653,18 @@ Public Class BTLFeatureVM
Next Next
End If End If
End Sub End Sub
Private Sub OnQBTLParamVMListChanged(sender As Object, e As NotifyCollectionChangedEventArgs)
If Not IsNothing(e.NewItems) AndAlso e.NewItems.Count > 0 Then
For Each BTLParamVM As BTLParamVM In e.NewItems
AddHandler BTLParamVM.PropertyChanged, AddressOf OnQBTLParamVMPropertyChanged
Next
End If
If Not IsNothing(e.OldItems) AndAlso e.OldItems.Count > 0 Then
For Each BTLParamVM As BTLParamVM In e.OldItems
RemoveHandler BTLParamVM.PropertyChanged, AddressOf OnQBTLParamVMPropertyChanged
Next
End If
End Sub
Private Sub OnPBTLParamVMPropertyChanged(sender As Object, e As PropertyChangedEventArgs) Private Sub OnPBTLParamVMPropertyChanged(sender As Object, e As PropertyChangedEventArgs)
Select Case e.PropertyName Select Case e.PropertyName
@@ -639,6 +675,15 @@ Public Class BTLFeatureVM
ResetCalcFeature() ResetCalcFeature()
End Select End Select
End Sub End Sub
Private Sub OnQBTLParamVMPropertyChanged(sender As Object, e As PropertyChangedEventArgs)
Select Case e.PropertyName
Case NameOf(sender.dValue), NameOf(sender.sValue)
' riseleziono questa feature
SelGeomFeature()
' rendo non calcolata questa feature
ResetCalcFeature()
End Select
End Sub
#End Region ' EVENTS #End Region ' EVENTS
@@ -5,8 +5,6 @@ Imports EgtWPFLib5
Public Class BTLParamVM Public Class BTLParamVM
Inherits VMBase Inherits VMBase
#Region "FIELDS & PROPERTIES"
Protected m_BTLParamM As BTLParamM Protected m_BTLParamM As BTLParamM
Public ReadOnly Property BTLParamM As BTLParamM Public ReadOnly Property BTLParamM As BTLParamM
Get Get
@@ -144,7 +142,7 @@ Public Class BTLParamVM
Dim INPROD As Integer = 0 Dim INPROD As Integer = 0
EgtDuploInRawCount(nPartId, INPROD) EgtDuploInRawCount(nPartId, INPROD)
' recupero pezzi lavorati da Db ' recupero pezzi lavorati da Db
Dim nDoneCnt As Integer = DbControllers.m_ProjController.getCountItemState(ProjectManagerVM.CurrProd.nProdId, nPartId, ItemState.Assigned) Dim nDoneCnt As Integer = DbControllers.m_ProjController.getCountItemState(ProjectManagerVM.CurrProj.nProjId, nPartId, ItemState.Assigned)
' controllo se i pezzi sono lavorati se si messaggio di warning altrimenti messaggio informativo ' controllo se i pezzi sono lavorati se si messaggio di warning altrimenti messaggio informativo
If nDoneCnt > 0 Then If nDoneCnt > 0 Then
MessageBox.Show("Pezzo " & nPartId & " non modificato in " & INPROD & " barra/e perche' settata/e come da produrre", EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Warning) MessageBox.Show("Pezzo " & nPartId & " non modificato in " & INPROD & " barra/e perche' settata/e come da produrre", EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Warning)
@@ -254,8 +252,6 @@ Public Class BTLParamVM
End Get End Get
End Property End Property
#End Region ' FIELDS & PROPERTIES
#Region "CONSTRUCTOR" #Region "CONSTRUCTOR"
Sub New(BTLParamM As BTLParamM, BTLFeatureM As BTLFeatureM) Sub New(BTLParamM As BTLParamM, BTLFeatureM As BTLFeatureM)
@@ -270,8 +266,6 @@ Public Class BTLParamVM
#End Region ' CONSTRUCTOR #End Region ' CONSTRUCTOR
#Region "METHODS"
Friend Sub UpdateParamValue(dNewValue As Double, sNewValue As String, Optional bDraw As Boolean = True) Friend Sub UpdateParamValue(dNewValue As Double, sNewValue As String, Optional bDraw As Boolean = True)
' verifico se solido attivo ' verifico se solido attivo
Dim bShowSolid As Boolean = Map.refShowBeamPanelVM.ShowSolid_IsChecked Dim bShowSolid As Boolean = Map.refShowBeamPanelVM.ShowSolid_IsChecked
@@ -337,6 +331,4 @@ Public Class BTLParamVM
If bDraw Then EgtDraw() If bDraw Then EgtDraw()
End Sub End Sub
#End Region ' METHODS
End Class End Class
+146 -104
View File
@@ -1,9 +1,10 @@
Imports System.Collections.ObjectModel Imports System.Collections.ObjectModel
Imports EgtWPFLib5
Imports EgtUILib
Imports EgtBEAMWALL.Core
Imports System.Collections.Specialized Imports System.Collections.Specialized
Imports System.ComponentModel Imports System.ComponentModel
Imports EgtBEAMWALL.Core Imports System.IO
Imports EgtUILib
Imports EgtWPFLib5
Public Class BTLPartVM Public Class BTLPartVM
Inherits VMBase Inherits VMBase
@@ -89,7 +90,7 @@ Public Class BTLPartVM
EgtOutLog("Trovato Duplo Ghost") EgtOutLog("Trovato Duplo Ghost")
Else Else
Dim MachGroupModel = Nothing Dim MachGroupModel = Nothing
If Not IsNothing(Map.refProdManagerVM) Then If Not IsNothing(Map.refOnlyProdManagerVM) Then
MachGroupModel = DbControllers.m_MachGroupController.FindByMachGroupId(ProjectManagerVM.CurrProj.nProdId, nMachgroupId) MachGroupModel = DbControllers.m_MachGroupController.FindByMachGroupId(ProjectManagerVM.CurrProj.nProdId, nMachgroupId)
End If End If
If Not IsNothing(MachGroupModel) AndAlso MachGroupModel.State > ItemState.ND Then If Not IsNothing(MachGroupModel) AndAlso MachGroupModel.State > ItemState.ND Then
@@ -1524,84 +1525,50 @@ Public Class BTLPartVM
End Get End Get
End Property End Property
Private m_PrevSelBTLFeatureVM As BTLFeatureVM
Public m_SelBTLFeatureVM As BTLFeatureVM Public m_SelBTLFeatureVM As BTLFeatureVM
Public Property SelBTLFeatureVM As BTLFeatureVM Public Property SelBTLFeatureVM As BTLFeatureVM
Get Get
Return m_SelBTLFeatureVM Return m_SelBTLFeatureVM
End Get End Get
Set(value As BTLFeatureVM) Set(value As BTLFeatureVM)
If Not IsNothing(m_PrevSelBTLFeatureVM) Then m_PrevSelBTLFeatureVM.DeselGeomFeature()
m_SelBTLFeatureVM = value m_SelBTLFeatureVM = value
'If Map.refMainMenuVM.SelPage = Pages.VIEW OrElse (Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE AndAlso Map.refProjectVM.LastSelGridType = ProjectVM.GridSelTypes.PART) Then
If Not IsNothing(m_SelBTLFeatureVM) Then If Not IsNothing(m_SelBTLFeatureVM) Then
m_SelBTLFeatureVM.SelGeomFeature() DirectCast(m_SelBTLFeatureVM, BTLFeatureVM).SelGeomFeature()
m_PrevSelBTLFeatureVM = value ' deseleziono i parametri
Map.refPParameterListVM.SetCurrDraw(DirectCast(m_SelBTLFeatureVM, BTLFeatureVM).sDrawPath) If Not IsNothing(SelBTLFeatureVM.SelPBTLParam) Then SelBTLFeatureVM.SelPBTLParam = Nothing
' deseleziono i parametri ' rinfresco bottoni freecontour
If Not IsNothing(SelBTLFeatureVM.SelPBTLParam) Then SelBTLFeatureVM.SelPBTLParam = Nothing m_SelBTLFeatureVM.RefreshFCMBtnVisibility()
' rinfresco bottoni freecontour ' aggiorno stato abilitazione del bottone modifica free contour
m_SelBTLFeatureVM.RefreshFCMBtnVisibility() If Map.refMainMenuVM.SelPage <> Pages.ONLYPRODPAGE Then
Map.refStatisticsTimePanelVM.SetViewPage_Visibility(Visibility.Visible) Map.refFeatureManagerVM.SetEditIsEnabled()
Map.refStatisticsTimePanelVM.SetMachiningPage_Visibility(Visibility.Collapsed) Map.refFeatureManagerVM.NotifyPropertyChanged(NameOf(Map.refFeatureManagerVM.Priority_Visibility))
' Controlo se nPRC è 900 rendo visibile combobox Variant
If m_SelBTLFeatureVM.nPRC = 900 Then
Map.refFeatureManagerVM.SetVariant_Visibility(Visibility.Visible)
Dim nVariant As Integer = 0
If Integer.TryParse(m_SelBTLFeatureVM.sDES, nVariant) Then
m_SelBTLFeatureVM.nSelVARIANT = nVariant
End If End If
If m_SelBTLFeatureVM.nSelVARIANT > 0 AndAlso ' Controlo se nPRC è 900 rendo visibile combobox Variant
System.IO.File.Exists(Map.refMainWindowVM.MainWindowM.sResourcesRoot & "\Features\" & m_SelBTLFeatureVM.sDescGRP & "." & m_SelBTLFeatureVM.sDES & ".png") Then If m_SelBTLFeatureVM.nPRC = 900 Then
' imposto path disegno da mostrare in BottomPanel Map.refFeatureManagerVM.SetVariant_Visibility(Visibility.Visible)
Map.refPParameterListVM.SetCurrDraw(Map.refMainWindowVM.MainWindowM.sResourcesRoot & "\Features\" & m_SelBTLFeatureVM.sDescGRP & "." & m_SelBTLFeatureVM.sDES & ".png") Dim nVariant As Integer = 0
If Integer.TryParse(m_SelBTLFeatureVM.sDES, nVariant) Then
m_SelBTLFeatureVM.nSelVARIANT = nVariant
End If
Else Else
Map.refPParameterListVM.SetCurrDraw(Map.refMainWindowVM.MainWindowM.sResourcesRoot & "\Features\" & m_SelBTLFeatureVM.sDescGRP & ".png") If Map.refMainMenuVM.SelPage <> Pages.ONLYPRODPAGE Then Map.refFeatureManagerVM.SetVariant_Visibility(Visibility.Collapsed)
End If End If
Else Else
Map.refFeatureManagerVM.SetVariant_Visibility(Visibility.Collapsed) EgtDeselectAll()
End If End If
' Forzo strategia If Not IsNothing(Map.refFeatureListManagerVM) Then Map.refFeatureListManagerVM.FeatureSelectionChanged()
'Map.refForcedStrategyBTLVM.Init(m_SelBTLFeatureVM.BTLFeatureM) 'End If
Map.refForcedStrategyPanelVM.Init(m_SelBTLFeatureVM.BTLFeatureM) If Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE Then
'Else EgtResetCurrMachGroup()
' EgtDeselectAll() ResetSearchFound()
Map.refStatisticsTimePanelVM.SetViewPage_Visibility(Visibility.Visible)
Map.refStatisticsTimePanelVM.SetMachiningPage_Visibility(Visibility.Collapsed)
End If End If
If Not IsNothing(Map.refFeatureListManagerVM) Then Map.refFeatureListManagerVM.FeatureSelectionChanged()
EgtDraw() EgtDraw()
NotifyPropertyChanged(NameOf(SelBTLFeatureVM)) NotifyPropertyChanged(NameOf(SelBTLFeatureVM))
' se modalità building, la tolgo
If Not IsNothing(m_SelBTLFeatureVM) AndAlso Map.refShowBeamPanelVM.ShowBuilding_IsChecked Then
Map.refProjectVM.BTLStructureVM.ShowBuilding(False, False)
Map.refShowBeamPanelVM.SetShowBuilding(False)
End If
End Set End Set
End Property End Property
'Public Property SelBTLFeatureVMOnlyGraph As BTLFeatureVM
' Get
' Return m_SelBTLFeatureVM
' End Get
' Set(value As BTLFeatureVM)
' m_SelBTLFeatureVM = value
' If Not IsNothing(m_SelBTLFeatureVM) Then
' m_SelBTLFeatureVM.SelGeomFeature()
' ' deseleziono i parametri
' If Not IsNothing(SelBTLFeatureVM.SelPBTLParam) Then SelBTLFeatureVM.SelPBTLParam = Nothing
' End If
' If Not IsNothing(Map.refFeatureListManagerVM) Then Map.refFeatureListManagerVM.FeatureSelectionChanged()
' EgtResetCurrMachGroup()
' ResetSearchFound()
' Map.refStatisticsTimePanelVM.SetViewPage_Visibility(Visibility.Visible)
' Map.refStatisticsTimePanelVM.SetMachiningPage_Visibility(Visibility.Collapsed)
' EgtDraw()
' NotifyPropertyChanged(NameOf(SelBTLFeatureVM))
' NotifyPropertyChanged(NameOf(SelBTLFeatureVMOnlyGraph))
' ' se modalità building, la tolgo
' If Not IsNothing(m_SelBTLFeatureVM) AndAlso Map.refShowBeamPanelVM.ShowBuilding_IsChecked Then
' Map.refProjectVM.BTLStructureVM.ShowBuilding(False, False)
' Map.refShowBeamPanelVM.SetShowBuilding(False)
' End If
' End Set
'End Property
Private m_Calc_PartEnd As Boolean = False Private m_Calc_PartEnd As Boolean = False
Public ReadOnly Property Calc_PartEnd As Boolean Public ReadOnly Property Calc_PartEnd As Boolean
@@ -1627,7 +1594,7 @@ Public Class BTLPartVM
Public ReadOnly Property Search_Background As SolidColorBrush Public ReadOnly Property Search_Background As SolidColorBrush
Get Get
Return If(m_bSearchFound, Brushes.Purple, Brushes.Transparent) Return If(m_bSearchFound AndAlso Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE, Brushes.Purple, Brushes.Transparent)
End Get End Get
End Property End Property
@@ -1659,33 +1626,6 @@ Public Class BTLPartVM
NotifyPropertyChanged(NameOf(IsSettingBtnOpen)) NotifyPropertyChanged(NameOf(IsSettingBtnOpen))
End Sub End Sub
Public Property IsInverted As Boolean
Get
Return BTLPartM.nINVERTED = 180
End Get
Set(value As Boolean)
' eseguo inversione
m_BTLPartM.Inversion(Map.refProjectVM.BTLStructureVM.nPROJTYPE)
' setto part e tutte le feature da ricalcolare
ResetCalcTotalPart()
EgtDraw()
' imposto lock
bLockInversion = True
NotifyPropertyChanged(NameOf(IsInverted))
End Set
End Property
Private m_IsRowEnabled As Boolean = True
Public ReadOnly Property IsRowEnabled As Boolean
Get
Return m_IsRowEnabled
End Get
End Property
Friend Sub SetIsRowEnabled(bIsRowEnabled As Boolean)
m_IsRowEnabled = bIsRowEnabled
NotifyPropertyChanged(NameOf(IsRowEnabled))
End Sub
' Definizione comandi ' Definizione comandi
Private m_cmdInvert As ICommand Private m_cmdInvert As ICommand
Private m_cmdBackRotation As ICommand Private m_cmdBackRotation As ICommand
@@ -1748,7 +1688,6 @@ Public Class BTLPartVM
' Aggiorno stato da stati feature ' Aggiorno stato da stati feature
CalcGlobalUpdate() CalcGlobalUpdate()
NotifyPropertyChanged(NameOf(CALC_FALL_Visibility)) NotifyPropertyChanged(NameOf(CALC_FALL_Visibility))
NotifyPropertyChanged(NameOf(IsInverted))
End Sub End Sub
Private Function FeatureFilter(Feature As Object) As Boolean Private Function FeatureFilter(Feature As Object) As Boolean
@@ -1780,6 +1719,10 @@ Public Class BTLPartVM
AddHandler BTLParamVM.PropertyChanged, AddressOf OnBTLPParamVMPropertyChanged AddHandler BTLParamVM.PropertyChanged, AddressOf OnBTLPParamVMPropertyChanged
Next Next
AddHandler BTLFeatureVM.PBTLParamVMList.CollectionChanged, AddressOf OnBTLPParamVMListChanged AddHandler BTLFeatureVM.PBTLParamVMList.CollectionChanged, AddressOf OnBTLPParamVMListChanged
For Each BTLParamVM As BTLParamVM In BTLFeatureVM.QBTLParamVMList
AddHandler BTLParamVM.PropertyChanged, AddressOf OnBTLQParamVMPropertyChanged
Next
AddHandler BTLFeatureVM.QBTLParamVMList.CollectionChanged, AddressOf OnBTLQParamVMListChanged
Next Next
m_BTLFeatureVMList = New ObservableCollection(Of BTLFeatureVM)(all) m_BTLFeatureVMList = New ObservableCollection(Of BTLFeatureVM)(all)
@@ -1926,7 +1869,7 @@ Public Class BTLPartVM
Dim nNewPartId As Integer = EgtBeamCreatePart() Dim nNewPartId As Integer = EgtBeamCreatePart()
If nNewPartId = GDB_ID.NULL Then Return Nothing If nNewPartId = GDB_ID.NULL Then Return Nothing
' scrivo info proj ' scrivo info proj
If Not IsNothing(Map.refProdManagerVM) Then If Not IsNothing(Map.refOnlyProdManagerVM) Then
EgtSetInfo(nNewPartId, BTL_PRT_PROJ, ProjectManagerVM.CurrProd.nProjIdList(0)) EgtSetInfo(nNewPartId, BTL_PRT_PROJ, ProjectManagerVM.CurrProd.nProjIdList(0))
End If End If
EgtBeamSetPartProdNbr(m_BTLStructureM.NewPDN()) EgtBeamSetPartProdNbr(m_BTLStructureM.NewPDN())
@@ -2287,9 +2230,16 @@ Public Class BTLPartVM
' .FullOpen = True, ' .FullOpen = True,
' .Color = Col.ToColor() ' .Color = Col.ToColor()
'} '}
Dim ColorDlg As New OnlyProdEgtColorPickerV(Application.Current.MainWindow, New EgtColorPickerVM()) With { Dim ColorDlg As Object
.Color = Col.ToColor() If bOnlyProd Then
} ColorDlg = New OnlyProdEgtColorPickerV(Application.Current.MainWindow, New EgtColorPickerVM()) With {
.Color = Col.ToColor()
}
Else
ColorDlg = New EgtColorPickerV(Application.Current.MainWindow, New EgtColorPickerVM()) With {
.Color = Col.ToColor()
}
End If
' Visualizzo dialogo ' Visualizzo dialogo
If ColorDlg.ShowDialog() <> Forms.DialogResult.OK Then Return False If ColorDlg.ShowDialog() <> Forms.DialogResult.OK Then Return False
' Recupero colore scelto ' Recupero colore scelto
@@ -2338,9 +2288,102 @@ Public Class BTLPartVM
''' Execute the Open. This method is invoked by the OpenCommand. ''' Execute the Open. This method is invoked by the OpenCommand.
''' </summary> ''' </summary>
Friend Sub Verify() Friend Sub Verify()
If IsNothing(ProjectManagerVM.CurrProd) OrElse IsNothing(Map.refProjectVM.BTLStructureVM) OrElse IsNothing(Map.refProjectVM.MachGroupPanelVM) Then Return If ((IsNothing(ProjectManagerVM.CurrProd) OrElse IsNothing(Map.refProjectVM.BTLStructureVM) OrElse IsNothing(Map.refProjectVM.MachGroupPanelVM))) Then Return
Map.refCALCPanelVM.Verify(ProjectType.PROJ) Dim ProjType As BWType
Return Dim BarList() As EgtBEAMWALL.Core.Bar = Nothing
ProjType = ProjectManagerVM.CurrProd.nType
If Map.refProjectVM.LastSelGridType = ProjectVM.GridSelTypes.PART Then
If Not CreateBarToVerify(Pages.VIEW, ProjType, BarList) Then Return
' lancio calcolo
EgtBEAMWALL.Core.CalcIntegration.Run(BarList, Map.refOnlyProdManagerVM.CurrProj.sProjDirPath, AddressOf ManageCalc)
ElseIf Map.refProjectVM.LastSelGridType = ProjectVM.GridSelTypes.MACHGROUP Then
If Not CreateBarToVerify(Pages.MACHINING, ProjType, BarList) Then Return
' lancio calcolo
EgtBEAMWALL.Core.CalcIntegration.Run(BarList, Map.refOnlyProdManagerVM.CurrProd.sProdDirPath, AddressOf ManageCalc)
End If
End Sub
Private Function CreateBarToVerify(SelPage As Pages, ProjType As BWType, ByRef BarList As Bar()) As Boolean
If SelPage = Pages.VIEW Then
If Not IsNothing(Map.refProjectVM.BTLStructureVM.SelBTLPart) Then
Dim TempBarList(0) As EgtBEAMWALL.Core.Bar
If Not Map.refProjectVM.BTLStructureVM.SelBTLPart.bDO Then Return False
Dim Bar As New EgtBEAMWALL.Core.Bar With {.nBarId = Map.refProjectVM.BTLStructureVM.SelBTLPart.nPartId,
.nProgramPage = ProjectType.PROJ,
.nProjType = ProjType,
.bBarOk = True,
.nMachineName = Map.refMachinePanelVM.SelectedMachine.Name,
.nGlobState = Map.refProjectVM.BTLStructureVM.SelBTLPart.nGlobalState}
Select Case Map.refProjectVM.BTLStructureVM.SelBTLPart.nGlobalState
Case Core.CalcStates.OK, CalcStates.INFO
Bar.nCmdType = CalcIntegration.CmdTypes.GENERATE
Case Else
If Map.refProjectVM.BTLStructureVM.SelBTLPart.nGlobalState = CalcStates.NOTCALCULATED OrElse Map.refProjectVM.BTLStructureVM.SelBTLPart.nFeaturesGlobalState > CalcStates.INFO Then
Dim sBTLPartFilePath As String = ProjectManagerVM.CurrProj.sProjDirPath & "\" & Map.refProjectVM.BTLStructureVM.SelBTLPart.nPDN.ToString() & ".ori.bwe"
If File.Exists(sBTLPartFilePath) Then File.Delete(sBTLPartFilePath)
End If
Bar.nCmdType = CalcIntegration.CmdTypes.CHECKGEN
End Select
TempBarList(0) = Bar
BarList = TempBarList
Else
Return False
End If
' disabilito interfaccia
Map.refProjectVM.SetCalcRunning(True)
ElseIf SelPage = Pages.MACHINING Then
If Not IsNothing(Map.refMachGroupPanelVM.SelectedMachGroup) Then
Dim SelMachGroup As MyMachGroupVM = Map.refMachGroupPanelVM.SelectedMachGroup
' se barra gia' assegnata a supervisore, esco
If SelMachGroup.nProduction_State >= ItemState.Assigned Then Return False
Dim TempBarList(0) As EgtBEAMWALL.Core.Bar
Dim MachineName As String = ""
EgtGetMachGroupMachineName(SelMachGroup.Id, MachineName)
Dim Bar As New EgtBEAMWALL.Core.Bar With {.nBarId = SelMachGroup.Id,
.nProgramPage = ProjectType.PROD,
.nProjType = ProjType,
.bBarOk = True,
.nMachineName = MachineName,
.nGlobState = SelMachGroup.nGlobalState}
Select Case SelMachGroup.nGlobalState
Case Core.CalcStates.OK, CalcStates.INFO
Bar.nCmdType = CalcIntegration.CmdTypes.GENERATE
Case Else
If SelMachGroup.nGlobalState = CalcStates.NOTCALCULATED OrElse (SelMachGroup.nPartsGlobalState > CalcStates.INFO) Then
Dim sMachGroupFilePath As String = ProjectManagerVM.CurrProd.sProdDirPath & "\" & SelMachGroup.Name.ToString() & ".ori.bwe"
If File.Exists(sMachGroupFilePath) Then File.Delete(sMachGroupFilePath)
End If
Bar.nCmdType = CalcIntegration.CmdTypes.CHECKGEN
End Select
TempBarList(0) = Bar
BarList = TempBarList
Else
Return False
End If
' disabilito interfaccia
Map.refProjectVM.SetCalcRunning(True)
End If
Return True
End Function
' funzione che gestisce risposta da thread di verifica, aggiorna progress e segnala comando di interruzione
Private Sub ManageCalc(dProgress As Double, sProgress As String, ByRef bCancel As Boolean)
If dProgress = 0 Then
Map.refMyStatusBarVM.SetLoadingProgress_Visibility(True)
Map.refMyStatusBarVM.SetStopProgress_IsActive(True)
Map.refMyStatusBarVM.SetStopProgress_IsEnabled(True)
Map.refMyStatusBarVM.SetOutputMessage(sProgress)
Map.refMyStatusBarVM.SetStopProgress_IsActive(True)
Map.refMyStatusBarVM.SetStopProgress_IsEnabled(True)
ElseIf dProgress = 1 Then
Map.refMyStatusBarVM.SetLoadingProgress_Visibility(False)
Map.refMyStatusBarVM.SetStopProgress_IsActive(False)
Map.refMyStatusBarVM.SetStopProgress_IsEnabled(False)
Map.refMyStatusBarVM.SetOutputMessage(sProgress, 3)
End If
bCancel = Map.refMyStatusBarVM.bStopProgress
Map.refMyStatusBarVM.SetLoadingProgress(dProgress * 100)
Map.refMyStatusBarVM.SetOutputMessage(sProgress)
End Sub End Sub
#End Region ' Verify #End Region ' Verify
@@ -2524,7 +2567,7 @@ Public Class BTLPartVM
nRawId = EgtGetFirstRawPart() nRawId = EgtGetFirstRawPart()
End While End While
Dim sLogPath As String = Map.refMainWindowVM.MainWindowM.sTempDir & "\RawPartLog.txt" Dim sLogPath As String = Map.refMainWindowVM.MainWindowM.sTempDir & "\RawPartLog.txt"
If Not ExecBeam(sLogPath, ProjectManagerVM.CurrProd.sMachine, CalcIntegration.CmdTypes.RAWPART, False) Then If Not ExecBeam(sLogPath, Map.refMachinePanelVM.SelectedMachine.Name, CalcIntegration.CmdTypes.RAWPART, False) Then
EgtOutLog("Fallito inserimento grezzo nella barra in AddPartToBeam") EgtOutLog("Fallito inserimento grezzo nella barra in AddPartToBeam")
' elimino duplo ' elimino duplo
For Each nDuploId In nPartDuploIdList For Each nDuploId In nPartDuploIdList
@@ -2546,7 +2589,7 @@ Public Class BTLPartVM
EgtRemoveRawPart(nRawId) EgtRemoveRawPart(nRawId)
nRawId = EgtGetFirstRawPart() nRawId = EgtGetFirstRawPart()
End While End While
If Not ExecBeam(sLogPath, ProjectManagerVM.CurrProd.sMachine, CalcIntegration.CmdTypes.RAWPART, False) Then If Not ExecBeam(sLogPath, Map.refMachinePanelVM.SelectedMachine.Name, CalcIntegration.CmdTypes.RAWPART, False) Then
EgtOutLog("Fallita esecuzione ExecBeam. ERRORE") EgtOutLog("Fallita esecuzione ExecBeam. ERRORE")
End If End If
End If End If
@@ -2699,7 +2742,6 @@ Public Class BTLPartVM
CalcGlobalUpdate(True) CalcGlobalUpdate(True)
' imposto path disegno da mostrare in BottomPanel ' imposto path disegno da mostrare in BottomPanel
Dim SelPBTLParam As BTLParamVM = Map.refProjectVM.BTLStructureVM.SelBTLPart.SelBTLFeatureVM.SelPBTLParam Dim SelPBTLParam As BTLParamVM = Map.refProjectVM.BTLStructureVM.SelBTLPart.SelBTLFeatureVM.SelPBTLParam
If Not IsNothing(Map.refProjectVM) AndAlso Not IsNothing(SelPBTLParam) Then Map.refPParameterListVM.SetCurrDraw(SelPBTLParam.sDrawPath)
Case NameOf(sender.bDO), NameOf(sender.sPriority) Case NameOf(sender.bDO), NameOf(sender.sPriority)
NotifyPropertyChanged(NameOf(bDOALL)) NotifyPropertyChanged(NameOf(bDOALL))
' setto pezzo da ricalcolare ' setto pezzo da ricalcolare
@@ -2719,6 +2761,6 @@ Public Class BTLPartVM
End Select End Select
End Sub End Sub
#End Region ' EVENTS #End Region
End Class End Class
@@ -0,0 +1,3 @@
Friend Class BTLRawPartVM
End Class
File diff suppressed because it is too large Load Diff
@@ -0,0 +1,155 @@
<EgtWPFLib5:EgtCustomWindow x:Class="BeamMachiningsWindowV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
xmlns:EgtBEAMWALLCORE="clr-namespace:EgtBEAMWALL.Core;assembly=EgtBEAMWALL.Core"
Title="{Binding Title}"
Style="{DynamicResource {x:Type EgtWPFLib5:EgtCustomWindow}}"
WindowStyle="None" ResizeMode="NoResize"
Width="500" Height="450"
IsResizable="False"
IsMinimizable="False" WindowStartupLocation="CenterOwner" ShowInTaskbar="False"
CloseCommand="{Binding Close_Command,Mode=OneWay,UpdateSourceTrigger=PropertyChanged}">
<Grid Margin="5,5,5,0">
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="1*"/>
<RowDefinition Height="Auto"/>
</Grid.RowDefinitions>
<TabControl ItemsSource="{Binding MachiningList}"
SelectedItem="{Binding SelMachining}"
IsSynchronizedWithCurrentItem="True"
Margin="5,0,5,0"
Style="{StaticResource TabControl_OnlyHeaders}"/>
<EgtBEAMWALLCORE:EgtDataGrid Grid.Row="1"
ItemsSource="{Binding TableRowList}"
SelectedIndex="{Binding SelRowIndex}"
AutoGenerateColumns="False"
CanUserResizeRows="False"
SelectionMode="Single"
ScrollViewer.CanContentScroll="True"
ScrollViewer.VerticalScrollBarVisibility="Auto"
ScrollViewer.HorizontalScrollBarVisibility="Auto"
Margin="0,0,0,5"
BindingColumns="{Binding BeamMachiningsColumns}">
<DataGrid.RowStyle>
<Style TargetType="DataGridRow">
<Setter Property="Height" Value="25"/>
<Setter Property="VerticalContentAlignment" Value="Center"/>
</Style>
</DataGrid.RowStyle>
<DataGrid.Resources>
<Style x:Key="DataGridCheckBoxColumn_Style"
TargetType="{x:Type DataGridCell}">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type DataGridCell}">
<Grid Background="{TemplateBinding Background}">
<ContentPresenter VerticalAlignment="Center" />
</Grid>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<!--Colonna On-->
<DataGridCheckBoxColumn x:Key="colON" Binding="{Binding OnPar, UpdateSourceTrigger=PropertyChanged}"
CellStyle="{StaticResource DataGridCheckBoxColumn_Style}">
<DataGridCheckBoxColumn.Header>
<TextBlock Text="{Binding Path=DataContext.OnHdr,RelativeSource={RelativeSource AncestorType={x:Type EgtWPFLib5:EgtCustomWindow}}}"/>
</DataGridCheckBoxColumn.Header>
</DataGridCheckBoxColumn>
<!--Colonna Name-->
<DataGridTemplateColumn x:Key="colNAME">
<DataGridTemplateColumn.Header>
<TextBlock Text="{Binding Path=DataContext.NameHdr,RelativeSource={RelativeSource AncestorType={x:Type EgtWPFLib5:EgtCustomWindow}}}"/>
</DataGridTemplateColumn.Header>
<DataGridTemplateColumn.CellEditingTemplate>
<DataTemplate>
<ComboBox IsEditable="False"
SelectedItem="{Binding Name,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
ItemsSource="{Binding Path=NamesList, Mode=OneWay, UpdateSourceTrigger=PropertyChanged}"/>
</DataTemplate>
</DataGridTemplateColumn.CellEditingTemplate>
<DataGridTemplateColumn.CellTemplate>
<DataTemplate>
<TextBlock Text="{Binding Path=Name,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
VerticalAlignment="Center"
Margin="5,0,0,0"/>
</DataTemplate>
</DataGridTemplateColumn.CellTemplate>
</DataGridTemplateColumn>
<!--Colonna Style-->
<DataGridTemplateColumn x:Key="colTYPE">
<DataGridTemplateColumn.Header>
<TextBlock Text="{Binding Path=DataContext.TypeHdr,RelativeSource={RelativeSource AncestorType={x:Type EgtWPFLib5:EgtCustomWindow}}}"/>
</DataGridTemplateColumn.Header>
<DataGridTemplateColumn.CellEditingTemplate>
<DataTemplate>
<ComboBox IsEditable="False"
SelectedItem="{Binding Type,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
ItemsSource="{Binding Path=TypeList, Mode=OneWay, UpdateSourceTrigger=PropertyChanged}"/>
</DataTemplate>
</DataGridTemplateColumn.CellEditingTemplate>
<DataGridTemplateColumn.CellTemplate>
<DataTemplate>
<TextBlock Text="{Binding Path=Type,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
VerticalAlignment="Center"
Margin="5,0,0,0"/>
</DataTemplate>
</DataGridTemplateColumn.CellTemplate>
</DataGridTemplateColumn>
</DataGrid.Resources>
</EgtBEAMWALLCORE:EgtDataGrid>
<Grid Grid.Row="2"
Margin="0,0,0,5"
HorizontalAlignment="Center">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<Button Content="/\"
Command="{Binding MoveRowUp_Command}"
Grid.Column="0"
Margin="0,0,2.5,0"
Style="{StaticResource EgtWPFLib5_InputButton}"/>
<Button Content="\/"
Command="{Binding MoveRowDown_Command}"
Grid.Column="1"
Margin="2.5,0,2.5,0"
Style="{StaticResource EgtWPFLib5_InputButton}"/>
<Button Content="{Binding AddRowMsg}"
Command="{Binding AddRow_Command}"
Grid.Column="2"
Margin="2.5,0,2.5,0"
Style="{StaticResource EgtWPFLib5_InputButton}"/>
<Button Content="{Binding DeleteRowMsg}"
Command="{Binding DeleteRow_Command}"
Grid.Column="3"
Margin="2.5,0,2.5,0"
Style="{StaticResource EgtWPFLib5_InputButton}"/>
<Button Content="{Binding SaveMsg}"
Command="{Binding Save_Command}"
Grid.Column="4"
Margin="2.5,0,0,0"
Style="{StaticResource EgtWPFLib5_InputButton}"/>
</Grid>
</Grid>
</EgtWPFLib5:EgtCustomWindow>
@@ -0,0 +1,20 @@
Imports EgtBEAMWALL.Core
Public Class BeamMachiningsWindowV
Private WithEvents m_BeamMachiningsWindowVM As MyBeamMachiningsWindowVM
Sub New(Owner As Window, BeamMachiningsWindowVM As MyBeamMachiningsWindowVM)
MyBase.New(Owner)
' This call is required by the designer.
InitializeComponent()
Me.DataContext = BeamMachiningsWindowVM
' Assegno al riferimento locale al VM il VM preso dal DataContext
m_BeamMachiningsWindowVM = BeamMachiningsWindowVM
End Sub
Private Sub CloseWindow(bDialogResult As Boolean) Handles m_BeamMachiningsWindowVM.m_CloseWindow
Me.DialogResult = bDialogResult
End Sub
End Class
@@ -0,0 +1,36 @@
Imports System.Collections.ObjectModel
Imports EgtBEAMWALL.Core
Imports EgtWPFLib5
Public Class MyBeamMachiningsWindowVM
Inherits BeamMachiningsWindowVM
#Region "FIELDS & PROPERTIES"
Private m_BeamMachiningsColumns As New ObservableCollection(Of EgtDataGridColumn)
Public Property BeamMachiningsColumns As ObservableCollection(Of EgtDataGridColumn)
Get
Return m_BeamMachiningsColumns
End Get
Set(value As ObservableCollection(Of EgtDataGridColumn))
m_BeamMachiningsColumns = value
End Set
End Property
#End Region ' FIELDS & PROPERTIES
#Region "CONSTRUCTOR"
Sub New(sTitle As String, sBaseDir As String, sMachTypePath As String, sTabTemplPath As String, Optional bIsBeam As Boolean = True)
MyBase.New(sTitle, sBaseDir, sMachTypePath, sTabTemplPath, bIsBeam)
' carico le colonne della datagrid
GetPrivateProfileColumns(S_BEAMMACHININGS, BeamMachiningsColumns)
' aggiorno la visibilità delle colonne
For Each col In BeamMachiningsColumns
col.ColumnVisibility = If(col.Visible, Visibility.Visible, Visibility.Collapsed)
Next
End Sub
#End Region ' CONSTRUCTOR
End Class
@@ -0,0 +1,91 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace EgtBEAMWALL.EgtBEAMWALL.ViewerOptimizer.Behavior
{
public class DataGridColumnsBehavior
{
public static readonly DependencyProperty BindableColumnsProperty = DependencyProperty.RegisterAttached("BindableColumns", typeof(ObservableCollection<DataGridColumn>), typeof(DataGridColumnsBehavior), new UIPropertyMetadata(null, BindableColumnsPropertyChanged));
/// <summary>Collection to store collection change handlers - to be able to unsubscribe later.</summary>
private static readonly Dictionary<DataGrid, NotifyCollectionChangedEventHandler> _handlers;
static DataGridColumnsBehavior()
{
_handlers = new Dictionary<DataGrid, NotifyCollectionChangedEventHandler>();
}
private static void BindableColumnsPropertyChanged(DependencyObject source, DependencyPropertyChangedEventArgs e)
{
if (!(source is DataGrid dataGrid)) return;
if (e.OldValue is ObservableCollection<DataGridColumn> oldColumns)
{
// Remove all columns.
dataGrid.Columns.Clear();
// Unsubscribe from old collection.
if (_handlers.TryGetValue(dataGrid, out var h))
{
oldColumns.CollectionChanged -= h;
_handlers.Remove(dataGrid);
}
}
var newColumns = e.NewValue as ObservableCollection<DataGridColumn>;
dataGrid.Columns.Clear();
if (newColumns != null)
{
// Add columns from this source.
foreach (var column in newColumns)
if (column != null)
{
var dg = (DataGrid)column.GetType().GetProperty("DataGridOwner", BindingFlags.Instance | BindingFlags.NonPublic)?.GetValue(column, null);
dg?.Columns.Clear();
dataGrid.Columns.Add(column);
}
// Subscribe to future changes.
NotifyCollectionChangedEventHandler h = (_, ne) => OnCollectionChanged(ne, dataGrid);
_handlers[dataGrid] = h;
newColumns.CollectionChanged += h;
}
}
private static void OnCollectionChanged(NotifyCollectionChangedEventArgs ne, DataGrid dataGrid)
{
switch (ne.Action)
{
case NotifyCollectionChangedAction.Reset:
dataGrid.Columns.Clear();
if (ne.NewItems != null && ne.NewItems.Count > 0)
foreach (DataGridColumn column in ne.NewItems)
dataGrid.Columns.Add(column);
break;
case NotifyCollectionChangedAction.Add:
foreach (DataGridColumn column in ne.NewItems)
dataGrid.Columns.Add(column);
break;
case NotifyCollectionChangedAction.Move:
dataGrid.Columns.Move(ne.OldStartingIndex, ne.NewStartingIndex);
break;
case NotifyCollectionChangedAction.Remove:
foreach (DataGridColumn column in ne.OldItems)
dataGrid.Columns.Remove(column);
break;
case NotifyCollectionChangedAction.Replace:
dataGrid.Columns[ne.NewStartingIndex] = ne.NewItems[0] as DataGridColumn;
break;
}
}
public static void SetBindableColumns(DependencyObject element, ObservableCollection<DataGridColumn> value)
{
element.SetValue(BindableColumnsProperty, value);
}
public static ObservableCollection<DataGridColumn> GetBindableColumns(DependencyObject element)
{
return (ObservableCollection<DataGridColumn>)element.GetValue(BindableColumnsProperty);
}
}
}
@@ -0,0 +1,94 @@
Imports System.Collections.ObjectModel
Imports System.Collections.Specialized
Imports System.Reflection
Public Class DataGridColumnsBehavior
Public Shared ReadOnly BindableColumnsProperty As DependencyProperty = DependencyProperty.RegisterAttached("BindableColumns", GetType(ObservableCollection(Of DataGridColumn)), GetType(DataGridColumnsBehavior), New UIPropertyMetadata(Nothing, AddressOf BindableColumnsPropertyChanged))
Private Shared ReadOnly _handlers As Dictionary(Of DataGrid, NotifyCollectionChangedEventHandler)
Shared Sub New()
_handlers = New Dictionary(Of DataGrid, NotifyCollectionChangedEventHandler)()
End Sub
Private Shared Sub BindableColumnsPropertyChanged(ByVal source As DependencyObject, ByVal e As DependencyPropertyChangedEventArgs)
Dim dataGrid As DataGrid = Nothing
If Not (source Is dataGrid) Then Return
Dim h = Nothing, oldColumns As ObservableCollection(Of DataGridColumn) = Nothing
If e.OldValue Is oldColumns Then
dataGrid.Columns.Clear()
If _handlers.TryGetValue(dataGrid, h) Then
RemoveHandler oldColumns.CollectionChanged, h
_handlers.Remove(dataGrid)
End If
End If
Dim newColumns = TryCast(e.NewValue, ObservableCollection(Of DataGridColumn))
dataGrid.Columns.Clear()
If newColumns IsNot Nothing Then
For Each column In newColumns
If column IsNot Nothing Then
Dim dg = CType(column.[GetType]().GetProperty("DataGridOwner", BindingFlags.Instance Or BindingFlags.NonPublic)?.GetValue(column, Nothing), DataGrid)
dg?.Columns.Clear()
dataGrid.Columns.Add(column)
End If
Next
Dim h As NotifyCollectionChangedEventHandler = Function(__, ne) OnCollectionChanged(ne, dataGrid)
_handlers(dataGrid) = h
AddHandler newColumns.CollectionChanged, h
End If
End Sub
Private Shared Sub OnCollectionChanged(ByVal ne As NotifyCollectionChangedEventArgs, ByVal dataGrid As DataGrid)
Select Case ne.Action
Case NotifyCollectionChangedAction.Reset
dataGrid.Columns.Clear()
If ne.NewItems IsNot Nothing AndAlso ne.NewItems.Count > 0 Then
For Each column As DataGridColumn In ne.NewItems
dataGrid.Columns.Add(column)
Next
End If
Case NotifyCollectionChangedAction.Add
For Each column As DataGridColumn In ne.NewItems
dataGrid.Columns.Add(column)
Next
Case NotifyCollectionChangedAction.Move
dataGrid.Columns.Move(ne.OldStartingIndex, ne.NewStartingIndex)
Case NotifyCollectionChangedAction.Remove
For Each column As DataGridColumn In ne.OldItems
dataGrid.Columns.Remove(column)
Next
Case NotifyCollectionChangedAction.Replace
dataGrid.Columns(ne.NewStartingIndex) = TryCast(ne.NewItems(0), DataGridColumn)
End Select
End Sub
Public Shared Sub SetBindableColumns(ByVal element As DependencyObject, ByVal value As ObservableCollection(Of DataGridColumn))
element.SetValue(BindableColumnsProperty, value)
End Sub
Public Shared Function GetBindableColumns(ByVal element As DependencyObject) As ObservableCollection(Of DataGridColumn)
Return CType(element.GetValue(BindableColumnsProperty), ObservableCollection(Of DataGridColumn))
End Function
Private Class CSharpImpl
<Obsolete("Please refactor calling code to use normal Visual Basic assignment")>
Shared Function __Assign(Of T)(ByRef target As T, value As T) As T
target = value
Return value
End Function
End Class
End Class
@@ -52,8 +52,6 @@ Public Class BlockedWndVM
#End Region ' FIELDS & PROPERTIES #End Region ' FIELDS & PROPERTIES
#Region "CONSTRUCTOR"
Sub New() Sub New()
If DbControllers.bNetwork Then If DbControllers.bNetwork Then
m_Buttons_Visibility = Visibility.Visible m_Buttons_Visibility = Visibility.Visible
@@ -71,10 +69,6 @@ Public Class BlockedWndVM
m_Waiting_Timer.Start() m_Waiting_Timer.Start()
End Sub End Sub
#End Region ' CONSTRUCTOR
#Region "METHODS"
Private Sub WaitingTimer_Tick() Private Sub WaitingTimer_Tick()
' se notifica di chiusura da supervisor, esco ' se notifica di chiusura da supervisor, esco
If Not SupervisorCommThread.bViewerOptimizerBlocked And Map.refMainWindowVM.m_ManagingSupervisorStop Then If Not SupervisorCommThread.bViewerOptimizerBlocked And Map.refMainWindowVM.m_ManagingSupervisorStop Then
@@ -108,8 +102,6 @@ Public Class BlockedWndVM
End If End If
End Sub End Sub
#End Region ' METHODS
#Region "COMMANDS" #Region "COMMANDS"
#Region "Save" #Region "Save"
@@ -132,7 +124,7 @@ Public Class BlockedWndVM
Public Sub Save() Public Sub Save()
' salvo progetto ' salvo progetto
'Map.refProdManagerVM.Save() 'Map.refProdManagerVM.Save()
Map.refProdManagerVM.Save() Map.refOnlyProdManagerVM.Save()
' mando messaggio di blocco avvenuto ' mando messaggio di blocco avvenuto
DbControllers.m_StatusMapController.UpdateAction("", ProjectManagerVM.CurrProd.nProdId, ProjectManagerVM.CurrProd.nProdId, StatusMapItemType.Comm, StatusMapOpType.ViewOptimStoped, "") DbControllers.m_StatusMapController.UpdateAction("", ProjectManagerVM.CurrProd.nProdId, ProjectManagerVM.CurrProd.nProdId, StatusMapItemType.Comm, StatusMapOpType.ViewOptimStoped, "")
End Sub End Sub
@@ -0,0 +1,106 @@
<Grid x:Class="BottomPanelV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
xmlns:EgtBEAMWALL="clr-namespace:EgtBEAMWALL.Optimizer"
Height="350"
Visibility="{Binding BottomPanel_Visibility}">
<TabControl SelectedIndex="{Binding SelPartFeatureTab}"
TabStripPlacement="Right"
Margin="5">
<TabControl.ItemContainerStyle>
<Style TargetType="{x:Type TabItem}">
<Setter Property="Visibility" Value="Collapsed"/>
</Style>
</TabControl.ItemContainerStyle>
<TabItem Header="STRUCTURE">
<TabItem.Content>
<EgtWPFLib5:EgtScrollViewer Focusable="False">
<EgtBEAMWALL:BTLDataV DataContext="{StaticResource BTLDataWndVM}"
Tag="{Binding Tag, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BottomPanelV}}}"
Margin="5"/>
</EgtWPFLib5:EgtScrollViewer>
</TabItem.Content>
</TabItem>
<TabItem Header="PART">
<TabItem.Content>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="1*"/>
<RowDefinition Height="Auto"/>
</Grid.RowDefinitions>
<EgtWPFLib5:EgtScrollViewer Focusable="False">
<EgtBEAMWALL:PartParametersV DataContext="{StaticResource PartParametersVM}"
Tag="{Binding Tag.SelBTLPart, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BottomPanelV}}}"
Margin="5"/>
</EgtWPFLib5:EgtScrollViewer>
<TextBlock Grid.Row="1"
Text="{Binding Tag.SelBTLPart.sCALC_MSG, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BottomPanelV}}}"
Foreground="{Binding Tag.SelBTLPart.CALC_ERR_Foreground, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BottomPanelV}}}"
Margin="5,0,5,0"
Visibility="{Binding Tag.SelBTLPart.CALC_MSG_Visibility, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BottomPanelV}}}"/>
</Grid>
</TabItem.Content>
</TabItem>
<TabItem Header="FEATURE">
<TabItem.Content>
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="300"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="1*"/>
<RowDefinition Height="Auto"/>
</Grid.RowDefinitions>
<Grid.Resources>
<Style TargetType="TextBlock">
<Style.Triggers>
<Trigger Property="Text" Value="">
<Setter Property="Visibility" Value="Collapsed"/>
</Trigger>
</Style.Triggers>
</Style>
</Grid.Resources>
<EgtBEAMWALL:FeatureManagerV DataContext="{StaticResource FeatureManagerVM}"
Tag="{Binding Tag.SelBTLPart.SelBTLFeatureVM, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BottomPanelV}}}"/>
<TabControl Grid.Row="1"
TabStripPlacement="Left"
Margin="5,5,2.5,5">
<TabItem Header="P">
<TabItem.Content>
<EgtBEAMWALL:PParameterListV DataContext="{StaticResource PParameterListVM}"
Tag="{Binding Tag.SelBTLPart.SelBTLFeatureVM, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BottomPanelV}}}"
Margin="5"/>
</TabItem.Content>
</TabItem>
<TabItem Header="Q">
<TabItem.Content>
<EgtBEAMWALL:QParameterListV DataContext="{StaticResource QParameterListVM}"
Tag="{Binding Tag.SelBTLPart.SelBTLFeatureVM, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BottomPanelV}}}"
Margin="5"/>
</TabItem.Content>
</TabItem>
</TabControl>
<Image Grid.Column="1"
Grid.Row="1"
Source="{Binding sCurrDraw}"
Margin="5"/>
<TextBlock Grid.Row="2" Grid.ColumnSpan="2"
Text="{Binding Tag.SelBTLPart.SelBTLFeatureVM.sCALC_MSG, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BottomPanelV}}}"
Foreground="{Binding Tag.SelBTLPart.SelBTLFeatureVM.Calc_Background, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BottomPanelV}}}"
Margin="5,0,5,0"/>
</Grid>
</TabItem.Content>
</TabItem>
<TabItem Header="STATISTICS">
<TabItem.Content>
<EgtBEAMWALL:StatisticsV DataContext="{StaticResource StatisticsVM}"
Tag="{Binding Tag, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BottomPanelV}}}"
Margin="5"/>
</TabItem.Content>
</TabItem>
</TabControl>
</Grid>
@@ -0,0 +1,3 @@
Public Class BottomPanelV
End Class
@@ -0,0 +1,51 @@
Imports EgtWPFLib5
Public Class BottomPanelVM
Inherits VMBase
Friend Enum PartFeatureTab As Integer
NULL = -1
STRUCTURE_ = 0
PART = 1
FEATURE = 2
STATISTICS = 3
End Enum
Private m_SelPartFeatureTab As PartFeatureTab
Public Property SelPartFeatureTab As Integer
Get
Return m_SelPartFeatureTab
End Get
Set(value As Integer)
m_SelPartFeatureTab = value
End Set
End Property
Friend Sub SetSelPartFeatureTab(SelPartFeatureTab As PartFeatureTab)
If m_SelPartFeatureTab = PartFeatureTab.STATISTICS Then
Map.refInstrumentPanelVM.SetStatisticsIsChecked(False)
End If
m_SelPartFeatureTab = SelPartFeatureTab
NotifyPropertyChanged(NameOf(SelPartFeatureTab))
End Sub
Private m_sCurrDraw As String
Public ReadOnly Property sCurrDraw As String
Get
Return m_sCurrDraw
End Get
End Property
Friend Sub SetCurrDraw(sCurrDraw As String)
m_sCurrDraw = sCurrDraw
NotifyPropertyChanged(NameOf(sCurrDraw))
End Sub
#Region "CONSTRUCTOR"
Sub New()
' Creo riferimento a questa classe in EgtCAM5Map
Map.SetRefBottomPanelVM(Me)
End Sub
#End Region ' CONSTRUCTOR
End Class
+430 -179
View File
@@ -1,18 +1,13 @@
Imports System.Collections.ObjectModel Imports System.IO
Imports System.IO
Imports System.Threading
Imports System.Windows.Threading
Imports EgtBEAMWALL.Core
Imports EgtUILib Imports EgtUILib
Imports EgtWPFLib5 Imports EgtWPFLib5
Imports EgwMultiEngineManager.Data Imports EgtBEAMWALL.Core
Imports EgwMultiEngineManager.Data.Constants Imports System.Collections.ObjectModel
Imports System.Windows.Threading
Public Class CALCPanelVM Public Class CALCPanelVM
Inherits VMBase Inherits VMBase
#Region "FIELDS & PROPERTIES"
Public Enum ProduceType As Integer Public Enum ProduceType As Integer
NULL = 0 NULL = 0
PRODUCE = 1 PRODUCE = 1
@@ -40,6 +35,16 @@ Public Class CALCPanelVM
End Set End Set
End Property End Property
'Private m_CALCPanel_IsEnabled As Boolean = True
'Public Property CALCPanel_IsEnabled As Boolean
' Get
' Return m_CALCPanel_IsEnabled
' End Get
' Set(value As Boolean)
' m_CALCPanel_IsEnabled = value
' End Set
'End Property
'Private m_VerifyAll_IsEnabled As Boolean = True 'Private m_VerifyAll_IsEnabled As Boolean = True
'Public Property VerifyAll_IsEnabled As Boolean 'Public Property VerifyAll_IsEnabled As Boolean
' Get ' Get
@@ -105,12 +110,80 @@ Public Class CALCPanelVM
End Set End Set
End Property End Property
'Public ReadOnly Property ViewPage_Visibility As Visibility
' Get
' Return If(Map.refMainMenuVM.SelPage = Pages.VIEW, Visibility.Visible, Visibility.Collapsed)
' End Get
'End Property
'Public ReadOnly Property Edit_Visibility As Visibility
' Get
' Return If(Map.refMainMenuVM.SelPage = Pages.VIEW AndAlso GetMainPrivateProfileInt(S_GENERAL, K_ENABLEEDIT, 0) = 1, Visibility.Visible, Visibility.Collapsed)
' End Get
'End Property
'Public ReadOnly Property Verify_IsEnabled As Boolean
' Get
' Return If(Map.refMainMenuVM.SelPage = Pages.VIEW,
' m_CALCPanel_IsEnabled AndAlso Not Map.refShowBeamPanelVM.bShowAll AndAlso
' Not IsNothing(Map.refProjectVM.BTLStructureVM) AndAlso Not Map.refProjectVM.BTLStructureVM.SelBTLPartsCnt > 1,
' m_CALCPanel_IsEnabled)
' End Get
'End Property
'Public ReadOnly Property Simulate_IsEnabled As Boolean
' Get
' Return If(Map.refMainMenuVM.SelPage = Pages.VIEW,
' m_CALCPanel_IsEnabled And Not Map.refShowBeamPanelVM.bShowAll AndAlso
' Not IsNothing(Map.refProjectVM.BTLStructureVM) AndAlso Not Map.refProjectVM.BTLStructureVM.SelBTLPartsCnt > 1,
' m_CALCPanel_IsEnabled)
' End Get
'End Property
'Public ReadOnly Property Edit_IsEnabled As Boolean
' Get
' Return If(Map.refMainMenuVM.SelPage = Pages.VIEW,
' m_CALCPanel_IsEnabled And Not Map.refShowBeamPanelVM.bShowAll AndAlso
' Not IsNothing(Map.refProjectVM.BTLStructureVM) AndAlso Not Map.refProjectVM.BTLStructureVM.SelBTLPartsCnt > 1,
' True)
' End Get
'End Property
' Definizione comandi ' Definizione comandi
'Private m_cmdVerify As ICommand
'Private m_cmdVerifyAll As ICommand
'Private m_cmdResetCalc As ICommand
'Private m_cmdSimulate As ICommand
'Private m_cmdEdit As ICommand
Private m_cmdChooseMachine As ICommand Private m_cmdChooseMachine As ICommand
Private m_cmdOk As ICommand Private m_cmdOk As ICommand
#Region "Messages" #Region "Messages"
'Public ReadOnly Property Verify_ToolTip As String
' Get
' Return EgtMsg(61901)
' End Get
'End Property
'Public ReadOnly Property VerifyAll_ToolTip As String
' Get
' Return EgtMsg(61928)
' End Get
'End Property
'Public ReadOnly Property Simulate_ToolTip As String
' Get
' Return EgtMsg(61902)
' End Get
'End Property
'Public ReadOnly Property Edit_ToolTip As String
' Get
' Return EgtMsg(61939)
' End Get
'End Property
Public ReadOnly Property ResetCalc_ToolTip As String Public ReadOnly Property ResetCalc_ToolTip As String
Get Get
Return EgtMsg(61940) Return EgtMsg(61940)
@@ -125,8 +198,6 @@ Public Class CALCPanelVM
#End Region ' Messages #End Region ' Messages
#End Region ' FIELDS & PROPERTIES
#Region "CONSTRUCTORS" #Region "CONSTRUCTORS"
Sub New() Sub New()
@@ -144,6 +215,28 @@ Public Class CALCPanelVM
#Region "METHODS" #Region "METHODS"
Friend Sub SetCalcPanelIsEnabled(bIsEnabled As Boolean)
'm_CALCPanel_IsEnabled = bIsEnabled
'm_VerifyAll_IsEnabled = bIsEnabled
'NotifyPropertyChanged(NameOf(CALCPanel_IsEnabled))
'NotifyPropertyChanged(NameOf(VerifyAll_IsEnabled))
'NotifyPropertyChanged(NameOf(Verify_IsEnabled))
'NotifyPropertyChanged(NameOf(Simulate_IsEnabled))
'NotifyPropertyChanged(NameOf(Edit_IsEnabled))
End Sub
Friend Sub SetIsEnabledForSelPart()
'NotifyPropertyChanged(NameOf(Verify_IsEnabled))
'm_VerifyAll_IsEnabled = False
'NotifyPropertyChanged(NameOf(VerifyAll_IsEnabled))
'NotifyPropertyChanged(NameOf(Simulate_IsEnabled))
'NotifyPropertyChanged(NameOf(Edit_IsEnabled))
End Sub
Friend Sub SetVerifyIsEnabled(bIsEnabled As Boolean)
'm_CALCPanel_IsEnabled = bIsEnabled
'NotifyPropertyChanged(NameOf(CALCPanel_IsEnabled))
'NotifyPropertyChanged(NameOf(Verify_IsEnabled))
End Sub
Private Sub Calc_ProcessResult(sender As Object, e As CalcResultEventArgs) Private Sub Calc_ProcessResult(sender As Object, e As CalcResultEventArgs)
ProcessResults(e.m_Result) ProcessResults(e.m_Result)
End Sub End Sub
@@ -158,7 +251,12 @@ Public Class CALCPanelVM
End If End If
' se verify o verifyall, salvo il progetto per conservarne gli stati calcolati ' se verify o verifyall, salvo il progetto per conservarne gli stati calcolati
If e.CmdType = CmdTypes.CHECKGEN Then If e.CmdType = CmdTypes.CHECKGEN Then
Map.refProdManagerVM.Save() 'If Map.refMainMenuVM.SelPage = Pages.VIEW Then
' Map.refProjManagerVM.Save()
'ElseIf Map.refMainMenuVM.SelPage = Pages.MACHINING Then
' Map.refProdManagerVM.Save()
'End If
Map.refOnlyProdManagerVM.Save()
End If End If
' se modalita' assemblato attiva ' se modalita' assemblato attiva
If Map.refMainMenuVM.SelPage = Pages.VIEW AndAlso Map.refShowBeamPanelVM.ShowBuilding_IsChecked AndAlso Map.refShowBeamPanelVM.bShowAll Then If Map.refMainMenuVM.SelPage = Pages.VIEW AndAlso Map.refShowBeamPanelVM.ShowBuilding_IsChecked AndAlso Map.refShowBeamPanelVM.bShowAll Then
@@ -206,7 +304,7 @@ Public Class CALCPanelVM
ProcessResults(Bar.sBarPath, Bar.nProgramPage, Bar.nBarId) ProcessResults(Bar.sBarPath, Bar.nProgramPage, Bar.nBarId)
End Sub End Sub
Friend Shared Sub ProcessResults(BtlPath As String, nProgramPage As ProjectType, nBarId As Integer) Private Shared Sub ProcessResults(BtlPath As String, nProgramPage As ProjectType, nBarId As Integer)
Dim ResPath As String = Path.ChangeExtension(BtlPath, ".txt") Dim ResPath As String = Path.ChangeExtension(BtlPath, ".txt")
Dim bErrors As Boolean = False Dim bErrors As Boolean = False
@@ -368,7 +466,7 @@ Public Class CALCPanelVM
CurrPartVM.CalcPartUpdate(Line.nERR, Line.dROT, Line.sMSG) CurrPartVM.CalcPartUpdate(Line.nERR, Line.dROT, Line.sMSG)
End If End If
Case ProcessResult.ProcessResultTypes.TASKID Case ProcessResult.ProcessResultTypes.TASKID
CurrBTLFeatureVM.CalcFeatureUpdate(nProgramPage, Line.nERR, Line.dROT, Line.sMSG) CurrBTLFeatureVM.CalcFeatureUpdate(Line.nERR, Line.dROT, Line.sMSG)
Case ProcessResult.ProcessResultTypes.FALL Case ProcessResult.ProcessResultTypes.FALL
If nProgramPage = ProjectType.PROJ Then If nProgramPage = ProjectType.PROJ Then
CurrBTLPartVM.CalcFallUpdate(Line.nFALL) CurrBTLPartVM.CalcFallUpdate(Line.nFALL)
@@ -491,10 +589,10 @@ Public Class CALCPanelVM
Dim nMachType As MachineType = DirectCast(Machine, MyMachine).nType Dim nMachType As MachineType = DirectCast(Machine, MyMachine).nType
Dim nProjType As BWType Dim nProjType As BWType
Dim sMachineName As String = "" Dim sMachineName As String = ""
nProjType = Map.refProdManagerVM.nProdType nProjType = Map.refOnlyProdManagerVM.nProdType
sMachineName = If(Not IsNothing(ProjectManagerVM.CurrProd), ProjectManagerVM.CurrProd.sMachine, "") sMachineName = If(Not IsNothing(ProjectManagerVM.CurrProd), ProjectManagerVM.CurrProd.sMachine, "")
If nMachType = nProjType OrElse If nMachType = nProjType OrElse
(nMachType = 3 And Not IsNothing(Map.refProdManagerVM) AndAlso Not IsNothing(ProjectManagerVM.CurrProd)) Then (nMachType = 3 And Not IsNothing(Map.refOnlyProdManagerVM) AndAlso Not IsNothing(ProjectManagerVM.CurrProd)) Then
MachineList.Add(Machine) MachineList.Add(Machine)
' Se il nome Macchina coincide setto la macchina selezionata con la macchina associata al progetto ' Se il nome Macchina coincide setto la macchina selezionata con la macchina associata al progetto
If Machine.Name = sMachineName Then If Machine.Name = sMachineName Then
@@ -536,123 +634,54 @@ Public Class CALCPanelVM
'NotifyPropertyChanged(NameOf(Edit_IsEnabled)) 'NotifyPropertyChanged(NameOf(Edit_IsEnabled))
End Sub End Sub
Friend Sub Verify(ProgramPage As ProjectType) #End Region ' METHODS
If (IsNothing(ProjectManagerVM.CurrProd) OrElse IsNothing(Map.refProjectVM.BTLStructureVM) OrElse IsNothing(Map.refProjectVM.MachGroupPanelVM)) Then Return
Dim ProjType As BWType = ProjectManagerVM.CurrProd.nType #Region "COMMANDS"
'#Region "Verify"
' ''' <summary>
' ''' Returns a command that do Open.
' ''' </summary>
' Public ReadOnly Property Verify_Command As ICommand
' Get
' If m_cmdVerify Is Nothing Then
' m_cmdVerify = New Command(AddressOf Verify)
' End If
' Return m_cmdVerify
' End Get
' End Property
''' <summary>
''' Execute the Open. This method is invoked by the OpenCommand.
''' </summary>
Friend Sub Verify()
If (Map.refMainMenuVM.SelPage = Pages.VIEW AndAlso (IsNothing(ProjectManagerVM.CurrProj) OrElse IsNothing(Map.refProjectVM.BTLStructureVM))) OrElse
(Map.refMainMenuVM.SelPage = Pages.MACHINING AndAlso (IsNothing(ProjectManagerVM.CurrProd) OrElse IsNothing(Map.refProjectVM.MachGroupPanelVM))) OrElse
(Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE AndAlso (IsNothing(ProjectManagerVM.CurrProd) OrElse IsNothing(Map.refProjectVM.BTLStructureVM) OrElse IsNothing(Map.refProjectVM.MachGroupPanelVM))) Then Return
Dim ProjType As BWType
Dim BarList() As EgtBEAMWALL.Core.Bar = Nothing Dim BarList() As EgtBEAMWALL.Core.Bar = Nothing
If GetMainPrivateProfileInt(S_GENERAL, "UseCam5", 0) = 1 Then If Map.refMainMenuVM.SelPage = Pages.VIEW Then
ProjType = ProjectManagerVM.CurrProj.nType
If Not CreateBarToVerify(Pages.VIEW, ProjType, BarList) Then Return
' lancio calcolo
EgtBEAMWALL.Core.CalcIntegration.Run(BarList, ProjectManagerVM.CurrProj.sProjDirPath, AddressOf ManageCalc)
ElseIf Map.refMainMenuVM.SelPage = Pages.MACHINING Then
ProjType = ProjectManagerVM.CurrProd.nType
If Not CreateBarToVerify(Pages.MACHINING, ProjType, BarList) Then Return
' lancio calcolo
EgtBEAMWALL.Core.CalcIntegration.Run(BarList, ProjectManagerVM.CurrProd.sProdDirPath, AddressOf ManageCalc)
ElseIf Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE Then
ProjType = ProjectManagerVM.CurrProd.nType
If Map.refProjectVM.LastSelGridType = ProjectVM.GridSelTypes.PART Then If Map.refProjectVM.LastSelGridType = ProjectVM.GridSelTypes.PART Then
If Not CreateBarToVerify(Pages.VIEW, ProjType, BarList) Then Return If Not CreateBarToVerify(Pages.VIEW, ProjType, BarList) Then Return
' lancio calcolo ' lancio calcolo
EgtBEAMWALL.Core.CalcIntegration.Run(BarList, ProjectManagerVM.CurrProd.sProdDirPath & "\Projs\" & Map.refProjectVM.BTLStructureVM.SelBTLPart.nPROJ.ToString("0000"), AddressOf ManageCalc) EgtBEAMWALL.Core.CalcIntegration.Run(BarList, Map.refOnlyProdManagerVM.CurrProj.sProjDirPath, AddressOf ManageCalc)
ElseIf Map.refProjectVM.LastSelGridType = ProjectVM.GridSelTypes.MACHGROUP Then ElseIf Map.refProjectVM.LastSelGridType = ProjectVM.GridSelTypes.MACHGROUP Then
If Not CreateBarToVerify(Pages.MACHINING, ProjType, BarList) Then Return If Not CreateBarToVerify(Pages.MACHINING, ProjType, BarList) Then Return
' lancio calcolo ' lancio calcolo
EgtBEAMWALL.Core.CalcIntegration.Run(BarList, ProjectManagerVM.CurrProd.sProdDirPath, AddressOf ManageCalc) EgtBEAMWALL.Core.CalcIntegration.Run(BarList, Map.refOnlyProdManagerVM.CurrProd.sProdDirPath, AddressOf ManageCalc)
End If End If
Else
Dim ExecThread As New Thread(Sub()
VerifyWithEngine(ProgramPage)
End Sub)
ExecThread.Start()
End If
End Sub
Private Sub VerifyProjWithEngine(CurrPart As BTLPartVM)
If Not CurrPart.bDO Then Return
Dim Args As New Dictionary(Of String, String)
Args.Add("BarId", CurrPart.nPartId)
Args.Add("ProgramPage", ProjectType.PROJ)
Dim BarPath As String = ProjectManagerVM.CurrProd.sProdDirPath & "\Projs\" & CurrPart.nPROJ.ToString("0000")
Args.Add("BarPath", BarPath)
Args.Add("ProjType", ProjectManagerVM.CurrProd.nType)
Args.Add("MachineName", ProjectManagerVM.CurrProd.sMachine)
Args.Add("GlobState", CurrPart.nGlobalState)
Dim nCmdType As CalcIntegration.CmdTypes = CmdTypes.GENERATE
Select Case CurrPart.nGlobalState
Case Core.CalcStates.OK, CalcStates.INFO
nCmdType = CalcIntegration.CmdTypes.GENERATE
Case Else
If CurrPart.nGlobalState = CalcStates.NOTCALCULATED OrElse CurrPart.nFeaturesGlobalState > CalcStates.INFO Then
Dim sBTLPartFilePath As String = BarPath & "\" & CurrPart.nPDN.ToString() & ".ori.bwe"
If File.Exists(sBTLPartFilePath) Then File.Delete(sBTLPartFilePath)
End If
nCmdType = CalcIntegration.CmdTypes.CHECKNOSIM
End Select
Args.Add("CmdType", nCmdType)
Dim ExecEnvironment As EXECENVIRONMENTS = EXECENVIRONMENTS.NULL
Select Case ProjectManagerVM.CurrProd.nType
Case BWType.BEAM
ExecEnvironment = EXECENVIRONMENTS.BEAM
Case BWType.WALL
ExecEnvironment = EXECENVIRONMENTS.WALL
End Select
Dim Request As New QuestionDTO(1, ExecEnvironment, Args)
Request.Args("BarPath") = CreateNewProjectFromPart(CurrPart.nPartId, BarPath)
EgtOutLog("Creato progetto " & CurrPart.nPartId)
If Request.ExecEnvironment <> EXECENVIRONMENTS.NULL Then
MyExecProcessManager.ExecProcessManagerList(Request.ExecEnvironment).ArgumentsEnqueue(Request)
End If
End Sub
Private Sub VerifyProdWithEngine(CurrMachGroup As MyMachGroupVM)
' se e' gia' stato assegnato a supervisor, la salto e vado alla prossima barra
If CurrMachGroup.nProduction_State >= ItemState.Assigned Then Return
Dim Args As New Dictionary(Of String, String)
Args.Add("BarId", CurrMachGroup.Id)
Args.Add("ProgramPage", ProjectType.PROD)
Dim BarPath As String = ProjectManagerVM.CurrProd.sProdDirPath
Args.Add("BarPath", BarPath)
Args.Add("ProjType", ProjectManagerVM.CurrProd.nType)
Dim MachineName As String = ""
EgtGetMachGroupMachineName(CurrMachGroup.Id, MachineName)
Args.Add("MachineName", MachineName)
Args.Add("GlobState", CurrMachGroup.nGlobalState)
Dim nCmdType As CalcIntegration.CmdTypes = CmdTypes.GENERATE
Select Case CurrMachGroup.nGlobalState
Case Core.CalcStates.OK, CalcStates.INFO
nCmdType = CalcIntegration.CmdTypes.GENERATE
Case Else
If CurrMachGroup.nGlobalState = CalcStates.NOTCALCULATED OrElse (CurrMachGroup.nPartsGlobalState > CalcStates.INFO) Then
Dim sMachGroupFilePath As String = BarPath & "\" & CurrMachGroup.Name.ToString() & ".ori.bwe"
If File.Exists(sMachGroupFilePath) Then File.Delete(sMachGroupFilePath)
End If
nCmdType = CalcIntegration.CmdTypes.CHECKGEN
End Select
Args.Add("CmdType", nCmdType)
Dim ExecEnvironment As EXECENVIRONMENTS = EXECENVIRONMENTS.NULL
Select Case ProjectManagerVM.CurrProd.nType
Case BWType.BEAM
ExecEnvironment = EXECENVIRONMENTS.BEAM
Case BWType.WALL
ExecEnvironment = EXECENVIRONMENTS.WALL
End Select
Dim Request As New QuestionDTO(1, ExecEnvironment, Args)
Request.Args("BarPath") = CreateNewProjectFromMachGroup(CurrMachGroup.Id, BarPath, CurrMachGroup.nGlobalState)
EgtOutLog("Creato progetto " & CurrMachGroup.Id)
If Request.ExecEnvironment <> EXECENVIRONMENTS.NULL Then
MyExecProcessManager.ExecProcessManagerList(Request.ExecEnvironment).ArgumentsEnqueue(Request)
End If
End Sub
Private Sub VerifyWithEngine(ProgramPage As ProjectType)
Dim ProjType As BWType = ProjectManagerVM.CurrProd.nType
' lancio calcolo
Dim ExecEnvironment As EXECENVIRONMENTS = EXECENVIRONMENTS.NULL
Select Case ProjType
Case BWType.BEAM
ExecEnvironment = EXECENVIRONMENTS.BEAM
Case BWType.WALL
ExecEnvironment = EXECENVIRONMENTS.WALL
End Select
If ProgramPage = ProjectType.PROJ Then
If Not Map.refProjectVM.BTLStructureVM.SelBTLPart.bDO Then Return
VerifyProjWithEngine(Map.refProjectVM.BTLStructureVM.SelBTLPart)
ElseIf ProgramPage = ProjectType.PROD Then
' se e' gia' stato assegnato a supervisor, la salto e vado alla prossima barra
If Map.refMachGroupPanelVM.SelectedMachGroup.nProduction_State >= ItemState.Assigned Then Return
VerifyProdWithEngine(Map.refMachGroupPanelVM.SelectedMachGroup)
End If End If
End Sub End Sub
@@ -665,7 +694,7 @@ Public Class CALCPanelVM
.nProgramPage = ProjectType.PROJ, .nProgramPage = ProjectType.PROJ,
.nProjType = ProjType, .nProjType = ProjType,
.bBarOk = True, .bBarOk = True,
.nMachineName = ProjectManagerVM.CurrProd.sMachine, .nMachineName = Map.refMachinePanelVM.SelectedMachine.Name,
.nGlobState = Map.refProjectVM.BTLStructureVM.SelBTLPart.nGlobalState} .nGlobState = Map.refProjectVM.BTLStructureVM.SelBTLPart.nGlobalState}
Select Case Map.refProjectVM.BTLStructureVM.SelBTLPart.nGlobalState Select Case Map.refProjectVM.BTLStructureVM.SelBTLPart.nGlobalState
Case Core.CalcStates.OK, CalcStates.INFO Case Core.CalcStates.OK, CalcStates.INFO
@@ -739,49 +768,54 @@ Public Class CALCPanelVM
Map.refMyStatusBarVM.SetOutputMessage(sProgress) Map.refMyStatusBarVM.SetOutputMessage(sProgress)
End Sub End Sub
Friend Sub VerifyAll(ProgramPage As ProjectType) '#End Region ' Verify
Dim ProjType As BWType = ProjectManagerVM.CurrProd.nType
If GetMainPrivateProfileInt(S_GENERAL, "UseCam5", 0) = 1 Then '#Region "VerifyAll"
Dim BarList() As EgtBEAMWALL.Core.Bar = Nothing
' ''' <summary>
' ''' Returns a command that do Open.
' ''' </summary>
' Public ReadOnly Property VerifyAll_Command As ICommand
' Get
' If m_cmdVerifyAll Is Nothing Then
' m_cmdVerifyAll = New Command(AddressOf VerifyAll)
' End If
' Return m_cmdVerifyAll
' End Get
' End Property
''' <summary>
''' Execute the Open. This method is invoked by the OpenCommand.
''' </summary>
Friend Sub VerifyAll()
If (Map.refMainMenuVM.SelPage = Pages.VIEW AndAlso (IsNothing(ProjectManagerVM.CurrProj) OrElse IsNothing(Map.refProjectVM.BTLStructureVM))) OrElse
(Map.refMainMenuVM.SelPage = Pages.MACHINING AndAlso (IsNothing(ProjectManagerVM.CurrProd) OrElse IsNothing(Map.refProjectVM.MachGroupPanelVM))) OrElse
(Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE AndAlso (IsNothing(ProjectManagerVM.CurrProj) OrElse IsNothing(Map.refProjectVM.BTLStructureVM)) AndAlso (IsNothing(ProjectManagerVM.CurrProd) OrElse IsNothing(Map.refProjectVM.MachGroupPanelVM))) Then Return
' se modalita' assemblato
Configuration.AssembledMode(Map.refShowBeamPanelVM.ShowBuilding_IsChecked)
Dim BarList() As EgtBEAMWALL.Core.Bar = Nothing
Dim ProjType As BWType
If Map.refMainMenuVM.SelPage = Pages.VIEW Then
ProjType = ProjectManagerVM.CurrProj.nType
If Not CreateBarListToVerify(Pages.VIEW, ProjType, BarList) Then Return
' lancio calcolo
EgtBEAMWALL.Core.CalcIntegration.Run(BarList, ProjectManagerVM.CurrProj.sProjDirPath, AddressOf ManageCalc)
ElseIf Map.refMainMenuVM.SelPage = Pages.MACHINING Then
ProjType = ProjectManagerVM.CurrProd.nType
If Not CreateBarListToVerify(Pages.MACHINING, ProjType, BarList) Then Return
' lancio calcolo
EgtBEAMWALL.Core.CalcIntegration.Run(BarList, ProjectManagerVM.CurrProd.sProdDirPath, AddressOf ManageCalc)
ElseIf Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE Then
ProjType = ProjectManagerVM.CurrProd.nType
If Map.refProjectVM.LastSelGridType = ProjectVM.GridSelTypes.PART OrElse Map.refProjectVM.LastSelGridType = ProjectVM.GridSelTypes.PARTLIST Then If Map.refProjectVM.LastSelGridType = ProjectVM.GridSelTypes.PART OrElse Map.refProjectVM.LastSelGridType = ProjectVM.GridSelTypes.PARTLIST Then
If Not CreateBarListToVerify(Pages.VIEW, ProjType, BarList) Then Return If Not CreateBarListToVerify(Pages.VIEW, ProjType, BarList) Then Return
' lancio calcolo ' lancio calcolo
EgtBEAMWALL.Core.CalcIntegration.Run(BarList, ProjectManagerVM.CurrProd.sProdDirPath & "\Projs\" & Map.refProjectVM.BTLStructureVM.SelBTLPart.nPROJ.ToString("0000"), AddressOf ManageCalc) EgtBEAMWALL.Core.CalcIntegration.Run(BarList, ProjectManagerVM.CurrProj.sProjDirPath, AddressOf ManageCalc)
ElseIf Map.refProjectVM.LastSelGridType = ProjectVM.GridSelTypes.MACHGROUP Then ElseIf Map.refProjectVM.LastSelGridType = ProjectVM.GridSelTypes.MACHGROUP Then
If Not CreateBarListToVerify(Pages.MACHINING, ProjType, BarList) Then Return If Not CreateBarListToVerify(Pages.MACHINING, ProjType, BarList) Then Return
' lancio calcolo ' lancio calcolo
EgtBEAMWALL.Core.CalcIntegration.Run(BarList, ProjectManagerVM.CurrProd.sProdDirPath, AddressOf ManageCalc) EgtBEAMWALL.Core.CalcIntegration.Run(BarList, ProjectManagerVM.CurrProd.sProdDirPath, AddressOf ManageCalc)
End If End If
Else
Dim ExecThread As New Thread(Sub()
VerifyAllWithEngine(ProgramPage)
End Sub)
ExecThread.Start()
End If
End Sub
Private Sub VerifyAllWithEngine(ProgramPage As ProjectType)
Dim QuestionList As New List(Of QuestionDTO)
If ProgramPage = ProjectType.PROJ Then
For PartIndex = 0 To Map.refProjectVM.BTLStructureVM.BTLPartVMList.Count - 1
If Not Map.refProjectVM.BTLStructureVM.BTLPartVMList(PartIndex).bDO Then Continue For
VerifyProjWithEngine(Map.refProjectVM.BTLStructureVM.BTLPartVMList(PartIndex))
Next
For PartIndex = 0 To Map.refProjectVM.BTLStructureVM.BTLPartVMList.Count - 1
Map.refProjectVM.BTLStructureVM.BTLPartVMList(PartIndex).SetIsRowEnabled(True)
Next
Map.refLeftPanelVM.SetCALCPanel_IsEnabled(True)
ElseIf ProgramPage = ProjectType.PROD Then
For PartIndex = 0 To Map.refMachGroupPanelVM.MachGroupVMList.Count - 1
' se e' gia' stato assegnato a supervisor, la salto e vado alla prossima barra
If DirectCast(Map.refMachGroupPanelVM.MachGroupVMList(PartIndex), MyMachGroupVM).nProduction_State >= ItemState.Assigned Then Return
VerifyProdWithEngine(Map.refMachGroupPanelVM.MachGroupVMList(PartIndex))
Next
For PartIndex = 0 To Map.refMachGroupPanelVM.MachGroupVMList.Count - 1
DirectCast(Map.refMachGroupPanelVM.MachGroupVMList(PartIndex), MyMachGroupVM).SetIsRowEnabled(True)
Next
Map.refRawPartManagerVM.SetCALCPanel_IsEnabled(True)
End If End If
End Sub End Sub
@@ -795,7 +829,7 @@ Public Class CALCPanelVM
.nProgramPage = ProjectType.PROJ, .nProgramPage = ProjectType.PROJ,
.nProjType = ProjType, .nProjType = ProjType,
.bBarOk = True, .bBarOk = True,
.nMachineName = ProjectManagerVM.CurrProd.sMachine, .nMachineName = Map.refMachinePanelVM.SelectedMachine.Name,
.nGlobState = CurrPart.nGlobalState} .nGlobState = CurrPart.nGlobalState}
Select Case CurrPart.nGlobalState Select Case CurrPart.nGlobalState
Case Core.CalcStates.OK, CalcStates.INFO Case Core.CalcStates.OK, CalcStates.INFO
@@ -846,12 +880,223 @@ Public Class CALCPanelVM
Return True Return True
End Function End Function
#End Region ' METHODS '#End Region ' VerifyAll
#Region "COMMANDS" '#Region "ResetCalc"
' ''' <summary>
' ''' Returns a command that do Exec.
' ''' </summary>
' Public ReadOnly Property ResetCalc_Command As ICommand
' Get
' If m_cmdResetCalc Is Nothing Then
' m_cmdResetCalc = New Command(AddressOf ResetCalc)
' End If
' Return m_cmdResetCalc
' End Get
' End Property
' ''' <summary>
' ''' Execute the Exec. This method is invoked by the ExecCommand.
' ''' </summary>
' Public Sub ResetCalc()
' If (Map.refMainMenuVM.SelPage = Pages.VIEW AndAlso (IsNothing(ProjectManagerVM.CurrProj) OrElse IsNothing(Map.refProjectVM.BTLStructureVM))) OrElse
' (Map.refMainMenuVM.SelPage = Pages.MACHINING AndAlso (IsNothing(ProjectManagerVM.CurrProd) OrElse IsNothing(Map.refProjectVM.MachGroupPanelVM))) OrElse
' (Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE AndAlso (IsNothing(ProjectManagerVM.CurrProj) OrElse IsNothing(Map.refProjectVM.BTLStructureVM)) AndAlso (IsNothing(ProjectManagerVM.CurrProd) OrElse IsNothing(Map.refProjectVM.MachGroupPanelVM))) Then Return
' If Map.refMainMenuVM.SelPage = Pages.VIEW OrElse (Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE AndAlso (Map.refProjectVM.LastSelGridType = ProjectVM.GridSelTypes.PART OrElse Map.refProjectVM.LastSelGridType = ProjectVM.GridSelTypes.PARTLIST)) Then
' If (Keyboard.Modifiers And ModifierKeys.Shift) = ModifierKeys.Shift Then
' For Each Part In Map.refProjectVM.BTLStructureVM.BTLPartVMList
' If Part.nGlobalState <> CalcStates.NOTCALCULATED Then
' ' resetto stato dei calcoli
' Part.ResetCalcTotalPart()
' End If
' Next
' ElseIf Map.refProjectVM.BTLStructureVM.SelBTLPartsCnt > 1 Then
' Else
' Dim SelPart As BTLPartVM = Map.refProjectVM.BTLStructureVM.SelBTLPart
' If IsNothing(SelPart) Then Return
' If SelPart.nGlobalState <> CalcStates.NOTCALCULATED Then
' SelPart.ResetCalcTotalPart()
' End If
' End If
' ElseIf Map.refMainMenuVM.SelPage = Pages.MACHINING OrElse (Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE AndAlso Map.refProjectVM.LastSelGridType = ProjectVM.GridSelTypes.MACHGROUP) Then
' If (Keyboard.Modifiers And ModifierKeys.Shift) = ModifierKeys.Shift Then
' For Each MachGroup As MyMachGroupVM In Map.refProjectVM.MachGroupPanelVM.MachGroupVMList
' If MachGroup.nProduction_State >= ItemState.Assigned Then Continue For
' If MachGroup.nGlobalState <> CalcStates.NOTCALCULATED Then
' MachGroup.ResetCalcTotalMachGroup()
' End If
' Next
' Else
' Dim SelMachGroup As MyMachGroupVM = Map.refMachGroupPanelVM.SelectedMachGroup
' If IsNothing(SelMachGroup) Then Return
' ' se barra gia' assegnata a supervisore, esco
' If SelMachGroup.nProduction_State >= ItemState.Assigned Then Return
' If SelMachGroup.nGlobalState <> CalcStates.NOTCALCULATED Then
' SelMachGroup.ResetCalcTotalMachGroup()
' End If
' End If
' End If
' End Sub
'#End Region ' ResetCalc
'#Region "Simulate"
' ''' <summary>
' ''' Returns a command that do Open.
' ''' </summary>
' Public ReadOnly Property Simulate_Command As ICommand
' Get
' If m_cmdSimulate Is Nothing Then
' m_cmdSimulate = New Command(AddressOf Simulate)
' End If
' Return m_cmdSimulate
' End Get
' End Property
' ''' <summary>
' ''' Execute the Open. This method is invoked by the OpenCommand.
' ''' </summary>
' Friend Sub Simulate()
' If (Map.refMainMenuVM.SelPage = Pages.VIEW AndAlso (IsNothing(ProjectManagerVM.CurrProj) OrElse IsNothing(Map.refProjectVM.BTLStructureVM))) OrElse
' (Map.refMainMenuVM.SelPage = Pages.MACHINING AndAlso (IsNothing(ProjectManagerVM.CurrProd) OrElse IsNothing(Map.refProjectVM.MachGroupPanelVM))) OrElse
' (Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE AndAlso (IsNothing(ProjectManagerVM.CurrProj) OrElse IsNothing(Map.refProjectVM.BTLStructureVM)) AndAlso (IsNothing(ProjectManagerVM.CurrProd) OrElse IsNothing(Map.refProjectVM.MachGroupPanelVM))) Then Return
' Dim ProjType As BWType
' Dim BarList() As EgtBEAMWALL.Core.Bar = Nothing
' If Map.refMainMenuVM.SelPage = Pages.VIEW Then
' ProjType = ProjectManagerVM.CurrProj.nType
' If Not CreateBarToSimulate(Pages.VIEW, ProjType, BarList) Then Return
' ' lancio simulazione
' EgtBEAMWALL.Core.CalcIntegration.Run(BarList, ProjectManagerVM.CurrProj.sProjDirPath, AddressOf ManageCalc)
' ElseIf Map.refMainMenuVM.SelPage = Pages.MACHINING Then
' ProjType = ProjectManagerVM.CurrProd.nType
' If Not CreateBarToSimulate(Pages.MACHINING, ProjType, BarList) Then Return
' ' lancio simulazione
' EgtBEAMWALL.Core.CalcIntegration.Run(BarList, ProjectManagerVM.CurrProd.sProdDirPath, AddressOf ManageCalc)
' ElseIf Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE Then
' ProjType = Map.refOnlyProdManagerVM.CurrProd.nType
' If Map.refProjectVM.LastSelGridType = ProjectVM.GridSelTypes.PART Then
' If Not CreateBarToSimulate(Pages.VIEW, ProjType, BarList) Then Return
' ' lancio simulazione
' EgtBEAMWALL.Core.CalcIntegration.Run(BarList, ProjectManagerVM.CurrProj.sProjDirPath, AddressOf ManageCalc)
' ElseIf Map.refProjectVM.LastSelGridType = ProjectVM.GridSelTypes.MACHGROUP Then
' If Not CreateBarToSimulate(Pages.MACHINING, ProjType, BarList) Then Return
' ' lancio simulazione
' EgtBEAMWALL.Core.CalcIntegration.Run(BarList, ProjectManagerVM.CurrProd.sProdDirPath, AddressOf ManageCalc)
' End If
' End If
' End Sub
' Private Function CreateBarToSimulate(SelPage As Pages, ProjType As BWType, ByRef BarList As Bar()) As Boolean
' If SelPage = Pages.VIEW Then
' If Not IsNothing(Map.refProjectVM.BTLStructureVM.SelBTLPart) Then
' Dim TempBarList(0) As EgtBEAMWALL.Core.Bar
' Dim Bar As New EgtBEAMWALL.Core.Bar With {.nBarId = Map.refProjectVM.BTLStructureVM.SelBTLPart.nPartId,
' .nProgramPage = ProjectType.PROJ,
' .nProjType = ProjType,
' .bBarOk = True,
' .nMachineName = Map.refMachinePanelVM.SelectedMachine.Name,
' .nCmdType = CalcIntegration.CmdTypes.SIMULATE,
' .nGlobState = Map.refProjectVM.BTLStructureVM.SelBTLPart.nGlobalState}
' If Map.refProjectVM.BTLStructureVM.SelBTLPart.nGlobalState = CalcStates.NOTCALCULATED Then
' Dim sBTLPartFilePath As String = ProjectManagerVM.CurrProj.sProjDirPath & "\" & Map.refProjectVM.BTLStructureVM.SelBTLPart.nPDN.ToString() & ".ori.bwe"
' If File.Exists(sBTLPartFilePath) Then File.Delete(sBTLPartFilePath)
' End If
' TempBarList(0) = Bar
' BarList = TempBarList
' Else
' Return False
' End If
' ' disabilito interfaccia
' Map.refProjectVM.SetCalcRunning(True)
' ElseIf SelPage = Pages.MACHINING Then
' If Not IsNothing(Map.refMachGroupPanelVM.SelectedMachGroup) Then
' Dim SelMachGroup As MyMachGroupVM = Map.refMachGroupPanelVM.SelectedMachGroup
' Dim TempBarList(0) As EgtBEAMWALL.Core.Bar
' Dim MachineName As String = ""
' EgtGetMachGroupMachineName(SelMachGroup.Id, MachineName)
' Dim Bar As New EgtBEAMWALL.Core.Bar With {.nBarId = SelMachGroup.Id,
' .nProgramPage = ProjectType.PROD,
' .nProjType = ProjType,
' .bBarOk = True,
' .nMachineName = MachineName,
' .nCmdType = CalcIntegration.CmdTypes.SIMULATE,
' .nGlobState = SelMachGroup.nGlobalState}
' If SelMachGroup.nGlobalState = CalcStates.NOTCALCULATED Then
' Dim sMachGroupFilePath As String = ProjectManagerVM.CurrProd.sProdDirPath & "\" & SelMachGroup.Name.ToString() & ".ori.bwe"
' If File.Exists(sMachGroupFilePath) Then File.Delete(sMachGroupFilePath)
' End If
' TempBarList(0) = Bar
' BarList = TempBarList
' Else
' Return False
' End If
' ' disabilito interfaccia
' Map.refProjectVM.SetCalcRunning(True)
' End If
' Return True
' End Function
'#End Region ' Simulate
'#Region "Edit"
' ''' <summary>
' ''' Returns a command that do Open.
' ''' </summary>
' Public ReadOnly Property Edit_Command As ICommand
' Get
' If m_cmdEdit Is Nothing Then
' m_cmdEdit = New Command(AddressOf Edit)
' End If
' Return m_cmdEdit
' End Get
' End Property
' ''' <summary>
' ''' Execute the Open. This method is invoked by the OpenCommand.
' ''' </summary>
' Friend Sub Edit()
' If Map.refMainMenuVM.SelPage = Pages.VIEW AndAlso (IsNothing(ProjectManagerVM.CurrProj) OrElse IsNothing(Map.refProjectVM.BTLStructureVM)) Then Return
' Dim ProjType As BWType
' If Map.refMainMenuVM.SelPage = Pages.VIEW Then
' ProjType = ProjectManagerVM.CurrProj.nType
' Else
' ProjType = ProjectManagerVM.CurrProd.nType
' End If
' Dim BarList() As EgtBEAMWALL.Core.Bar
' If Map.refMainMenuVM.SelPage = Pages.VIEW Then
' If Not IsNothing(Map.refProjectVM.BTLStructureVM.SelBTLPart) Then
' ' salvo il progetto prima di editarlo
' Map.refProjManagerVM.Save()
' Dim TempBarList(0) As EgtBEAMWALL.Core.Bar
' Dim Bar As New EgtBEAMWALL.Core.Bar With {.nBarId = Map.refProjectVM.BTLStructureVM.SelBTLPart.nPartId,
' .nProgramPage = ProjectType.PROJ,
' .nProjType = ProjType,
' .bBarOk = True,
' .nMachineName = Map.refMachinePanelVM.SelectedMachine.Name,
' .nCmdType = CalcIntegration.CmdTypes.EDIT,
' .nGlobState = Map.refProjectVM.BTLStructureVM.SelBTLPart.nGlobalState}
' TempBarList(0) = Bar
' BarList = TempBarList
' Else
' Return
' End If
' ' disabilito interfaccia
' Map.refProjectVM.SetCalcRunning(True)
' ' lancio edit
' EgtBEAMWALL.Core.CalcIntegration.Run(BarList, ProjectManagerVM.CurrProj.sProjDirPath, AddressOf ManageCalc)
' End If
' End Sub
'#End Region ' Edit
#Region "ChooseMachine" #Region "ChooseMachine"
''' <summary>
''' Returns a command that do Open.
''' </summary>
Public ReadOnly Property ChooseMachine_Command As ICommand Public ReadOnly Property ChooseMachine_Command As ICommand
Get Get
If m_cmdChooseMachine Is Nothing Then If m_cmdChooseMachine Is Nothing Then
@@ -861,9 +1106,12 @@ Public Class CALCPanelVM
End Get End Get
End Property End Property
''' <summary>
''' Execute the Open. This method is invoked by the OpenCommand.
''' </summary>
Friend Sub ChooseMachine() Friend Sub ChooseMachine()
' rendo visibile la CmBx per la scelta e il pulsante di conferma solo se il Proj corrente non ha associato alcun Prod ' rendo visibile la CmBx per la scelta e il pulsante di conferma solo se il Proj corrente non ha associato alcun Prod
If ProjectManagerVM.CurrProd.nProjId > 0 Then If ProjectManagerVM.CurrProj.nProdId > 0 AndAlso Map.refMainMenuVM.SelPage <> Pages.ONLYPRODPAGE Then
MessageBox.Show(EgtMsg(61929), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Exclamation) MessageBox.Show(EgtMsg(61929), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Exclamation)
Else Else
SetChooseMachine_Visibility(True) SetChooseMachine_Visibility(True)
@@ -874,6 +1122,9 @@ Public Class CALCPanelVM
#Region "Ok" #Region "Ok"
''' <summary>
''' Returns a command that do Open.
''' </summary>
Public ReadOnly Property Ok_Command As ICommand Public ReadOnly Property Ok_Command As ICommand
Get Get
If m_cmdOk Is Nothing Then If m_cmdOk Is Nothing Then
@@ -883,6 +1134,9 @@ Public Class CALCPanelVM
End Get End Get
End Property End Property
''' <summary>
''' Execute the Open. This method is invoked by the OpenCommand.
''' </summary>
Friend Sub Ok() Friend Sub Ok()
' aggiorno la Macchina selezionata nel Machine Panel e collasso CmBx e pulsante di conferma ' aggiorno la Macchina selezionata nel Machine Panel e collasso CmBx e pulsante di conferma
If Not IsNothing(SelectedMachine) Then Map.refMachinePanelVM.SelectedMachine = SelectedMachine If Not IsNothing(SelectedMachine) Then Map.refMachinePanelVM.SelectedMachine = SelectedMachine
@@ -893,17 +1147,17 @@ Public Class CALCPanelVM
Dim nPartProjId As Integer Dim nPartProjId As Integer
'Dim TempList As New List(Of BTLPartM) 'Dim TempList As New List(Of BTLPartM)
Dim nPartId As Integer = EgtGetFirstPart() Dim nPartId As Integer = EgtGetFirstPart()
'If Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE Then If Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE Then
ProjId = ProjectManagerVM.CurrProd.nProjIdList(0) ProjId = ProjectManagerVM.CurrProd.nProjIdList(0)
'Else Else
' ProjId = ProjectManagerVM.CurrProj.nProjId ProjId = ProjectManagerVM.CurrProj.nProjId
'End If End If
EgtGetInfo(nPartId, BTL_PRT_PROJ, nPartProjId) EgtGetInfo(nPartId, BTL_PRT_PROJ, nPartProjId)
While nPartId <> GDB_ID.NULL While nPartId <> GDB_ID.NULL
' se devo filtrare un progetto ' se devo filtrare un progetto
If ProjId > 0 Then If ProjId > 0 OrElse Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE Then
' verifico se il pezzo appartiene al ProjId ' verifico se il pezzo appartiene al ProjId
If nPartProjId = ProjId Then If nPartProjId = ProjId OrElse Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE Then
EgtRemoveInfo(nPartId, ITG_PROJ_ERR) EgtRemoveInfo(nPartId, ITG_PROJ_ERR)
EgtRemoveInfo(nPartId, ITG_PROJ_MSG) EgtRemoveInfo(nPartId, ITG_PROJ_MSG)
EgtRemoveInfo(nPartId, ITG_PROJ_ROT) EgtRemoveInfo(nPartId, ITG_PROJ_ROT)
@@ -930,12 +1184,9 @@ Public Class CALCPanelVM
' verifico che sia una feature ' verifico che sia una feature
Dim nGRP As Integer Dim nGRP As Integer
If EgtGetInfo(nFeatureId, BTL_FTR_GRP, nGRP) AndAlso Not EgtExistsInfo(nFeatureId, BTL_FTR_MAINID) Then If EgtGetInfo(nFeatureId, BTL_FTR_GRP, nGRP) AndAlso Not EgtExistsInfo(nFeatureId, BTL_FTR_MAINID) Then
'EgtRemoveInfo(nFeatureId, If(Map.refMainMenuVM.SelPage = Pages.VIEW OrElse Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE, ITG_PROJ_ERR, ITG_PROD_ERR)) EgtRemoveInfo(nFeatureId, If(Map.refMainMenuVM.SelPage = Pages.VIEW OrElse Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE, ITG_PROJ_ERR, ITG_PROD_ERR))
EgtRemoveInfo(nFeatureId, ITG_PROD_ERR) EgtRemoveInfo(nFeatureId, If(Map.refMainMenuVM.SelPage = Pages.VIEW OrElse Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE, ITG_PROJ_MSG, ITG_PROD_MSG))
'EgtRemoveInfo(nFeatureId, If(Map.refMainMenuVM.SelPage = Pages.VIEW OrElse Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE, ITG_PROJ_MSG, ITG_PROD_MSG)) EgtRemoveInfo(nFeatureId, If(Map.refMainMenuVM.SelPage = Pages.VIEW OrElse Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE, ITG_PROJ_ROT, ITG_PROD_ROT))
EgtRemoveInfo(nFeatureId, ITG_PROD_MSG)
'EgtRemoveInfo(nFeatureId, If(Map.refMainMenuVM.SelPage = Pages.VIEW OrElse Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE, ITG_PROJ_ROT, ITG_PROD_ROT))
EgtRemoveInfo(nFeatureId, ITG_PROD_ROT)
End If End If
nFeatureId = EgtGetNext(nFeatureId) nFeatureId = EgtGetNext(nFeatureId)
End While End While
@@ -944,7 +1195,7 @@ Public Class CALCPanelVM
nPartId = EgtGetNextPart(nPartId) nPartId = EgtGetNextPart(nPartId)
End While End While
' Se OnlyProdPage rimuovo MachGroup ' Se OnlyProdPage rimuovo MachGroup
If Map.refProjectVM.MachGroupPanelVM.MachGroupVMList.Count > 0 Then If Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE AndAlso Map.refProjectVM.MachGroupPanelVM.MachGroupVMList.Count > 0 Then
If MessageBox.Show(EgtMsg(61779), EgtMsg(30009), MessageBoxButton.OKCancel, MessageBoxImage.Exclamation) = MessageBoxResult.OK Then If MessageBox.Show(EgtMsg(61779), EgtMsg(30009), MessageBoxButton.OKCancel, MessageBoxImage.Exclamation) = MessageBoxResult.OK Then
For Index As Integer = Map.refMachGroupPanelVM.MachGroupVMList.Count - 1 To 0 Step -1 For Index As Integer = Map.refMachGroupPanelVM.MachGroupVMList.Count - 1 To 0 Step -1
Dim CurrMachGroup As MyMachGroupVM = Map.refMachGroupPanelVM.MachGroupVMList(Index) Dim CurrMachGroup As MyMachGroupVM = Map.refMachGroupPanelVM.MachGroupVMList(Index)
+61 -24
View File
@@ -1,32 +1,69 @@
<StackPanel x:Class="CalcPanelV" <EgtFloating:EgtFloatingPanel x:Class="CalcPanelV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Style="{StaticResource OnlyProdPartManager_StackPanel}"> xmlns:EgtFloating="clr-namespace:EgtWPFLib5.EgtFloating;assembly=EgtWPFLib5"
IsTopDockable="True" IsBottomDockable="False" IsLeftDockable="False"
IsRightDockable="False" Style="{StaticResource ToolBar_EgtFloatingPanel}">
<Button FontSize="20"
FontWeight="Light"
ToolTip="{Binding Verify_ToolTip}"
Style="{StaticResource ToolBar_Button}"
Command="{Binding Verify_Command}"
IsEnabled="{Binding Verify_IsEnabled}">
<Image Source="/Resources/CALCPanel/Verify.png" Stretch="Uniform"/>
</Button>
<Button FontSize="20"
FontWeight="Light"
ToolTip="{Binding VerifyAll_ToolTip}"
Style="{StaticResource ToolBar_Button}"
Command="{Binding VerifyAll_Command}"
IsEnabled="{Binding VerifyAll_IsEnabled}">
<Image Source="/Resources/CALCPanel/VerifyAll.png" Stretch="Uniform"/>
</Button>
<Button Command="{Binding ResetCalc_Command}"
ToolTip="{Binding ResetCalc_ToolTip}"
IsEnabled="{Binding CALCPanel_IsEnabled}"
Style="{StaticResource ToolBar_Button}">
<Image Source="/Resources/CALCPanel/ResetCalc.png" Stretch="Uniform"/>
</Button>
<Button ToolTip="{Binding Simulate_ToolTip}"
Style="{StaticResource ToolBar_Button}"
Command="{Binding Simulate_Command}"
IsEnabled="{Binding Simulate_IsEnabled}">
<Image Source="/Resources/CALCPanel/Simulate.png" Stretch="Uniform"/>
</Button>
<Button ToolTip="{Binding Edit_ToolTip}"
Style="{StaticResource ToolBar_Button}"
Command="{Binding Edit_Command}"
IsEnabled="{Binding Edit_IsEnabled}"
Visibility="{Binding Edit_Visibility}">
<Image Source="/Resources/CALCPanel/Edit.png" Stretch="Uniform"/>
</Button>
<Button ToolTip="{Binding ChooseMachine_ToolTip}" <Button ToolTip="{Binding ChooseMachine_ToolTip}"
Style="{StaticResource ToolBar_Button}"
Command="{Binding ChooseMachine_Command}" Command="{Binding ChooseMachine_Command}"
IsEnabled="{Binding CALCPanel_IsEnabled}" IsEnabled="{Binding CALCPanel_IsEnabled}"
Visibility="{Binding ChooseMachineBtn_Visibility}" Visibility="{Binding ChooseMachineBtn_Visibility}">
Style="{StaticResource ToolBarViewPanel_Button}">
<Image Source="/Resources/CALCPanel/ChooseMachine.png" Stretch="Uniform"/> <Image Source="/Resources/CALCPanel/ChooseMachine.png" Stretch="Uniform"/>
</Button> </Button>
<Grid Margin="0,0,5,0" Visibility="{Binding ChooseMachine_Visibility}"> <Grid Margin="0,0,5,0" Visibility="{Binding ChooseMachine_Visibility}">
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/> <ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/> <ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions> </Grid.ColumnDefinitions>
<!--Combobox per selezionare la macchina corrente--> <!--Combobox per selezionare la macchina corrente-->
<ComboBox Grid.Column="0" <ComboBox ItemsSource="{Binding Path=MachineList}" DisplayMemberPath="Name"
ItemsSource="{Binding Path=MachineList}" SelectedItem="{Binding Path=SelectedMachine}" SelectedValuePath="Name"
DisplayMemberPath="Name" Height="22" Width="150"
SelectedItem="{Binding Path=SelectedMachine}" Grid.Column="0"/>
SelectedValuePath="Name" <Button Content="OK"
Style="{StaticResource OnlyProdCalcPanel_ComboBox}"/> FontSize="10"
<Button Grid.Column="1" FontWeight="Light"
Content="OK" Style="{StaticResource ToolBar_Button}"
Command="{Binding Ok_Command}" Command="{Binding Ok_Command}"
Style="{StaticResource ToolBarOnlyProdCalcPanel_Button}"/> Grid.Column="1"/>
</Grid> </Grid>
</StackPanel> </EgtFloating:EgtFloatingPanel>
@@ -0,0 +1,64 @@
<StackPanel x:Class="OnlyProdCalcPanelV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:EgtFloating="clr-namespace:EgtWPFLib5.EgtFloating;assembly=EgtWPFLib5"
Style="{StaticResource OnlyProdPartManager_StackPanel}">
<!--<Button ToolTip="{Binding Verify_ToolTip}"
Command="{Binding Verify_Command}"
IsEnabled="{Binding Verify_IsEnabled}"
Style="{StaticResource ToolBarViewPanel_Button}">
<Image Source="/Resources/CALCPanel/Verify.png" Stretch="Uniform"/>
</Button>
<Button ToolTip="{Binding VerifyAll_ToolTip}"
Command="{Binding VerifyAll_Command}"
IsEnabled="{Binding VerifyAll_IsEnabled}"
Style="{StaticResource ToolBarViewPanel_Button}">
<Image Source="/Resources/CALCPanel/VerifyAll.png" Stretch="Uniform"/>
</Button>-->
<!--<Button Command="{Binding ResetCalc_Command}"
ToolTip="{Binding ResetCalc_ToolTip}"
IsEnabled="{Binding CALCPanel_IsEnabled}"
Style="{StaticResource ToolBarViewPanel_Button}">
<Image Source="/Resources/CALCPanel/ResetCalc.png" Stretch="Uniform"/>
</Button>-->
<!--<Button ToolTip="{Binding Simulate_ToolTip}"
Command="{Binding Simulate_Command}"
IsEnabled="{Binding Simulate_IsEnabled}"
Style="{StaticResource ToolBarViewPanel_Button}">
<Image Source="/Resources/CALCPanel/Simulate.png" Stretch="Uniform"/>
</Button>-->
<!--<Button ToolTip="{Binding Edit_ToolTip}"
Command="{Binding Edit_Command}"
IsEnabled="{Binding Edit_IsEnabled}"
Visibility="{Binding Edit_Visibility}"
Style="{StaticResource ToolBarViewPanel_Button}">
<Image Source="/Resources/CALCPanel/Edit.png" Stretch="Uniform"/>
</Button>-->
<Button ToolTip="{Binding ChooseMachine_ToolTip}"
Command="{Binding ChooseMachine_Command}"
IsEnabled="{Binding CALCPanel_IsEnabled}"
Visibility="{Binding ChooseMachineBtn_Visibility}"
Style="{StaticResource ToolBarViewPanel_Button}">
<Image Source="/Resources/CALCPanel/ChooseMachine.png" Stretch="Uniform"/>
</Button>
<Grid Margin="0,0,5,0" Visibility="{Binding ChooseMachine_Visibility}">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<!--Combobox per selezionare la macchina corrente-->
<ComboBox Grid.Column="0"
ItemsSource="{Binding Path=MachineList}"
DisplayMemberPath="Name"
SelectedItem="{Binding Path=SelectedMachine}"
SelectedValuePath="Name"
Style="{StaticResource OnlyProdCalcPanel_ComboBox}"/>
<Button Grid.Column="1"
Content="OK"
Command="{Binding Ok_Command}"
Style="{StaticResource ToolBarOnlyProdCalcPanel_Button}"/>
</Grid>
</StackPanel>
@@ -0,0 +1,3 @@
Public Class OnlyProdCalcPanelV
End Class
@@ -2,6 +2,7 @@
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5" xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
xmlns:EgtBEAMWALL="clr-namespace:EgtBEAMWALL.Optimizer"
Style="{DynamicResource {x:Type EgtWPFLib5:EgtCustomWindow}}" Style="{DynamicResource {x:Type EgtWPFLib5:EgtCustomWindow}}"
WindowStyle="None" ResizeMode="NoResize" WindowStyle="None" ResizeMode="NoResize"
SizeToContent="WidthAndHeight" SizeToContent="WidthAndHeight"
@@ -2,6 +2,7 @@
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5" xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
xmlns:EgtBEAMWALL="clr-namespace:EgtBEAMWALL.Optimizer"
Style="{DynamicResource {x:Type EgtWPFLib5:EgtCustomWindow}}" Style="{DynamicResource {x:Type EgtWPFLib5:EgtCustomWindow}}"
WindowStyle="None" ResizeMode="NoResize" WindowStyle="None" ResizeMode="NoResize"
SizeToContent="Height" SizeToContent="Height"
@@ -1,9 +1,83 @@
<DockPanel x:Class="ConfigurationPageV" <DockPanel x:Class="ConfigurationPageV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:OPTIMIZER="clr-namespace:EgtBEAMWALL.Optimizer" xmlns:EgtBEAMWALLCORE="clr-namespace:EgtBEAMWALL.Core;assembly=EgtBEAMWALL.Core"
xmlns:EgtBEAMWALL="clr-namespace:EgtBEAMWALL.Optimizer"
DataContext="{StaticResource ConfigurationPageVM}"> DataContext="{StaticResource ConfigurationPageVM}">
<OPTIMIZER:MachinePanelV DataContext="{Binding MachinePanelVM}"/> <Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="10*"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="1*"/>
<RowDefinition Height="6*"/>
</Grid.RowDefinitions>
<TabControl Grid.Row="0" Grid.Column="0" Grid.RowSpan="2" Grid.ColumnSpan="2"
SelectedIndex="{Binding SelConfigSubPage}">
<TabItem>
<TabItem.Header>
<StackPanel Orientation="Horizontal">
<TextBlock Text="{Binding General_Msg}"
Style="{StaticResource OptionTextBlock}"/>
<Button Command="{Binding SaveCommand}"
ToolTip="{Binding SaveToolTip}"
Visibility="{Binding General_Visibility}"
Style="{StaticResource OptionPanel_Button}">
<Image Source="/Resources/ProjectManager/Save.png" Stretch="Uniform"/>
</Button>
</StackPanel>
</TabItem.Header>
<TabItem.Content>
<EgtBEAMWALLCORE:General_ConfigurationPageV/>
</TabItem.Content>
</TabItem>
<TabItem>
<TabItem.Header>
<StackPanel Orientation="Horizontal">
<TextBlock Text="{Binding ParameterQ_Msg}"
Style="{StaticResource OptionTextBlock}"/>
<Button Command="{Binding SaveCommand}"
ToolTip="{Binding SaveToolTip}"
Visibility="{Binding ParameterQ_Visibility}"
Style="{StaticResource OptionPanel_Button}">
<Image Source="/Resources/ProjectManager/Save.png" Stretch="Uniform"/>
</Button>
</StackPanel>
</TabItem.Header>
<TabItem.Content>
<EgtBEAMWALLCORE:QParameter_ConfigurationPageV/>
</TabItem.Content>
</TabItem>
<TabItem>
<TabItem.Header>
<TextBlock Text="{Binding Machine_Msg}"
Style="{StaticResource Machine_TextBlock}"/>
</TabItem.Header>
<TabItem.Content>
<EgtBEAMWALLCORE:Machine_ConfigurationPageV/>
</TabItem.Content>
</TabItem>
<TabItem>
<TabItem.Header>
<StackPanel Orientation="Horizontal">
<TextBlock Text="{Binding PDFEditor_Msg}"
Style="{StaticResource OptionTextBlock}"/>
<Button Command="{Binding SaveCommand}"
ToolTip="{Binding SaveToolTip}"
Visibility="{Binding PDFEditor_Visibility}"
Style="{StaticResource OptionPanel_Button}">
<Image Source="/Resources/ProjectManager/Save.png" Stretch="Uniform"/>
</Button>
</StackPanel>
</TabItem.Header>
<TabItem.Content>
<EgtBEAMWALL:PDFEditorV/>
</TabItem.Content>
</TabItem>
</TabControl>
</Grid>
</DockPanel> </DockPanel>
@@ -1,2 +1,5 @@
Public Class ConfigurationPageV Public Class ConfigurationPageV
Private Sub ScrollViewer_Scroll(sender As Object, e As Primitives.ScrollEventArgs)
End Sub
End Class End Class
File diff suppressed because it is too large Load Diff
@@ -1,3 +0,0 @@
Public Class ConfigurationProgramV
End Class
@@ -0,0 +1,118 @@
<Grid x:Class="General_ConfigurationPageV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="1*"/>
<RowDefinition Height="1*"/>
</Grid.RowDefinitions>
<StackPanel Grid.Row="0" Grid.Column="0" Margin="5,5,5,0">
<GroupBox Header="{Binding CurrentLanguage_Msg}"
Margin="0,0,0,5">
<UniformGrid Rows="2" Margin="3,3,3,3">
<ComboBox ItemsSource="{Binding LanguageList, Mode=OneWay}" Height="25"
DisplayMemberPath="Name" SelectedItem="{Binding SelectedLanguage}"
Margin="0,0,0,5"/>
<TextBlock Text="{Binding LanguageAdvert_Msg}" TextWrapping="Wrap"
TextAlignment="Center"/>
</UniformGrid>
</GroupBox>
<UniformGrid Columns="2"
Margin="0,0,0,5">
<TextBlock Text="{Binding MMUnits_Msg}" VerticalAlignment="Center"/>
<ComboBox ItemsSource="{Binding UnitMeasureList, Mode=OneWay}"
SelectedIndex="{Binding SelMeasureUnit}" Height="25"
Margin="0,5,0,0"/>
</UniformGrid>
<GroupBox Header="{Binding Nesting_Msg}"
Margin="0,0,0,5">
<StackPanel>
<UniformGrid Columns="2"
Margin="0,0,0,5">
<TextBlock Text="{Binding SectionTime_Msg}"
Grid.Row="0" Grid.Column="0"/>
<EgtWPFLib5:EgtTextBox Text="{Binding SectionTime, UpdateSourceTrigger=Explicit}"
Grid.Row="0" Grid.Column="1"/>
</UniformGrid>
<UniformGrid Columns="2"
Margin="0,0,0,5">
<TextBlock Text="{Binding PartTime_Msg}"
Grid.Row="1" Grid.Column="0"/>
<EgtWPFLib5:EgtTextBox Text="{Binding PartTime, UpdateSourceTrigger=Explicit}"
Grid.Row="1" Grid.Column="1"/>
</UniformGrid>
</StackPanel>
</GroupBox>
<UniformGrid Columns="2"
Margin="0,0,0,5">
<TextBlock Text="{Binding PrintLabel_Msg}" VerticalAlignment="Center"/>
<CheckBox IsChecked="{Binding bPrintLabel_IsChecked}"
Margin="0,5,0,0"/>
</UniformGrid>
<GroupBox Header="Backup And Restore">
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
</Grid.RowDefinitions>
<Grid Grid.Row="0"
Margin="0,2,0,5">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions>
<CheckBox x:Name="ExternalBackup_CheckBox"
IsChecked="{Binding bExternalBackupActive}"
VerticalAlignment="Center"/>
<TextBlock Grid.Column="1"
Text="External file path:"
VerticalAlignment="Center"/>
</Grid>
<Grid Grid.Row="1"
Margin="0,2,0,5">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<TextBox Text="{Binding ExternalBackupFolderPath}"
IsEnabled="{Binding IsChecked, ElementName=ExternalBackup_CheckBox}"
Margin="0,0,2.5,0"/>
<Button Grid.Column="1"
Content="..."
Width="18"
Command="{Binding ChooseExternalBackupFolderPath_Command}"
IsEnabled="{Binding IsChecked, ElementName=ExternalBackup_CheckBox}"
Margin="2.5,0,0,0"/>
</Grid>
<Grid Grid.Row="2">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<TextBlock Text="Reminder Frequency"/>
<ComboBox Grid.Column="1"
ItemsSource="{Binding ReminderList}"
SelectedItem="{Binding SelReminder}"/>
</Grid>
<StackPanel Grid.Row="3"
Orientation="Horizontal">
<Button Content="Backup"
Command="{Binding Backup_Command}"
Style="{StaticResource ToolBar_TextButton}"/>
<Button Content="Restore"
Command="{Binding Restore_Command}"
Style="{StaticResource ToolBar_TextButton}"/>
</StackPanel>
</Grid>
</GroupBox>
</StackPanel>
</Grid>
@@ -0,0 +1,3 @@
Public Class General_ConfigurationPageV
End Class
@@ -0,0 +1,70 @@
<Grid x:Class="Machine_ConfigurationPageV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:EgtBEAMWALL="clr-namespace:EgtBEAMWALL.ViewerOptimizer"
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="10*"/>
</Grid.RowDefinitions>
<StackPanel Grid.Row="0" Grid.Column="0" Orientation="Horizontal">
<GroupBox Style="{StaticResource GroupBoxStyle_NoHeader}" Padding="5,10,5,5">
<EgtBEAMWALL:MachinePanelV DataContext="{Binding MachinePanelVM}" VerticalAlignment="Center"/>
</GroupBox>
</StackPanel>
<StackPanel Grid.Row="1" Grid.Column="0" Orientation="Horizontal">
<ItemsControl ItemsSource="{Binding ConfigMachTableList}">
<ItemsControl.ItemsPanel>
<ItemsPanelTemplate>
<StackPanel x:Name="GroupStackPanel" Orientation="Horizontal"/>
</ItemsPanelTemplate>
</ItemsControl.ItemsPanel>
<ItemsControl.ItemTemplate>
<DataTemplate>
<GroupBox Header="{Binding sName}" Width="Auto" VerticalAlignment="Top" Height="Auto">
<ItemsControl Name="MachParamsItemsControl" ItemsSource="{Binding MachParamList}" Margin="0,5,0,0">
<ItemsControl.ItemsPanel>
<ItemsPanelTemplate>
<WrapPanel Orientation="Vertical"/>
</ItemsPanelTemplate>
</ItemsControl.ItemsPanel>
<ItemsControl.ItemTemplate>
<DataTemplate>
<Grid Margin="0,0,5,5">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*" />
<ColumnDefinition Width="*" />
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<TextBlock Text="{Binding sName}"
TextWrapping="WrapWithOverflow"
Width="100"
Style="{StaticResource MachParamTextBlock}"/>
<EgtWPFLib5:EgtTextBox Text="{Binding sValue, UpdateSourceTrigger=Explicit}"
Grid.Column="1"
Width="70"/>
<TextBlock Text="{Binding sDescription}"
TextWrapping="WrapWithOverflow"
Width="200"
Style="{StaticResource MachParamTextBlock}"
Grid.Column="2"/>
</Grid>
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>
</GroupBox>
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>
</StackPanel>
</Grid>
@@ -0,0 +1,3 @@
Public Class Machine_ConfigurationPageV
End Class
@@ -0,0 +1,143 @@
<Grid x:Class="OnlyProdCheckVersionV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:EgtBEAMWALLCORE="clr-namespace:EgtBEAMWALL.Core;assembly=EgtBEAMWALL.Core"
xmlns:EgtBEAMWALL="clr-namespace:EgtBEAMWALL.Optimizer">
<Grid.Resources>
<!--<EgtBEAMWALL:IsPermittedConverter x:Key="IsPermittedConverter"/>-->
</Grid.Resources>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions>
<Grid Margin="10"
VerticalAlignment="Top"
HorizontalAlignment="Left">
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
<RowDefinition Height="1*"/>
</Grid.RowDefinitions>
<StackPanel Orientation="Horizontal" HorizontalAlignment="Center">
<TextBlock Text="{Binding ActVersion_Msg}"
VerticalAlignment="Center"
FontSize="15"
FontWeight="Bold"
Margin="10,0,0,0"
Style="{StaticResource OptionTextBlock_OnlyProd}"/>
<TextBlock Text="{Binding ActualVersion}"
VerticalAlignment="Center"
FontSize="15"
FontWeight="Bold"
Margin="10,0,0,0"
Style="{StaticResource OptionTextBlock_OnlyProd}"/>
</StackPanel>
<UniformGrid Grid.Row="1"
Columns="2"
Margin="0,20,0,10">
<Button Content="{Binding AllVersion_Msg}"
Width="180"
Command="{Binding GetAllReleaseCommand}"
Style="{StaticResource OnlyProdEgtWPFLib5_InputButton}"/>
<Button Content="{Binding VersionFrom_Msg}"
Width="150"
Command="{Binding GetVersionFromCommand}"
Style="{StaticResource OnlyProdEgtWPFLib5_InputButton}"/>
</UniformGrid>
<Border Grid.Row="2"
Margin="0,10,10,10"
Visibility="{Binding ProgramVersionListVisibility}"
Style="{StaticResource OnlyProdPage_Border}">
<DataGrid ItemsSource="{Binding ProgramVersionList}"
SelectedItem="{Binding ProgramVersionListItem}"
AutoGenerateColumns="False"
CanUserSortColumns="False"
CanUserResizeColumns="False"
CanUserResizeRows="False"
CanUserReorderColumns="False"
SelectionMode="Single"
ScrollViewer.CanContentScroll="True"
ScrollViewer.VerticalScrollBarVisibility="Auto"
ScrollViewer.HorizontalScrollBarVisibility="Hidden"
AlternatingRowBackground="{StaticResource BeamWall_LinkWater}"
AlternationCount="2"
CellStyle="{StaticResource CellDataGrid_CustomHighLight}"
RowStyle="{StaticResource RowDataGrid_CustomHighLight}"
Style="{StaticResource DataGrid_OnlyProd}">
<DataGrid.ColumnHeaderStyle>
<Style TargetType="{x:Type DataGridColumnHeader}">
<Setter Property="Background" Value="{StaticResource BeamWall_Teal}"/>
<Setter Property="Foreground" Value="{StaticResource BeamWall_White}"/>
<Setter Property="HorizontalContentAlignment" Value="Center"/>
<Setter Property="FontWeight" Value="Bold"/>
<Setter Property="FontSize" Value="15"/>
</Style>
</DataGrid.ColumnHeaderStyle>
<DataGrid.Columns>
<!--Numero Versione-->
<DataGridTemplateColumn Width="170">
<DataGridTemplateColumn.HeaderTemplate>
<DataTemplate>
<TextBlock Text="{Binding DataContext.NumVersion_Msg, RelativeSource={RelativeSource AncestorType=DataGrid}}"/>
</DataTemplate>
</DataGridTemplateColumn.HeaderTemplate>
<DataGridTemplateColumn.CellTemplate>
<DataTemplate>
<TextBlock Text="{Binding VersNum}"/>
</DataTemplate>
</DataGridTemplateColumn.CellTemplate>
</DataGridTemplateColumn>
<!--Versione-->
<DataGridTemplateColumn Width="110">
<DataGridTemplateColumn.HeaderTemplate>
<DataTemplate>
<TextBlock Text="{Binding DataContext.Version_Msg, RelativeSource={RelativeSource AncestorType=DataGrid}}"/>
</DataTemplate>
</DataGridTemplateColumn.HeaderTemplate>
<DataGridTemplateColumn.CellTemplate>
<DataTemplate>
<TextBlock Text="{Binding VersText}"/>
</DataTemplate>
</DataGridTemplateColumn.CellTemplate>
</DataGridTemplateColumn>
<!--Data di Rilascio-->
<DataGridTemplateColumn Width="160">
<DataGridTemplateColumn.HeaderTemplate>
<DataTemplate>
<TextBlock Text="{Binding DataContext.DateVersion_Msg, RelativeSource={RelativeSource AncestorType=DataGrid}}"/>
</DataTemplate>
</DataGridTemplateColumn.HeaderTemplate>
<DataGridTemplateColumn.CellTemplate>
<DataTemplate>
<TextBlock Text="{Binding ReleaseDate, StringFormat=dd/MM/yyyy}"/>
</DataTemplate>
</DataGridTemplateColumn.CellTemplate>
</DataGridTemplateColumn>
<!--Stato Versione-->
<DataGridTemplateColumn Width="150">
<DataGridTemplateColumn.HeaderTemplate>
<DataTemplate>
<TextBlock Text="{Binding DataContext.StateVersion_Msg, RelativeSource={RelativeSource AncestorType=DataGrid}}"/>
</DataTemplate>
</DataGridTemplateColumn.HeaderTemplate>
<!--<DataGridTemplateColumn.CellTemplate>
<DataTemplate>
<TextBlock Text="{Binding Converter={StaticResource IsPermittedConverter}}"/>
</DataTemplate>
</DataGridTemplateColumn.CellTemplate>-->
</DataGridTemplateColumn>
</DataGrid.Columns>
</DataGrid>
</Border>
</Grid>
<Border Grid.Column="1"
Margin="0,10,10,10"
Style="{StaticResource OnlyProdPage_Border}">
<!--<WebView:WebView2 Grid.Column="1"
Source="{Binding LinkVersionView}"/>-->
</Border>
</Grid>
@@ -0,0 +1,3 @@
Public Class OnlyProdCheckVersionV
End Class
@@ -1,9 +1,10 @@
<DockPanel x:Class="ConfigurationProgramV" <DockPanel x:Class="OnlyProdConfigurationPageV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:EgtBEAMWALLCORE="clr-namespace:EgtBEAMWALL.Core;assembly=EgtBEAMWALL.Core" xmlns:EgtBEAMWALLCORE="clr-namespace:EgtBEAMWALL.Core;assembly=EgtBEAMWALL.Core"
xmlns:OPTIMIZER="clr-namespace:EgtBEAMWALL.Optimizer" xmlns:EgtBEAMWALL="clr-namespace:EgtBEAMWALL.Optimizer"
DataContext="{StaticResource ConfigurationPageVM}"> DataContext="{StaticResource ConfigurationPageVM}">
<Grid> <Grid>
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"/> <ColumnDefinition Width="1*"/>
@@ -13,7 +14,7 @@
<RowDefinition Height="1*"/> <RowDefinition Height="1*"/>
<RowDefinition Height="6*"/> <RowDefinition Height="6*"/>
</Grid.RowDefinitions> </Grid.RowDefinitions>
<TabControl Grid.RowSpan="2" Grid.ColumnSpan="2" <TabControl Grid.Row="0" Grid.Column="0" Grid.RowSpan="2" Grid.ColumnSpan="2"
SelectedIndex="{Binding SelConfigSubPage}" SelectedIndex="{Binding SelConfigSubPage}"
Style="{StaticResource OnlyProd_TabControl}"> Style="{StaticResource OnlyProd_TabControl}">
<TabItem> <TabItem>
@@ -33,6 +34,38 @@
<EgtBEAMWALLCORE:OnlyProdGeneral_ConfigurationPageV/> <EgtBEAMWALLCORE:OnlyProdGeneral_ConfigurationPageV/>
</TabItem.Content> </TabItem.Content>
</TabItem> </TabItem>
<!--<TabItem>
<TabItem.Header>
<StackPanel Orientation="Horizontal" Margin="5">
<TextBlock Text="{Binding ParameterQ_Msg}"
FontSize="15"/>
<Button Command="{Binding SaveCommand}"
ToolTip="{Binding SaveToolTip}"
Visibility="{Binding ParameterQ_Visibility}"
Style="{StaticResource SaveOptionPanel_Button}">
<Image Source="/Resources/ProjectManager/Save.png" Stretch="Uniform"/>
</Button>
</StackPanel>
</TabItem.Header>
<TabItem.Content>
<EgtBEAMWALLCORE:OnlyProdQParameter_ConfigurationPageV/>
</TabItem.Content>
</TabItem>-->
<TabItem>
<TabItem.Header>
<StackPanel Orientation="Horizontal" Margin="5">
<TextBlock Text="{Binding Machine_Msg}"
FontSize="15"/>
</StackPanel>
</TabItem.Header>
<TabItem.Content>
<StackPanel>
<Button Content="Strategies"
Command="{Binding StrategyManager_Command}"/>
<EgtBEAMWALLCORE:OnlyProdMachine_ConfigurationPageV/>
</StackPanel>
</TabItem.Content>
</TabItem>
<TabItem> <TabItem>
<TabItem.Header> <TabItem.Header>
<StackPanel Orientation="Horizontal" Margin="5"> <StackPanel Orientation="Horizontal" Margin="5">
@@ -47,9 +80,20 @@
</StackPanel> </StackPanel>
</TabItem.Header> </TabItem.Header>
<TabItem.Content> <TabItem.Content>
<OPTIMIZER:PDFEditorV/> <EgtBEAMWALL:OnlyProdPDFEditorV/>
</TabItem.Content> </TabItem.Content>
</TabItem> </TabItem>
<!--<TabItem>
<TabItem.Header>
<StackPanel Orientation="Horizontal" Margin="5">
<TextBlock Text="{Binding CtrlVersion_Msg}"
FontSize="15"/>
</StackPanel>
</TabItem.Header>
<TabItem.Content>
<EgtBEAMWALL:OnlyProdCheckVersionV/>
</TabItem.Content>
</TabItem>-->
</TabControl> </TabControl>
</Grid> </Grid>
</DockPanel> </DockPanel>
@@ -0,0 +1,2 @@
Public Class OnlyProdConfigurationPageV
End Class
@@ -0,0 +1,80 @@
<Grid x:Class="QParameter_ConfigurationPageV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:EgtBEAMWALL="clr-namespace:EgtBEAMWALL.ViewerOptimizer">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="2*"/>
<ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="1*"/>
</Grid.RowDefinitions>
<EgtBEAMWALL:QParamListV DataContext="{Binding}"
ItemsSource="{Binding QBTLParamVMList}"
SelectedItem="{Binding SelQParam}"
Grid.Column="0"
Margin="5">
<DataGrid.GroupStyle>
<GroupStyle>
<GroupStyle.Panel>
<ItemsPanelTemplate>
<DataGridRowsPresenter/>
</ItemsPanelTemplate>
</GroupStyle.Panel>
<GroupStyle.HeaderTemplate>
<DataTemplate>
<StackPanel>
<TextBlock Text="{Binding Path=Name}"/>
</StackPanel>
</DataTemplate>
</GroupStyle.HeaderTemplate>
<GroupStyle.ContainerStyle>
<Style TargetType="{x:Type GroupItem}">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type GroupItem}">
<Expander IsExpanded="True">
<Expander.Background>
<SolidColorBrush Color="#FFBABABA"></SolidColorBrush>
</Expander.Background>
<Expander.Header>
<StackPanel Orientation="Horizontal">
<TextBlock Text="{Binding Path=Name}" />
</StackPanel>
</Expander.Header>
<ItemsPresenter />
</Expander>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</GroupStyle.ContainerStyle>
</GroupStyle>
<GroupStyle>
<GroupStyle.ContainerStyle>
<Style TargetType="{x:Type GroupItem}">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type GroupItem}">
<Expander IsExpanded="True">
<Expander.Background>
<SolidColorBrush Color="LightGray"></SolidColorBrush>
</Expander.Background>
<Expander.Header>
<StackPanel Orientation="Horizontal">
<TextBlock Text="{Binding Path=Name}" />
</StackPanel>
</Expander.Header>
<ItemsPresenter />
</Expander>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</GroupStyle.ContainerStyle>
</GroupStyle>
</DataGrid.GroupStyle>
</EgtBEAMWALL:QParamListV>
</Grid>
@@ -0,0 +1,3 @@
Public Class QParameter_ConfigurationPageV
End Class
+187 -384
View File
@@ -14,21 +14,6 @@
<Deterministic>true</Deterministic> <Deterministic>true</Deterministic>
<NuGetPackageImportStamp> <NuGetPackageImportStamp>
</NuGetPackageImportStamp> </NuGetPackageImportStamp>
<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> <PropertyGroup>
<OptionExplicit>On</OptionExplicit> <OptionExplicit>On</OptionExplicit>
@@ -63,9 +48,6 @@
<PlatformTarget>x86</PlatformTarget> <PlatformTarget>x86</PlatformTarget>
<Prefer32Bit>true</Prefer32Bit> <Prefer32Bit>true</Prefer32Bit>
</PropertyGroup> </PropertyGroup>
<PropertyGroup>
<ApplicationIcon>Resources\EgtBEAMWALL.ico</ApplicationIcon>
</PropertyGroup>
<ItemGroup> <ItemGroup>
<Reference Include="EgtBEAMWALL.Core"> <Reference Include="EgtBEAMWALL.Core">
<HintPath>..\EgtBEAMWALL.Core\bin\Debug\EgtBEAMWALL.Core.dll</HintPath> <HintPath>..\EgtBEAMWALL.Core\bin\Debug\EgtBEAMWALL.Core.dll</HintPath>
@@ -103,6 +85,9 @@
<Reference Include="System.Xaml"> <Reference Include="System.Xaml">
<RequiredTargetFramework>4.0</RequiredTargetFramework> <RequiredTargetFramework>4.0</RequiredTargetFramework>
</Reference> </Reference>
<Reference Include="Windows">
<HintPath>..\..\..\Program Files (x86)\Windows Kits\10\UnionMetadata\10.0.22000.0\Windows.winmd</HintPath>
</Reference>
<Reference Include="WindowsBase" /> <Reference Include="WindowsBase" />
<Reference Include="PresentationCore" /> <Reference Include="PresentationCore" />
<Reference Include="PresentationFramework" /> <Reference Include="PresentationFramework" />
@@ -118,16 +103,16 @@
<DependentUpon>AboutBoxV.xaml</DependentUpon> <DependentUpon>AboutBoxV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="AddFeatureWnd\AddFeatureWndVM.vb" /> <Compile Include="AddFeatureWnd\AddFeatureWndVM.vb" />
<Compile Include="AddFeatureWnd\AddFeatureWndV.xaml.vb"> <Compile Include="AddFeatureWnd\NewAddFeatureWndV.xaml.vb">
<DependentUpon>AddFeatureWndV.xaml</DependentUpon> <DependentUpon>NewAddFeatureWndV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="AddPartWnd\AddPartWndVM.vb" /> <Compile Include="AddPartWnd\AddPartWndVM.vb" />
<Compile Include="AddPartWnd\AddPartWndV.xaml.vb"> <Compile Include="AddPartWnd\OnlyProdAddPartWndV.xaml.vb">
<DependentUpon>AddPartWndV.xaml</DependentUpon> <DependentUpon>OnlyProdAddPartWndV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="AddRawPartWnd\AddRawPartWndVM.vb" /> <Compile Include="AddRawPartWnd\AddRawPartWndVM.vb" />
<Compile Include="AddRawPartWnd\AddRawPartWndV.xaml.vb"> <Compile Include="AddRawPartWnd\OnlyProdAddRawPartWndV.xaml.vb">
<DependentUpon>AddRawPartWndV.xaml</DependentUpon> <DependentUpon>OnlyProdAddRawPartWndV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="AddSectionXMaterialWnd\AddSectionXMaterialWndV.xaml.vb"> <Compile Include="AddSectionXMaterialWnd\AddSectionXMaterialWndV.xaml.vb">
<DependentUpon>AddSectionXMaterialWndV.xaml</DependentUpon> <DependentUpon>AddSectionXMaterialWndV.xaml</DependentUpon>
@@ -137,54 +122,23 @@
<DependentUpon>Application.xaml</DependentUpon> <DependentUpon>Application.xaml</DependentUpon>
<SubType>Code</SubType> <SubType>Code</SubType>
</Compile> </Compile>
<Compile Include="ConfigurationPage\ConfigurationProgramV.xaml.vb">
<DependentUpon>ConfigurationProgramV.xaml</DependentUpon>
</Compile>
<Compile Include="ExecProcessManager\MyExecProcessManager.vb" />
<Compile Include="ForcedStrategyBTL\ForcedStrategyBTLV.xaml.vb">
<DependentUpon>ForcedStrategyBTLV.xaml</DependentUpon>
</Compile>
<Compile Include="ForcedStrategyPanel\ForcedStrategyPanelV.xaml.vb">
<DependentUpon>ForcedStrategyPanelV.xaml</DependentUpon>
</Compile>
<Compile Include="ForcedStrategyPanel\ForcedStrategyPanelVM.vb" />
<Compile Include="GeneralParametersStrategy\GeneralParametersStrategyV.xaml.vb">
<DependentUpon>GeneralParametersStrategyV.xaml</DependentUpon>
</Compile>
<Compile Include="GeneralParametersStrategy\GeneralParametersStrategyVM.vb" />
<Compile Include="GeneralParametersStrategy\GeneralParametersWnd.xaml.vb">
<DependentUpon>GeneralParametersWnd.xaml</DependentUpon>
</Compile>
<Compile Include="GeneralParametersStrategy\GeneralParametersWndVM.vb" />
<Compile Include="GeneralParametersStrategy\JsonGeneralParameters.vb" />
<Compile Include="GeneralParametersStrategy\JsonGenericParametersHelper.vb" />
<Compile Include="GeneralParametersStrategy\JsonParameters.vb" />
<Compile Include="GeneralParametersStrategy\JsonParametersHelper.vb" />
<Compile Include="GeneralParametersStrategy\ProjectParametersV.xaml.vb">
<DependentUpon>ProjectParametersV.xaml</DependentUpon>
</Compile>
<Compile Include="MachinePanel\MachinePanelV.xaml.vb">
<DependentUpon>MachinePanelV.xaml</DependentUpon>
</Compile>
<Compile Include="NestingRunningWnd\NestingRunningWndVM.vb" /> <Compile Include="NestingRunningWnd\NestingRunningWndVM.vb" />
<Compile Include="NestingRunningWnd\NestingRunningWndV.xaml.vb"> <Compile Include="NestingRunningWnd\OnlyProdNestingRunningWndV.xaml.vb">
<DependentUpon>NestingRunningWndV.xaml</DependentUpon> <DependentUpon>OnlyProdNestingRunningWndV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="NewOpenProjectFileDialog\NewOpenProjectFileDialogVM.vb" /> <Compile Include="NewOpenProjectFileDialog\NewOpenProjectFileDialogVM.vb" />
<Compile Include="ProdManager\ProdManagerV.xaml.vb"> <Compile Include="OnlyProdManager\OnlyProdManagerV.vb" />
<DependentUpon>ProdManagerV.xaml</DependentUpon> <Compile Include="OnlyProdManager\OnlyProdManagerVM.vb" />
</Compile> <Compile Include="OnlyProdProject\OnlyProdProjectV.xaml.vb">
<Compile Include="ProdManager\ProdManagerVM.vb" /> <DependentUpon>OnlyProdProjectV.xaml</DependentUpon>
<Compile Include="Project\ProjectV.xaml.vb">
<DependentUpon>ProjectV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="OpenProjectFileDialog\OpenProjectFileDialogVM.vb" /> <Compile Include="OpenProjectFileDialog\OpenProjectFileDialogVM.vb" />
<Compile Include="OptimizePanel\OptimizePanelV.xaml.vb"> <Compile Include="OptimizePanel\OnlyProdOptimizePanelV.xaml.vb">
<DependentUpon>OptimizePanelV.xaml</DependentUpon> <DependentUpon>OnlyProdOptimizePanelV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="OptimizePanel\OptimizePanelVM.vb" /> <Compile Include="OptimizePanel\OptimizePanelVM.vb" />
<Compile Include="PartManager\PartManagerV.xaml.vb"> <Compile Include="PartManager\OnlyProdPartManagerV.xaml.vb">
<DependentUpon>PartManagerV.xaml</DependentUpon> <DependentUpon>OnlyProdPartManagerV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="PartManager\PartManagerVM.vb" /> <Compile Include="PartManager\PartManagerVM.vb" />
<Compile Include="PartParametersWnd\PartParametersWndV.xaml.vb"> <Compile Include="PartParametersWnd\PartParametersWndV.xaml.vb">
@@ -198,72 +152,56 @@
<Compile Include="ProjectFileVM\ProdFileVM.vb" /> <Compile Include="ProjectFileVM\ProdFileVM.vb" />
<Compile Include="ProjectFileVM\ProjFileVM.vb" /> <Compile Include="ProjectFileVM\ProjFileVM.vb" />
<Compile Include="ProjectManager\ProjectManagerVM.vb" /> <Compile Include="ProjectManager\ProjectManagerVM.vb" />
<Compile Include="ProjectTypeWnd\OnlyProdProjectTypeWndV.xaml.vb">
<DependentUpon>OnlyProdProjectTypeWndV.xaml</DependentUpon>
</Compile>
<Compile Include="ProjectTypeWnd\ProjectTypeWndV.xaml.vb"> <Compile Include="ProjectTypeWnd\ProjectTypeWndV.xaml.vb">
<DependentUpon>ProjectTypeWndV.xaml</DependentUpon> <DependentUpon>ProjectTypeWndV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="ProjectTypeWnd\ProjectTypeWndVM.vb" /> <Compile Include="ProjectTypeWnd\ProjectTypeWndVM.vb" />
<Compile Include="Project\ProjectVM.vb" /> <Compile Include="Project\ProjectVM.vb" />
<Compile Include="RawPartManager\RawPartManagerV.xaml.vb"> <Compile Include="RawPartManager\OnlyProdRawPartManagerV.xaml.vb">
<DependentUpon>RawPartManagerV.xaml</DependentUpon> <DependentUpon>OnlyProdRawPartManagerV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="RawPartManager\RawPartManagerVM.vb" /> <Compile Include="RawPartManager\RawPartManagerVM.vb" />
<Compile Include="RawPartManager\RawPartManagerWndV.xaml.vb"> <Compile Include="RawPartManager\RawPartManagerWndV.xaml.vb">
<DependentUpon>RawPartManagerWndV.xaml</DependentUpon> <DependentUpon>RawPartManagerWndV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="SaveAsStrategyWnd\SaveAsStrategyV.xaml.vb">
<DependentUpon>SaveAsStrategyV.xaml</DependentUpon>
</Compile>
<Compile Include="SaveAsStrategyWnd\SaveAsStrategyVM.vb" />
<Compile Include="SceneHost\MySceneHostVM.vb" /> <Compile Include="SceneHost\MySceneHostVM.vb" />
<Compile Include="SceneHost\SceneHostV.xaml.vb"> <Compile Include="SceneHost\SceneHostV.xaml.vb">
<DependentUpon>SceneHostV.xaml</DependentUpon> <DependentUpon>SceneHostV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="SceneShowBulding\SceneBuildingV.xaml.vb">
<DependentUpon>SceneBuildingV.xaml</DependentUpon>
</Compile>
<Compile Include="SceneShowBulding\SceneBuildingVM.vb" />
<Compile Include="SceneShowBulding\SceneShowBuldingV.xaml.vb">
<DependentUpon>SceneShowBuldingV.xaml</DependentUpon>
</Compile>
<Compile Include="SceneShowBulding\SceneShowBuldingVM.vb" />
<Compile Include="SceneShowBulding\ViewPanelShowBuildingVM.vb" />
<Compile Include="SetUp\SetUpSupportClass.vb" /> <Compile Include="SetUp\SetUpSupportClass.vb" />
<Compile Include="SetUp\SetUpV.xaml.vb"> <Compile Include="SetUp\SetUpV.xaml.vb">
<DependentUpon>SetUpV.xaml</DependentUpon> <DependentUpon>SetUpV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="SetUp\SetUpVM.vb" /> <Compile Include="SetUp\SetUpVM.vb" />
<Compile Include="ShowBeamPanel\ShowBeamPanelV.xaml.vb"> <Compile Include="ShowBeamPanel\OnlyProdShowBeamPanelV.xaml.vb">
<DependentUpon>ShowBeamPanelV.xaml</DependentUpon> <DependentUpon>OnlyProdShowBeamPanelV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="ShowBeamPanel\ShowBeamPanelVM.vb" /> <Compile Include="ShowBeamPanel\ShowBeamPanelVM.vb" />
<Compile Include="ShowPanel\ShowPanelV.xaml.vb"> <Compile Include="ShowPanel\OnlyProdShowPanelV.xaml.vb">
<DependentUpon>ShowPanelV.xaml</DependentUpon> <DependentUpon>OnlyProdShowPanelV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="SpecialPanel\SpecialPanelV.xaml.vb"> <Compile Include="SpecialPanel\OnlyProdSpecialPanelV.xaml.vb">
<DependentUpon>SpecialPanelV.xaml</DependentUpon> <DependentUpon>OnlyProdSpecialPanelV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="SpecialPanel\SpecialPanelVM.vb" /> <Compile Include="SpecialPanel\SpecialPanelVM.vb" />
<Compile Include="SplashScreen\SplashScreenV.xaml.vb"> <Compile Include="StatisticsTimePanel\OnlyProdStatisticsTimePanelV.xaml.vb">
<DependentUpon>SplashScreenV.xaml</DependentUpon> <DependentUpon>OnlyProdStatisticsTimePanelV.xaml</DependentUpon>
</Compile>
<Compile Include="StatisticsTimePanel\StatisticsTimePanelV.xaml.vb">
<DependentUpon>StatisticsTimePanelV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="StatisticsTimePanel\StatisticsTimePanelVM.vb" /> <Compile Include="StatisticsTimePanel\StatisticsTimePanelVM.vb" />
<Compile Include="StatisticsWnd\OptimizerStatisticsWndV.xaml.vb"> <Compile Include="StatisticsWnd\OptimizerStatisticsWndV.xaml.vb">
<DependentUpon>OptimizerStatisticsWndV.xaml</DependentUpon> <DependentUpon>OptimizerStatisticsWndV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="StatisticsWnd\StatisticsWndV.xaml.vb"> <Compile Include="Statistics\OnlyProdOptimizerStatisticsV.xaml.vb">
<DependentUpon>StatisticsWndV.xaml</DependentUpon> <DependentUpon>OnlyProdOptimizerStatisticsV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="Statistics\OptimizerStatisticsV.xaml.vb"> <Compile Include="Statistics\OnlyProdPDFEditorV.xaml.vb">
<DependentUpon>OptimizerStatisticsV.xaml</DependentUpon> <DependentUpon>OnlyProdPDFEditorV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="Statistics\PDFEditorV.xaml.vb"> <Compile Include="Statistics\OnlyProdStatisticsV.xaml.vb">
<DependentUpon>PDFEditorV.xaml</DependentUpon> <DependentUpon>OnlyProdStatisticsV.xaml</DependentUpon>
</Compile>
<Compile Include="Statistics\StatisticsV.xaml.vb">
<DependentUpon>StatisticsV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="Statistics\PDFEditorVM.vb" /> <Compile Include="Statistics\PDFEditorVM.vb" />
<Compile Include="Statistics\PDFHelper.vb" /> <Compile Include="Statistics\PDFHelper.vb" />
@@ -273,35 +211,27 @@
<Compile Include="StatusBar\StatusBarV.xaml.vb"> <Compile Include="StatusBar\StatusBarV.xaml.vb">
<DependentUpon>StatusBarV.xaml</DependentUpon> <DependentUpon>StatusBarV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="StrategyManager\JsonAvailableStrategyHelper.vb" /> <Compile Include="StrategyManagerWnd\StrategyManagerWndV.xaml.vb">
<Compile Include="StrategyManager\JsonStrategyHelper.vb" /> <DependentUpon>StrategyManagerWndV.xaml</DependentUpon>
<Compile Include="StrategyManager\ParameterStrategyV.xaml.vb">
<DependentUpon>ParameterStrategyV.xaml</DependentUpon>
</Compile>
<Compile Include="StrategyManager\StrategyManagerV.xaml.vb">
<DependentUpon>StrategyManagerV.xaml</DependentUpon>
</Compile>
<Compile Include="StrategyManager\StrategyManagerVM.vb" />
<Compile Include="StrategyManager\StrategyProductionV.xaml.vb">
<DependentUpon>StrategyProductionV.xaml</DependentUpon>
</Compile>
<Compile Include="StrategyManager\StrategyV.xaml.vb">
<DependentUpon>StrategyV.xaml</DependentUpon>
</Compile>
<Compile Include="StrategyManager\UserAdminV.xaml.vb">
<DependentUpon>UserAdminV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="StrategyManagerWnd\StrategyManagerWndVM.vb" />
<Compile Include="SupervisorCommThread\SupervisorComm.vb" /> <Compile Include="SupervisorCommThread\SupervisorComm.vb" />
<Compile Include="SupervisorCommThread\SupervisorCommThread.vb" /> <Compile Include="SupervisorCommThread\SupervisorCommThread.vb" />
<Compile Include="ToolsDbWindow\MyToolDbWindowVM.vb" /> <Compile Include="ToolsDbWindow\MyToolDbWindowVM.vb" />
<Compile Include="ToolsDbWindow\ToolsUpdate.vb" /> <Compile Include="ToolsDbWindow\ToolsUpdate.vb" />
<Compile Include="UpdateBTLWnd\OnlyProdUpdateBTLWndV.xaml.vb">
<DependentUpon>OnlyProdUpdateBTLWndV.xaml</DependentUpon>
</Compile>
<Compile Include="UpdateBTLWnd\OnlyProdUpdateOrAppendWndV.xaml.vb">
<DependentUpon>OnlyProdUpdateOrAppendWndV.xaml</DependentUpon>
</Compile>
<Compile Include="UpdateBTLWnd\UpdateBTLWndV.xaml.vb"> <Compile Include="UpdateBTLWnd\UpdateBTLWndV.xaml.vb">
<DependentUpon>UpdateBTLWndV.xaml</DependentUpon> <DependentUpon>UpdateBTLWndV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="UpdateBTLWnd\UpdateBTLWndVM.vb" />
<Compile Include="UpdateBTLWnd\UpdateOrAppendWndV.xaml.vb"> <Compile Include="UpdateBTLWnd\UpdateOrAppendWndV.xaml.vb">
<DependentUpon>UpdateOrAppendWndV.xaml</DependentUpon> <DependentUpon>UpdateOrAppendWndV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="UpdateBTLWnd\UpdateBTLWndVM.vb" />
<Compile Include="UpdateBTLWnd\UpdateOrAppendWndVM.vb" /> <Compile Include="UpdateBTLWnd\UpdateOrAppendWndVM.vb" />
<Compile Include="Utility\Configuration.vb" /> <Compile Include="Utility\Configuration.vb" />
<Compile Include="Utility\CurrentMachine.vb" /> <Compile Include="Utility\CurrentMachine.vb" />
@@ -313,19 +243,16 @@
<Compile Include="Utility\LuaExec.vb" /> <Compile Include="Utility\LuaExec.vb" />
<Compile Include="Utility\MachParamIniFile.vb" /> <Compile Include="Utility\MachParamIniFile.vb" />
<Compile Include="Utility\Map.vb" /> <Compile Include="Utility\Map.vb" />
<Compile Include="Utility\MapV.vb" />
<Compile Include="Utility\MyMachine.vb" />
<Compile Include="Utility\PartsObservableCollection.vb" /> <Compile Include="Utility\PartsObservableCollection.vb" />
<Compile Include="Utility\SectionXMaterialToBeAdded.vb" /> <Compile Include="Utility\SectionXMaterialToBeAdded.vb" />
<Compile Include="Utility\Statistic_Messages.vb" /> <Compile Include="Utility\Statistic_Messages.vb" />
<Compile Include="Utility\TextBlockUtils.vb" /> <Compile Include="Utility\TextBlockUtils.vb" />
<Compile Include="Utility\TreeHelperManager.vb" />
<Compile Include="Utility\TreeViewItemBase.vb" /> <Compile Include="Utility\TreeViewItemBase.vb" />
<Compile Include="ViewPanel\ViewPanelV.xaml.vb"> <Compile Include="ViewPanel\OnlyProdViewPanelV.xaml.vb">
<DependentUpon>ViewPanelV.xaml</DependentUpon> <DependentUpon>OnlyProdViewPanelV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="WarehouseWnd\WarehouseWndV.xaml.vb"> <Compile Include="WarehouseWnd\OnlyProdWarehouseWndV.xaml.vb">
<DependentUpon>WarehouseWndV.xaml</DependentUpon> <DependentUpon>OnlyProdWarehouseWndV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="WarehouseWnd\WarehouseHelper.vb" /> <Compile Include="WarehouseWnd\WarehouseHelper.vb" />
<Compile Include="WarehouseWnd\WarehouseWndVM.vb" /> <Compile Include="WarehouseWnd\WarehouseWndVM.vb" />
@@ -359,16 +286,16 @@
</Compile> </Compile>
<Compile Include="BTLDataWnd\BTLDataWndVM.vb" /> <Compile Include="BTLDataWnd\BTLDataWndVM.vb" />
<Compile Include="BTLPartManager\BTLPartManagerVM.vb" /> <Compile Include="BTLPartManager\BTLPartManagerVM.vb" />
<Compile Include="BTLPartManager\BTLPartManagerV.xaml.vb"> <Compile Include="BTLPartManager\OnlyProdBTLPartManagerV.xaml.vb">
<DependentUpon>BTLPartManagerV.xaml</DependentUpon> <DependentUpon>OnlyProdBTLPartManagerV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="BTLViewModel\BTLFeatureVM.vb" /> <Compile Include="BTLViewModel\BTLFeatureVM.vb" />
<Compile Include="BTLViewModel\BTLParamVM.vb" /> <Compile Include="BTLViewModel\BTLParamVM.vb" />
<Compile Include="BTLViewModel\BTLPartVM.vb" /> <Compile Include="BTLViewModel\BTLPartVM.vb" />
<Compile Include="BTLViewModel\BTLStructureVM.vb" /> <Compile Include="BTLViewModel\BTLStructureVM.vb" />
<Compile Include="CALCPanel\CALCPanelVM.vb" /> <Compile Include="CALCPanel\CALCPanelVM.vb" />
<Compile Include="CALCPanel\CalcPanelV.xaml.vb"> <Compile Include="CALCPanel\OnlyProdCalcPanelV.xaml.vb">
<DependentUpon>CalcPanelV.xaml</DependentUpon> <DependentUpon>OnlyProdCalcPanelV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="ChangeMaterialWnd\ChangeMaterialWndV.xaml.vb"> <Compile Include="ChangeMaterialWnd\ChangeMaterialWndV.xaml.vb">
<DependentUpon>ChangeMaterialWndV.xaml</DependentUpon> <DependentUpon>ChangeMaterialWndV.xaml</DependentUpon>
@@ -379,84 +306,107 @@
</Compile> </Compile>
<Compile Include="ChangeParameterWnd\ChangeParameterWndVM.vb" /> <Compile Include="ChangeParameterWnd\ChangeParameterWndVM.vb" />
<Compile Include="ConfigurationPage\ConfigurationPageVM.vb" /> <Compile Include="ConfigurationPage\ConfigurationPageVM.vb" />
<Compile Include="ConfigurationPage\ConfigurationPageV.xaml.vb"> <Compile Include="ConfigurationPage\OnlyProdCheckVersionV.xaml.vb">
<DependentUpon>ConfigurationPageV.xaml</DependentUpon> <DependentUpon>OnlyProdCheckVersionV.xaml</DependentUpon>
</Compile>
<Compile Include="ConfigurationPage\OnlyProdConfigurationPageV.xaml.vb">
<DependentUpon>OnlyProdConfigurationPageV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="Constants\ConstWarehouseIni.vb" /> <Compile Include="Constants\ConstWarehouseIni.vb" />
<Compile Include="DataGridMultiselectManaging\IListItemConverter.vb" /> <Compile Include="DataGridMultiselectManaging\IListItemConverter.vb" />
<Compile Include="DataGridMultiselectManaging\MultiSelectorBehaviours.vb" /> <Compile Include="DataGridMultiselectManaging\MultiSelectorBehaviours.vb" />
<Compile Include="DataGridMultiselectManaging\TwoListSynchronizer.vb" /> <Compile Include="DataGridMultiselectManaging\TwoListSynchronizer.vb" />
<Compile Include="FeatureListManager\FeatureListManagerVM.vb" /> <Compile Include="FeatureListManager\FeatureListManagerVM.vb" />
<Compile Include="FeatureListManager\FeatureListManagerV.xaml.vb"> <Compile Include="FeatureListManager\OnlyProdFeatureListManagerV.xaml.vb">
<DependentUpon>FeatureListManagerV.xaml</DependentUpon> <DependentUpon>OnlyProdFeatureListManagerV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="FeatureManager\FeatureManagerVM.vb" /> <Compile Include="FeatureManager\FeatureManagerVM.vb" />
<Compile Include="FeatureManager\FeatureManagerV.xaml.vb"> <Compile Include="FeatureManager\OnlyProdFeatureManagerV.xaml.vb">
<DependentUpon>FeatureManagerV.xaml</DependentUpon> <DependentUpon>OnlyProdFeatureManagerV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="FreeContourInput\FreeContourInputVM.vb" /> <Compile Include="FreeContourInput\FreeContourInputVM.vb" />
<Compile Include="FreeContourInput\FreeContourInputV.xaml.vb"> <Compile Include="FreeContourInput\OnlyProdFreeContourInputV.xaml.vb">
<DependentUpon>FreeContourInputV.xaml</DependentUpon> <DependentUpon>OnlyProdFreeContourInputV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="FreeContourManager\FreeContourManagerVM.vb" /> <Compile Include="FreeContourManager\FreeContourManagerVM.vb" />
<Compile Include="FreeContourManager\FreeContourManagerV.xaml.vb"> <Compile Include="FreeContourManager\OnlyProdFreeContourManagerV.xaml.vb">
<DependentUpon>FreeContourManagerV.xaml</DependentUpon> <DependentUpon>OnlyProdFreeContourManagerV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="InputPwdWnd\InputPwdWndVM.vb" /> <Compile Include="InputPwdWnd\InputPwdWndVM.vb" />
<Compile Include="InputPwdWnd\InputPwdWndV.xaml.vb"> <Compile Include="InputPwdWnd\OnlyProdInputPwdWndV.xaml.vb">
<DependentUpon>InputPwdWndV.xaml</DependentUpon> <DependentUpon>OnlyProdInputPwdWndV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="InstrumentPanel\MyInstrumentPanelVM.vb" /> <Compile Include="InstrumentPanel\MyInstrumentPanelVM.vb" />
<Compile Include="InstrumentPanel\InstrumentPanelV.xaml.vb"> <Compile Include="InstrumentPanel\OnlyProdInstrumentPanelV.xaml.vb">
<DependentUpon>InstrumentPanelV.xaml</DependentUpon> <DependentUpon>OnlyProdInstrumentPanelV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="ItemParamList\BTLDataV.xaml.vb"> <Compile Include="ItemParamList\BTLDataV.xaml.vb">
<DependentUpon>BTLDataV.xaml</DependentUpon> <DependentUpon>BTLDataV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="ItemParamList\BTLPartListVM.vb" /> <Compile Include="ItemParamList\BTLPartListVM.vb" />
<Compile Include="ItemParamList\DuploQParameterListVM.vb" />
<Compile Include="ItemParamList\FeatureInPartInRawPartListVM.vb" /> <Compile Include="ItemParamList\FeatureInPartInRawPartListVM.vb" />
<Compile Include="ItemParamList\BTLPartListV.xaml.vb"> <Compile Include="ItemParamList\FeatureListVM.vb" />
<DependentUpon>BTLPartListV.xaml</DependentUpon> <Compile Include="ItemParamList\OnlyProdBTLPartListV.xaml.vb">
<DependentUpon>OnlyProdBTLPartListV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="ItemParamList\FeatureInPartInRawPartListV.xaml.vb"> <Compile Include="ItemParamList\OnlyProdFeatureInPartInRawPartListV.xaml.vb">
<DependentUpon>FeatureInPartInRawPartListV.xaml</DependentUpon> <DependentUpon>OnlyProdFeatureInPartInRawPartListV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="ItemParamList\PParameterListV.xaml.vb"> <Compile Include="ItemParamList\OnlyProdFeatureListV.xaml.vb">
<DependentUpon>PParameterListV.xaml</DependentUpon> <DependentUpon>OnlyProdFeatureListV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="ItemParamList\RawPartListV.xaml.vb"> <Compile Include="ItemParamList\OnlyProdPartInRawPartListV.xaml.vb">
<DependentUpon>RawPartListV.xaml</DependentUpon> <DependentUpon>OnlyProdPartInRawPartListV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="ItemParamList\OnlyProdPParameterListV.xaml.vb">
<DependentUpon>OnlyProdPParameterListV.xaml</DependentUpon>
</Compile>
<Compile Include="ItemParamList\OnlyProdQParameterListProdV.xaml.vb">
<DependentUpon>OnlyProdQParameterListProdV.xaml</DependentUpon>
</Compile>
<Compile Include="ItemParamList\OnlyProdQParameterListV.xaml.vb">
<DependentUpon>OnlyProdQParameterListV.xaml</DependentUpon>
</Compile>
<Compile Include="ItemParamList\OnlyProdRawPartListV.xaml.vb">
<DependentUpon>OnlyProdRawPartListV.xaml</DependentUpon>
</Compile>
<Compile Include="ItemParamList\PartInRawPartListVM.vb" />
<Compile Include="ItemParamList\PartParametersV.xaml.vb"> <Compile Include="ItemParamList\PartParametersV.xaml.vb">
<DependentUpon>PartParametersV.xaml</DependentUpon> <DependentUpon>PartParametersV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="ItemParamList\PartParametersVM.vb" /> <Compile Include="ItemParamList\PartParametersVM.vb" />
<Compile Include="ItemParamList\PParameterListVM.vb" /> <Compile Include="ItemParamList\PParameterListVM.vb" />
<Compile Include="ItemParamList\QBTLParamVM.vb" />
<Compile Include="ItemParamList\QParameterListVM.vb" />
<Compile Include="ItemParamList\QParamListV.xaml.vb">
<DependentUpon>QParamListV.xaml</DependentUpon>
</Compile>
<Compile Include="ItemParamList\RawPartListVM.vb" /> <Compile Include="ItemParamList\RawPartListVM.vb" />
<Compile Include="LeftPanel\LeftPanelVM.vb" /> <Compile Include="LeftPanel\LeftPanelVM.vb" />
<Compile Include="LeftPanel\LeftPanelV.xaml.vb"> <Compile Include="LeftPanel\OnlyProdLeftPanelV.xaml.vb">
<DependentUpon>LeftPanelV.xaml</DependentUpon> <DependentUpon>OnlyProdLeftPanelV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="MachGroupPanel\MyMachGroupPanelVM.vb" /> <Compile Include="MachGroupPanel\MyMachGroupPanelVM.vb" />
<Compile Include="MachGroupPanel\MyMachGroupVM.vb" /> <Compile Include="MachGroupPanel\MyMachGroupVM.vb" />
<Compile Include="MachGroupPanel\PartVM.vb" /> <Compile Include="MachGroupPanel\PartVM.vb" />
<Compile Include="MachinePanel\MachinePanelVM.vb" /> <Compile Include="MachinePanel\MachinePanelVM.vb" />
<Compile Include="MacroFeatureWnd\MacroFeatureWndVM.vb" /> <Compile Include="MacroFeatureWnd\MacroFeatureWndVM.vb" />
<Compile Include="MacroFeatureWnd\MacroFeatureWnd.xaml.vb"> <Compile Include="MacroFeatureWnd\NewMacroFeatureWnd.xaml.vb">
<DependentUpon>MacroFeatureWnd.xaml</DependentUpon> <DependentUpon>NewMacroFeatureWnd.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="MainMenu\MainMenuVM.vb" /> <Compile Include="MainMenu\MainMenuVM.vb" />
<Compile Include="MainMenu\MainMenuV.xaml.vb"> <Compile Include="MainMenu\OnlyProdMainMenuV.xaml.vb">
<DependentUpon>MainMenuV.xaml</DependentUpon> <DependentUpon>OnlyProdMainMenuV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="MainWindow\MainWindowM.vb" /> <Compile Include="MainWindow\MainWindowM.vb" />
<Compile Include="MainWindow\MainWindowVM.vb" /> <Compile Include="MainWindow\MainWindowVM.vb" />
<Compile Include="MainWindow\MainWindowV.xaml.vb"> <Compile Include="MainWindow\OnlyProdMainWindowV.xaml.vb">
<DependentUpon>MainWindowV.xaml</DependentUpon> <DependentUpon>OnlyProdMainWindowV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="MovePartInRawPartWnd\MovePartInRawPartWndVM.vb" /> <Compile Include="MovePartInRawPartWnd\MovePartInRawPartWndVM.vb" />
<Compile Include="MovePartInRawPartWnd\MovePartInRawPartWndV.xaml.vb"> <Compile Include="MovePartInRawPartWnd\OnlyProdMovePartInRawPartWndV.xaml.vb">
<DependentUpon>MovePartInRawPartWndV.xaml</DependentUpon> <DependentUpon>OnlyProdMovePartInRawPartWndV.xaml</DependentUpon>
</Compile> </Compile>
<Compile Include="MultiCopyRawPartWnd\MultiCopyRawPartWndV.xaml.vb"> <Compile Include="MultiCopyRawPartWnd\MultiCopyRawPartWndV.xaml.vb">
<DependentUpon>MultiCopyRawPartWndV.xaml</DependentUpon> <DependentUpon>MultiCopyRawPartWndV.xaml</DependentUpon>
@@ -497,15 +447,15 @@
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="AddFeatureWnd\AddFeatureWndV.xaml"> <Page Include="AddFeatureWnd\NewAddFeatureWndV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="AddPartWnd\AddPartWndV.xaml"> <Page Include="AddPartWnd\OnlyProdAddPartWndV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="AddRawPartWnd\AddRawPartWndV.xaml"> <Page Include="AddRawPartWnd\OnlyProdAddRawPartWndV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
@@ -521,11 +471,11 @@
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="BTLPartManager\BTLPartManagerV.xaml"> <Page Include="BTLPartManager\OnlyProdBTLPartManagerV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="CALCPanel\CalcPanelV.xaml"> <Page Include="CALCPanel\OnlyProdCalcPanelV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
@@ -537,55 +487,35 @@
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="ConfigurationPage\ConfigurationProgramV.xaml"> <Page Include="ConfigurationPage\OnlyProdCheckVersionV.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="ConfigurationPage\ConfigurationPageV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="FeatureListManager\FeatureListManagerV.xaml"> <Page Include="ConfigurationPage\OnlyProdConfigurationPageV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="FeatureManager\FeatureManagerV.xaml"> <Page Include="FeatureListManager\OnlyProdFeatureListManagerV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="ForcedStrategyBTL\ForcedStrategyBTLV.xaml"> <Page Include="FeatureManager\OnlyProdFeatureManagerV.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="ForcedStrategyPanel\ForcedStrategyPanelV.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="FreeContourInput\FreeContourInputV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="FreeContourManager\FreeContourManagerV.xaml"> <Page Include="FreeContourInput\OnlyProdFreeContourInputV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="GeneralParametersStrategy\GeneralParametersStrategyV.xaml"> <Page Include="FreeContourManager\OnlyProdFreeContourManagerV.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="GeneralParametersStrategy\GeneralParametersWnd.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="GeneralParametersStrategy\ProjectParametersV.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="InputPwdWnd\InputPwdWndV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="InstrumentPanel\InstrumentPanelV.xaml"> <Page Include="InputPwdWnd\OnlyProdInputPwdWndV.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Page Include="InstrumentPanel\OnlyProdInstrumentPanelV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
@@ -593,19 +523,35 @@
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="ItemParamList\BTLPartListV.xaml"> <Page Include="ItemParamList\OnlyProdBTLPartListV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="ItemParamList\FeatureInPartInRawPartListV.xaml"> <Page Include="ItemParamList\OnlyProdFeatureInPartInRawPartListV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="ItemParamList\PParameterListV.xaml"> <Page Include="ItemParamList\OnlyProdFeatureListV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="ItemParamList\RawPartListV.xaml"> <Page Include="ItemParamList\OnlyProdPartInRawPartListV.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Page Include="ItemParamList\OnlyProdPParameterListV.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Page Include="ItemParamList\OnlyProdQParameterListProdV.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Page Include="ItemParamList\OnlyProdQParameterListV.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Page Include="ItemParamList\OnlyProdRawPartListV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
@@ -613,27 +559,27 @@
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="LeftPanel\LeftPanelV.xaml"> <Page Include="ItemParamList\QParamListV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="MachinePanel\MachinePanelV.xaml"> <Page Include="LeftPanel\OnlyProdLeftPanelV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="MacroFeatureWnd\MacroFeatureWnd.xaml"> <Page Include="MacroFeatureWnd\NewMacroFeatureWnd.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="MainMenu\MainMenuV.xaml"> <Page Include="MainMenu\OnlyProdMainMenuV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="MainWindow\MainWindowV.xaml"> <Page Include="MainWindow\OnlyProdMainWindowV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="MovePartInRawPartWnd\MovePartInRawPartWndV.xaml"> <Page Include="MovePartInRawPartWnd\OnlyProdMovePartInRawPartWndV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
@@ -641,23 +587,23 @@
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="NestingRunningWnd\NestingRunningWndV.xaml"> <Page Include="NestingRunningWnd\OnlyProdNestingRunningWndV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="ProdManager\ProdManagerV.xaml"> <Page Include="OnlyProdManager\OnlyProdManagerV.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="Project\ProjectV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="OptimizePanel\OptimizePanelV.xaml"> <Page Include="OnlyProdProject\OnlyProdProjectV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="PartManager\PartManagerV.xaml"> <Page Include="OptimizePanel\OnlyProdOptimizePanelV.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Page Include="PartManager\OnlyProdPartManagerV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
@@ -669,11 +615,15 @@
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="ProjectTypeWnd\ProjectTypeWndV.xaml"> <Page Include="ProjectTypeWnd\OnlyProdProjectTypeWndV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="RawPartManager\RawPartManagerV.xaml"> <Page Include="ProjectTypeWnd\ProjectTypeWndV.xaml">
<SubType>Designer</SubType>
<Generator>XamlIntelliSenseFileGenerator</Generator>
</Page>
<Page Include="RawPartManager\OnlyProdRawPartManagerV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
@@ -681,43 +631,27 @@
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="SaveAsStrategyWnd\SaveAsStrategyV.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="SceneHost\SceneHostV.xaml"> <Page Include="SceneHost\SceneHostV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="SceneShowBulding\SceneBuildingV.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="SceneShowBulding\SceneShowBuldingV.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="SetUp\SetUpV.xaml"> <Page Include="SetUp\SetUpV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="ShowBeamPanel\ShowBeamPanelV.xaml"> <Page Include="ShowBeamPanel\OnlyProdShowBeamPanelV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="ShowPanel\ShowPanelV.xaml"> <Page Include="ShowPanel\OnlyProdShowPanelV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="SpecialPanel\SpecialPanelV.xaml"> <Page Include="SpecialPanel\OnlyProdSpecialPanelV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="SplashScreen\SplashScreenV.xaml"> <Page Include="StatisticsTimePanel\OnlyProdStatisticsTimePanelV.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="StatisticsTimePanel\StatisticsTimePanelV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
@@ -725,19 +659,15 @@
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="StatisticsWnd\StatisticsWndV.xaml"> <Page Include="Statistics\OnlyProdOptimizerStatisticsV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="Statistics\OptimizerStatisticsV.xaml"> <Page Include="Statistics\OnlyProdPDFEditorV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="Statistics\PDFEditorV.xaml"> <Page Include="Statistics\OnlyProdStatisticsV.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Page Include="Statistics\StatisticsV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
@@ -745,43 +675,35 @@
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="StrategyManager\ParameterStrategyV.xaml"> <Page Include="StrategyManagerWnd\StrategyManagerWndV.xaml">
<SubType>Designer</SubType> <SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
</Page> </Page>
<Page Include="StrategyManager\StrategyManagerV.xaml"> <Page Include="UpdateBTLWnd\OnlyProdUpdateBTLWndV.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page> </Page>
<Page Include="StrategyManager\StrategyProductionV.xaml"> <Page Include="UpdateBTLWnd\OnlyProdUpdateOrAppendWndV.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="StrategyManager\StrategyV.xaml">
<SubType>Designer</SubType> <SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="StrategyManager\UserAdminV.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page> </Page>
<Page Include="UpdateBTLWnd\UpdateBTLWndV.xaml"> <Page Include="UpdateBTLWnd\UpdateBTLWndV.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
<Generator>XamlIntelliSenseFileGenerator</Generator>
</Page> </Page>
<Page Include="UpdateBTLWnd\UpdateOrAppendWndV.xaml"> <Page Include="UpdateBTLWnd\UpdateOrAppendWndV.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
<Generator>XamlIntelliSenseFileGenerator</Generator>
</Page> </Page>
<Page Include="Utility\Dictionary.xaml"> <Page Include="Utility\Dictionary.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="ViewPanel\ViewPanelV.xaml"> <Page Include="ViewPanel\OnlyProdViewPanelV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
<Page Include="WarehouseWnd\WarehouseWndV.xaml"> <Page Include="WarehouseWnd\OnlyProdWarehouseWndV.xaml">
<Generator>MSBuild:Compile</Generator> <Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType> <SubType>Designer</SubType>
</Page> </Page>
@@ -952,7 +874,9 @@
<Resource Include="Resources\ViewPanel\ZoomIn.png" /> <Resource Include="Resources\ViewPanel\ZoomIn.png" />
<Resource Include="Resources\ViewPanel\ZoomOut.png" /> <Resource Include="Resources\ViewPanel\ZoomOut.png" />
</ItemGroup> </ItemGroup>
<ItemGroup /> <ItemGroup>
<Folder Include="Behavior\" />
</ItemGroup>
<ItemGroup> <ItemGroup>
<PackageReference Include="BouncyCastle"> <PackageReference Include="BouncyCastle">
<Version>1.8.5</Version> <Version>1.8.5</Version>
@@ -960,15 +884,6 @@
<PackageReference Include="DotNetZip"> <PackageReference Include="DotNetZip">
<Version>1.16.0</Version> <Version>1.16.0</Version>
</PackageReference> </PackageReference>
<PackageReference Include="EgwMultiEngineManager.Core">
<Version>2.7.10.1</Version>
</PackageReference>
<PackageReference Include="EgwMultiEngineManager.Data">
<Version>2.7.10.1</Version>
</PackageReference>
<PackageReference Include="EgwWPFBaseLib">
<Version>2.7.10-beta.9</Version>
</PackageReference>
<PackageReference Include="EntityFramework"> <PackageReference Include="EntityFramework">
<Version>6.4.4</Version> <Version>6.4.4</Version>
</PackageReference> </PackageReference>
@@ -985,7 +900,7 @@
<Version>8.0.21</Version> <Version>8.0.21</Version>
</PackageReference> </PackageReference>
<PackageReference Include="Newtonsoft.Json"> <PackageReference Include="Newtonsoft.Json">
<Version>13.0.4</Version> <Version>13.0.1</Version>
</PackageReference> </PackageReference>
<PackageReference Include="NLog"> <PackageReference Include="NLog">
<Version>5.0.1</Version> <Version>5.0.1</Version>
@@ -1021,123 +936,11 @@
<ItemGroup> <ItemGroup>
<Resource Include="Resources\NewPage\Ok.png" /> <Resource Include="Resources\NewPage\Ok.png" />
</ItemGroup> </ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\+.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\SaveModify.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\LogoProvaStrategy.png" />
</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>
<Resource Include="Resources\NewPage\VerifyIntestazione.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\AddToRawPartIntestazione.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\SettingIntestazione.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\InversionIntestazione.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\Rotate.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\RotateIntestazione.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\ProduceRawPartIntestazione.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\SimulateIntestazione.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\RotateIntestazioneRawPart.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\InversionIntestazioneRawPart.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\Remove.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\MoveDown.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\MoveUp.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\MoveLeft.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\MoveRight.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\Inversion.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\deselectall.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\selectall.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\configuration.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\configurationIsChecked.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\padlock.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\padlock-unlock.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\play.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\add.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\diskette.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\pezzo.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Resources\NewPage\adjustment.png" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.VisualBasic.targets" /> <Import Project="$(MSBuildToolsPath)\Microsoft.VisualBasic.targets" />
<PropertyGroup> <PropertyGroup>
<PostBuildEvent>IF "$(PlatformName)"=="x86" IF "$(ConfigurationName)" == "Release" copy $(TargetPath) c:\EgtProg\EgtBEAMWALL\EgtBEAMWALL.OptimizerR32.exe <PostBuildEvent>IF "$(PlatformName)"=="x86" IF "$(ConfigurationName)" == "Release" copy $(TargetPath) c:\EgtProg\EgtBEAMWALL\EgtBEAMWALL.OptimizerR32.exe
IF "$(PlatformName)"=="x86" IF "$(ConfigurationName)" == "Debug" copy $(TargetPath) c:\EgtProg\EgtBEAMWALL\EgtBEAMWALL.OptimizerD32.exe IF "$(PlatformName)"=="x86" IF "$(ConfigurationName)" == "Debug" copy $(TargetPath) c:\EgtProg\EgtBEAMWALL\EgtBEAMWALL.OptimizerD32.exe
IF "$(PlatformName)"=="x64" IF "$(ConfigurationName)" == "Release" copy $(TargetPath) c:\EgtProg\EgtBEAMWALL\EgtBEAMWALL.OptimizerR64.exe IF "$(PlatformName)"=="x64" IF "$(ConfigurationName)" == "Release" copy $(TargetPath) c:\EgtProg\EgtBEAMWALL\EgtBEAMWALL.OptimizerR64.exe
IF "$(PlatformName)"=="x64" IF "$(ConfigurationName)" == "Debug" copy $(TargetPath) c:\EgtProg\EgtBEAMWALL\EgtBEAMWALL.OptimizerD64.exe IF "$(PlatformName)"=="x64" IF "$(ConfigurationName)" == "Debug" copy $(TargetPath) c:\EgtProg\EgtBEAMWALL\EgtBEAMWALL.OptimizerD64.exe</PostBuildEvent>
IF "$(ConfigurationName)" == "Debug" copy c:\EgtDev\EgtBEAMWALL\EgtBEAMWALL.Optimizer\bin\x86\Debug\EgwMultiEngineManager.Data.dll c:\EgtProg\EgtBEAMWALL\EgwMultiEngineManager.Data.dll
IF "$(ConfigurationName)" == "Release" copy c:\EgtDev\EgtBEAMWALL\EgtBEAMWALL.Optimizer\bin\x86\Release\EgwMultiEngineManager.Data.dll c:\EgtProg\EgtBEAMWALL\EgwMultiEngineManager.Data.dll
IF "$(ConfigurationName)" == "Debug" copy c:\EgtDev\EgtBEAMWALL\EgtBEAMWALL.Optimizer\bin\x86\Debug\EgwMultiEngineManager.Core.dll c:\EgtProg\EgtBEAMWALL\EgwMultiEngineManager.Core.dll
IF "$(ConfigurationName)" == "Release" copy c:\EgtDev\EgtBEAMWALL\EgtBEAMWALL.Optimizer\bin\x86\Release\EgwMultiEngineManager.Core.dll c:\EgtProg\EgtBEAMWALL\EgwMultiEngineManager.Core.dll
IF "$(ConfigurationName)" == "Debug" copy c:\EgtDev\EgtBEAMWALL\EgtBEAMWALL.Optimizer\bin\x86\Debug\EgwWPFBaseLib.dll c:\EgtProg\EgtBEAMWALL\EgwWPFBaseLib.dll
IF "$(ConfigurationName)" == "Release" copy c:\EgtDev\EgtBEAMWALL\EgtBEAMWALL.Optimizer\bin\x86\Release\EgwWPFBaseLib.dll c:\EgtProg\EgtBEAMWALL\EgwWPFBaseLib.dll</PostBuildEvent>
</PropertyGroup>
<PropertyGroup>
<PreBuildEvent>
</PreBuildEvent>
</PropertyGroup> </PropertyGroup>
</Project> </Project>
@@ -1,86 +0,0 @@
Imports System.IO
Imports EgtBEAMWALL.Core.ConstIni
Imports EgtUILib
Imports EgtWPFLib5
Imports EgwMultiEngineManager.Core
Imports EgwMultiEngineManager.Data
Imports EgwMultiEngineManager.Data.Constants
Module MyExecProcessManager
Private m_ExecProcessManagerList As New Dictionary(Of EXECENVIRONMENTS, ExecProcessManager)
Public ReadOnly Property ExecProcessManagerList As Dictionary(Of EXECENVIRONMENTS, ExecProcessManager)
Get
Return m_ExecProcessManagerList
End Get
End Property
Friend Function Init() As Boolean
' creazione manager dei processi
Dim sCamExePath As String = ""
GetMainPrivateProfileString(S_GENERAL, K_CAMEXEPATH, "", sCamExePath)
EgtOutLog("CAMExePath = " & sCamExePath)
If Not File.Exists(sCamExePath) Then
Dim sMsg As String = "CAMExePath not found!"
EgtOutLog(sMsg)
Return False
End If
Dim sPipeLuaDir As String = ""
GetMainPrivateProfileString(S_GENERAL, K_PIPELUADIR, "", sPipeLuaDir)
EgtOutLog("PipeLuaDir = " & sPipeLuaDir)
If Not File.Exists(sCamExePath) Then
Dim sMsg As String = "PipeLuaDir not found!"
EgtOutLog(sMsg)
Return False
End If
Dim nGroupIndex As Integer = 1
Dim sEnvironment As String = ""
Dim sPipeLuaFile As String = ""
Dim nMaxCamInstances As Integer = 0
While GetMainPrivateProfileString(S_EXECGROUP & nGroupIndex.ToString(), K_ENVIRONMENT, "", sEnvironment) > 0 AndAlso
GetMainPrivateProfileString(S_EXECGROUP & nGroupIndex.ToString(), K_PIPELUAFILE, "", sPipeLuaFile) AndAlso
GetMainPrivateProfileString(S_EXECGROUP & nGroupIndex.ToString(), K_MAXCAMINSTANCES, "", nMaxCamInstances)
System.Console.WriteLine("Group" & nGroupIndex.ToString())
System.Console.WriteLine("Environment = " & sEnvironment)
System.Console.WriteLine("PipeLuaFile = " & sPipeLuaFile)
System.Console.WriteLine("MaxCAMInstances = " & nMaxCamInstances)
Dim Environment As EXECENVIRONMENTS = EXECENVIRONMENTS.NULL
Select Case sEnvironment
Case "BEAM"
Environment = EXECENVIRONMENTS.BEAM
Case "WALL"
Environment = EXECENVIRONMENTS.WALL
End Select
Dim PipeLuaPath As String = sPipeLuaDir & "\" & sPipeLuaFile
If nMaxCamInstances <= 0 OrElse Environment = EXECENVIRONMENTS.NULL OrElse Not File.Exists(PipeLuaPath) Then
System.Console.WriteLine(String.Format("Group{0} not created!", nGroupIndex.ToString()))
nGroupIndex += 1
Continue While
End If
Dim NewExecProcessManager As New ExecProcessManager(nGroupIndex, Environment, sCamExePath, PipeLuaPath, nMaxCamInstances, ExecProcessManager.ReturnModes.EVENT_, False)
AddHandler NewExecProcessManager.m_AnswerReceived, AddressOf ExecProcessManager_AnswerReceived
NewExecProcessManager.StartExecutionThread()
m_ExecProcessManagerList.Add(Environment, NewExecProcessManager)
nGroupIndex += 1
End While
Return True
End Function
Private Sub ExecProcessManager_AnswerReceived(Answer As AnswerDTO)
Dim sBarPath As String = Answer.Args("BarPath")
Dim nProgramPage As Integer = -1
Integer.TryParse(Answer.Args("ProgramPage"), nProgramPage)
Dim nBarId As Integer = -1
Integer.TryParse(Answer.Args("BarId"), nBarId)
EgtOutLog("Risultato progetto " & nBarId)
Map.refCALCPanelVM.ProcessResults(sBarPath, nProgramPage, nBarId)
End Sub
Friend Function Close()
For Each Key In m_ExecProcessManagerList.Keys
m_ExecProcessManagerList(Key).Dispose()
Next
Return True
End Function
End Module
@@ -1,26 +1,36 @@
<StackPanel x:Class="FeatureListManagerV" <StackPanel x:Class="FeatureListManagerV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
DataContext="{StaticResource FeatureListManagerVM}" Orientation="Horizontal"
Style="{StaticResource OnlyProdFeatureListManager_StackPanel}"> HorizontalAlignment="Right"
DataContext="{StaticResource FeatureListManagerVM}">
<Button Command="{Binding CopyFeature_Command}" <Button Command="{Binding CopyFeature_Command}"
Visibility="{Binding ViewPage_Visibility}"
ToolTip="{Binding CopyFeature_ToolTip}" ToolTip="{Binding CopyFeature_ToolTip}"
IsEnabled="{Binding CopyFeature_IsEnabled}" IsEnabled="{Binding CopyFeature_IsEnabled}"
Style="{StaticResource OnlyProdLeftPanel_Button}"> Style="{StaticResource LeftPanel_Button}">
<Image Source="/Resources/LeftPanel/CopyFeature.png" Stretch="Uniform"/> <Image Source="/Resources/LeftPanel/CopyFeature.png" Stretch="Uniform"/>
</Button> </Button>
<Button Command="{Binding MacroFeature_Command}"
Visibility="{Binding ViewPage_Visibility}"
ToolTip="{Binding MacroFeature_ToolTip}"
IsEnabled="{Binding MacroFeature_IsEnabled}"
Style="{StaticResource LeftPanel_Button}">
<Image Source="/Resources/LeftPanel/MacroFeature.png" Stretch="Uniform"/>
</Button>
<Button Command="{Binding AddFeature_Command}" <Button Command="{Binding AddFeature_Command}"
Visibility="{Binding ViewPage_Visibility}"
ToolTip="{Binding AddFeature_ToolTip}" ToolTip="{Binding AddFeature_ToolTip}"
IsEnabled="{Binding AddFeature_IsEnabled}" IsEnabled="{Binding AddFeature_IsEnabled}"
Style="{StaticResource OnlyProdLeftPanel_Button}"> Style="{StaticResource LeftPanel_Button}">
<Image Source="/Resources/LeftPanel/AddFeature.png" Stretch="Uniform"/> <Image Source="/Resources/LeftPanel/AddFeature.png" Stretch="Uniform"/>
</Button> </Button>
<Button Command="{Binding RemoveFeature_Command}" <Button Command="{Binding RemoveFeature_Command}"
Visibility="{Binding ViewPage_Visibility}"
ToolTip="{Binding RemoveFeature_ToolTip}" ToolTip="{Binding RemoveFeature_ToolTip}"
IsEnabled="{Binding RemoveFeature_IsEnabled}" IsEnabled="{Binding RemoveFeature_IsEnabled}"
Style="{StaticResource OnlyProdLeftPanel_Button}"> Style="{StaticResource LeftPanel_Button}">
<Image Source="/Resources/NewPage/Remove.png" Stretch="Uniform"/> <Image Source="/Resources/LeftPanel/RemoveFeature.png" Stretch="Uniform"/>
</Button> </Button>
</StackPanel> </StackPanel>
@@ -7,6 +7,12 @@ Public Class FeatureListManagerVM
#Region "FIELDS & PROPERTIES" #Region "FIELDS & PROPERTIES"
Public ReadOnly Property ViewPage_Visibility As Visibility
Get
Return If(Map.refMainMenuVM.SelPage = Pages.VIEW OrElse Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE, Visibility.Visible, Visibility.Collapsed)
End Get
End Property
Public ReadOnly Property PartIsSelected As Boolean Public ReadOnly Property PartIsSelected As Boolean
Get Get
Return Not IsNothing(Map.refProjectVM) AndAlso Not IsNothing(Map.refProjectVM.BTLStructureVM) AndAlso Not IsNothing(Map.refProjectVM.BTLStructureVM.SelBTLPart) Return Not IsNothing(Map.refProjectVM) AndAlso Not IsNothing(Map.refProjectVM.BTLStructureVM) AndAlso Not IsNothing(Map.refProjectVM.BTLStructureVM.SelBTLPart)
@@ -19,43 +25,39 @@ Public Class FeatureListManagerVM
End Get End Get
End Property End Property
Public ReadOnly Property CopyFeature_IsEnabled As Boolean Public ReadOnly Property CopyFeature_IsEnabled As Boolean
Get Get
If Not IsNothing(Map.refBTLPartManagerVM) Then Return PartIsSelected AndAlso FeatureIsSelected
Return Map.refBTLPartManagerVM.BTLPartManager_IsEnabled AndAlso PartIsSelected AndAlso FeatureIsSelected
End If
Return False
End Get End Get
End Property End Property
Public ReadOnly Property MacroFeature_IsEnabled As Boolean Public ReadOnly Property MacroFeature_IsEnabled As Boolean
Get Get
If Not IsNothing(Map.refBTLPartManagerVM) Then Return PartIsSelected AndAlso FeatureIsSelected
Return Map.refBTLPartManagerVM.BTLPartManager_IsEnabled AndAlso PartIsSelected AndAlso FeatureIsSelected
End If
Return False
End Get End Get
End Property End Property
Public ReadOnly Property AddFeature_IsEnabled As Boolean Public ReadOnly Property AddFeature_IsEnabled As Boolean
Get Get
Return PartIsSelected AndAlso Not IsNothing(Map.refProjectVM.BTLStructureVM) AndAlso Not Map.refProjectVM.BTLStructureVM.SelBTLParts.Count > 1 Return PartIsSelected AndAlso Not IsNothing(Map.refProjectVM.BTLStructureVM) AndAlso Not Map.refProjectVM.BTLStructureVM.SelBTLPartsCnt > 1
End Get End Get
End Property End Property
Public ReadOnly Property RemoveFeature_IsEnabled As Boolean Public ReadOnly Property RemoveFeature_IsEnabled As Boolean
Get Get
If Not IsNothing(Map.refBTLPartManagerVM) Then Return PartIsSelected AndAlso FeatureIsSelected
Return Map.refBTLPartManagerVM.BTLPartManager_IsEnabled AndAlso PartIsSelected AndAlso FeatureIsSelected
End If
Return False
End Get End Get
End Property End Property
Private m_cmdCopyFeature As ICommand Private m_cmdCopyFeature As ICommand
Private m_cmdMacroFeature As ICommand
Private m_cmdAddFeature As ICommand Private m_cmdAddFeature As ICommand
Private m_cmdRemoveFeature As ICommand Private m_cmdRemoveFeature As ICommand
#End Region ' Fields & Properties
#Region "Messages" #Region "Messages"
Public ReadOnly Property CopyFeature_ToolTip As String Public ReadOnly Property CopyFeature_ToolTip As String
@@ -64,6 +66,12 @@ Public Class FeatureListManagerVM
End Get End Get
End Property End Property
Public ReadOnly Property MacroFeature_ToolTip As String
Get
Return EgtMsg(61909)
End Get
End Property
Public ReadOnly Property AddFeature_ToolTip As String Public ReadOnly Property AddFeature_ToolTip As String
Get Get
Return EgtMsg(61910) Return EgtMsg(61910)
@@ -76,9 +84,8 @@ Public Class FeatureListManagerVM
End Get End Get
End Property End Property
#End Region ' Messages
#End Region ' Fields & Properties #End Region ' Messages
#Region "CONSTRUCTOR" #Region "CONSTRUCTOR"
@@ -90,6 +97,17 @@ Public Class FeatureListManagerVM
#Region "METHODS" #Region "METHODS"
Friend Sub UpdateView()
NotifyPropertyChanged(NameOf(ViewPage_Visibility))
End Sub
Friend Sub SetLeftPanelIsEnabled(bIsEnabled As Boolean)
NotifyPropertyChanged(NameOf(CopyFeature_IsEnabled))
NotifyPropertyChanged(NameOf(AddFeature_IsEnabled))
NotifyPropertyChanged(NameOf(RemoveFeature_IsEnabled))
NotifyPropertyChanged(NameOf(MacroFeature_IsEnabled))
End Sub
Friend Sub PartShowAllChanged() Friend Sub PartShowAllChanged()
NotifyPropertyChanged(NameOf(AddFeature_IsEnabled)) NotifyPropertyChanged(NameOf(AddFeature_IsEnabled))
End Sub End Sub
@@ -105,7 +123,7 @@ Public Class FeatureListManagerVM
If MacroListCount > 0 AndAlso nSelMacro >= 0 Then If MacroListCount > 0 AndAlso nSelMacro >= 0 Then
' Creo nuova feature sulla base della Macro selezionata ' Creo nuova feature sulla base della Macro selezionata
' Creo table e setto variabili ' Creo table e setto variabili
CreateMacroTable(AddFeatureWndVM) CreateMacroTable()
Dim bOk As Boolean Dim bOk As Boolean
If AddFeatureWndVM.nSelMacroDefault >= 0 Then If AddFeatureWndVM.nSelMacroDefault >= 0 Then
bOk = EgtLuaExecFile(AddFeatureWndVM.m_MacroCustomFilePathList(nSelMacro)) bOk = EgtLuaExecFile(AddFeatureWndVM.m_MacroCustomFilePathList(nSelMacro))
@@ -149,7 +167,7 @@ Public Class FeatureListManagerVM
End If End If
End Sub End Sub
Private Sub CreateMacroTable(AddFeatureWndVM As AddFeatureWndVM) Private Sub CreateMacroTable()
Dim nMacroW, nMacroH As Integer Dim nMacroW, nMacroH As Integer
If Not IsNothing(Map.refProjectVM.BTLStructureVM) AndAlso Not IsNothing(Map.refProjectVM.BTLStructureVM.SelBTLPart) AndAlso Not IsNothing(Map.refProjectVM.BTLStructureVM.SelBTLPart.m_SelBTLFeatureVM) Then If Not IsNothing(Map.refProjectVM.BTLStructureVM) AndAlso Not IsNothing(Map.refProjectVM.BTLStructureVM.SelBTLPart) AndAlso Not IsNothing(Map.refProjectVM.BTLStructureVM.SelBTLPart.m_SelBTLFeatureVM) Then
If Map.refProjectVM.BTLStructureVM.SelBTLPart.nROTATED = 0 OrElse Map.refProjectVM.BTLStructureVM.SelBTLPart.nROTATED = 180 Then If Map.refProjectVM.BTLStructureVM.SelBTLPart.nROTATED = 0 OrElse Map.refProjectVM.BTLStructureVM.SelBTLPart.nROTATED = 180 Then
@@ -173,8 +191,8 @@ Public Class FeatureListManagerVM
nMacroH = Map.refProjectVM.BTLStructureVM.SelBTLPart.dBtlH nMacroH = Map.refProjectVM.BTLStructureVM.SelBTLPart.dBtlH
End If End If
End If End If
EgtLuaCreateGlobTable("MACRO") EgtLuaCreateGlobTable("MACRO")
EgtLuaSetGlobStringVar("MACRO.NAME", AddFeatureWndVM.nSelPRC.sName)
EgtLuaSetGlobNumVar("MACRO.L", Map.refProjectVM.BTLStructureVM.SelBTLPart.dBtlL) EgtLuaSetGlobNumVar("MACRO.L", Map.refProjectVM.BTLStructureVM.SelBTLPart.dBtlL)
EgtLuaSetGlobNumVar("MACRO.W", nMacroW) EgtLuaSetGlobNumVar("MACRO.W", nMacroW)
EgtLuaSetGlobNumVar("MACRO.H", nMacroH) EgtLuaSetGlobNumVar("MACRO.H", nMacroH)
@@ -187,6 +205,9 @@ Public Class FeatureListManagerVM
#Region "CopyFeature" #Region "CopyFeature"
''' <summary>
''' Returns a command that do Exec.
''' </summary>
Public ReadOnly Property CopyFeature_Command As ICommand Public ReadOnly Property CopyFeature_Command As ICommand
Get Get
If m_cmdCopyFeature Is Nothing Then If m_cmdCopyFeature Is Nothing Then
@@ -196,7 +217,11 @@ Public Class FeatureListManagerVM
End Get End Get
End Property End Property
''' <summary>
''' Execute the Exec. This method is invoked by the ExecCommand.
''' </summary>
Public Sub CopyFeature() Public Sub CopyFeature()
If IsNothing(ProjectManagerVM.CurrProj) Then Return
Dim SelPart As BTLPartVM = Map.refProjectVM.BTLStructureVM.SelBTLPart Dim SelPart As BTLPartVM = Map.refProjectVM.BTLStructureVM.SelBTLPart
If IsNothing(SelPart) Then Return If IsNothing(SelPart) Then Return
Dim SelFeature As BTLFeatureVM = SelPart.SelBTLFeatureVM Dim SelFeature As BTLFeatureVM = SelPart.SelBTLFeatureVM
@@ -212,8 +237,40 @@ Public Class FeatureListManagerVM
#End Region ' CopyFeature #End Region ' CopyFeature
#Region "MacroFeature"
''' <summary>
''' Returns a command that do Exec.
''' </summary>
Public ReadOnly Property MacroFeature_Command As ICommand
Get
If m_cmdMacroFeature Is Nothing Then
m_cmdMacroFeature = New Command(AddressOf MacroFeature)
End If
Return m_cmdMacroFeature
End Get
End Property
''' <summary>
''' Execute the Exec. This method is invoked by the ExecCommand.
''' </summary>
Public Sub MacroFeature()
If IsNothing(ProjectManagerVM.CurrProj) Then Return
If IsNothing(Map.refProjectVM.BTLStructureVM.SelBTLPart) Then Return
' apro finestra di creazione macro
Dim MacroFeatureWndVM As New MacroFeatureWndVM()
Dim NewMacroFeatureWnd As New NewMacroFeatureWnd(Application.Current.MainWindow, MacroFeatureWndVM)
If NewMacroFeatureWnd.ShowDialog() Then
End If
End Sub
#End Region ' MacroFeature
#Region "AddFeature" #Region "AddFeature"
''' <summary>
''' Returns a command that do Exec.
''' </summary>
Public ReadOnly Property AddFeature_Command As ICommand Public ReadOnly Property AddFeature_Command As ICommand
Get Get
If m_cmdAddFeature Is Nothing Then If m_cmdAddFeature Is Nothing Then
@@ -223,14 +280,18 @@ Public Class FeatureListManagerVM
End Get End Get
End Property End Property
''' <summary>
''' Execute the Exec. This method is invoked by the ExecCommand.
''' </summary>
Public Sub AddFeature(ByVal param As Object) Public Sub AddFeature(ByVal param As Object)
If IsNothing(ProjectManagerVM.CurrProj) Then Return
If IsNothing(Map.refProjectVM.BTLStructureVM.SelBTLPart) Then Return If IsNothing(Map.refProjectVM.BTLStructureVM.SelBTLPart) Then Return
' apro finestra di definizione nuova feature ' apro finestra di definizione nuova feature
Dim AddFeatureWndVM As New AddFeatureWndVM() Dim AddFeatureWndVM As New AddFeatureWndVM()
Dim NewFeat As BTLFeatureM = Nothing Dim NewFeat As BTLFeatureM = Nothing
Dim nNewFeatureId As Integer = 0 Dim nNewFeatureId As Integer = 0
Dim bMacroFlag As Boolean = False Dim bMacroFlag As Boolean = False
Dim AddNewFeatureWnd As New AddFeatureWndV(Application.Current.MainWindow, AddFeatureWndVM) Dim AddNewFeatureWnd As New NewAddFeatureWndV(Application.Current.MainWindow, AddFeatureWndVM)
If AddNewFeatureWnd.ShowDialog() Then If AddNewFeatureWnd.ShowDialog() Then
' verifico se una Macro è selezionata ' verifico se una Macro è selezionata
If AddFeatureWndVM.nSelMacroDefault >= 0 Then If AddFeatureWndVM.nSelMacroDefault >= 0 Then
@@ -245,6 +306,9 @@ Public Class FeatureListManagerVM
#Region "RemoveFeature" #Region "RemoveFeature"
''' <summary>
''' Returns a command that do Exec.
''' </summary>
Public ReadOnly Property RemoveFeature_Command As ICommand Public ReadOnly Property RemoveFeature_Command As ICommand
Get Get
If m_cmdRemoveFeature Is Nothing Then If m_cmdRemoveFeature Is Nothing Then
@@ -254,7 +318,11 @@ Public Class FeatureListManagerVM
End Get End Get
End Property End Property
''' <summary>
''' Execute the Exec. This method is invoked by the ExecCommand.
''' </summary>
Public Sub RemoveFeature() Public Sub RemoveFeature()
If IsNothing(ProjectManagerVM.CurrProj) Then Return
If IsNothing(Map.refProjectVM.BTLStructureVM.SelBTLPart) Then Return If IsNothing(Map.refProjectVM.BTLStructureVM.SelBTLPart) Then Return
If IsNothing(Map.refProjectVM.BTLStructureVM.SelBTLPart.SelBTLFeatureVM) Then Return If IsNothing(Map.refProjectVM.BTLStructureVM.SelBTLPart.SelBTLFeatureVM) Then Return
If EgtBeamEraseProcess(Map.refProjectVM.BTLStructureVM.SelBTLPart.SelBTLFeatureVM.nFeatureId) Then If EgtBeamEraseProcess(Map.refProjectVM.BTLStructureVM.SelBTLPart.SelBTLFeatureVM.nFeatureId) Then
@@ -0,0 +1,32 @@
<StackPanel x:Class="OnlyProdFeatureListManagerV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
DataContext="{StaticResource FeatureListManagerVM}"
Style="{StaticResource OnlyProdFeatureListManager_StackPanel}">
<Button Command="{Binding CopyFeature_Command}"
ToolTip="{Binding CopyFeature_ToolTip}"
IsEnabled="{Binding CopyFeature_IsEnabled}"
Style="{StaticResource OnlyProdLeftPanel_Button}">
<Image Source="/Resources/LeftPanel/CopyFeature.png" Stretch="Uniform"/>
</Button>
<Button Command="{Binding MacroFeature_Command}"
ToolTip="{Binding MacroFeature_ToolTip}"
IsEnabled="{Binding MacroFeature_IsEnabled}"
Style="{StaticResource OnlyProdLeftPanel_Button}">
<Image Source="/Resources/LeftPanel/MacroFeature.png" Stretch="Uniform"/>
</Button>
<Button Command="{Binding AddFeature_Command}"
ToolTip="{Binding AddFeature_ToolTip}"
IsEnabled="{Binding AddFeature_IsEnabled}"
Style="{StaticResource OnlyProdLeftPanel_Button}">
<Image Source="/Resources/LeftPanel/AddFeature.png" Stretch="Uniform"/>
</Button>
<Button Command="{Binding RemoveFeature_Command}"
ToolTip="{Binding RemoveFeature_ToolTip}"
IsEnabled="{Binding RemoveFeature_IsEnabled}"
Style="{StaticResource OnlyProdLeftPanel_Button}">
<Image Source="/Resources/LeftPanel/RemoveFeature.png" Stretch="Uniform"/>
</Button>
</StackPanel>
@@ -0,0 +1,3 @@
Public Class OnlyProdFeatureListManagerV
End Class
@@ -1,85 +1,55 @@
<Grid x:Class="FeatureManagerV" <StackPanel x:Class="FeatureManagerV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5" xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
xmlns:OPTIMIZER="clr-namespace:EgtBEAMWALL.Optimizer" xmlns:EgtBEAMWALL="clr-namespace:EgtBEAMWALL.Optimizer"
Margin="30,4,0,2"> Orientation="Horizontal"
Height="32">
<Grid.ColumnDefinitions> <TextBlock Text="{Binding Face_Msg}"
<ColumnDefinition Width="Auto"/> IsEnabled="{Binding FeatureManager_IsEnabled}"
<ColumnDefinition Width="Auto"/> Style="{StaticResource OptionTextBlock}"/>
<ColumnDefinition Width="Auto"/> <ComboBox ItemsSource="{Binding Tag.SIDEList, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:FeatureManagerV}}}"
<ColumnDefinition Width="Auto"/> SelectedItem="{Binding Tag.nSelSIDE, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:FeatureManagerV}}}"
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions>
<Expander Header="{Binding Face_Msg}"
IsEnabled="{Binding FeatureManager_IsEnabled}" IsEnabled="{Binding FeatureManager_IsEnabled}"
Width="80"> Style="{StaticResource FeatureComboBox}"/>
<ListBox ItemsSource="{Binding Tag.SIDEList, RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:FeatureManagerV}}}" <TextBlock Text="{Binding Group_Msg}"
SelectedItem="{Binding Tag.nSelSIDE, RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:FeatureManagerV}}}" IsEnabled="{Binding FeatureManager_IsEnabled}"
IsEnabled="{Binding FeatureManager_IsEnabled}" Style="{StaticResource OptionTextBlock}"/>
Style="{StaticResource FeatureManager_ListBox}" <ComboBox ItemsSource="{Binding Tag.GRPList, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:FeatureManagerV}}}"
ItemContainerStyle="{StaticResource AlternationIndex_ListBoxItem}"/> SelectedItem="{Binding Tag.nSelGRP, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:FeatureManagerV}}}"
</Expander>
<Expander Grid.Column="1"
Header="{Binding Group_Msg}"
IsEnabled="{Binding FeatureManager_IsEnabled}" IsEnabled="{Binding FeatureManager_IsEnabled}"
Width="80"> Style="{StaticResource FeatureComboBox}"/>
<ListBox ItemsSource="{Binding Tag.GRPList, RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:FeatureManagerV}}}" <TextBlock Text="{Binding Priority_Msg}"
SelectedItem="{Binding Tag.nSelGRP, RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:FeatureManagerV}}}"
IsEnabled="{Binding FeatureManager_IsEnabled}"
Style="{StaticResource FeatureManager_ListBox}"
ItemContainerStyle="{StaticResource AlternationIndex_ListBoxItem}"/>
</Expander>
<TextBlock Grid.Column="2"
Text="{Binding Priority_Msg}"
IsEnabled="{Binding FeatureManager_IsEnabled}" IsEnabled="{Binding FeatureManager_IsEnabled}"
Visibility="{Binding Priority_Visibility}" Visibility="{Binding Priority_Visibility}"
Style="{StaticResource OptionTextBlock}"/> Style="{StaticResource OptionTextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="3" <EgtWPFLib5:EgtTextBox Text="{Binding Tag.sPriority,
Text="{Binding Tag.sPriority, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:FeatureManagerV}},
RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:FeatureManagerV}},
UpdateSourceTrigger=Explicit}" UpdateSourceTrigger=Explicit}"
IsEnabled="{Binding FeatureManager_IsEnabled}" IsEnabled="{Binding FeatureManager_IsEnabled}"
Visibility="{Binding Priority_Visibility}" Visibility="{Binding Priority_Visibility}"
Style="{StaticResource Dimension_TextBox}"/> Width="45"/>
<TextBlock Grid.Column="4" <TextBlock Text="{Binding Tag.sName, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:FeatureManagerV}}}"
Text="{Binding Tag.sName, RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:FeatureManagerV}}}" Style="{StaticResource OptionTextBlock}"/>
Style="{StaticResource OnlyProdFeatureManager_OnlyProd}"/> <ComboBox ItemsSource="{Binding Tag.VARIANTList, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:FeatureManagerV}}}"
<ComboBox Grid.Column="5" SelectedItem="{Binding Tag.nSelVARIANT, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:FeatureManagerV}}}"
ItemsSource="{Binding Tag.VARIANTList, RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:FeatureManagerV}}}"
SelectedItem="{Binding Tag.nSelVARIANT, RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:FeatureManagerV}}}"
IsEnabled="{Binding FeatureManager_IsEnabled}" IsEnabled="{Binding FeatureManager_IsEnabled}"
Visibility="{Binding Variant_Visibility}" Visibility="{Binding Variant_Visibility}"
Style="{StaticResource FeatureComboBox}"/> Style="{StaticResource FeatureComboBox}"/>
<Button Grid.Column="6"
Content="{Binding Edit_Msg}"
Command="{Binding Tag.Edit_Command, RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:FeatureManagerV}}}"
Visibility="{Binding Tag.Edit_Visibility, RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:FeatureManagerV}}}"
IsEnabled="{Binding Edit_IsEnabled}"
Style="{StaticResource GeneralConfigurationToolBar_TextButton}"/>
<Button Grid.Column="7"
Content="{Binding Save_Msg}"
Command="{Binding Tag.Save_Command, RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:FeatureManagerV}}}"
Visibility="{Binding Tag.SaveCancel_Visibility, RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:FeatureManagerV}}}"
Style="{StaticResource GeneralConfigurationToolBar_TextButton}"/>
<Button Grid.Column="8"
Content="{Binding Cancel_Msg}"
Command="{Binding Tag.Cancel_Command, RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:FeatureManagerV}}}"
Visibility="{Binding Tag.SaveCancel_Visibility, RelativeSource={RelativeSource AncestorType={x:Type OPTIMIZER:FeatureManagerV}}}"
Style="{StaticResource GeneralConfigurationToolBar_TextButton}"/>
<Button Grid.Column="9" HorizontalAlignment="Right"
Command="{Binding MacroFeature_Command}"
ToolTip="{Binding MacroFeature_ToolTip}"
IsEnabled="{Binding MacroFeature_IsEnabled}"
Style="{StaticResource OnlyProdFeatureMan_Button}">
<Image Source="/Resources/LeftPanel/MacroFeature.png" Stretch="Uniform"/>
</Button>
</Grid> <Button Content="{Binding Edit_Msg}"
Command="{Binding Tag.Edit_Command, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:FeatureManagerV}}}"
Visibility="{Binding Tag.Edit_Visibility, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:FeatureManagerV}}}"
IsEnabled="{Binding Edit_IsEnabled}"
Style="{StaticResource EgtWPFLib5_InputButton}"/>
<Button Content="{Binding Save_Msg}"
Command="{Binding Tag.Save_Command, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:FeatureManagerV}}}"
Visibility="{Binding Tag.SaveCancel_Visibility, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:FeatureManagerV}}}"
Style="{StaticResource EgtWPFLib5_InputButton}"/>
<Button Content="{Binding Cancel_Msg}"
Command="{Binding Tag.Cancel_Command, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:FeatureManagerV}}}"
Visibility="{Binding Tag.SaveCancel_Visibility, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:FeatureManagerV}}}"
Style="{StaticResource EgtWPFLib5_InputButton}"/>
</StackPanel>
@@ -1,4 +1,5 @@
Imports EgtUILib Imports EgtBEAMWALL.Core
Imports EgtUILib
Imports EgtWPFLib5 Imports EgtWPFLib5
Public Class FeatureManagerVM Public Class FeatureManagerVM
@@ -83,17 +84,8 @@ Public Class FeatureManagerVM
End Get End Get
End Property End Property
Public ReadOnly Property MacroFeature_ToolTip As String
Get
Return EgtMsg(61909)
End Get
End Property
#End Region ' Messages #End Region ' Messages
' Definisco i comandi
Private m_cmdMacroFeature As ICommand
#End Region ' FIELDS & PROPERTIES #End Region ' FIELDS & PROPERTIES
#Region "CONSTRUCTORS" #Region "CONSTRUCTORS"
@@ -120,31 +112,4 @@ Public Class FeatureManagerVM
#End Region ' METHODS #End Region ' METHODS
#Region "COMMANDS"
#Region "MacroFeature"
Public ReadOnly Property MacroFeature_Command As ICommand
Get
If m_cmdMacroFeature Is Nothing Then
m_cmdMacroFeature = New Command(AddressOf MacroFeature)
End If
Return m_cmdMacroFeature
End Get
End Property
Public Sub MacroFeature()
If IsNothing(ProjectManagerVM.CurrProd) Then Return
If IsNothing(Map.refProjectVM.BTLStructureVM.SelBTLPart) Then Return
' apro finestra di creazione macro
Dim MacroFeatureWndVM As New MacroFeatureWndVM()
Dim MacroFeatureWnd As New MacroFeatureWnd(Application.Current.MainWindow, MacroFeatureWndVM)
If MacroFeatureWnd.ShowDialog() Then
End If
End Sub
#End Region ' MacroFeature
#End Region ' Commands
End Class End Class
@@ -0,0 +1,70 @@
<Grid x:Class="OnlyProdFeatureManagerV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
xmlns:EgtBEAMWALL="clr-namespace:EgtBEAMWALL.Optimizer"
Margin="30,4,0,2">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<Expander Header="{Binding Face_Msg}"
IsEnabled="{Binding FeatureManager_IsEnabled}"
Width="80">
<ListBox ItemsSource="{Binding Tag.SIDEList, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:OnlyProdFeatureManagerV}}}"
SelectedItem="{Binding Tag.nSelSIDE, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:OnlyProdFeatureManagerV}}}"
IsEnabled="{Binding FeatureManager_IsEnabled}"
Style="{StaticResource FeatureManager_ListBox}"
ItemContainerStyle="{StaticResource AlternationIndex_ListBoxItem}"/>
</Expander>
<Expander Grid.Column="1"
Header="{Binding Group_Msg}"
IsEnabled="{Binding FeatureManager_IsEnabled}"
Width="80">
<ListBox ItemsSource="{Binding Tag.GRPList, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:OnlyProdFeatureManagerV}}}"
SelectedItem="{Binding Tag.nSelGRP, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:OnlyProdFeatureManagerV}}}"
IsEnabled="{Binding FeatureManager_IsEnabled}"
Style="{StaticResource FeatureManager_ListBox}"
ItemContainerStyle="{StaticResource AlternationIndex_ListBoxItem}"/>
</Expander>
<TextBlock Grid.Column="2"
Text="{Binding Priority_Msg}"
IsEnabled="{Binding FeatureManager_IsEnabled}"
Visibility="{Binding Priority_Visibility}"
Style="{StaticResource OptionTextBlock}"/>
<EgtWPFLib5:EgtTextBox Grid.Column="3"
Text="{Binding Tag.sPriority,
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:OnlyProdFeatureManagerV}},
UpdateSourceTrigger=Explicit}"
IsEnabled="{Binding FeatureManager_IsEnabled}"
Visibility="{Binding Priority_Visibility}"
Style="{StaticResource Dimension_TextBox}"/>
<TextBlock Grid.Column="4"
Text="{Binding Tag.sName, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:OnlyProdFeatureManagerV}}}"
Style="{StaticResource OnlyProdFeatureManager_OnlyProd}"/>
<Button Grid.Column="5"
Content="{Binding Edit_Msg}"
Command="{Binding Tag.Edit_Command, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:OnlyProdFeatureManagerV}}}"
Visibility="{Binding Tag.Edit_Visibility, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:OnlyProdFeatureManagerV}}}"
IsEnabled="{Binding Edit_IsEnabled}"
Style="{StaticResource GeneralConfigurationToolBar_TextButton}"/>
<Button Grid.Column="6"
Content="{Binding Save_Msg}"
Command="{Binding Tag.Save_Command, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:OnlyProdFeatureManagerV}}}"
Visibility="{Binding Tag.SaveCancel_Visibility, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:OnlyProdFeatureManagerV}}}"
Style="{StaticResource GeneralConfigurationToolBar_TextButton}"/>
<Button Grid.Column="7"
Content="{Binding Cancel_Msg}"
Command="{Binding Tag.Cancel_Command, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:OnlyProdFeatureManagerV}}}"
Visibility="{Binding Tag.SaveCancel_Visibility, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:OnlyProdFeatureManagerV}}}"
Style="{StaticResource GeneralConfigurationToolBar_TextButton}"/>
</Grid>
@@ -0,0 +1,3 @@
Public Class OnlyProdFeatureManagerV
End Class
@@ -1,55 +0,0 @@
<UserControl x:Class="ForcedStrategyBTLV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:Optimizer="clr-namespace:EgtBEAMWALL.Optimizer">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions>
<Border Margin="2,0,2,0"
Grid.RowSpan="2"
Style="{StaticResource OnlyProdPage_Border}">
<ListBox ItemsSource="{Binding StrategyList}"
SelectedItem="{Binding SelStrategy}"
IsSynchronizedWithCurrentItem="True"
HorizontalAlignment="Left"
Style="{StaticResource NewAddFeature_ListBox}">
<ListBox.Resources>
<DataTemplate DataType="{x:Type Optimizer:Strategy}">
<StackPanel Orientation="Horizontal">
<RadioButton IsChecked="{Binding IsSelected, RelativeSource={RelativeSource AncestorType={x:Type ListBoxItem}}}"
GroupName="ForcedStrategy"/>
<Image Source="{Binding sStrategyImagePath}"
Stretch="Uniform"
Width="100"
Height="100"/>
<TextBlock Text="{Binding sStrategyName}"
Style="{StaticResource DialogWindow_TextBlock}"/>
</StackPanel>
</DataTemplate>
</ListBox.Resources>
<ListBox.ItemContainerStyle>
<Style TargetType="ListBoxItem">
<!--<EventSetter Event="PreviewMouseDown" Handler="AvailableStrategyList_PreviewMouseDown"/>-->
</Style>
</ListBox.ItemContainerStyle>
</ListBox>
</Border>
<GroupBox Grid.Column="1"
Foreground="Black"
BorderThickness="2"
Margin="0,-5,0,0"
BorderBrush="{StaticResource BeamWall_Glacier}">
<GroupBox.Header>
<TextBlock Text="{Binding SelStrategy.sStrategyName}"
FontWeight="Bold"
Style="{StaticResource DialogWindow_TextBlock}"/>
</GroupBox.Header>
<Optimizer:ParameterStrategyV Tag="{Binding SelStrategy}"/>
</GroupBox>
</Grid>
</UserControl>
@@ -1,3 +0,0 @@
Public Class ForcedStrategyBTL
End Class
@@ -1,74 +0,0 @@
<UserControl x:Class="ForcedStrategyPanelV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:OPTIMIZER="clr-namespace:EgtBEAMWALL.Optimizer">
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="1*"/>
<RowDefinition Height="Auto"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions>
<Border Grid.RowSpan="2"
Margin="2,0,2,0"
Style="{StaticResource OnlyProdPage_Border}">
<ListBox ItemsSource="{Binding StrategyList}"
SelectedItem="{Binding SelStrategy}"
Height="Auto"
IsSynchronizedWithCurrentItem="True"
Style="{StaticResource NewAddFeature_ListBox}">
<ListBox.Resources>
<DataTemplate DataType="{x:Type OPTIMIZER:Strategy}">
<StackPanel Orientation="Horizontal">
<RadioButton IsChecked="{Binding IsSelected, RelativeSource={RelativeSource AncestorType={x:Type ListBoxItem}}}"
GroupName="ForcedStrategy"/>
<Image Source="{Binding sStrategyImagePath}"
Stretch="Uniform"
Width="100"
Height="100"/>
<TextBlock Text="{Binding sStrategyName}"
Style="{StaticResource DialogWindow_TextBlock}"/>
</StackPanel>
</DataTemplate>
</ListBox.Resources>
<ListBox.ItemContainerStyle>
<Style TargetType="ListBoxItem">
<!--<EventSetter Event="PreviewMouseDown" Handler="AvailableStrategyList_PreviewMouseDown"/>-->
</Style>
</ListBox.ItemContainerStyle>
</ListBox>
</Border>
<GroupBox Grid.Column="1"
Foreground="Black"
BorderThickness="2"
Margin="0,-5,0,0"
BorderBrush="{StaticResource BeamWall_Glacier}">
<GroupBox.Header>
<TextBlock Text="{Binding SelStrategy.sStrategyName}"
FontWeight="Bold"
Style="{StaticResource DialogWindow_TextBlock}"/>
</GroupBox.Header>
<OPTIMIZER:ParameterStrategyV Tag="{Binding SelStrategy}"/>
</GroupBox>
<StackPanel Grid.Row="2"
Grid.ColumnSpan="2"
HorizontalAlignment="Right"
Style="{StaticResource OnlyProdPartManager_StackPanel}">
<Button Command="{Binding Ok_Command}"
ToolTip="{Binding Ok_Msg}"
Style="{StaticResource ToolBarViewPanel_Button}">
<Image Source="/Resources/NewPage/Ok.png" Stretch="Uniform"/>
</Button>
<Button Command="{Binding Cancel_Command}"
ToolTip="{Binding Cancel_Msg}"
Style="{StaticResource ToolBarViewPanel_Button}">
<Image Source="/Resources/PDFEditor/Delete.png" Stretch="Uniform"/>
</Button>
</StackPanel>
</Grid>
</UserControl>
@@ -1,3 +0,0 @@
Public Class ForcedStrategyPanelV
End Class
@@ -1,400 +0,0 @@
Imports System.Collections.ObjectModel
Imports System.IO
Imports EgtBEAMWALL.Core
Imports EgtUILib
Imports EgtWPFLib5
Imports Newtonsoft.Json
Public Class ForcedStrategyPanelVM
Inherits VMBase
#Region "FIELDS & PROPERTIES"
Public Const AUTOMATICSTRATEGYID As String = "AUTOMATIC"
Private m_StrategyList As New ObservableCollection(Of Strategy)
Public Property StrategyList As ObservableCollection(Of Strategy)
Get
Return m_StrategyList
End Get
Set(value As ObservableCollection(Of Strategy))
m_StrategyList = value
End Set
End Property
Private m_SelStrategy As Strategy
Public Property SelStrategy As Strategy
Get
Return m_SelStrategy
End Get
Set(value As Strategy)
m_SelStrategy = value
NotifyPropertyChanged(NameOf(SelStrategy))
End Set
End Property
Private m_CurrentFeature As BTLFeatureM
' Definizione Comandi
Private m_cmdOk As ICommand
Private m_cmdCancel As ICommand
#Region "Messages"
Public ReadOnly Property UserMsg As String
Get
Return EgtMsg(61748)
End Get
End Property
Public ReadOnly Property AdvanceMsg As String
Get
Return EgtMsg(61749)
End Get
End Property
#End Region ' Messages
#End Region ' Fields & Properties
#Region "CONSTRUCTOR"
Sub New()
Map.SetRefForcedStrategyPanelVM(Me)
End Sub
#End Region ' Constructor
#Region "METHODS"
Friend Sub Init(Feature As BTLFeatureM)
m_CurrentFeature = Feature
Dim nTmpGRP As Integer = CalcBeamPrivateProfileGRP(Feature.nSelGRP)
LoadStrategyListFromTopology(Feature.nFeatureId, Feature.nPRC, nTmpGRP)
' leggo eventuali parametri forzati
Dim sStrategyID As String = ""
EgtGetInfo(m_CurrentFeature.nFeatureId, "STRATEGY", sStrategyID)
If String.IsNullOrWhiteSpace(sStrategyID) Then Return
Dim ForcedStrategy As Strategy = m_StrategyList.FirstOrDefault(Function(x) x.sStrategyId = sStrategyID)
If IsNothing(ForcedStrategy) Then
Else
SelStrategy = ForcedStrategy
For Each Param In SelStrategy.ParameterList
Select Case Param.GetType()
Case GetType(BooleanStrategyParameter)
Dim bValue As Boolean = False
EgtGetInfo(m_CurrentFeature.nFeatureId, m_SelStrategy.sStrategyId & "_" & Param.sNameNge, bValue)
DirectCast(Param, BooleanStrategyParameter).SetValue(bValue)
Case GetType(DoubleStrategyParameter)
Dim dValue As Double = 0
EgtGetInfo(m_CurrentFeature.nFeatureId, m_SelStrategy.sStrategyId & "_" & Param.sNameNge, dValue)
DirectCast(Param, DoubleStrategyParameter).SetValue(dValue)
Case GetType(ComboStrategyParameter)
Dim sValue As String = String.Empty
EgtGetInfo(m_CurrentFeature.nFeatureId, m_SelStrategy.sStrategyId & "_" & Param.sNameNge, sValue)
Dim ComboStrategyParameter As ComboStrategyParameter = DirectCast(Param, ComboStrategyParameter)
Dim SelCombo = ComboStrategyParameter.ComboList.FirstOrDefault(Function(x) x.sValue = sValue)
ComboStrategyParameter.SelValue = SelCombo
Case GetType(StringStrategyParameter)
Dim sValue As String = String.Empty
EgtGetInfo(m_CurrentFeature.nFeatureId, m_SelStrategy.sStrategyId & "_" & Param.sNameNge, sValue)
DirectCast(Param, StringStrategyParameter).SetValue(sValue)
Case GetType(ListStrategyParameter)
Dim sValue As String = String.Empty
EgtGetInfo(m_CurrentFeature.nFeatureId, m_SelStrategy.sStrategyId & "_" & Param.sNameNge, sValue)
Dim ListStrategyParameter As ListStrategyParameter = DirectCast(Param, ListStrategyParameter)
Dim SelValue As ToolParameter = Nothing
Dim sTrimValue As String = sValue.TrimEnd(";"c)
Dim sTmpValue As String() = sTrimValue.Split(";"c)
Dim sSplitValue As String() = Nothing
For Each ItemValue As String In sTmpValue
sSplitValue = ItemValue.Split(","c)
For Each ItemTool As ToolParameter In ListStrategyParameter.ListValue
If sSplitValue(0) = ItemTool.sUUID AndAlso sSplitValue(1) = ItemTool.sName Then
ItemTool.bIsActive = True
SelValue = ListStrategyParameter.ListValue.FirstOrDefault(Function(x) x.sName = ItemTool.sName AndAlso x.sUUID = ItemTool.sUUID)
End If
Next
Next
ListStrategyParameter.SelValue = SelValue
End Select
Next
End If
End Sub
Friend Function LoadStrategyListFromTopology(nFeatureId As Integer, nPRC As Integer, nGRP As Integer) As Boolean
m_StrategyList.Clear()
Dim sTopologyName As String = "Feature"
Dim sStrategiesDirPath As String = Map.refMainWindowVM.MainWindowM.GetStrategiesDirPath(ProjectManagerVM.CurrProd.nType)
Dim sAvailableStrategiesFilePath As String = sStrategiesDirPath & "\" & AVAILABLESTRATEGYLIST_FILE & ".json"
Dim sReadedFile As String = String.Empty
' carico default
If File.Exists(sAvailableStrategiesFilePath) Then
sReadedFile = File.ReadAllText(sAvailableStrategiesFilePath)
Dim JsonStrategyFeatureList As List(Of JsonAvailableStrategyFeature) = JsonConvert.DeserializeObject(Of List(Of JsonAvailableStrategyFeature))(sReadedFile)
'nGRP = CalcBeamPrivateProfileGRP(nGRP)
Dim JsonAvailableStrategyFeature As JsonAvailableStrategyFeature = JsonStrategyFeatureList.FirstOrDefault(Function(x) x.nGrp = nGRP AndAlso x.nPrc = nPRC)
If IsNothing(JsonAvailableStrategyFeature) Then Return False
Dim JsonAvailableTopology As JsonAvailableTopology = JsonAvailableStrategyFeature.TopologyList.FirstOrDefault(Function(x) x.sName = sTopologyName)
If IsNothing(JsonAvailableTopology) Then
' ricavo topologia da feature
FindTopologyFromFeature(nFeatureId, sTopologyName)
JsonAvailableTopology = JsonAvailableStrategyFeature.TopologyList.FirstOrDefault(Function(x) x.sName = sTopologyName)
End If
If IsNothing(JsonAvailableTopology) Then Return False
m_StrategyList = New ObservableCollection(Of Strategy)((From JsonAvailableStrategy In JsonAvailableTopology.StrategyList
Select JsonAvailableStrategy.Deserialize(ProjectManagerVM.CurrProd.nType, -1)).ToList())
End If
If File.Exists(sAvailableStrategiesFilePath) Then
sReadedFile = File.ReadAllText(sAvailableStrategiesFilePath)
Dim JsonStrategyFeatureList As List(Of JsonAvailableStrategyFeature) = JsonConvert.DeserializeObject(Of List(Of JsonAvailableStrategyFeature))(sReadedFile)
'nGRP = CalcBeamPrivateProfileGRP(nGRP)
Dim JsonAvailableStrategyFeature As JsonAvailableStrategyFeature = JsonStrategyFeatureList.FirstOrDefault(Function(x) x.nGrp = nGRP AndAlso x.nPrc = nPRC)
If IsNothing(JsonAvailableStrategyFeature) Then Return False
Dim JsonAvailableTopology As JsonAvailableTopology = JsonAvailableStrategyFeature.TopologyList.FirstOrDefault(Function(x) x.sName = sTopologyName)
If IsNothing(JsonAvailableTopology) Then
' ricavo topologia da feature
FindTopologyFromFeature(nFeatureId, sTopologyName)
JsonAvailableTopology = JsonAvailableStrategyFeature.TopologyList.FirstOrDefault(Function(x) x.sName = sTopologyName)
End If
If IsNothing(JsonAvailableTopology) Then Return False
m_StrategyList = New ObservableCollection(Of Strategy)((From JsonAvailableStrategy In JsonAvailableTopology.StrategyList
Select JsonAvailableStrategy.Deserialize(ProjectManagerVM.CurrProd.nType, -1)).ToList())
End If
' recupero custom
Dim nPartId As Integer = EgtGetParent(EgtGetParent(nFeatureId))
Dim nPartProjId As Integer = 0
If Not EgtGetInfo(nPartId, PROJ, nPartProjId) OrElse nPartProjId <= 0 Then Return False
Dim nBTLInfoLayerId As Integer = GetCurrProjBtlInfoLayerId(nPartProjId)
Dim sStrategySetupName As String = ""
EgtGetInfo(nBTLInfoLayerId, "AISETUP", sStrategySetupName)
If Not String.IsNullOrWhiteSpace(sStrategySetupName) Then
' carico custom
Dim sAISetupDirPath As String = Map.refMainWindowVM.MainWindowM.GetAISetupDirPath(ProjectManagerVM.CurrProd.nType, True)
Dim sStrategyConfigurationFilePath As String = sAISetupDirPath & "\" & sStrategySetupName & ".json"
If File.Exists(sStrategyConfigurationFilePath) Then
sReadedFile = File.ReadAllText(sStrategyConfigurationFilePath)
Dim JsonRoot As CustomJsonRoot = Nothing
Try
JsonRoot = JsonConvert.DeserializeObject(Of CustomJsonRoot)(sReadedFile)
Catch ex As Exception
JsonRoot = Nothing
End Try
Dim JsonFeatureList As ObservableCollection(Of JsonStrategyFeature) = Nothing
If Not IsNothing(JsonRoot) Then
JsonFeatureList = JsonRoot.FEATURE
Else
If IsNothing(JsonRoot) Then
EgtOutLog("JSON ERRATO: Il file Json importato non è nel formato corretto")
If File.Exists(sAvailableStrategiesFilePath) Then
sReadedFile = File.ReadAllText(sAvailableStrategiesFilePath)
Dim JsonStrategyFeatureList As List(Of JsonAvailableStrategyFeature) = JsonConvert.DeserializeObject(Of List(Of JsonAvailableStrategyFeature))(sReadedFile)
'nGRP = CalcBeamPrivateProfileGRP(nGRP)
Dim JsonAvailableStrategyFeature As JsonAvailableStrategyFeature = JsonStrategyFeatureList.FirstOrDefault(Function(x) x.nGrp = nGRP AndAlso x.nPrc = nPRC)
If IsNothing(JsonAvailableStrategyFeature) Then Return False
Dim JsonAvailableTopology As JsonAvailableTopology = JsonAvailableStrategyFeature.TopologyList.FirstOrDefault(Function(x) x.sName = sTopologyName)
If IsNothing(JsonAvailableTopology) Then
' ricavo topologia da feature
FindTopologyFromFeature(nFeatureId, sTopologyName)
JsonAvailableTopology = JsonAvailableStrategyFeature.TopologyList.FirstOrDefault(Function(x) x.sName = sTopologyName)
End If
If IsNothing(JsonAvailableTopology) Then Return False
m_StrategyList = New ObservableCollection(Of Strategy)((From JsonAvailableStrategy In JsonAvailableTopology.StrategyList
Select JsonAvailableStrategy.Deserialize(ProjectManagerVM.CurrProd.nType, -1)).ToList())
End If
Return True
Else
JsonFeatureList = JsonConvert.DeserializeObject(Of ObservableCollection(Of JsonStrategyFeature))(sReadedFile)
End If
End If
'Dim JsonStrategyFeatureList As List(Of JsonStrategyFeature) = JsonConvert.DeserializeObject(Of List(Of JsonStrategyFeature))(sReadedFile)
Dim JsonStrategyFeature As JsonStrategyFeature = JsonFeatureList.FirstOrDefault(Function(x) x.nGrp = nGRP AndAlso x.nPrc = nPRC)
If IsNothing(JsonStrategyFeature) Then Return False
Dim JsonTopology As JsonTopology = JsonStrategyFeature.TopologyList.FirstOrDefault(Function(x) x.sName = sTopologyName)
If IsNothing(JsonTopology) Then Return False
For Each Strategy In JsonTopology.StrategyList
Dim DefaultStrategy As Strategy = m_StrategyList.FirstOrDefault(Function(x) x.sStrategyId = Strategy.sStrategyId)
If IsNothing(DefaultStrategy) Then
' DefaultTopology.StrategyList.Add(New Strategy(DefaultTopology, Strategy))
' verifico indici!!
Else
DefaultStrategy.ReadConfiguration(Strategy)
End If
Next
End If
End If
' aggiungo strategia automatica
m_StrategyList.Insert(0, New Strategy() With {.sStrategyId = AUTOMATICSTRATEGYID, .sStrategyName = AUTOMATICSTRATEGYID})
If Map.refMainMenuVM.UnlockAllIsChecked Then
Map.refMainMenuVM.UnlockAll(m_StrategyList)
ElseIf Map.refMainMenuVM.UserAdmin_IsChecked Then
Map.refMainMenuVM.ShowParam(m_StrategyList)
End If
NotifyPropertyChanged(NameOf(StrategyList))
Return True
End Function
Friend Sub GetDefaultJsonStrategy(sStrategiesDirPath As String, sAvailableStrategiesFilePath As String, sTopologyName As String, nFeatureId As Integer, nPRC As Integer, nGRP As Integer)
If File.Exists(sAvailableStrategiesFilePath) Then
Dim sReadedFile As String = File.ReadAllText(sAvailableStrategiesFilePath)
Dim JsonStrategyFeatureList As List(Of JsonAvailableStrategyFeature) = JsonConvert.DeserializeObject(Of List(Of JsonAvailableStrategyFeature))(sReadedFile)
'nGRP = CalcBeamPrivateProfileGRP(nGRP)
Dim JsonAvailableStrategyFeature As JsonAvailableStrategyFeature = JsonStrategyFeatureList.FirstOrDefault(Function(x) x.nGrp = nGRP AndAlso x.nPrc = nPRC)
If IsNothing(JsonAvailableStrategyFeature) Then Return
Dim JsonAvailableTopology As JsonAvailableTopology = JsonAvailableStrategyFeature.TopologyList.FirstOrDefault(Function(x) x.sName = sTopologyName)
If IsNothing(JsonAvailableTopology) Then
' ricavo topologia da feature
FindTopologyFromFeature(nFeatureId, sTopologyName)
JsonAvailableTopology = JsonAvailableStrategyFeature.TopologyList.FirstOrDefault(Function(x) x.sName = sTopologyName)
End If
If IsNothing(JsonAvailableTopology) Then Return
m_StrategyList = New ObservableCollection(Of Strategy)((From JsonAvailableStrategy In JsonAvailableTopology.StrategyList
Select JsonAvailableStrategy.Deserialize(ProjectManagerVM.CurrProd.nType, -1)).ToList())
End If
End Sub
Friend Function GetCurrProjBtlInfoLayerId(nProjId As Integer) As Integer
' cerco tra i layer BTLInfo
Dim nBTLInfoLayerId As Integer = EgtGetFirstNameInGroup(GDB_ID.ROOT, BTLINFO)
While nBTLInfoLayerId <> GDB_ID.NULL
' verifico se il layer appartiene al ProjId
Dim nBTLInfoLayerProjId As Integer
EgtGetInfo(nBTLInfoLayerId, BTL_PRT_PROJ, nBTLInfoLayerProjId)
If nBTLInfoLayerProjId = nProjId Then
Return nBTLInfoLayerId
End If
nBTLInfoLayerId = EgtGetNextName(nBTLInfoLayerId, BTLINFO)
End While
Return -1
End Function
Friend Sub ForcedStrategy()
' cancello precedenti valori
Dim sPrecStrategyID As String = ""
EgtGetInfo(m_CurrentFeature.nFeatureId, "STRATEGY", sPrecStrategyID)
If Not String.IsNullOrWhiteSpace(sPrecStrategyID) Then
Dim PrecInfo As String() = {}
EgtGetAllInfo(m_CurrentFeature.nFeatureId, PrecInfo)
Dim PrecStrategyInfo As String() = PrecInfo.Where(Function(x) x.StartsWith(sPrecStrategyID)).ToArray()
For Each Info In PrecStrategyInfo
EgtRemoveInfo(m_CurrentFeature.nFeatureId, Info.Split("="c)(0))
Next
End If
If Not IsNothing(m_SelStrategy) Then
If m_SelStrategy.sStrategyId = AUTOMATICSTRATEGYID Then
EgtRemoveInfo(m_CurrentFeature.nFeatureId, "STRATEGY")
Else
EgtSetInfo(m_CurrentFeature.nFeatureId, "STRATEGY", SelStrategy.sStrategyId)
Dim sInfo As String = String.Empty
For Each Param In SelStrategy.ParameterList
Select Case Param.GetType()
Case GetType(BooleanStrategyParameter)
EgtSetInfo(m_CurrentFeature.nFeatureId, m_SelStrategy.sStrategyId & "_" & Param.sNameNge, DirectCast(Param, BooleanStrategyParameter).bValue)
Case GetType(DoubleStrategyParameter)
EgtSetInfo(m_CurrentFeature.nFeatureId, m_SelStrategy.sStrategyId & "_" & Param.sNameNge, DirectCast(Param, DoubleStrategyParameter).sValue)
Case GetType(ComboStrategyParameter)
EgtSetInfo(m_CurrentFeature.nFeatureId, m_SelStrategy.sStrategyId & "_" & Param.sNameNge, DirectCast(Param, ComboStrategyParameter).SelValue.sValue)
Case GetType(StringStrategyParameter)
EgtSetInfo(m_CurrentFeature.nFeatureId, m_SelStrategy.sStrategyId & "_" & Param.sNameNge, DirectCast(Param, StringStrategyParameter).sValue)
Case GetType(ListStrategyParameter)
For Each Item As ToolParameter In DirectCast(Param, ListStrategyParameter).ListValue
If Item.bIsActive Then
sInfo &= Item.sUUID & "," & Item.sName & ";"
EgtSetInfo(m_CurrentFeature.nFeatureId, m_SelStrategy.sStrategyId & "_" & Param.sNameNge, sInfo)
End If
Next
End Select
Next
End If
End If
End Sub
#End Region ' Methods
#Region "COMMANDS"
#Region "Ok_Command"
Public ReadOnly Property Ok_Command As ICommand
Get
If m_cmdOk Is Nothing Then
m_cmdOk = New Command(AddressOf Ok)
End If
Return m_cmdOk
End Get
End Property
Public Sub Ok()
'' cancello precedenti valori
'Dim sPrecStrategyID As String = ""
'EgtGetInfo(m_CurrentFeature.nFeatureId, "STRATEGY", sPrecStrategyID)
'If Not String.IsNullOrWhiteSpace(sPrecStrategyID) Then
' Dim PrecInfo As String() = {}
' EgtGetAllInfo(m_CurrentFeature.nFeatureId, PrecInfo)
' Dim PrecStrategyInfo As String() = PrecInfo.Where(Function(x) x.StartsWith(sPrecStrategyID)).ToArray()
' For Each Info In PrecStrategyInfo
' EgtRemoveInfo(m_CurrentFeature.nFeatureId, Info.Split("="c)(0))
' Next
'End If
'If m_SelStrategy.sStrategyId = AUTOMATICSTRATEGYID Then
' EgtRemoveInfo(m_CurrentFeature.nFeatureId, "STRATEGY")
'Else
' EgtSetInfo(m_CurrentFeature.nFeatureId, "STRATEGY", SelStrategy.sStrategyId)
' Dim sInfo As String = String.Empty
' For Each Param In SelStrategy.ParameterList
' Select Case Param.GetType()
' Case GetType(BooleanStrategyParameter)
' EgtSetInfo(m_CurrentFeature.nFeatureId, m_SelStrategy.sStrategyId & "_" & Param.sNameNge, DirectCast(Param, BooleanStrategyParameter).bValue)
' Case GetType(DoubleStrategyParameter)
' EgtSetInfo(m_CurrentFeature.nFeatureId, m_SelStrategy.sStrategyId & "_" & Param.sNameNge, DirectCast(Param, DoubleStrategyParameter).sValue)
' Case GetType(ComboStrategyParameter)
' EgtSetInfo(m_CurrentFeature.nFeatureId, m_SelStrategy.sStrategyId & "_" & Param.sNameNge, DirectCast(Param, ComboStrategyParameter).SelValue.sValue)
' Case GetType(StringStrategyParameter)
' EgtSetInfo(m_CurrentFeature.nFeatureId, m_SelStrategy.sStrategyId & "_" & Param.sNameNge, DirectCast(Param, StringStrategyParameter).sValue)
' Case GetType(ListStrategyParameter)
' For Each Item As ToolParameter In DirectCast(Param, ListStrategyParameter).ListValue
' If Item.bIsActive Then
' sInfo &= Item.sUUID & "," & Item.sName & ";"
' EgtSetInfo(m_CurrentFeature.nFeatureId, m_SelStrategy.sStrategyId & "_" & Param.sNameNge, sInfo)
' End If
' Next
' End Select
' Next
'End If
ForcedStrategy()
Map.refProjectVM.SetSelManagerTab(ProjectVM.StrategyManagerTab.RAWPARTMANAGER)
' Abilito LeftPanel
Map.refProjectVM.SetOnlyProdLeftPanel_IsEnabled(True)
Map.refProjectVM.SetOnlyProdLeftPanel_Opacity(1)
End Sub
#End Region ' Ok_Command
#Region "Cancel_Command"
Public ReadOnly Property Cancel_Command As ICommand
Get
If m_cmdCancel Is Nothing Then
m_cmdCancel = New Command(AddressOf Cancel)
End If
Return m_cmdCancel
End Get
End Property
Public Sub Cancel()
Map.refProjectVM.SetSelManagerTab(ProjectVM.StrategyManagerTab.RAWPARTMANAGER)
' Abilito LeftPanel
Map.refProjectVM.SetOnlyProdLeftPanel_IsEnabled(True)
Map.refProjectVM.SetOnlyProdLeftPanel_Opacity(1)
End Sub
#End Region ' Cancel_Command
#End Region ' Commands
End Class
@@ -1,12 +1,12 @@
<UserControl x:Class="FreeContourInputV" <UserControl x:Class="FreeContourInputV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
Height="32"> Height="32">
<StackPanel> <StackPanel Orientation="Horizontal">
<StackPanel.Style> <StackPanel.Style>
<Style TargetType="{x:Type StackPanel}"> <Style TargetType="{x:Type StackPanel}">
<Setter Property="Orientation" Value="Horizontal"/>
<Style.Triggers> <Style.Triggers>
<DataTrigger Binding="{Binding FocusTextBox}" Value="True"> <DataTrigger Binding="{Binding FocusTextBox}" Value="True">
<Setter Property="FocusManager.FocusedElement" Value="{Binding ElementName=PropertySearch}"/> <Setter Property="FocusManager.FocusedElement" Value="{Binding ElementName=PropertySearch}"/>
@@ -14,40 +14,33 @@
</Style.Triggers> </Style.Triggers>
</Style> </Style>
</StackPanel.Style> </StackPanel.Style>
<TextBlock Text="{Binding Message}" <TextBlock Text="{Binding Message}"
Visibility="{Binding Message_Visibility}" Visibility="{Binding Message_Visibility}"
Style="{StaticResource OptionTextBlock}"/> Style="{StaticResource OptionTextBlock}"/>
<TextBox Text="{Binding Text, UpdateSourceTrigger=PropertyChanged}" <TextBox Text="{Binding Text, UpdateSourceTrigger=PropertyChanged}"
Visibility="{Binding Text_Visibility}" Width="200"
Visibility="{Binding Text_Visibility}" Margin="5,0,5,0"
Style="{StaticResource FreeContour_TextBox}"> Style="{StaticResource FreeContour_TextBox}">
<TextBox.InputBindings> <TextBox.InputBindings>
<KeyBinding Key="Enter" Command="{Binding Done_Command, UpdateSourceTrigger=PropertyChanged}"/> <KeyBinding Key="Enter" Command="{Binding Done_Command, UpdateSourceTrigger=PropertyChanged}"/>
<KeyBinding Key="S" Modifiers="Control" Command="{Binding Show_Command}"/> <KeyBinding Key="S" Modifiers="Control" Command="{Binding Show_Command}"/>
</TextBox.InputBindings> </TextBox.InputBindings>
</TextBox> </TextBox>
<CheckBox Content="{Binding CheckBoxText}" <CheckBox Content="{Binding CheckBoxText}" IsChecked="{Binding IsChecked}"
IsChecked="{Binding IsChecked}" Visibility="{Binding Check_Visibility}" Margin="5,0,5,0"
Visibility="{Binding Check_Visibility}" VerticalAlignment="Center"/>
Style="{StaticResource FreeContourInput_CheckBox}"/> <ComboBox ItemsSource="{Binding ComboItemsList}" SelectedIndex="{Binding ComboSelectedIndex}"
<ComboBox ItemsSource="{Binding ComboItemsList}" Visibility="{Binding Combo_Visibility}" Margin="5,0,5,0" Style="{x:Null}"/>
SelectedIndex="{Binding ComboSelectedIndex}"
Visibility="{Binding Combo_Visibility}"
Margin="5,0,5,0"/>
<Grid Margin="5,0,5,0"> <Grid Margin="5,0,5,0">
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"/> <ColumnDefinition Width="1*"/>
<ColumnDefinition Width="1*"/> <ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions> </Grid.ColumnDefinitions>
<Button Command="{Binding Show_Command}" <Button Command="{Binding Show_Command}" Visibility="{Binding ShowBtn_Visibility}"
Visibility="{Binding ShowBtn_Visibility}" Content="{Binding ShowMsg}" Style="{StaticResource EgtWPFLib5_InputButton}"/>
Content="{Binding ShowMsg}" <Button Command="{Binding Done_Command}" Visibility="{Binding DoneBtn_Visibility}"
Style="{StaticResource GeneralConfigurationToolBar_TextButton}"/> Grid.Column="1"
<Button Grid.Column="1" Content="{Binding OkMsg}" Style="{StaticResource EgtWPFLib5_InputButton}"/>
Command="{Binding Done_Command}"
Visibility="{Binding DoneBtn_Visibility}"
Content="{Binding OkMsg}"
Style="{StaticResource GeneralConfigurationToolBar_TextButton}"/>
</Grid> </Grid>
</StackPanel> </StackPanel>
</UserControl> </UserControl>
@@ -0,0 +1,53 @@
<UserControl x:Class="OnlyProdFreeContourInputV"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Height="32">
<StackPanel>
<StackPanel.Style>
<Style TargetType="{x:Type StackPanel}">
<Setter Property="Orientation" Value="Horizontal"/>
<Style.Triggers>
<DataTrigger Binding="{Binding FocusTextBox}" Value="True">
<Setter Property="FocusManager.FocusedElement" Value="{Binding ElementName=PropertySearch}"/>
</DataTrigger>
</Style.Triggers>
</Style>
</StackPanel.Style>
<TextBlock Text="{Binding Message}"
Visibility="{Binding Message_Visibility}"
Style="{StaticResource OptionTextBlock}"/>
<TextBox Text="{Binding Text, UpdateSourceTrigger=PropertyChanged}"
Visibility="{Binding Text_Visibility}"
Style="{StaticResource FreeContour_TextBox}">
<TextBox.InputBindings>
<KeyBinding Key="Enter" Command="{Binding Done_Command, UpdateSourceTrigger=PropertyChanged}"/>
<KeyBinding Key="S" Modifiers="Control" Command="{Binding Show_Command}"/>
</TextBox.InputBindings>
</TextBox>
<CheckBox Content="{Binding CheckBoxText}"
IsChecked="{Binding IsChecked}"
Visibility="{Binding Check_Visibility}"
Style="{StaticResource FreeContourInput_CheckBox}"/>
<ComboBox ItemsSource="{Binding ComboItemsList}"
SelectedIndex="{Binding ComboSelectedIndex}"
Visibility="{Binding Combo_Visibility}"
Margin="5,0,5,0"/>
<Grid Margin="5,0,5,0">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"/>
<ColumnDefinition Width="1*"/>
</Grid.ColumnDefinitions>
<Button Command="{Binding Show_Command}"
Visibility="{Binding ShowBtn_Visibility}"
Content="{Binding ShowMsg}"
Style="{StaticResource GeneralConfigurationToolBar_TextButton}"/>
<Button Grid.Column="1"
Command="{Binding Done_Command}"
Visibility="{Binding DoneBtn_Visibility}"
Content="{Binding OkMsg}"
Style="{StaticResource GeneralConfigurationToolBar_TextButton}"/>
</Grid>
</StackPanel>
</UserControl>
@@ -0,0 +1,3 @@
Public Class OnlyProdFreeContourInputV
End Class

Some files were not shown because too many files have changed in this diff Show More