- eliminati riferimenti a Name in codice EgtDataGrid
- aggiunto nuget EgwMultiEngine.Core - iniziato modifiche popup in OnlyProdBTLPartListV
This commit is contained in:
@@ -78,11 +78,11 @@ Public Class EgtDataGrid
|
||||
|
||||
For Each one As EgtDataGridColumn In e.NewItems
|
||||
Try
|
||||
Dim col As DataGridColumn = CurrDataGrid.FindResource(one.Name)
|
||||
Dim col As DataGridColumn = Me.FindResource(one.Name)
|
||||
one.InitColumn(col)
|
||||
CurrDataGrid.Columns.Insert(e.NewStartingIndex, col)
|
||||
Me.Columns.Insert(e.NewStartingIndex, col)
|
||||
If col.DisplayIndex <> e.NewStartingIndex Then
|
||||
CurrDataGrid.Columns(e.NewStartingIndex).DisplayIndex = e.NewStartingIndex
|
||||
Me.Columns(e.NewStartingIndex).DisplayIndex = e.NewStartingIndex
|
||||
End If
|
||||
Catch ex As Exception
|
||||
MessageBox.Show(String.Format(EgtMsg(61883), one.Name, one.ParentDataGridName), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning)
|
||||
@@ -95,30 +95,30 @@ Public Class EgtDataGrid
|
||||
If e.OldItems IsNot Nothing Then
|
||||
|
||||
For Each one As EgtDataGridColumn In e.OldItems
|
||||
Dim col As DataGridColumn = CurrDataGrid.FindResource(one.Name)
|
||||
CurrDataGrid.Columns.Remove(col)
|
||||
Dim col As DataGridColumn = Me.FindResource(one.Name)
|
||||
Me.Columns.Remove(col)
|
||||
Next
|
||||
End If
|
||||
|
||||
Case NotifyCollectionChangedAction.Move
|
||||
'Dim col As DataGridColumn = CurrDataGrid.FindResource(BindingColumns(e.OldStartingIndex))
|
||||
'Dim col As DataGridColumn = Me.FindResource(BindingColumns(e.OldStartingIndex))
|
||||
'col.DisplayIndex = e.NewStartingIndex
|
||||
CurrDataGrid.Columns.Move(e.OldStartingIndex, e.NewStartingIndex)
|
||||
CurrDataGrid.Columns(e.NewStartingIndex).DisplayIndex = e.NewStartingIndex
|
||||
'Dim x = CurrDataGrid.Columns(e.OldStartingIndex).DisplayIndex
|
||||
Me.Columns.Move(e.OldStartingIndex, e.NewStartingIndex)
|
||||
Me.Columns(e.NewStartingIndex).DisplayIndex = e.NewStartingIndex
|
||||
'Dim x = Me.Columns(e.OldStartingIndex).DisplayIndex
|
||||
Case NotifyCollectionChangedAction.Reset
|
||||
CurrDataGrid.Columns.Clear()
|
||||
Me.Columns.Clear()
|
||||
|
||||
If e.NewItems IsNot Nothing Then
|
||||
|
||||
For Each one As DataGridColumn In e.NewItems
|
||||
Dim col As DataGridColumn = CurrDataGrid.FindResource(one)
|
||||
CurrDataGrid.Columns.Add(col)
|
||||
Dim col As DataGridColumn = Me.FindResource(one)
|
||||
Me.Columns.Add(col)
|
||||
Next
|
||||
End If
|
||||
Case NotifyCollectionChangedAction.Replace
|
||||
Dim col As DataGridColumn = CurrDataGrid.FindResource(e.NewItems(0))
|
||||
CurrDataGrid.Columns(e.NewStartingIndex) = col
|
||||
Dim col As DataGridColumn = Me.FindResource(e.NewItems(0))
|
||||
Me.Columns(e.NewStartingIndex) = col
|
||||
End Select
|
||||
End Sub
|
||||
|
||||
@@ -132,11 +132,11 @@ Public Class EgtDataGrid
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub DataGrid_SizedChanged(sender As Object, e As SizeChangedEventArgs) Handles CurrDataGrid.SizeChanged
|
||||
Private Sub DataGrid_SizedChanged(sender As Object, e As SizeChangedEventArgs) Handles Me.SizeChanged
|
||||
' confronto la larghezza effettiva della EgtDataGrid con la somma delle larghezze delle colonne
|
||||
UpdateColumnsWidth()
|
||||
If BindingColumns.Count > 0 Then
|
||||
If CurrDataGrid.ActualWidth - LASTCOLUMN_MINWIDTH > columnsWidth Then
|
||||
If Me.ActualWidth - LASTCOLUMN_MINWIDTH > columnsWidth Then
|
||||
' nascondo la ScrollBar orizzontale e setto lo UnitType dell'ultima colonna visibile a Star
|
||||
ScrollViewer.SetHorizontalScrollBarVisibility(CurrDataGrid, ScrollBarVisibility.Hidden)
|
||||
BindingColumns.Last(Function(x) x.Visible = True).Width = New DataGridLength(1, DataGridLengthUnitType.Star)
|
||||
@@ -254,12 +254,12 @@ Public Class EgtDataGrid
|
||||
cm.IsOpen = True
|
||||
End Sub
|
||||
|
||||
Private Sub CurrDataGrid_ColumnReordering(sender As Object, e As DataGridColumnEventArgs) Handles CurrDataGrid.ColumnReordering
|
||||
Private Sub CurrDataGrid_ColumnReordering(sender As Object, e As DataGridColumnEventArgs) Handles Me.ColumnReordering
|
||||
' conservo il vecchio indice in modo da effettuare lo scambio in BindingColumns una volta riordinate graficamente
|
||||
OldIndex = e.Column.DisplayIndex
|
||||
End Sub
|
||||
|
||||
Private Sub CurrDataGrid_ColumnReordered(sender As Object, e As DataGridColumnEventArgs) Handles CurrDataGrid.ColumnReordered
|
||||
Private Sub CurrDataGrid_ColumnReordered(sender As Object, e As DataGridColumnEventArgs) Handles Me.ColumnReordered
|
||||
' scambio le colonne in BindingColumns
|
||||
BindingColumns.Move(OldIndex, e.Column.DisplayIndex)
|
||||
' scrivo tutte le colonne interessate dallo spostamento
|
||||
@@ -315,12 +315,12 @@ Public Class EgtDataGrid
|
||||
ResetSortDirections()
|
||||
End Sub
|
||||
|
||||
Private Sub CurrDataGrid_Loaded(sender As Object, e As RoutedEventArgs) Handles CurrDataGrid.Loaded
|
||||
Private Sub CurrDataGrid_Loaded(sender As Object, e As RoutedEventArgs) Handles Me.Loaded
|
||||
' setto la SortDirection, se attiva, sulla colonna su cui è attiva
|
||||
Dim colIndex As Integer = 0
|
||||
For Each col In BindingColumns
|
||||
If col.SortDirection > 0 Then
|
||||
CurrDataGrid.Items.SortDescriptions.Add(New SortDescription(CurrDataGrid.Columns(colIndex).SortMemberPath, col.SortDirection - 1))
|
||||
Me.Items.SortDescriptions.Add(New SortDescription(Me.Columns(colIndex).SortMemberPath, col.SortDirection - 1))
|
||||
Exit For
|
||||
End If
|
||||
colIndex += 1
|
||||
@@ -333,7 +333,7 @@ Public Class EgtDataGrid
|
||||
Next
|
||||
End Sub
|
||||
|
||||
Private Sub CurrDataGrid_Sorting(sender As Object, e As DataGridSortingEventArgs) Handles CurrDataGrid.Sorting
|
||||
Private Sub CurrDataGrid_Sorting(sender As Object, e As DataGridSortingEventArgs) Handles Me.Sorting
|
||||
' salvo la SortDirection corrente della colonna prima di resettarla per tutte le colonne
|
||||
Dim CurrSortDirection As ListSortDirection? = e.Column.SortDirection
|
||||
ResetSortDirections(True)
|
||||
@@ -356,11 +356,11 @@ Public Class EgtDataGrid
|
||||
Next
|
||||
Else
|
||||
' altrimenti (caso ResetSort da ContextMenu) è necessatio un Clear più ampio e anche grafico
|
||||
CurrDataGrid.Items.SortDescriptions.Clear()
|
||||
Me.Items.SortDescriptions.Clear()
|
||||
For Each column In BindingColumns
|
||||
column.SortDirection = 0
|
||||
' resetto graficamente anche l'header della colonna
|
||||
CurrDataGrid.Columns(column.DisplayIndex).SortDirection = Nothing
|
||||
Me.Columns(column.DisplayIndex).SortDirection = Nothing
|
||||
Next
|
||||
RaiseEvent ResetSort()
|
||||
End If
|
||||
|
||||
@@ -1,43 +1,49 @@
|
||||
<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}"
|
||||
ToolTip="{Binding CopyPart_ToolTip}"
|
||||
IsEnabled="{Binding CopyPart_IsEnabled}"
|
||||
Click="ClosePopUp_Click"
|
||||
Style="{StaticResource OnlyProdLeftPanel_Button}">
|
||||
<Image Source="/Resources/LeftPanel/CopyPart.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button Command="{Binding RemovePart_Command}"
|
||||
ToolTip="{Binding RemovePart_ToolTip}"
|
||||
IsEnabled="{Binding RemovePart_IsEnabled}"
|
||||
Click="ClosePopUp_Click"
|
||||
Style="{StaticResource OnlyProdLeftPanel_Button}">
|
||||
<Image Source="/Resources/NewPage/Remove.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding Simulate_ToolTip}"
|
||||
Command="{Binding Simulate_Command}"
|
||||
IsEnabled="{Binding Simulate_IsEnabled}"
|
||||
Click="ClosePopUp_Click"
|
||||
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}"
|
||||
Click="ClosePopUp_Click"
|
||||
Style="{StaticResource OnlyProdLeftPanel_Button}">
|
||||
<Image Source="/Resources/CALCPanel/Edit.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button Command="{Binding ResetCalc_Command}"
|
||||
ToolTip="{Binding ResetCalc_ToolTip}"
|
||||
IsEnabled="{Binding CALCPanel_IsEnabled}"
|
||||
Click="ClosePopUp_Click"
|
||||
Style="{StaticResource OnlyProdLeftPanel_Button}">
|
||||
<Image Source="/Resources/CALCPanel/ResetCalc.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Border x:Class="OnlyProdBTLPartManagerV"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
DataContext="{StaticResource BTLPartManagerVM}"
|
||||
CornerRadius="5"
|
||||
BorderThickness="2"
|
||||
BorderBrush="{StaticResource BeamWall_Teal}"
|
||||
Background="{StaticResource BeamWall_FountainBlue}">
|
||||
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal"
|
||||
Style="{StaticResource OnlyProdBTLPartManager_StackPanel}">
|
||||
<Button Command="{Binding CopyPart_Command}"
|
||||
ToolTip="{Binding CopyPart_ToolTip}"
|
||||
IsEnabled="{Binding CopyPart_IsEnabled}"
|
||||
Click="ClosePopUp_Click"
|
||||
Style="{StaticResource OnlyProdLeftPanel_Button}">
|
||||
<Image Source="/Resources/LeftPanel/CopyPart.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button Command="{Binding RemovePart_Command}"
|
||||
ToolTip="{Binding RemovePart_ToolTip}"
|
||||
IsEnabled="{Binding RemovePart_IsEnabled}"
|
||||
Click="ClosePopUp_Click"
|
||||
Style="{StaticResource OnlyProdLeftPanel_Button}">
|
||||
<Image Source="/Resources/NewPage/Remove.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding Simulate_ToolTip}"
|
||||
Command="{Binding Simulate_Command}"
|
||||
IsEnabled="{Binding Simulate_IsEnabled}"
|
||||
Click="ClosePopUp_Click"
|
||||
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}"
|
||||
Click="ClosePopUp_Click"
|
||||
Style="{StaticResource OnlyProdLeftPanel_Button}">
|
||||
<Image Source="/Resources/CALCPanel/Edit.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button Command="{Binding ResetCalc_Command}"
|
||||
ToolTip="{Binding ResetCalc_ToolTip}"
|
||||
IsEnabled="{Binding CALCPanel_IsEnabled}"
|
||||
Click="ClosePopUp_Click"
|
||||
Style="{StaticResource OnlyProdLeftPanel_Button}">
|
||||
<Image Source="/Resources/CALCPanel/ResetCalc.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</StackPanel>
|
||||
|
||||
</Border>
|
||||
|
||||
@@ -79,9 +79,6 @@
|
||||
<Reference Include="EgtWPFLib5">
|
||||
<HintPath>..\ExtLibs\EgtWPFLib5.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="EgwMultiEngineManager.Core">
|
||||
<HintPath>..\ExtLibs\EgwMultiEngineManager.Core.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
<Reference Include="PresentationFramework.Aero2" />
|
||||
<Reference Include="System.ComponentModel" />
|
||||
@@ -988,8 +985,11 @@
|
||||
<PackageReference Include="DotNetZip">
|
||||
<Version>1.16.0</Version>
|
||||
</PackageReference>
|
||||
<PackageReference Include="EgwMultiEngineManager.Core">
|
||||
<Version>2.7.10.1</Version>
|
||||
</PackageReference>
|
||||
<PackageReference Include="EgwMultiEngineManager.Data">
|
||||
<Version>2.7.9-beta.1</Version>
|
||||
<Version>2.7.10.1</Version>
|
||||
</PackageReference>
|
||||
<PackageReference Include="EntityFramework">
|
||||
<Version>6.4.4</Version>
|
||||
@@ -1132,6 +1132,14 @@
|
||||
<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)"=="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</PostBuildEvent>
|
||||
IF "$(PlatformName)"=="x64" IF "$(ConfigurationName)" == "Debug" copy $(TargetPath) c:\EgtProg\EgtBEAMWALL\EgtBEAMWALL.OptimizerD64.exe
|
||||
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</PostBuildEvent>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<PreBuildEvent>
|
||||
</PreBuildEvent>
|
||||
</PropertyGroup>
|
||||
</Project>
|
||||
@@ -1,12 +1,10 @@
|
||||
Imports System.IO
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports EgtBEAMWALL.Core.ConstIni
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
Imports EgwMultiEngineManager
|
||||
Imports EgwMultiEngineManager.Core
|
||||
Imports EgwMultiEngineManager.Data
|
||||
Imports EgwMultiEngineManager.Data.Constants
|
||||
Imports EgwMultiEngineManager.ExecProcessManager
|
||||
|
||||
Module MyExecProcessManager
|
||||
|
||||
@@ -59,7 +57,7 @@ Module MyExecProcessManager
|
||||
nGroupIndex += 1
|
||||
Continue While
|
||||
End If
|
||||
Dim NewExecProcessManager As New ExecProcessManager(nGroupIndex, Environment, sCamExePath, PipeLuaPath, nMaxCamInstances, ReturnModes.EVENT_)
|
||||
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)
|
||||
|
||||
@@ -21,13 +21,17 @@ Public Class FeatureListManagerVM
|
||||
|
||||
Public ReadOnly Property CopyFeature_IsEnabled As Boolean
|
||||
Get
|
||||
Return Map.refBTLPartManagerVM.BTLPartManager_IsEnabled AndAlso PartIsSelected AndAlso FeatureIsSelected
|
||||
If Not IsNothing(Map.refBTLPartManagerVM) Then
|
||||
Return Map.refBTLPartManagerVM.BTLPartManager_IsEnabled AndAlso PartIsSelected AndAlso FeatureIsSelected
|
||||
End If
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Public ReadOnly Property MacroFeature_IsEnabled As Boolean
|
||||
Get
|
||||
Return Map.refBTLPartManagerVM.BTLPartManager_IsEnabled AndAlso PartIsSelected AndAlso FeatureIsSelected
|
||||
If Not IsNothing(Map.refBTLPartManagerVM) Then
|
||||
Return Map.refBTLPartManagerVM.BTLPartManager_IsEnabled AndAlso PartIsSelected AndAlso FeatureIsSelected
|
||||
End If
|
||||
End Get
|
||||
End Property
|
||||
|
||||
@@ -39,7 +43,9 @@ Public Class FeatureListManagerVM
|
||||
|
||||
Public ReadOnly Property RemoveFeature_IsEnabled As Boolean
|
||||
Get
|
||||
Return Map.refBTLPartManagerVM.BTLPartManager_IsEnabled AndAlso PartIsSelected AndAlso FeatureIsSelected
|
||||
If Not IsNothing(Map.refBTLPartManagerVM) Then
|
||||
Return Map.refBTLPartManagerVM.BTLPartManager_IsEnabled AndAlso PartIsSelected AndAlso FeatureIsSelected
|
||||
End If
|
||||
End Get
|
||||
End Property
|
||||
|
||||
|
||||
@@ -363,8 +363,15 @@
|
||||
<Image Source="/Resources/NewPage/Setting.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Popup AllowsTransparency="True"
|
||||
PopupAnimation="Scroll"
|
||||
PopupAnimation="None"
|
||||
Placement="Right"
|
||||
StaysOpen="False">
|
||||
<Popup.VerticalOffset>
|
||||
<MultiBinding Converter="{StaticResource DataGridCellBorderThicknessConverter}">
|
||||
<Binding Path="ActualWidth" RelativeSource="{RelativeSource Self}"/>
|
||||
<Binding Path="ActualWidth" ElementName="SettingsBtn"/>
|
||||
</MultiBinding>
|
||||
</Popup.VerticalOffset>
|
||||
<EgtBEAMWALL:OnlyProdBTLPartManagerV/>
|
||||
</Popup>
|
||||
</StackPanel>
|
||||
|
||||
@@ -83,3 +83,16 @@ Public Class OnlyProdBTLPartListV
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
|
||||
Public Class SettingsBtnVerticalOffsetMultiConverter
|
||||
Implements IMultiValueConverter
|
||||
|
||||
Public Function Convert(values() As Object, targetType As Type, parameter As Object, culture As Globalization.CultureInfo) As Object Implements IMultiValueConverter.Convert
|
||||
Dim x = 3
|
||||
Return 10
|
||||
End Function
|
||||
|
||||
Public Function ConvertBack(value As Object, targetTypes() As Type, parameter As Object, culture As Globalization.CultureInfo) As Object() Implements IMultiValueConverter.ConvertBack
|
||||
Throw New NotImplementedException()
|
||||
End Function
|
||||
End Class
|
||||
Reference in New Issue
Block a user