- correzione pressione tasto su tabelle per gestione tasto canc
- piccoli miglioramenti grafici - corretta funzione salvataggio alyout della tabella feature pezzo in barra
This commit is contained in:
@@ -163,7 +163,7 @@ Public Class BTLFeatureVM
|
||||
|
||||
Public ReadOnly Property CALC_ROT_Visibility As Visibility
|
||||
Get
|
||||
Return If(m_BTLFeatureM.nCALC_ROT <> 0, Visibility.Visible, Visibility.Collapsed)
|
||||
Return If(m_BTLFeatureM.nCALC_ROT <> 0, Visibility.Visible, Visibility.Hidden)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
|
||||
@@ -267,13 +267,13 @@ Public MustInherit Class MyMachGroupVM
|
||||
|
||||
Public ReadOnly Property CALC_ROT_Visibility As Visibility
|
||||
Get
|
||||
Return If(MyMachGroupM.nCALC_ROT <> 0, Visibility.Visible, Visibility.Collapsed)
|
||||
Return If(MyMachGroupM.nCALC_ROT <> 0, Visibility.Visible, Visibility.Hidden)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Public ReadOnly Property CALC_FALL_Visibility As Visibility
|
||||
Get
|
||||
Return If(MyMachGroupM.nCALC_FALL <> 0, Visibility.Visible, Visibility.Collapsed)
|
||||
Return If(MyMachGroupM.nCALC_FALL <> 0, Visibility.Visible, Visibility.Hidden)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
|
||||
@@ -319,13 +319,13 @@ Public MustInherit Class PartVM
|
||||
|
||||
Public ReadOnly Property CALC_ROT_Visibility As Visibility
|
||||
Get
|
||||
Return If(m_PartM.nCALC_ROT <> 0, Visibility.Visible, Visibility.Collapsed)
|
||||
Return If(m_PartM.nCALC_ROT <> 0, Visibility.Visible, Visibility.Hidden)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Public ReadOnly Property CALC_FALL_Visibility As Visibility
|
||||
Get
|
||||
Return If(m_PartM.nCALC_FALL <> 0, Visibility.Visible, Visibility.Collapsed)
|
||||
Return If(m_PartM.nCALC_FALL <> 0, Visibility.Visible, Visibility.Hidden)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
|
||||
@@ -258,22 +258,20 @@ Public Class BTLPartListV
|
||||
End Sub
|
||||
|
||||
Private Sub BTLPart_GridControl_PreviewKeyDown(sender As Object, e As KeyEventArgs)
|
||||
Dim BTLStructureVM As BTLStructureVM = TryCast(Me.Tag, BTLStructureVM)
|
||||
If IsNothing(BTLStructureVM) Then Return
|
||||
If e.Key = Key.Delete Then
|
||||
Dim BTLStructureVM As BTLStructureVM = TryCast(Me.Tag, BTLStructureVM)
|
||||
If IsNothing(BTLStructureVM) Then Return
|
||||
|
||||
Dim SelBTLPart As BTLPartVM = BTLStructureVM.SelBTLPart
|
||||
Dim SelBTLFeatureVM As BTLFeatureVM = SelBTLPart?.SelBTLFeatureVM
|
||||
Dim SelBTLPart As BTLPartVM = BTLStructureVM.SelBTLPart
|
||||
Dim SelBTLFeatureVM As BTLFeatureVM = SelBTLPart?.SelBTLFeatureVM
|
||||
|
||||
If bSelOnFeature AndAlso Not IsNothing(SelBTLFeatureVM) Then
|
||||
If SelBTLFeatureVM.DeleteFeature_Command.CanExecute(Nothing) Then
|
||||
SelBTLFeatureVM.DeleteFeature_Command.Execute(Nothing)
|
||||
If bSelOnFeature AndAlso Not IsNothing(SelBTLFeatureVM) Then
|
||||
SelBTLFeatureVM.DeleteFeature()
|
||||
e.Handled = True
|
||||
Return
|
||||
End If
|
||||
Return
|
||||
End If
|
||||
|
||||
If BTLStructureVM.DeletePart_Command.CanExecute(Nothing) Then
|
||||
BTLStructureVM.DeletePart_Command.Execute(Nothing)
|
||||
BTLStructureVM.DeletePart()
|
||||
e.Handled = True
|
||||
End If
|
||||
End Sub
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
<dxg:GridControl.View>
|
||||
<dxg:TableView x:Name="FeatureVMList_TableView"
|
||||
ShowGridMenu="OnShowGridMenu"
|
||||
|
||||
ShowTotalSummary="False"
|
||||
ColumnHeaderStyle="{StaticResource HeaderStyle}"
|
||||
ColumnHeaderImageStyle="{StaticResource HeaderImageStyle}"
|
||||
|
||||
@@ -32,7 +32,7 @@
|
||||
Style="{StaticResource TableViewStyle}"/>
|
||||
</dxg:GridControl.View>
|
||||
<dxg:GridColumn FieldName="bDO"
|
||||
SortFieldName="bDO"
|
||||
AllowSorting="False"
|
||||
Header=""
|
||||
Fixed="Left"
|
||||
Style="{StaticResource ColumnInfoStyle}">
|
||||
@@ -56,40 +56,42 @@
|
||||
AllowColumnFiltering="False">
|
||||
<dxg:GridColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<Grid>
|
||||
<Grid Margin="5,0">
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="10"/>
|
||||
<ColumnDefinition Width="12"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<Border Width="{Binding ActualHeight, RelativeSource={RelativeSource self}}"
|
||||
Background="{Binding RowData.Row.Calc_Background}"/>
|
||||
<Border Background="{Binding RowData.Row.Calc_Background}"
|
||||
Style="{StaticResource Calc_Border}"/>
|
||||
<Grid Grid.Column="1"
|
||||
Style="{StaticResource FeatureInPartInRawPartList_Grid}">
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="1*"/>
|
||||
<RowDefinition Height="Auto"/>
|
||||
</Grid.RowDefinitions>
|
||||
<TextBlock Visibility="{Binding RowData.Row.CALC_ROT_Visibility}"
|
||||
<TextBlock Text="⭯"
|
||||
Visibility="{Binding RowData.Row.CALC_ROT_Visibility}"
|
||||
Style="{StaticResource CALC_ROT_TextBlock}"/>
|
||||
<TextBlock Grid.Row="1"
|
||||
Text="{Binding RowData.Row.CALC_ERR_Letter}"
|
||||
Foreground="{Binding RowData.Row.CALC_ERR_Foreground}"
|
||||
Style="{StaticResource FeatureInPartInRawPartList_TextBlock}"/>
|
||||
Style="{StaticResource CALC_ERR_TextBlock}"/>
|
||||
</Grid>
|
||||
</Grid>
|
||||
</DataTemplate>
|
||||
</dxg:GridColumn.CellTemplate>
|
||||
</dxg:GridColumn>
|
||||
<dxg:GridColumn FieldName="sDesc"
|
||||
AllowSorting="False"
|
||||
Header="{Binding Description_Msg}"
|
||||
Style="{StaticResource ColumnInfoStyle}"/>
|
||||
<dxg:GridColumn FieldName="sPriority"
|
||||
Header="{Binding Priority_Msg}"
|
||||
Style="{StaticResource ColumnInfoStyle}"/>
|
||||
<dxg:GridColumn FieldName="Strategy"
|
||||
AllowSorting="False"
|
||||
Header=""
|
||||
Image="{StaticResource HeaderEdit_Image}"
|
||||
AllowSorting="False"
|
||||
Fixed="Right"
|
||||
Style="{StaticResource ColumnButtonStyle}">
|
||||
<dxg:GridColumn.CellTemplate>
|
||||
|
||||
@@ -48,7 +48,7 @@ Public Class FeatureInPartInRawPartListV
|
||||
End Sub
|
||||
|
||||
' salvataggio del layout colonne
|
||||
Public Sub SaveStatisticGridControlLayout()
|
||||
Public Sub SaveFeatureInPartInRawPartGridControlLayout()
|
||||
FeatureVMList_GridControl.SaveLayoutToJson(m_sDataGridLayoutPath)
|
||||
End Sub
|
||||
|
||||
@@ -56,7 +56,7 @@ Public Class FeatureInPartInRawPartListV
|
||||
' imposto DataContext
|
||||
m_FeatureInPartInRawPartListVM = Me.DataContext
|
||||
' imposto riferimento ad action per salvataggio layout tabella
|
||||
m_FeatureInPartInRawPartListVM.refFeatureInPartInRawPartListGridControlLayout = AddressOf SaveStatisticGridControlLayout
|
||||
m_FeatureInPartInRawPartListVM.refSaveFeatureInPartInRawPartGridControlLayout = AddressOf SaveFeatureInPartInRawPartGridControlLayout
|
||||
' rispristino layout tabella
|
||||
If Not IsNothing(m_sDataGridLayoutPath) AndAlso File.Exists(m_sDataGridLayoutPath) Then
|
||||
FeatureVMList_GridControl.RestoreLayoutFromJson(m_sDataGridLayoutPath)
|
||||
|
||||
@@ -8,7 +8,7 @@ Public Class FeatureInPartInRawPartListVM
|
||||
|
||||
#Region "FIELDS & PROPERTIES"
|
||||
|
||||
Public refFeatureInPartInRawPartListGridControlLayout As Action
|
||||
Public refSaveFeatureInPartInRawPartGridControlLayout As Action
|
||||
|
||||
Private m_colFeatureInPartInRawPart_Do As EgwWPFBaseLib.ColumnLayout
|
||||
Public ReadOnly Property colFeatureInPartInRawPart_Do As EgwWPFBaseLib.ColumnLayout
|
||||
@@ -80,6 +80,12 @@ Public Class FeatureInPartInRawPartListVM
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Friend Sub Close()
|
||||
If Not IsNothing(refSaveFeatureInPartInRawPartGridControlLayout) Then
|
||||
refSaveFeatureInPartInRawPartGridControlLayout()
|
||||
End If
|
||||
End Sub
|
||||
|
||||
#End Region ' Methods
|
||||
|
||||
End Class
|
||||
|
||||
@@ -25,6 +25,7 @@
|
||||
<dxg:TableView x:Name="RawPart_TableView"
|
||||
ShowGridMenu="OnShowGridMenu"
|
||||
PreviewKeyDown="RawPart_TableView_PreviewKeyDown"
|
||||
ShowTotalSummary="True"
|
||||
|
||||
ColumnHeaderStyle="{StaticResource HeaderStyle}"
|
||||
ColumnHeaderImageStyle="{StaticResource HeaderImageStyle}"
|
||||
@@ -61,11 +62,13 @@
|
||||
|
||||
</dxg:GridControl.View>
|
||||
<dxg:GridColumn FieldName="nPDN"
|
||||
AllowSorting="False"
|
||||
Header="{Binding PDN_Msg}"
|
||||
Fixed="Left"
|
||||
AllowEditing="False"
|
||||
Style="{StaticResource ColumnInfoStyle}"/>
|
||||
<dxg:GridColumn FieldName="GlobalState"
|
||||
AllowSorting="False"
|
||||
Header=""
|
||||
SortFieldName="nGlobalState"
|
||||
AllowColumnFiltering="False"
|
||||
@@ -90,13 +93,13 @@
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<TextBlock Grid.ColumnSpan="2"
|
||||
<TextBlock Text="⭯"
|
||||
Visibility="{Binding RowData.Row.CALC_ROT_Visibility}"
|
||||
Style="{StaticResource CALC_ROTFeatureRawPartList_TextBlock}"/>
|
||||
Style="{StaticResource CALC_ROT_TextBlock}"/>
|
||||
<TextBlock Grid.Column="1"
|
||||
Text="{Binding RowData.Row.CALC_ERR_Letter}"
|
||||
Foreground="{Binding RowData.Row.CALC_ERR_Foreground}"
|
||||
Style="{StaticResource CALC_ERRRawPartList_TextBlock}"/>
|
||||
Style="{StaticResource CALC_ERR_TextBlock}"/>
|
||||
</Grid>
|
||||
</Grid>
|
||||
</DataTemplate>
|
||||
@@ -109,7 +112,7 @@
|
||||
AllowEditing="False"
|
||||
Style="{StaticResource ColumnInfoStyle}"/>
|
||||
<dxg:GridColumn FieldName="sL"
|
||||
SortFieldName="dL"
|
||||
AllowSorting="False"
|
||||
Header="{Binding L_Msg}"
|
||||
AllowColumnFiltering="False"
|
||||
AllowEditing="False"
|
||||
@@ -164,19 +167,19 @@
|
||||
</dxg:GridColumn.CellTemplate>
|
||||
</dxg:GridColumn>
|
||||
<dxg:GridColumn FieldName="sPOSX"
|
||||
SortFieldName="dPOSX"
|
||||
AllowSorting="False"
|
||||
Header="{Binding PosX_Msg}"
|
||||
AllowColumnFiltering="False"
|
||||
AllowEditing="False"
|
||||
Style="{StaticResource ColumnInfoStyle}"/>
|
||||
<dxg:GridColumn FieldName="sPOSY"
|
||||
SortFieldName="dPOSY"
|
||||
AllowSorting="False"
|
||||
Header="{Binding PosY_Msg}"
|
||||
AllowColumnFiltering="False"
|
||||
AllowEditing="False"
|
||||
Style="{StaticResource ColumnInfoStyle}"/>
|
||||
<dxg:GridColumn FieldName="sOffset"
|
||||
SortFieldName="dOffset"
|
||||
AllowSorting="False"
|
||||
Header="{Binding Offset_Msg}"
|
||||
AllowColumnFiltering="False"
|
||||
Style="{StaticResource ColumnInfoStyle}">
|
||||
@@ -185,6 +188,7 @@
|
||||
</dxg:GridColumn.EditSettings>
|
||||
</dxg:GridColumn>
|
||||
<dxg:GridColumn FieldName="sMATERIAL"
|
||||
AllowSorting="False"
|
||||
Header="{Binding MAT_Msg}"
|
||||
AllowEditing="False"
|
||||
Style="{StaticResource ColumnInfoStyle}"/>
|
||||
@@ -286,11 +290,11 @@
|
||||
</Grid.RowDefinitions>
|
||||
<TextBlock Text="⭯"
|
||||
Visibility="{Binding RowData.Row.CALC_ROT_Visibility}"
|
||||
Style="{StaticResource CALC_ROTRawPartList_TextBlock}"/>
|
||||
Style="{StaticResource CALC_ROT_TextBlock}"/>
|
||||
<TextBlock Grid.Row="1"
|
||||
Text="{Binding RowData.Row.CALC_ERR_Letter}"
|
||||
Foreground="{Binding RowData.Row.CALC_ERR_Foreground}"
|
||||
Style="{StaticResource FeatureInPartInRawPartList_TextBlock}"/>
|
||||
Style="{StaticResource CALC_ERR_TextBlock}"/>
|
||||
</Grid>
|
||||
</Grid>
|
||||
</DataTemplate>
|
||||
|
||||
@@ -272,22 +272,20 @@ Public Class RawPartListV
|
||||
End Sub
|
||||
|
||||
Private Sub RawPart_TableView_PreviewKeyDown(sender As Object, e As KeyEventArgs)
|
||||
Dim MyMachGroupPanelVM As MyMachGroupPanelVM = TryCast(Me.Tag, MyMachGroupPanelVM)
|
||||
If IsNothing(MyMachGroupPanelVM) Then Return
|
||||
If e.Key = Key.Delete Then
|
||||
Dim MyMachGroupPanelVM As MyMachGroupPanelVM = TryCast(Me.Tag, MyMachGroupPanelVM)
|
||||
If IsNothing(MyMachGroupPanelVM) Then Return
|
||||
|
||||
Dim SelectedMachGroup As MyMachGroupVM = MyMachGroupPanelVM.SelectedMachGroup
|
||||
Dim SelPart As PartVM = SelectedMachGroup?.SelPart
|
||||
Dim SelectedMachGroup As MyMachGroupVM = MyMachGroupPanelVM.SelectedMachGroup
|
||||
Dim SelPart As PartVM = SelectedMachGroup?.SelPart
|
||||
|
||||
If Map.refMachGroupPanelVM.bSelOnPart AndAlso Not IsNothing(SelPart) Then
|
||||
If SelPart.RemovePart_Command.CanExecute(Nothing) Then
|
||||
SelPart.RemovePart_Command.Execute(Nothing)
|
||||
If MyMachGroupPanelVM.bSelOnPart AndAlso Not IsNothing(SelPart) Then
|
||||
SelPart.RemovePart()
|
||||
e.Handled = True
|
||||
Return
|
||||
End If
|
||||
Return
|
||||
End If
|
||||
|
||||
If SelectedMachGroup.RemoveRawPart_Command.CanExecute(Nothing) Then
|
||||
SelectedMachGroup.RemoveRawPart_Command.Execute(Nothing)
|
||||
SelectedMachGroup.RemoveRawPart()
|
||||
e.Handled = True
|
||||
End If
|
||||
End Sub
|
||||
|
||||
@@ -432,7 +432,7 @@ Public Class MainWindowVM
|
||||
EgwWPFBaseLib.EgwDataGrid.WriteColumnLayout(DataGridColumnsIniFile.m_sDataGridColumnsIniFile, DataGridColumnDictionary)
|
||||
Map.refPartListVM.Close()
|
||||
Map.refRawPartListVM.Close()
|
||||
|
||||
Map.refFeatureInPartInRawPartListVM.Close()
|
||||
End If
|
||||
' Termino il Model
|
||||
m_MainWindowM.Close()
|
||||
|
||||
@@ -204,7 +204,6 @@ Public Class ProjectVM
|
||||
End Property
|
||||
Friend Sub SetFeatureListVisibility(bVisible As Boolean)
|
||||
m_FeatureList_Visibility = If(bVisible, Visibility.Visible, Visibility.Collapsed)
|
||||
If Not m_FeatureList_Visibility Then Map.refFeatureInPartInRawPartListVM.refFeatureInPartInRawPartListGridControlLayout()
|
||||
NotifyPropertyChanged(NameOf(FeatureList_Visibility))
|
||||
End Sub
|
||||
|
||||
|
||||
@@ -2842,7 +2842,7 @@
|
||||
<Setter Property="NavigationStyle" Value="Cell"/>
|
||||
<Setter Property="RowMinHeight" Value="28"/>
|
||||
<Setter Property="ShowGroupPanel" Value="False"/>
|
||||
<Setter Property="ShowTotalSummary" Value="True"/>
|
||||
<Setter Property="ShowTotalSummary" Value="False"/>
|
||||
<Setter Property="ShowSearchPanelMode" Value="Default"/>
|
||||
<Setter Property="ShowFilterPanelMode" Value="Never"/>
|
||||
<Setter Property="ShowIndicator" Value="False"/>
|
||||
|
||||
Reference in New Issue
Block a user