Compare commits
53 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| fd565e96cc | |||
| b7628fff66 | |||
| cd3c90764e | |||
| 0db2ce6b91 | |||
| 993e7e86a2 | |||
| e335308709 | |||
| 4c13cdb8f4 | |||
| 9b06802cf9 | |||
| caf4fbcff9 | |||
| 218eeaffe8 | |||
| 03509c7022 | |||
| 6a600e632d | |||
| b866cd273e | |||
| 7be4dd9c75 | |||
| 1d156eddc1 | |||
| 726afaa58d | |||
| d1592cce43 | |||
| dc6c075508 | |||
| f126f72c3b | |||
| 2735c66b11 | |||
| a4b48377c7 | |||
| bc22e32821 | |||
| 5624f05ad6 | |||
| 0c68d8c142 | |||
| e2480dcf1d | |||
| cc63f278c6 | |||
| 54360bbccf | |||
| c71d7c84f7 | |||
| 9e9aad2eed | |||
| a2a1b83888 | |||
| f44ae792c6 | |||
| 4692bd0308 | |||
| 2e863c0ce2 | |||
| 1735e281e5 | |||
| 125e7346d4 | |||
| bd3cdf7ea0 | |||
| d90a49248f | |||
| 3833b7c7c5 | |||
| 89b063b92f | |||
| df26bef2aa | |||
| 5cddbffb45 | |||
| 2daa33ba91 | |||
| f83e8294bc | |||
| 1dfc46e6ce | |||
| d7df513bf7 | |||
| 8aac3ea989 | |||
| a514a70b5b | |||
| cf86b93725 | |||
| fef104b371 | |||
| afe756aada | |||
| 34fa0909ab | |||
| a662d1dca2 | |||
| e5a32f9c21 |
@@ -1,5 +1,7 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.ComponentModel
|
||||
Imports EgtUILib
|
||||
Imports EgtUILib.EgtInterface
|
||||
|
||||
' Classe che definisce un elemento di base del TreeView
|
||||
Public Class TreeViewItemBase
|
||||
@@ -31,7 +33,7 @@ Public Class TreeViewItemBase
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Private m_isExpanded As Boolean
|
||||
Friend m_isExpanded As Boolean
|
||||
Public Property IsExpanded As Boolean
|
||||
Get
|
||||
Return m_isExpanded
|
||||
@@ -92,6 +94,7 @@ Public Class InheritableTreeViewItem
|
||||
Implements INotifyPropertyChanged
|
||||
|
||||
Friend m_Name As String
|
||||
|
||||
Public Property Name As String
|
||||
Get
|
||||
Return m_Name
|
||||
@@ -195,7 +198,6 @@ Public Class ParentItem
|
||||
Inherits TreeViewItemBase
|
||||
|
||||
Private m_sPictureString As String
|
||||
Private m_Items As ObservableCollection(Of ChildItem)
|
||||
|
||||
Public Property PictureString As String
|
||||
Get
|
||||
@@ -209,6 +211,7 @@ Public Class ParentItem
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Private m_Items As ObservableCollection(Of ChildItem)
|
||||
Public Property Items As ObservableCollection(Of ChildItem)
|
||||
Get
|
||||
Return m_Items
|
||||
@@ -255,4 +258,4 @@ Public Class ChildItem
|
||||
MyBase.New(Name, IsSelected, IsExpanded, IsActive)
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
End Class
|
||||
@@ -105,11 +105,15 @@ Module ConstIni
|
||||
Public Const S_IMPORT As String = "Import"
|
||||
Public Const K_DXFSCALE As String = "DxfScale"
|
||||
Public Const K_STLSCALE As String = "StlScale"
|
||||
Public Const K_OFFSCALE As String = "OffScale"
|
||||
Public Const K_PLYSCALE As String = "PlyScale"
|
||||
Public Const K_IMGSCALE As String = "ImgScale"
|
||||
Public Const K_CNCFLAG As String = "CncFlag"
|
||||
Public Const K_BTLFLAG As String = "BtlFlag"
|
||||
Public Const K_BTLAUXDIR As String = "BtlAuxDir"
|
||||
Public Const K_3MFFLAG As String = "3mfFlag"
|
||||
Public Const K_ADVFLAG As String = "AdvFlag"
|
||||
Public Const K_ADVTOLER As String = "AdvToler"
|
||||
|
||||
Public Const S_EXPORT As String = "Export"
|
||||
Public Const K_DXFFLAG As String = "DxfFlag"
|
||||
@@ -155,6 +159,7 @@ Module ConstIni
|
||||
Public Const K_TABLESDIR As String = "TablesDir"
|
||||
Public Const K_CURRMTABLE As String = "CurrMTable"
|
||||
Public Const K_MTABLEWINPLACE As String = "MTableWinPlace"
|
||||
Public Const K_OPTIMIZEMACHFORLINE As String = "OptimizeMachForLine"
|
||||
|
||||
Public Const S_GUNSTOCK As String = "GunStock"
|
||||
Public Const K_GUNSTOCKENABLE As String = "GsEnable"
|
||||
@@ -184,6 +189,7 @@ Module ConstIni
|
||||
Public Const K_SELGEOMSURFFINISHING As String = "SelGeomSurfFinishing"
|
||||
Public Const K_SELGEOMSURFROUGHING As String = "SelGeomSurfRoughing"
|
||||
Public Const K_SELGEOMFIVEAXMILLING As String = "SelGeomFiveAxMilling"
|
||||
Public Const K_SELGEOMPROBING As String = "SelGeomProbing"
|
||||
Public Const K_SELVMILLQUALITY As String = "VMillQuality"
|
||||
Public Const K_MACHININGGROUP As String = "MachiningGroup"
|
||||
Public Const K_SHOWONLYTABLE As String = "ShowOnlyTable"
|
||||
@@ -193,6 +199,7 @@ Module ConstIni
|
||||
Public Const S_SIMUL As String = "Simul"
|
||||
Public Const K_SLIDERX As String = "SliderX"
|
||||
Public Const K_SLIDERVAL As String = "SliderVal"
|
||||
Public Const K_TRACEENABLE As String = "TraceEnable"
|
||||
|
||||
Public Const S_OPTIONS As String = "Options"
|
||||
Public Const K_NEWMACHININGISLASTONE As String = "NewMachiningIsLastOne"
|
||||
|
||||
@@ -1,6 +1,10 @@
|
||||
Module ConstMachIni
|
||||
|
||||
Public Const S_PARTPROGRAM As String = "PartProgram"
|
||||
Public Const K_EXTENSION As String = "Extension"
|
||||
|
||||
Public Const S_TOOLS As String = "Tools"
|
||||
Public Const K_PROBE As String = "Probe"
|
||||
Public Const K_DRILLBIT As String = "Drillbit"
|
||||
Public Const K_SAWBLADE As String = "Sawblade"
|
||||
Public Const K_MILL As String = "Mill"
|
||||
@@ -8,22 +12,17 @@
|
||||
Public Const K_CHISEL As String = "Chisel"
|
||||
Public Const K_WATERJET As String = "WaterJet"
|
||||
Public Const K_COMPO As String = "Compo"
|
||||
Public Const K_SHOWTOOLCHANGER As String = "ShowToolChanger"
|
||||
Public Const K_SHOWHEADEXIT As String = "ShowHeadExit"
|
||||
Public Const K_DRILLHOLDER As String = "DrillHolder"
|
||||
Public Const K_SAWBLADEHOLDER As String = "SawBladeHolder"
|
||||
Public Const K_MILLHOLDER As String = "MillHolder"
|
||||
Public Const K_DRILLMAKER As String = "DrillMaker"
|
||||
Public Const K_SAWBLADEMAKER As String = "SawbladeMaker"
|
||||
Public Const K_MILLMAKER As String = "MillMaker"
|
||||
Public Const K_MORTISEMAKER As String = "MortiseMaker"
|
||||
Public Const K_CHISELMAKER As String = "ChiselMaker"
|
||||
Public Const K_MOUNTEDTOOLCONFIG As String = "MountedToolConfig"
|
||||
Public Const K_ACTIVE As String = "Active"
|
||||
|
||||
Public Const S_TOOLHOLDER As String = "ToolHolder"
|
||||
|
||||
Public Const S_MACHININGS As String = "Machinings"
|
||||
Public Const K_PROBING As String = "Probing"
|
||||
Public Const K_SAWING As String = "Sawing"
|
||||
Public Const K_DRILLING As String = "Drilling"
|
||||
Public Const K_MILLING As String = "Milling"
|
||||
@@ -37,18 +36,12 @@
|
||||
Public Const K_SURFFINISHING As String = "SurfFinishing"
|
||||
Public Const K_5AXMILLING As String = "5AxMilling"
|
||||
Public Const K_WATERJETTING As String = "WaterJetting"
|
||||
Public Const K_SAWINGONARCS As String = "SawingOnArcs"
|
||||
|
||||
Public Const S_GENMACHINING As String = "GenMachining"
|
||||
Public Const K_GENSCRIPT As String = "GenScript"
|
||||
|
||||
Public Const S_TOOLCHANGER As String = "ToolChanger"
|
||||
Public Const K_NUMBER As String = "Number"
|
||||
Public Const K_POS As String = "Pos"
|
||||
Public Const K_NAME As String = "Name"
|
||||
Public Const K_MANUALNUMBER As String = "ManualNumber"
|
||||
Public Const K_MANUALPOS As String = "ManualPos"
|
||||
Public Const K_MANUALNAME As String = "ManualName"
|
||||
Public Const S_5AXMILLING As String = "5AxMilling"
|
||||
Public Const K_5AXSCRIPT As String = "5AxScript"
|
||||
|
||||
Public Const S_DISPOSITION As String = "Disposition"
|
||||
Public Const K_DISP_INITSCRIPT As String = "InitScript"
|
||||
@@ -68,6 +61,9 @@
|
||||
Public Const S_VMILL As String = "VMill"
|
||||
Public Const K_VM_ENABLE As String = "Enable"
|
||||
|
||||
Public Const S_TOOLTRACE As String = "ToolTrace"
|
||||
Public Const K_TT_ENABLE As String = "Enable"
|
||||
|
||||
Public Const S_ESTIMATIONS As String = "Estimations"
|
||||
Public Const K_EST_ENABLE As String = "Enable"
|
||||
|
||||
|
||||
@@ -0,0 +1,4 @@
|
||||
Public Interface IListItemConverter
|
||||
Function Convert(ByVal masterListItem As Object) As Object
|
||||
Function ConvertBack(ByVal targetListItem As Object) As Object
|
||||
End Interface
|
||||
@@ -0,0 +1,80 @@
|
||||
Imports System.Windows.Controls.Primitives
|
||||
Imports System.ComponentModel
|
||||
|
||||
|
||||
Public Class MultiSelectorBehaviours
|
||||
|
||||
Public Shared ReadOnly SynchronizedSelectedItemsProperty As DependencyProperty = DependencyProperty.RegisterAttached("SynchronizedSelectedItems", GetType(IList), GetType(MultiSelectorBehaviours), New PropertyMetadata(Nothing, AddressOf OnSynchronizedSelectedItemsChanged))
|
||||
Public Shared ReadOnly SynchronizationManagerProperty As DependencyProperty = DependencyProperty.RegisterAttached("SynchronizationManager", GetType(SynchronizationManager), GetType(MultiSelectorBehaviours), New PropertyMetadata(Nothing))
|
||||
|
||||
|
||||
Public Shared Function GetSynchronizedSelectedItems(ByVal dependencyObject As DependencyObject) As IList
|
||||
Return CType(dependencyObject.GetValue(SynchronizedSelectedItemsProperty), IList)
|
||||
End Function
|
||||
|
||||
Public Shared Sub SetSynchronizedSelectedItems(ByVal dependencyObject As DependencyObject, ByVal value As IList)
|
||||
dependencyObject.SetValue(SynchronizedSelectedItemsProperty, value)
|
||||
End Sub
|
||||
|
||||
Private Shared Function GetSynchronizationManager(ByVal dependencyObject As DependencyObject) As SynchronizationManager
|
||||
Return CType(dependencyObject.GetValue(SynchronizationManagerProperty), SynchronizationManager)
|
||||
End Function
|
||||
|
||||
Private Shared Sub SetSynchronizationManager(ByVal dependencyObject As DependencyObject, ByVal value As SynchronizationManager)
|
||||
dependencyObject.SetValue(SynchronizationManagerProperty, value)
|
||||
End Sub
|
||||
|
||||
Private Shared Sub OnSynchronizedSelectedItemsChanged(ByVal dependencyObject As DependencyObject, ByVal e As DependencyPropertyChangedEventArgs)
|
||||
If e.OldValue IsNot Nothing Then
|
||||
Dim synchronizer As SynchronizationManager = GetSynchronizationManager(dependencyObject)
|
||||
synchronizer.StopSynchronizing()
|
||||
SetSynchronizationManager(dependencyObject, Nothing)
|
||||
End If
|
||||
|
||||
Dim list As IList = TryCast(e.NewValue, IList)
|
||||
Dim selector As Selector = TryCast(dependencyObject, Selector)
|
||||
|
||||
If list IsNot Nothing AndAlso selector IsNot Nothing Then
|
||||
Dim synchronizer As SynchronizationManager = GetSynchronizationManager(dependencyObject)
|
||||
|
||||
If synchronizer Is Nothing Then
|
||||
synchronizer = New SynchronizationManager(selector)
|
||||
SetSynchronizationManager(dependencyObject, synchronizer)
|
||||
End If
|
||||
|
||||
synchronizer.StartSynchronizingList()
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Class SynchronizationManager
|
||||
Private ReadOnly _multiSelector As Selector
|
||||
Private _synchronizer As TwoListSynchronizer
|
||||
|
||||
Friend Sub New(ByVal selector As Selector)
|
||||
_multiSelector = selector
|
||||
End Sub
|
||||
|
||||
Public Sub StartSynchronizingList()
|
||||
Dim list As IList = GetSynchronizedSelectedItems(_multiSelector)
|
||||
|
||||
If list IsNot Nothing Then
|
||||
_synchronizer = New TwoListSynchronizer(GetSelectedItemsCollection(_multiSelector), list)
|
||||
_synchronizer.StartSynchronizing()
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Public Sub StopSynchronizing()
|
||||
_synchronizer.StopSynchronizing()
|
||||
End Sub
|
||||
|
||||
Public Shared Function GetSelectedItemsCollection(ByVal selector As Selector) As IList
|
||||
If TypeOf selector Is MultiSelector Then
|
||||
Return (TryCast(selector, MultiSelector)).SelectedItems
|
||||
ElseIf TypeOf selector Is ListBox Then
|
||||
Return (TryCast(selector, ListBox)).SelectedItems
|
||||
Else
|
||||
Throw New InvalidOperationException("Target object has no SelectedItems property to bind.")
|
||||
End If
|
||||
End Function
|
||||
End Class
|
||||
End Class
|
||||
@@ -0,0 +1,163 @@
|
||||
Imports System.Collections.Specialized
|
||||
|
||||
Public Class TwoListSynchronizer
|
||||
Implements IWeakEventListener
|
||||
|
||||
Private Shared ReadOnly DefaultConverter As IListItemConverter = New DoNothingListItemConverter()
|
||||
Private ReadOnly _masterList As IList
|
||||
Private ReadOnly _masterTargetConverter As IListItemConverter
|
||||
Private ReadOnly _targetList As IList
|
||||
|
||||
Public Sub New(ByVal masterList As IList, ByVal targetList As IList, ByVal masterTargetConverter As IListItemConverter)
|
||||
_masterList = masterList
|
||||
_targetList = targetList
|
||||
_masterTargetConverter = masterTargetConverter
|
||||
End Sub
|
||||
|
||||
Public Sub New(ByVal masterList As IList, ByVal targetList As IList)
|
||||
Me.New(masterList, targetList, DefaultConverter)
|
||||
End Sub
|
||||
|
||||
Private Delegate Sub ChangeListAction(ByVal list As IList, ByVal e As NotifyCollectionChangedEventArgs, ByVal converter As Converter(Of Object, Object))
|
||||
|
||||
Public Sub StartSynchronizing()
|
||||
ListenForChangeEvents(_masterList)
|
||||
ListenForChangeEvents(_targetList)
|
||||
SetListValuesFromSource(_masterList, _targetList, New Converter(Of Object, Object)(AddressOf ConvertFromMasterToTarget))
|
||||
|
||||
If Not TargetAndMasterCollectionsAreEqual() Then
|
||||
SetListValuesFromSource(_targetList, _masterList, New Converter(Of Object, Object)(AddressOf ConvertFromTargetToMaster))
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Public Sub StopSynchronizing()
|
||||
StopListeningForChangeEvents(_masterList)
|
||||
StopListeningForChangeEvents(_targetList)
|
||||
End Sub
|
||||
|
||||
Public Function ReceiveWeakEvent(ByVal managerType As Type, ByVal sender As Object, ByVal e As EventArgs) As Boolean Implements IWeakEventListener.ReceiveWeakEvent
|
||||
HandleCollectionChanged(TryCast(sender, IList), TryCast(e, NotifyCollectionChangedEventArgs))
|
||||
Return True
|
||||
End Function
|
||||
|
||||
Protected Sub ListenForChangeEvents(ByVal list As IList)
|
||||
If TypeOf list Is INotifyCollectionChanged Then
|
||||
CollectionChangedEventManager.AddListener(TryCast(list, INotifyCollectionChanged), Me)
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Protected Sub StopListeningForChangeEvents(ByVal list As IList)
|
||||
If TypeOf list Is INotifyCollectionChanged Then
|
||||
CollectionChangedEventManager.RemoveListener(TryCast(list, INotifyCollectionChanged), Me)
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub AddItems(ByVal list As IList, ByVal e As NotifyCollectionChangedEventArgs, ByVal converter As Converter(Of Object, Object))
|
||||
Dim itemCount As Integer = e.NewItems.Count
|
||||
|
||||
For i As Integer = 0 To itemCount - 1
|
||||
Dim insertionPoint As Integer = e.NewStartingIndex + i
|
||||
|
||||
If insertionPoint > list.Count Then
|
||||
list.Add(converter(e.NewItems(i)))
|
||||
Else
|
||||
list.Insert(insertionPoint, converter(e.NewItems(i)))
|
||||
End If
|
||||
Next
|
||||
End Sub
|
||||
|
||||
Private Function ConvertFromMasterToTarget(ByVal masterListItem As Object) As Object
|
||||
Return If(_masterTargetConverter Is Nothing, masterListItem, _masterTargetConverter.Convert(masterListItem))
|
||||
End Function
|
||||
|
||||
Private Function ConvertFromTargetToMaster(ByVal targetListItem As Object) As Object
|
||||
Return If(_masterTargetConverter Is Nothing, targetListItem, _masterTargetConverter.ConvertBack(targetListItem))
|
||||
End Function
|
||||
|
||||
Private Sub HandleCollectionChanged(ByVal sender As Object, ByVal e As NotifyCollectionChangedEventArgs)
|
||||
Dim sourceList As IList = TryCast(sender, IList)
|
||||
|
||||
Select Case e.Action
|
||||
Case NotifyCollectionChangedAction.Add
|
||||
PerformActionOnAllLists(AddressOf AddItems, sourceList, e)
|
||||
Case NotifyCollectionChangedAction.Move
|
||||
PerformActionOnAllLists(AddressOf MoveItems, sourceList, e)
|
||||
Case NotifyCollectionChangedAction.Remove
|
||||
PerformActionOnAllLists(AddressOf RemoveItems, sourceList, e)
|
||||
Case NotifyCollectionChangedAction.Replace
|
||||
PerformActionOnAllLists(AddressOf ReplaceItems, sourceList, e)
|
||||
Case NotifyCollectionChangedAction.Reset
|
||||
UpdateListsFromSource(TryCast(sender, IList))
|
||||
Case Else
|
||||
End Select
|
||||
End Sub
|
||||
|
||||
Private Sub MoveItems(ByVal list As IList, ByVal e As NotifyCollectionChangedEventArgs, ByVal converter As Converter(Of Object, Object))
|
||||
RemoveItems(list, e, converter)
|
||||
AddItems(list, e, converter)
|
||||
End Sub
|
||||
|
||||
Private Sub PerformActionOnAllLists(ByVal action As ChangeListAction, ByVal sourceList As IList, ByVal collectionChangedArgs As NotifyCollectionChangedEventArgs)
|
||||
If sourceList Is _masterList Then
|
||||
PerformActionOnList(_targetList, action, collectionChangedArgs, New Converter(Of Object, Object)(AddressOf ConvertFromMasterToTarget))
|
||||
Else
|
||||
PerformActionOnList(_masterList, action, collectionChangedArgs, New Converter(Of Object, Object)(AddressOf ConvertFromTargetToMaster))
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub PerformActionOnList(ByVal list As IList, ByVal action As ChangeListAction, ByVal collectionChangedArgs As NotifyCollectionChangedEventArgs, ByVal converter As Converter(Of Object, Object))
|
||||
StopListeningForChangeEvents(list)
|
||||
action(list, collectionChangedArgs, converter)
|
||||
ListenForChangeEvents(list)
|
||||
End Sub
|
||||
|
||||
Private Sub RemoveItems(ByVal list As IList, ByVal e As NotifyCollectionChangedEventArgs, ByVal converter As Converter(Of Object, Object))
|
||||
If e.OldItems.Count = 1 AndAlso e.OldStartingIndex <= list.Count - 1 Then
|
||||
list.RemoveAt(e.OldStartingIndex)
|
||||
Else
|
||||
For Each Item In e.OldItems
|
||||
list.Remove(Item)
|
||||
Next
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub ReplaceItems(ByVal list As IList, ByVal e As NotifyCollectionChangedEventArgs, ByVal converter As Converter(Of Object, Object))
|
||||
RemoveItems(list, e, converter)
|
||||
AddItems(list, e, converter)
|
||||
End Sub
|
||||
|
||||
Private Sub SetListValuesFromSource(ByVal sourceList As IList, ByVal targetList As IList, ByVal converter As Converter(Of Object, Object))
|
||||
StopListeningForChangeEvents(targetList)
|
||||
targetList.Clear()
|
||||
|
||||
For Each o As Object In sourceList
|
||||
targetList.Add(converter(o))
|
||||
Next
|
||||
|
||||
ListenForChangeEvents(targetList)
|
||||
End Sub
|
||||
|
||||
Private Function TargetAndMasterCollectionsAreEqual() As Boolean
|
||||
Return _masterList.Cast(Of Object)().SequenceEqual(_targetList.Cast(Of Object)().[Select](Function(item) ConvertFromTargetToMaster(item)))
|
||||
End Function
|
||||
|
||||
Private Sub UpdateListsFromSource(ByVal sourceList As IList)
|
||||
If sourceList Is _masterList Then
|
||||
SetListValuesFromSource(_masterList, _targetList, New Converter(Of Object, Object)(AddressOf ConvertFromMasterToTarget))
|
||||
Else
|
||||
SetListValuesFromSource(_targetList, _masterList, New Converter(Of Object, Object)(AddressOf ConvertFromTargetToMaster))
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Friend Class DoNothingListItemConverter
|
||||
Implements IListItemConverter
|
||||
|
||||
Public Function Convert(ByVal masterListItem As Object) As Object Implements IListItemConverter.Convert
|
||||
Return masterListItem
|
||||
End Function
|
||||
|
||||
Public Function ConvertBack(ByVal targetListItem As Object) As Object Implements IListItemConverter.ConvertBack
|
||||
Return targetListItem
|
||||
End Function
|
||||
End Class
|
||||
End Class
|
||||
@@ -9,157 +9,102 @@
|
||||
|
||||
<StackPanel Background="Transparent" MaxHeight="{Binding MaxHeight,RelativeSource={RelativeSource AncestorType={x:Type EgtFloating:EgtFloatingPanel}}}">
|
||||
<Expander Name="Draw2D" Style="{StaticResource ExpanderStyle}" Grid.Row="0"
|
||||
IsExpanded="{Binding Draw2DIsExpanded}">
|
||||
IsExpanded="{Binding Draw2DIsExpanded}">
|
||||
<Expander.Header>
|
||||
<TextBlock Text="{Binding Draw2DMsg}"/>
|
||||
</Expander.Header>
|
||||
<UniformGrid Columns="3">
|
||||
<Button x:Name="PuntoBtn" ToolTip="Punto" Style="{StaticResource DrawPanelButton}"
|
||||
Command="{Binding PointBaseCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/Point+.png" Stretch="Uniform"/>
|
||||
<Button.ContextMenu>
|
||||
<ContextMenu Style="{StaticResource ContextMenu_Button}">
|
||||
<Button ToolTip="Vettore" Style="{StaticResource DrawPanelButton}"
|
||||
Command="{Binding PointVectorCommand}">
|
||||
<Image Source="/Resources/DrawPanel/Point.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="Riferimento" Style="{StaticResource DrawPanelButton}"
|
||||
Command="{Binding PointReferenceCommand}">
|
||||
<Image Source="/Resources/DrawPanel/Point.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</ContextMenu>
|
||||
</Button.ContextMenu>
|
||||
<Button ToolTip="{Binding PointToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding PointCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/Point.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="Linea 2 Punti" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding Line2PBaseCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/Line2P+.png" Stretch="Uniform"/>
|
||||
<Button.ContextMenu>
|
||||
<ContextMenu Style="{StaticResource ContextMenu_Button}">
|
||||
<Button ToolTip="Linea 2 Punti con Continuazione" Style="{StaticResource DrawPanelButton}"
|
||||
Command="{Binding Line2PContinuationCommand}">
|
||||
<Image Source="/Resources/DrawPanel/Line2P.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</ContextMenu>
|
||||
</Button.ContextMenu>
|
||||
<Button ToolTip="{Binding Line2PToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding Line2PCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/Line2P.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="Linea Punto Direzione Lunghezza" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding LinePDLBaseCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/LinePDL+.png" Stretch="Uniform"/>
|
||||
<Button.ContextMenu>
|
||||
<ContextMenu Style="{StaticResource ContextMenu_Button}">
|
||||
<Button ToolTip="Linea Punto Vettore Direzione Lunghezza" Style="{StaticResource DrawPanelButton}"
|
||||
Command="{Binding LinePDLVectorCommand}">
|
||||
<Image Source="/Resources/DrawPanel/Line2P.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</ContextMenu>
|
||||
</Button.ContextMenu>
|
||||
<Button ToolTip="{Binding LinePDLToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding LinePDLCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/LinePDL.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding ArcCSEToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ArcCSECommand}" IsEnabled="{Binding bLayerOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ArcCSECommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/ArcCSE.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding Arc2PRToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding Arc2PRCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/Arc2PR.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding Arc3PToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding Arc3PCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding Arc3PCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/Arc3P.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="Arco " Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ArcPDPCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/ArcPDP+.png" Stretch="Uniform"/>
|
||||
<Button.ContextMenu>
|
||||
<ContextMenu Style="{StaticResource ContextMenu_Button}">
|
||||
<Button ToolTip="Linea Punto Vettore Direzione Lunghezza" Style="{StaticResource DrawPanelButton}"
|
||||
Command="{Binding LinePDLVectorCommand}">
|
||||
<Image Source="/Resources/DrawPanel/ArcPDP.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</ContextMenu>
|
||||
</Button.ContextMenu>
|
||||
<Button ToolTip="{Binding ArcPDPToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ArcPDPCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/ArcPDP.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding CirclePDToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding CircleCPCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Button ToolTip="{Binding BiArcToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding BiArcCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/BiArc.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button Style="{StaticResource DrawPanelButton}"
|
||||
Visibility="Hidden"/>
|
||||
<Button ToolTip="{Binding CircleCPToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding CircleCPCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/CircleCP.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding Circle3PToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding Circle3PCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/Circle3P.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding CircleCDToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding CircleCDCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding CircleCDCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/CircleCD.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding Circle3PToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding Circle3PCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/Circle3P.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding Rectangle2PToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding Rectangle2PCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding Rectangle2PCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/Rectangle2P.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding PolygonToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding PolygonCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding PolygonCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/Polygon.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding PolygonSideToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding PolygonSideCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding PolygonSideCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/PolygonSide.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="Quota Lineare" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding LinearDimensionBaseCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/LinearDimension+.png" Stretch="Uniform"/>
|
||||
<Button.ContextMenu>
|
||||
<ContextMenu Style="{StaticResource ContextMenu_Button}">
|
||||
<Button ToolTip="Quota Allineata" Style="{StaticResource DrawPanelButton}"
|
||||
Command="{Binding AlignedDimensionCommand}">
|
||||
<Image Source="/Resources/DrawPanel/LinearDimension.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</ContextMenu>
|
||||
</Button.ContextMenu>
|
||||
<Button ToolTip="{Binding LinearDimensionToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding LinearDimensionCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/LinearDimension.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="Quota Angolare" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding AngularDimensionBaseCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/AngularDimension +.png" Stretch="Uniform"/>
|
||||
<Button.ContextMenu>
|
||||
<ContextMenu Style="{StaticResource ContextMenu_Button}">
|
||||
<Button ToolTip="Quota Angolare Avanzata" Style="{StaticResource DrawPanelButton}"
|
||||
Command="{Binding AlignedDimensionPlusCommand}">
|
||||
<Image Source="/Resources/DrawPanel/AngularDimension.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</ContextMenu>
|
||||
</Button.ContextMenu>
|
||||
<Button ToolTip="{Binding AngularDimensionToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding AngularDimensionCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/AngularDimension.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="Quota Diametrale" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding DiamDimensionCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/DiametralDimension+.png" Stretch="Uniform"/>
|
||||
<Button.ContextMenu>
|
||||
<ContextMenu Style="{StaticResource ContextMenu_Button}">
|
||||
<Button ToolTip="Quota Radiale" Style="{StaticResource DrawPanelButton}"
|
||||
Command="{Binding RadDimensionCommand}">
|
||||
<Image Source="/Resources/DrawPanel/DiametralDimension.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</ContextMenu>
|
||||
</Button.ContextMenu>
|
||||
<Button ToolTip="{Binding DiamRadDimensionToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding DiamRadDimensionCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/DiametralDimension.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="Testo" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding TextBaseCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/Text+.png" Stretch="Uniform"/>
|
||||
<Button.ContextMenu>
|
||||
<ContextMenu Style="{StaticResource ContextMenu_Button}">
|
||||
<Button ToolTip="Testo Avanzato" Style="{StaticResource DrawPanelButton}"
|
||||
Command="{Binding TextPlusCommand}">
|
||||
<Image Source="/Resources/DrawPanel/TextA.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</ContextMenu>
|
||||
</Button.ContextMenu>
|
||||
<Button ToolTip="{Binding TextToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding TextCommand}" IsEnabled="{Binding bLayerOk}">
|
||||
<Image Source="/Resources/DrawPanel/Text.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</UniformGrid>
|
||||
</Expander>
|
||||
@@ -169,135 +114,95 @@
|
||||
<TextBlock Text="{Binding Draw3DMsg}"/>
|
||||
</Expander.Header>
|
||||
<UniformGrid Columns="3">
|
||||
<Button ToolTip="Piano Contornato" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding FloorCommand}" IsEnabled="{Binding bLayerOkAndSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/Plane+.png" Stretch="Uniform"/>
|
||||
<Button.ContextMenu>
|
||||
<ContextMenu Style="{StaticResource ContextMenu_Button}">
|
||||
<Button ToolTip="Regione Piana" Style="{StaticResource DrawPanelButton}"
|
||||
Command="{Binding RegionCommand}">
|
||||
<Image Source="/Resources/DrawPanel/Plane.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</ContextMenu>
|
||||
</Button.ContextMenu>
|
||||
<Button ToolTip="{Binding PlaneToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding PlaneCommand}" IsEnabled="{Binding bLayerOkAndSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/Plane.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding ExtrudeToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ExtrudeCommand}" IsEnabled="{Binding bLayerOkAndSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ExtrudeCommand}" IsEnabled="{Binding bLayerOkAndSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/Extrude.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding RevolveToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding RevolveCommand}" IsEnabled="{Binding bLayerOkAndSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding RevolveCommand}" IsEnabled="{Binding bLayerOkAndSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/Revolve.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding ScrewToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ScrewCommand}" IsEnabled="{Binding bLayerOkAndSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ScrewCommand}" IsEnabled="{Binding bLayerOkAndSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/Screw.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding SweptToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding SweptCommand}" IsEnabled="{Binding bLayerOkAndSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding SweptCommand}" IsEnabled="{Binding bLayerOkAndSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/Swept.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding RuledToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding RuledCommand}" IsEnabled="{Binding bLayerOkAndSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding RuledCommand}" IsEnabled="{Binding bLayerOkAndSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/Ruled.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding SolidAddSurfToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding SolidAddSurfCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding SolidAddSurfCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/SolidAddSurf.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="Sottrai Superfici e Regioni Piane" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding SubtractSurfacesCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/SolidSubtractSurf+.png" Stretch="Uniform"/>
|
||||
<Button.ContextMenu>
|
||||
<ContextMenu Style="{StaticResource ContextMenu_Button}">
|
||||
<Button ToolTip="Taglia Superficie con Superficie Inversa" Style="{StaticResource DrawPanelButton}"
|
||||
Command="{Binding CutSurfacesCommand}">
|
||||
<Image Source="/Resources/DrawPanel/SolidSubtractSurf.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</ContextMenu>
|
||||
</Button.ContextMenu>
|
||||
<Button ToolTip="{Binding SolidSubtractSurfToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding SolidSubtractSurfCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/SolidSubtractSurf.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="Interseca Superfici e Regioni Piane" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding IntersectSurfCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/SolidIntersectSurf+.png" Stretch="Uniform"/>
|
||||
<Button.ContextMenu>
|
||||
<ContextMenu Style="{StaticResource ContextMenu_Button}">
|
||||
<Button ToolTip="Taglia Superficie con Superficie" Style="{StaticResource DrawPanelButton}"
|
||||
Command="{Binding CutSurfCommand}">
|
||||
<Image Source="/Resources/DrawPanel/SolidIntersectSurf.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</ContextMenu>
|
||||
</Button.ContextMenu>
|
||||
<Button ToolTip="{Binding SolidIntersectSurfToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding SolidIntersectSurfCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/SolidIntersectSurf.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding IntersectSurfSurfToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding IntersectSurfSurfCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding IntersectSurfSurfCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/IntersectSurfSurf.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding ExtractLoopsToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ExtractLoopsCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ExtractLoopsCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/ExtractLoops.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding ExtractFacetLoopsToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ExtractFacetLoopsCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ExtractFacetLoopsCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/ExtractFacetLoops.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="Esplodi Superfici e Regioni Piane" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ExplodeSurfaceCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/ExplodeSurf+.png" Stretch="Uniform"/>
|
||||
<Button.ContextMenu>
|
||||
<ContextMenu Style="{StaticResource ContextMenu_Button}">
|
||||
<Button ToolTip="Esplodi Superfici Mesh in Triangoli" Style="{StaticResource DrawPanelButton}"
|
||||
Command="{Binding ExplodeSurfaceMeshCommand}">
|
||||
<Image Source="/Resources/DrawPanel/ExplodeSurf.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</ContextMenu>
|
||||
</Button.ContextMenu>
|
||||
<Button ToolTip="{Binding ExplodeSurfToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ExplodeSurfCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/ExplodeSurf.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding ExtractSurfFacetToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ExtractSurfFacetCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ExtractSurfFacetCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/ExtractSurfFacet.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding MergeSurfToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding MergeSurfCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding MergeSurfCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/MergeSurf.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding InvertSurfToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding InvertSurfCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding InvertSurfCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/InvertSurf.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding ApproxSurfToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ApproxSurfCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ApproxSurfCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/ApproxSurf.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="Muovi Vertice di Superficie" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding MoveStmVertexCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/StmMoveVertex+.png" Stretch="Uniform"/>
|
||||
<Button.ContextMenu>
|
||||
<ContextMenu Style="{StaticResource ContextMenu_Button}">
|
||||
<Button ToolTip="Muovi Faccia di Superficie" Style="{StaticResource DrawPanelButton}"
|
||||
Command="{Binding MoveStmFacetCommand}">
|
||||
<Image Source="/Resources/DrawPanel/StmMoveVertex.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</ContextMenu>
|
||||
</Button.ContextMenu>
|
||||
<Button ToolTip="{Binding StmMoveVertexFacetToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding MoveStmVertexFacetCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/StmMoveVertex.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</UniformGrid>
|
||||
</Expander>
|
||||
@@ -307,22 +212,14 @@
|
||||
</Expander.Header>
|
||||
<UniformGrid Columns="3">
|
||||
<Button ToolTip="{Binding DeleteToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding DeleteCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding DeleteCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/Delete.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="Cambia Layer" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ChangeLayerBaseCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/ChangeLayer+.png" Stretch="Uniform"/>
|
||||
<Button.ContextMenu>
|
||||
<ContextMenu Style="{StaticResource ContextMenu_Button}">
|
||||
<Button ToolTip="Cambia Layer con Trasformazioni" Style="{StaticResource DrawPanelButton}"
|
||||
Command="{Binding ChangeLayerTrasfCommand}">
|
||||
<Image Source="/Resources/DrawPanel/ChangeLayer.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</ContextMenu>
|
||||
</Button.ContextMenu>
|
||||
<Button ToolTip="{Binding ChangeLayerToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ChangeLayerCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/ChangeLayer.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding ChangeStatusToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
@@ -330,159 +227,108 @@
|
||||
<Image Source="/Resources/DrawPanel/ChangeStatus.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding ChangeColorToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ChangeColorCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ChangeColorCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/ChangeColor.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding ChangeAlphaToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ChangeAlphaCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ChangeAlphaCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/ChangeColorAlpha.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding ResetColorToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ResetColorCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ResetColorCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/RemoveColor.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding InvertCurveToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding InvertCurveCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding InvertCurveCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/InvertCurve.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding ChangeStartToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ChangeStartCurveCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ChangeStartCurveCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/ChangeStart.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding ThickCurveToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding SetCurveThCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding SetCurveThCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/ThickCurve.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding ExtendCurveToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ExtendCurveCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ExtendCurveCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/ExtendCurve.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding BreakCurveToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding BreakCurveCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding BreakCurveCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/BreakCurve.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding SplitCurveToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding SplitCurveCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding SplitCurveCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/SplitCurve.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding ExplodeCurveToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ExplodeCurveCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ExplodeCurveCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/ExplodeCurve.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="Unisci Curve" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding JoinCurveBasCommand}" IsEnabled="{Binding bLayerOkAndSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/JoinCurve+.png" Stretch="Uniform"/>
|
||||
<Button.ContextMenu>
|
||||
<ContextMenu Style="{StaticResource ContextMenu_Button}">
|
||||
<Button ToolTip="Unisci Curve creando una Copia" Style="{StaticResource DrawPanelButton}"
|
||||
Command="{Binding JoinCurveCopyCommand}">
|
||||
<Image Source="/Resources/DrawPanel/JoinCurve.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="Fondi Curve nella Composita" Style="{StaticResource DrawPanelButton}"
|
||||
Command="{Binding JoinCurveCompositeCommand}">
|
||||
<Image Source="/Resources/DrawPanel/JoinCurve.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</ContextMenu>
|
||||
</Button.ContextMenu>
|
||||
<Button ToolTip="{Binding JoinCurveToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding JoinCurveCommand}" IsEnabled="{Binding bLayerOkAndSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/JoinCurve.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding OffsetToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding OffsetCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding OffsetCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/Offset.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding FilletToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding FilletCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding FilletCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/Fillet.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding ChamferToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ChamferCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ChamferCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/Chamfer.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="Arco Capovolto" Style="{StaticResource DrawPanelButton}"
|
||||
Command="{Binding UpsideDownArchCommand}" ToolTipService.ShowOnDisabled="True" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/ArcFlip+.png" Stretch="Uniform"/>
|
||||
<Button.ContextMenu >
|
||||
<ContextMenu Style="{StaticResource ContextMenu_Button}">
|
||||
<Button ToolTip="Arco Esplementare" Style="{StaticResource DrawPanelButton}"
|
||||
Command="{Binding ComplementaryArchCommand}">
|
||||
<Image Source="/Resources/DrawPanel/ArcFlip.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</ContextMenu>
|
||||
</Button.ContextMenu>
|
||||
<Button ToolTip="{Binding ArcFlipToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ArcFlipCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/ArcFlip.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding ModifyCurveToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ModifyCurveCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ModifyCurveCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/ModifyCurve.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="Aggiungi Punto" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding AddPointCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/AddPointCurve+.png" Stretch="Uniform"/>
|
||||
<Button.ContextMenu>
|
||||
<ContextMenu Style="{StaticResource ContextMenu_Button}">
|
||||
<Button ToolTip="Trasforma in Arco" Style="{StaticResource DrawPanelButton}"
|
||||
Command="{Binding TrasformArcCommand}">
|
||||
<Image Source="/Resources/DrawPanel/AddPointCurve.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="Chiudi Curva Composita" Style="{StaticResource DrawPanelButton}"
|
||||
Command="{Binding CloseCurveCommand}">
|
||||
<Image Source="/Resources/DrawPanel/AddPointCurve.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</ContextMenu>
|
||||
</Button.ContextMenu>
|
||||
</Button>
|
||||
<Button ToolTip="Rimuovi Punto" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding RemoveCurveCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/RemovePointCurve+.png" Stretch="Uniform"/>
|
||||
<Button.ContextMenu>
|
||||
<ContextMenu Style="{StaticResource ContextMenu_Button}">
|
||||
<Button ToolTip="Trasforma in Retta" Style="{StaticResource DrawPanelButton}"
|
||||
Command="{Binding TrasformRectCommand}">
|
||||
<Image Source="/Resources/DrawPanel/RemovePointCurve.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="Apri Curva Composita" Style="{StaticResource DrawPanelButton}"
|
||||
Command="{Binding OpenCurveCommand}">
|
||||
<Image Source="/Resources/DrawPanel/RemovePointCurve.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</ContextMenu>
|
||||
</Button.ContextMenu>
|
||||
</Button>
|
||||
<Button ToolTip="Approssima Curva" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ApproxCurveBaseCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/ApproxCurve+.png" Stretch="Uniform"/>
|
||||
<Button.ContextMenu>
|
||||
<ContextMenu Style="{StaticResource ContextMenu_Button}">
|
||||
<Button ToolTip="Approssima Curva con Linee" Style="{StaticResource DrawPanelButton}"
|
||||
Command="{Binding ApproxCurveLineCommand}">
|
||||
<Image Source="/Resources/DrawPanel/ApproxCurve.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</ContextMenu>
|
||||
</Button.ContextMenu>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding AddPointCurveToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding AddPointCurveCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/AddPointCurve.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding RemovePointCurveToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding RemovePointCurveCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/RemovePointCurve.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding ApproxCurveToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ApproxCurveCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/ApproxCurve.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding ModifyArcRadiusToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ModifyArcRadiusCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ModifyArcRadiusCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/ModifyArcRadius.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding ModifyTextToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ModifyTextCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ModifyTextCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/ModifyText.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</UniformGrid>
|
||||
@@ -493,8 +339,8 @@
|
||||
</Expander.Header>
|
||||
<UniformGrid Columns="3">
|
||||
<Button ToolTip="{Binding MoveToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding MoveCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding MoveCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/Move.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button Style="{StaticResource DrawPanelButton}"
|
||||
@@ -502,33 +348,33 @@
|
||||
<Button Style="{StaticResource DrawPanelButton}"
|
||||
Visibility="Hidden"/>
|
||||
<Button ToolTip="{Binding RotateToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding RotateCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding RotateCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/Rotate.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding MirrorToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding MirrorCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding MirrorCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/Mirror.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding ScaleToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ScaleCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding ScaleCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/Scale.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding Rotate3DToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding Rotate3DCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding Rotate3DCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/Rotate3D.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding Mirror3DToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding Mirror3DCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding Mirror3DCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/Mirror3D.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
<Button ToolTip="{Binding Scale3DToolTip}" Style="{StaticResource DrawPanelButton}"
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding Scale3DCommand}" IsEnabled="{Binding bSelOk}">
|
||||
ToolTipService.ShowOnDisabled="True"
|
||||
Command="{Binding Scale3DCommand}" IsEnabled="{Binding bSelOk}">
|
||||
<Image Source="/Resources/DrawPanel/Scale3D.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</UniformGrid>
|
||||
|
||||
@@ -161,6 +161,9 @@
|
||||
<DependentUpon>CurrSetUpV.xaml</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="CurrSetUp\CurrSetUpVM.vb" />
|
||||
<Compile Include="DataGridMultiselectManaging\IListItemConverter.vb" />
|
||||
<Compile Include="DataGridMultiselectManaging\MultiSelectorBehaviours.vb" />
|
||||
<Compile Include="DataGridMultiselectManaging\TwoListSynchronizer.vb" />
|
||||
<Compile Include="LeftTray\LeftTrayV.xaml.vb">
|
||||
<DependentUpon>LeftTrayV.xaml</DependentUpon>
|
||||
</Compile>
|
||||
@@ -170,6 +173,9 @@
|
||||
<DependentUpon>EstimationsExpanderV.xaml</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="OptionPanel\MachiningOptionPanel\EstimationsExpander\EstimationsExpander.vb" />
|
||||
<Compile Include="OptionPanel\MachiningOptionPanel\OperationExpander\MachiningParameterExpander\ProbingParameterExpanderV.xaml.vb">
|
||||
<DependentUpon>ProbingParameterExpanderV.xaml</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="OptionPanel\MachiningOptionPanel\OperationExpander\MachiningParameterExpander\FiveAxisMachinigParameterExpanderV.xaml.vb">
|
||||
<DependentUpon>FiveAxisMachinigParameterExpanderV.xaml</DependentUpon>
|
||||
</Compile>
|
||||
@@ -472,6 +478,10 @@
|
||||
<Generator>MSBuild:Compile</Generator>
|
||||
<SubType>Designer</SubType>
|
||||
</Page>
|
||||
<Page Include="OptionPanel\MachiningOptionPanel\OperationExpander\MachiningParameterExpander\ProbingParameterExpanderV.xaml">
|
||||
<Generator>MSBuild:Compile</Generator>
|
||||
<SubType>Designer</SubType>
|
||||
</Page>
|
||||
<Page Include="OptionPanel\MachiningOptionPanel\OperationExpander\MachiningParameterExpander\FiveAxisMachinigParameterExpanderV.xaml">
|
||||
<SubType>Designer</SubType>
|
||||
<Generator>MSBuild:Compile</Generator>
|
||||
@@ -1036,64 +1046,10 @@
|
||||
<Resource Include="Resources\DrawPanel\StmMoveVertex.png" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Resource Include="Resources\DrawPanel\Point+.png" />
|
||||
<Resource Include="Resources\DrawPanel\Arc2PR.png" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Resource Include="Resources\DrawPanel\Line2P+.png" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Resource Include="Resources\DrawPanel\LinePDL+.png" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Resource Include="Resources\DrawPanel\ArcPDP+.png" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Resource Include="Resources\DrawPanel\Text+.png" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Resource Include="Resources\DrawPanel\TextA.png" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Resource Include="Resources\DrawPanel\ArcFlip+.png" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Resource Include="Resources\DrawPanel\LinearDimension+.png" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Resource Include="Resources\DrawPanel\AngularDimension +.png" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Resource Include="Resources\DrawPanel\DiametralDimension+.png" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Resource Include="Resources\DrawPanel\Plane+.png" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Resource Include="Resources\DrawPanel\SolidSubtractSurf+.png" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Resource Include="Resources\DrawPanel\SolidIntersectSurf+.png" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Resource Include="Resources\DrawPanel\ExplodeSurf+.png" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Resource Include="Resources\DrawPanel\StmMoveVertex+.png" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Resource Include="Resources\DrawPanel\ChangeLayer+.png" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Resource Include="Resources\DrawPanel\JoinCurve+.png" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Resource Include="Resources\DrawPanel\AddPointCurve+.png" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Resource Include="Resources\DrawPanel\RemovePointCurve+.png" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Resource Include="Resources\DrawPanel\ApproxCurve+.png" />
|
||||
<Resource Include="Resources\DrawPanel\BiArc.png" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.VisualBasic.targets" />
|
||||
<PropertyGroup>
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:local="clr-namespace:EgtCAM5"
|
||||
DockPanel.Dock="Left">
|
||||
|
||||
|
||||
<local:DrawPanelV DataContext="{StaticResource DrawPanelViewModel}"/>
|
||||
|
||||
</Grid>
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
Imports System.IO
|
||||
Imports EgtCAM5.MyMachinePanelVM
|
||||
Imports System.Security.Cryptography
|
||||
Imports System.Windows.Forms.AxHost
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
|
||||
@@ -98,20 +97,23 @@ Public Class MyMachGroupPanelVM
|
||||
' Vuoi creare un nuovo Gruppo di Lavoro con i pezzi selezionati ? - LAVORA
|
||||
If MessageBox.Show(EgtMsg(5552), EgtMsg(5002), MessageBoxButton.YesNo, MessageBoxImage.Question) = MessageBoxResult.Yes Then
|
||||
Return If(AddNewMachGroup(nGroupId, vPart), 0, 1)
|
||||
Else
|
||||
Else
|
||||
Return -2
|
||||
End If
|
||||
End If
|
||||
' Se non ci sono pezzi selezionati
|
||||
' Se non ci sono pezzi selezionati
|
||||
Else
|
||||
' se ci sono gruppi di lavorazione
|
||||
If bMachGroup Then
|
||||
nGroupId = EgtGetFirstMachGroup()
|
||||
nGroupId = EgtGetCurrMachGroup()
|
||||
If nGroupId = GDB_ID.NULL Then
|
||||
nGroupId = EgtGetFirstMachGroup()
|
||||
End If
|
||||
Return If(EgtSetCurrMachGroup(nGroupId), 0, 1)
|
||||
' se altrimenti ammessi gruppi di lavoro vuoti
|
||||
' se altrimenti ammessi gruppi di lavoro vuoti
|
||||
ElseIf bAllowEmpty Then
|
||||
Return If(AddNewMachGroup(nGroupId, vPart), 0, 1)
|
||||
' altrimenti esco
|
||||
' altrimenti esco
|
||||
Else
|
||||
Return -1
|
||||
End If
|
||||
|
||||
@@ -1,16 +1,15 @@
|
||||
<EgtWPFLib5:EgtCustomWindow x:Class="MainWindowV"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:interactivity="clr-namespace:System.Windows.Interactivity;assembly=System.Windows.Interactivity"
|
||||
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
|
||||
xmlns:local="clr-namespace:EgtCAM5"
|
||||
Title="{Binding Title}" Icon="{Binding IconSource}"
|
||||
TitleBarBrush="{StaticResource EgaltechBlue1}" TitleBarHeight="32"
|
||||
BorderBrush="{StaticResource EgaltechBlue1}" BorderThickness="2"
|
||||
MinHeight="600" MinWidth="800" WindowStyle="None" ResizeMode="NoResize"
|
||||
AboutBoxCommand="{Binding AboutBoxCommand}"
|
||||
AllowDrop="True" Drop="MainWindow_Drop"
|
||||
SnapsToDevicePixels="True"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:interactivity="clr-namespace:System.Windows.Interactivity;assembly=System.Windows.Interactivity"
|
||||
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
|
||||
xmlns:local="clr-namespace:EgtCAM5"
|
||||
Title="{Binding Title}" Icon="{Binding IconSource}"
|
||||
TitleBarBrush="{StaticResource EgaltechBlue1}" TitleBarHeight="32"
|
||||
BorderBrush="{StaticResource EgaltechBlue1}" BorderThickness="2"
|
||||
MinHeight="600" MinWidth="800" WindowStyle="None" ResizeMode="NoResize"
|
||||
AboutBoxCommand="{Binding AboutBoxCommand}"
|
||||
AllowDrop="True" Drop="MainWindow_Drop"
|
||||
CloseCommand="{Binding CloseApplicationCommand,Mode=OneWay,UpdateSourceTrigger=PropertyChanged}">
|
||||
<EgtWPFLib5:EgtCustomWindow.TitlePanel>
|
||||
<local:TopCommandBarV DataContext="{StaticResource TopCommandBarViewModel}"/>
|
||||
|
||||
@@ -16,7 +16,6 @@ Public Class MainWindowVM
|
||||
Private m_sDataRoot As String = String.Empty
|
||||
Private m_sConfigDir As String = String.Empty
|
||||
Private m_OnTerminateProcessCallback As New OnTerminateProcessCallback(AddressOf OnTerminateProcess)
|
||||
Private m_IndexTab As Integer = 0
|
||||
|
||||
' EGALTECH ENVIRONMENT FIELDS WITH PROPERTY
|
||||
|
||||
@@ -386,8 +385,8 @@ Public Class MainWindowVM
|
||||
EgtSetLockId(sLockId)
|
||||
End If
|
||||
' Recupero livello e opzioni della chiave
|
||||
Dim bKey As Boolean = EgtGetKeyLevel(3279, 2611, 1, IniFile.m_nKeyLevel) And
|
||||
EgtGetKeyOptions(3279, 2611, 1, IniFile.m_nKeyOptions)
|
||||
Dim bKey As Boolean = EgtGetKeyLevel(3279, 2707, 1, IniFile.m_nKeyLevel) And
|
||||
EgtGetKeyOptions(3279, 2707, 1, IniFile.m_nKeyOptions)
|
||||
' Leggo e imposto livello utilizzatore
|
||||
IniFile.m_nUserLevel = Math.Min(IniFile.m_nKeyLevel, GetPrivateProfileInt(S_GENERAL, K_USERLEVEL, 1))
|
||||
' Imposto abilitazione lavorazioni avanzate
|
||||
@@ -423,14 +422,6 @@ Public Class MainWindowVM
|
||||
GetPrivateProfileString(S_GEOMDB, K_NFEFONTDIR, "", sNfeDir)
|
||||
GetPrivateProfileString(S_GEOMDB, K_DEFAULTFONT, "", OptionModule.m_sFontText)
|
||||
EgtSetFont(sNfeDir, OptionModule.m_sFontText)
|
||||
' Imposto direttorio ausiliario per import/gestione BTL
|
||||
Dim sBtlAuxDir As String = String.Empty
|
||||
GetPrivateProfileString(S_IMPORT, K_BTLAUXDIR, "", sBtlAuxDir)
|
||||
EgtSetBtlAuxDir(sBtlAuxDir)
|
||||
' Imposto direttorio libreria per export ThreeJs
|
||||
Dim sThreeJSLibDir As String = String.Empty
|
||||
GetPrivateProfileString(S_EXPORT, K_THREEJSLIBDIR, "", sThreeJSLibDir)
|
||||
EgtSetThreeJSLibDir(sThreeJSLibDir)
|
||||
' Imposto dir di default per libreria Lua e lancio libreria di base
|
||||
Dim sLuaLibsDir As String = String.Empty
|
||||
GetPrivateProfileString(S_LUA, K_LIBSDIR, "", sLuaLibsDir)
|
||||
@@ -438,6 +429,14 @@ Public Class MainWindowVM
|
||||
Dim sLuaBaseLib As String = String.Empty
|
||||
GetPrivateProfileString(S_LUA, K_BASELIB, "EgtBase", sLuaBaseLib)
|
||||
EgtLuaRequire(sLuaBaseLib)
|
||||
' Imposto direttorio ausiliario per import/gestione BTL (sempre dopo impostazioni lua)
|
||||
Dim sBtlAuxDir As String = String.Empty
|
||||
GetPrivateProfileString(S_IMPORT, K_BTLAUXDIR, "", sBtlAuxDir)
|
||||
EgtSetBtlAuxDir(sBtlAuxDir)
|
||||
' Imposto direttorio libreria per export ThreeJs
|
||||
Dim sThreeJSLibDir As String = String.Empty
|
||||
GetPrivateProfileString(S_EXPORT, K_THREEJSLIBDIR, "", sThreeJSLibDir)
|
||||
EgtSetThreeJSLibDir(sThreeJSLibDir)
|
||||
' Imposto direttorio temporaneo a EgtInterface
|
||||
EgtSetTempDir(m_sTempDir)
|
||||
' Imposto IniFile a EgtInterface
|
||||
@@ -598,6 +597,12 @@ Public Class MainWindowVM
|
||||
' pulisco output
|
||||
Map.refStatusBarVM.NotifyStatusOutput("")
|
||||
Map.refInputExpanderVM.ResetInputBox()
|
||||
If not IsNothing( Map.refMachiningParameterExpanderVM) Then
|
||||
' Nascondo la combobox delle usernotes
|
||||
Map.refMachiningParameterExpanderVM.CurrOperation.SetComboAddVisibility(Visibility.Collapsed)
|
||||
'riattivo il pulsante per visualizzare la combobox delle note
|
||||
Map.refMachiningParameterExpanderVM.CurrOperation.SetShowNoteListCombo_IsEnable(True)
|
||||
End If
|
||||
ElseIf e.Key = Key.Left OrElse e.Key = Key.Right OrElse e.Key = Key.Up OrElse e.Key = Key.Down AndAlso
|
||||
Map.refTopCommandBarVM.MachiningIsChecked AndAlso Map.refOperationParametersExpanderVM.OperationParameters.IsEnabled Then
|
||||
Map.refMachiningParameterExpanderVM.FocusSlider()
|
||||
|
||||
@@ -30,7 +30,7 @@ Imports System.Windows
|
||||
#End If
|
||||
<Assembly: AssemblyCompany("Egalware s.r.l.")>
|
||||
<Assembly: AssemblyProduct("EgtCAM5")>
|
||||
<Assembly: AssemblyCopyright("Copyright © 2016-2024 by Egalware s.r.l.")>
|
||||
<Assembly: AssemblyCopyright("Copyright © 2016-2025 by Egalware s.r.l.")>
|
||||
<Assembly: AssemblyTrademark("")>
|
||||
<Assembly: ComVisible(false)>
|
||||
|
||||
@@ -70,6 +70,6 @@ Imports System.Windows
|
||||
' by using the '*' as shown below:
|
||||
' <Assembly: AssemblyVersion("1.0.*")>
|
||||
|
||||
<Assembly: AssemblyVersion("2.6.11.1")>
|
||||
<Assembly: AssemblyFileVersion("2.6.11.1")>
|
||||
<Assembly: AssemblyVersion("2.7.7.2")>
|
||||
<Assembly: AssemblyFileVersion("2.7.7.2")>
|
||||
|
||||
|
||||
@@ -3,12 +3,12 @@
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
|
||||
|
||||
<Expander IsExpanded="{Binding IsEnabled}" IsEnabled="{Binding IsEnabled}"
|
||||
Style="{StaticResource ExpanderStyle}">
|
||||
Style="{StaticResource ExpanderStyle}">
|
||||
<Expander.Header>
|
||||
<TextBlock Text="{Binding PropertiesMsg}"/>
|
||||
</Expander.Header>
|
||||
<UniformGrid>
|
||||
<TextBox Text="{Binding InfoBox, Mode=OneWay}" MaxHeight="250" IsReadOnly="True"
|
||||
<TextBox Text="{Binding InfoBox, Mode=OneWay}" MaxHeight="100" IsReadOnly="True"
|
||||
HorizontalScrollBarVisibility="Auto" VerticalScrollBarVisibility="Auto"/>
|
||||
</UniformGrid>
|
||||
</Expander>
|
||||
|
||||
@@ -1,9 +1,11 @@
|
||||
<UserControl x:Class="InputExpanderV"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:EgtCAM5="clr-namespace:EgtCAM5"
|
||||
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5">
|
||||
|
||||
<Expander Header="{Binding Title}" IsExpanded="{Binding IsExpanded}" IsEnabled="{Binding IsEnabled}"
|
||||
Style="{StaticResource ExpanderStyle}">
|
||||
Style="{StaticResource ExpanderStyle}">
|
||||
<StackPanel>
|
||||
<StackPanel.Style>
|
||||
<Style TargetType="{x:Type StackPanel}">
|
||||
@@ -16,26 +18,75 @@
|
||||
</StackPanel.Style>
|
||||
<TextBlock Text="{Binding TextBlock}"
|
||||
Visibility="{Binding TextVisibility}" Margin="5,5,0,5"/>
|
||||
<TextBox Text="{Binding TextBox,UpdateSourceTrigger=PropertyChanged}"
|
||||
Visibility="{Binding TextVisibility}" Margin="5,0,5,5">
|
||||
<TextBox.InputBindings>
|
||||
<KeyBinding Key="Enter" Command="{Binding DoneCommand}"/>
|
||||
<KeyBinding Key="S" Modifiers="Control" Command="{Binding ShowCommand}"/>
|
||||
</TextBox.InputBindings>
|
||||
</TextBox>
|
||||
<Grid>
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<TextBox x:Name="Txt" Text="{Binding TextBox,UpdateSourceTrigger=PropertyChanged}"
|
||||
PreviewKeyDown="TextBox_PreviewKeyDown" Height="Auto"
|
||||
Visibility="{Binding TextVisibility}" Margin="5,0,5,5" >
|
||||
<TextBox.InputBindings>
|
||||
<KeyBinding Key="Enter" Command="{Binding DoneCommand}"/>
|
||||
<KeyBinding Key="S" Modifiers="Control" Command="{Binding ShowCommand}"/>
|
||||
</TextBox.InputBindings>
|
||||
</TextBox>
|
||||
<Button Grid.Column="1"
|
||||
Content="+"
|
||||
Command="{Binding ShowInfoItemCommand}"
|
||||
Visibility="Collapsed"
|
||||
Width="20"
|
||||
Height="20"
|
||||
Margin="5,-1,5,0"
|
||||
VerticalAlignment="Top"/>
|
||||
<!--Visibility="{Binding ShowInfoItemVisibility}"-->
|
||||
</Grid>
|
||||
<CheckBox Content="{Binding CheckBoxText}" IsChecked="{Binding IsChecked}"
|
||||
Visibility="{Binding CheckVisibility}" Margin="5,0,5,5"/>
|
||||
<ComboBox ItemsSource="{Binding ComboItemsList}" SelectedIndex="{Binding ComboSelectedIndex}"
|
||||
Visibility="{Binding ComboVisibility}" Margin="5,0,5,5"/>
|
||||
Visibility="{Binding ComboVisibility}" Margin="5,5,5,5"/>
|
||||
|
||||
<ItemsControl ItemsSource="{Binding InfoList}"
|
||||
Visibility="{Binding InfoVisibility}"
|
||||
Margin="5,5,0,10">
|
||||
<ItemsControl.ItemTemplate>
|
||||
<DataTemplate>
|
||||
<Grid>
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<TextBlock Text="{Binding Key}"
|
||||
Width="70"
|
||||
Margin="0,6,-15,0"/>
|
||||
<TextBox Grid.Column="1"
|
||||
Text="{Binding Valour, UpdateSourceTrigger=PropertyChanged}"
|
||||
Margin="0,5,5,10">
|
||||
<TextBox.InputBindings>
|
||||
<KeyBinding Key="Enter" Command="{Binding DoneInfoCommand}"/>
|
||||
</TextBox.InputBindings>
|
||||
</TextBox>
|
||||
<Button Grid.Column="2"
|
||||
Content="-"
|
||||
Command="{Binding RemoveInfoItemCommand}"
|
||||
Width="20"
|
||||
Height="20"
|
||||
Margin="5,-2,5,5"/>
|
||||
</Grid>
|
||||
</DataTemplate>
|
||||
</ItemsControl.ItemTemplate>
|
||||
</ItemsControl>
|
||||
|
||||
<Grid Margin="5,0,5,5">
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<Button Command="{Binding ShowCommand}" Visibility="{Binding ShowBtnVisibility}"
|
||||
Content="{Binding ShowMsg}" Style="{StaticResource EgtCAM5_InputButton}"/>
|
||||
Content="{Binding ShowMsg}" Style="{StaticResource EgtCAM5_InputButton}"/>
|
||||
<Button Command="{Binding DoneCommand}" Grid.Column="1"
|
||||
Content="{Binding OkMsg}" Style="{StaticResource EgtCAM5_InputButton}"/>
|
||||
Content="{Binding OkMsg}" Style="{StaticResource EgtCAM5_InputButton}"/>
|
||||
</Grid>
|
||||
</StackPanel>
|
||||
</Expander>
|
||||
|
||||
@@ -1,3 +1,11 @@
|
||||
Public Class InputExpanderV
|
||||
|
||||
Private Sub TextBox_PreviewKeyDown(sender As Object, e As KeyEventArgs)
|
||||
If (e.Key = Key.Enter And (Keyboard.Modifiers And ModifierKeys.Shift)= ModifierKeys.Shift) Or
|
||||
(e.Key = Key.V And (Keyboard.Modifiers And ModifierKeys.Control) = ModifierKeys.Control) Then
|
||||
Txt.AcceptsReturn = True
|
||||
Txt.TextWrapping = TextWrapping.Wrap
|
||||
End If
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
|
||||
@@ -1,11 +1,29 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports EgtUILib
|
||||
Imports MS.Internal
|
||||
|
||||
Public Class InputExpanderVM
|
||||
Inherits ViewModelBase
|
||||
|
||||
#Region "FIELDS & PROPERTIES"
|
||||
|
||||
' Variabile temporanea per salvare bShow
|
||||
Private m_tmpbShow As Boolean
|
||||
|
||||
Private m_tmpInfoList As New ObservableCollection(Of InfoItem)
|
||||
''' <summary>
|
||||
''' Lista temporanea delle info
|
||||
''' </summary>
|
||||
Private Property tmpInfoList As ObservableCollection(Of InfoItem)
|
||||
Get
|
||||
Return m_tmpInfoList
|
||||
End Get
|
||||
Set(value As ObservableCollection(Of InfoItem))
|
||||
m_tmpInfoList = value
|
||||
OnPropertyChanged("tmpInfoList")
|
||||
End Set
|
||||
End Property
|
||||
|
||||
' Expander fields
|
||||
Private m_IsExpanded As Boolean
|
||||
Public Property IsExpanded As Boolean
|
||||
@@ -140,15 +158,47 @@ Public Class InputExpanderVM
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Private m_InfoList As New ObservableCollection(Of InfoItem)
|
||||
''' <summary>
|
||||
''' Lista delle info modificate
|
||||
''' </summary>
|
||||
Public Property InfoList As ObservableCollection(Of InfoItem)
|
||||
Get
|
||||
Return m_InfoList
|
||||
End Get
|
||||
Set(value As ObservableCollection(Of InfoItem))
|
||||
m_InfoList = value
|
||||
OnPropertyChanged("InfoList")
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Private m_ComboSelectedIndex As Integer
|
||||
Public Property ComboSelectedIndex As Integer
|
||||
Get
|
||||
Return m_ComboSelectedIndex
|
||||
End Get
|
||||
Set(value As Integer)
|
||||
Map.refProjectVM.SetLastInteger(value)
|
||||
If m_tmpbShow Then Map.refProjectVM.SetLastInteger(value)
|
||||
m_ComboSelectedIndex = value
|
||||
' Assegno l'indice selezionato ad una variabile temporanea per utilizzarlo quando rimuovo l'info dalla lista
|
||||
Dim tmpComboSelectedIndex As Integer = ComboSelectedIndex
|
||||
' Controllo se l'indice è maggiore o uguale a zero e la lista tmp contiene valori
|
||||
If m_ComboSelectedIndex >= 0 AndAlso tmpInfoList.Count > 0 Then
|
||||
' Controllo se la info è contenuta nella lista ComboItemsList
|
||||
If ComboItemsList.Contains(tmpInfoList(m_ComboSelectedIndex).sKey) Then
|
||||
' Aggiungo la info alla lista per visualizzarla
|
||||
InfoList.Add(New InfoItem(tmpInfoList(m_ComboSelectedIndex).nId, tmpInfoList(m_ComboSelectedIndex).sKey, m_tmpInfoList(m_ComboSelectedIndex).sValour))
|
||||
' Nascondo la combobox
|
||||
ComboVisibility = Visibility.Collapsed
|
||||
' Rimuovo la info dalla ComboItemsList
|
||||
ComboItemsList.Remove(tmpInfoList(m_ComboSelectedIndex).sKey)
|
||||
End If
|
||||
' Rimuovo la info dalla tmpInfoList
|
||||
tmpInfoList.Remove(tmpInfoList(tmpComboSelectedIndex))
|
||||
End If
|
||||
OnPropertyChanged("ComboSelectedIndex")
|
||||
OnPropertyChanged("ComboItemsList")
|
||||
OnPropertyChanged("InfoList")
|
||||
End Set
|
||||
End Property
|
||||
|
||||
@@ -177,9 +227,43 @@ Public Class InputExpanderVM
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Private m_ShowInfoItemVisibility As Visibility
|
||||
''' <summary>
|
||||
''' Propietà visibilità bottone +
|
||||
''' </summary>
|
||||
Public Property ShowInfoItemVisibility As Visibility
|
||||
Get
|
||||
Return m_ShowInfoItemVisibility
|
||||
End Get
|
||||
Set(value As Visibility)
|
||||
If value <> m_ShowInfoItemVisibility Then
|
||||
m_ShowInfoItemVisibility = value
|
||||
OnPropertyChanged("ShowInfoItemVisibility")
|
||||
End If
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Private m_InfoVisibility As Visibility
|
||||
''' <summary>
|
||||
''' Propietà visibilità lista info modificate
|
||||
''' </summary>
|
||||
Public Property InfoVisibility As Visibility
|
||||
Get
|
||||
Return m_InfoVisibility
|
||||
End Get
|
||||
Set(value As Visibility)
|
||||
If value <> m_InfoVisibility Then
|
||||
m_InfoVisibility = value
|
||||
OnPropertyChanged("InfoVisibility")
|
||||
End If
|
||||
End Set
|
||||
End Property
|
||||
|
||||
' Commands definition
|
||||
Private m_cmdShow As ICommand
|
||||
Private m_cmdDone As ICommand
|
||||
Private m_cmdShowInfoItem As ICommand
|
||||
Private m_cmdRemoveInfoItem As ICommand
|
||||
|
||||
#Region "Messages"
|
||||
|
||||
@@ -257,6 +341,15 @@ Public Class InputExpanderVM
|
||||
''' Execute the Point. This method is invoked by the PointCommand.
|
||||
''' </summary>
|
||||
Public Sub Done(ByVal param As Object)
|
||||
' Controllo se la lista contenente la info modificata sia presente
|
||||
If InfoList.Count > 0 Then
|
||||
' Ciclo sulla lista
|
||||
For Each Item As InfoItem In InfoList
|
||||
Map.refProjectVM.NotifyInputText((Item.Key & "=" & Item.Valour).Trim())
|
||||
' Assegno a m_TextBox la info modificata
|
||||
m_TextBox &= vbCrLf & (Item.Key & "=" & Item.Valour).Trim() & vbCrLf
|
||||
Next
|
||||
End If
|
||||
Map.refProjectVM.Done(m_TextBox)
|
||||
End Sub
|
||||
|
||||
@@ -269,6 +362,30 @@ Public Class InputExpanderVM
|
||||
|
||||
#End Region ' DoneCommand
|
||||
|
||||
#Region "ShowInfoItemCommand"
|
||||
|
||||
''' <summary>
|
||||
''' Comando per la visualizzazione della combobox
|
||||
''' </summary>
|
||||
Public ReadOnly Property ShowInfoItemCommand As ICommand
|
||||
Get
|
||||
If m_cmdShowInfoItem Is Nothing Then
|
||||
m_cmdShowInfoItem = New Command(AddressOf ShowInfoItem)
|
||||
End If
|
||||
Return m_cmdShowInfoItem
|
||||
End Get
|
||||
End Property
|
||||
|
||||
''' <summary>
|
||||
''' Funzione per la visualizzazione della combobox
|
||||
''' </summary>
|
||||
''' <param name="param"></param>
|
||||
Public Sub ShowInfoItem(ByVal param As Object)
|
||||
ComboVisibility = Visibility.Visible
|
||||
End Sub
|
||||
|
||||
#End Region ' ShowInfoItemCommand
|
||||
|
||||
#End Region
|
||||
|
||||
#Region "METHODS"
|
||||
@@ -279,13 +396,37 @@ Public Class InputExpanderVM
|
||||
TextBlock = PrepareInputBoxParam.sLabel
|
||||
TextBox = ""
|
||||
TextVisibility = Visibility.Visible
|
||||
' Controllo se il titolo è uguale a INFO se si
|
||||
If Title = EgtMsg(5359).ToUpper() Then
|
||||
' Metto tmpbShow a false
|
||||
m_tmpbShow = False
|
||||
' Rendo visibile il pulsante che mostra la lista delle info
|
||||
ShowInfoItemVisibility = Visibility.Visible
|
||||
' Rendo visibile la lista delle info selezionate
|
||||
InfoVisibility = Visibility.Visible
|
||||
' Pulisco la lista tmpInfoList
|
||||
tmpInfoList.Clear()
|
||||
' Pulisco la lista InfoList
|
||||
InfoList.Clear()
|
||||
' Pulisco la lista ComboItemsList
|
||||
ComboItemsList.Clear()
|
||||
' Popolo la lista ComboItemsList
|
||||
ComboInfo()
|
||||
End If
|
||||
End If
|
||||
If PrepareInputBoxParam.sCheckLabel <> "" Then
|
||||
CheckBoxText = PrepareInputBoxParam.sCheckLabel
|
||||
CheckVisibility = Visibility.Visible
|
||||
End If
|
||||
If PrepareInputBoxParam.bShowCombo Then
|
||||
' Assegno a tmpbShow PrepareInputBoxParam.bShowCombo
|
||||
m_tmpbShow = PrepareInputBoxParam.bShowCombo
|
||||
' Pulisco la lista ComboItemsList
|
||||
ComboItemsList.Clear()
|
||||
' Pulisco la lista tmpInfoList
|
||||
tmpInfoList.Clear()
|
||||
' Pulisco la lista InfoList
|
||||
InfoList.Clear()
|
||||
ComboVisibility = Visibility.Visible
|
||||
End If
|
||||
If PrepareInputBoxParam.bShowBtn Then
|
||||
@@ -302,6 +443,8 @@ Public Class InputExpanderVM
|
||||
CheckVisibility = Visibility.Collapsed
|
||||
ComboVisibility = Visibility.Collapsed
|
||||
ShowBtnVisibility = Visibility.Collapsed
|
||||
ShowInfoItemVisibility = Visibility.Collapsed
|
||||
InfoVisibility = Visibility.Collapsed
|
||||
IsExpanded = False
|
||||
IsEnabled = False
|
||||
End Sub
|
||||
@@ -329,12 +472,44 @@ Public Class InputExpanderVM
|
||||
|
||||
Private Function AddInputBoxCombo(ByVal sText As String, ByVal bSelected As Boolean) As Boolean
|
||||
ComboItemsList.Add(sText)
|
||||
|
||||
If bSelected Then
|
||||
ComboSelectedIndex = ComboItemsList.Count - 1
|
||||
End If
|
||||
Return True
|
||||
End Function
|
||||
|
||||
''' <summary>
|
||||
''' Rimovi nota da info lista
|
||||
''' </summary>
|
||||
''' <param name="InfoItem">Informazione da eliminare</param>
|
||||
Friend Sub RemoveItemInfo(InfoItem As InfoItem)
|
||||
' Rimuovo info da lista modifica
|
||||
InfoList.Remove(InfoItem)
|
||||
' Riaggiungo la info eliminata
|
||||
ComboItemsList.Add(InfoItem.sKey)
|
||||
' Riaggiungo la info eliminata
|
||||
tmpInfoList.Add(InfoItem)
|
||||
End Sub
|
||||
|
||||
''' <summary>
|
||||
''' Funzione che popola la lista ComboItemsList
|
||||
''' </summary>
|
||||
Private Sub ComboInfo()
|
||||
'''''''''''''''''''''''''''''' Recuperare funzione egtgetallinfo quando sarà pronta
|
||||
Dim val As Integer
|
||||
If Not m_tmpbShow Then
|
||||
For Ind As Integer = 0 To 6
|
||||
val += Ind
|
||||
tmpInfoList.Add(New InfoItem(Ind, "A" & +Ind, val.ToString()))
|
||||
Next
|
||||
|
||||
For Each InfoItem As InfoItem In tmpInfoList
|
||||
ComboItemsList.Add(InfoItem.sKey)
|
||||
Next
|
||||
End If
|
||||
End Sub
|
||||
|
||||
#End Region ' Methods
|
||||
|
||||
End Class
|
||||
|
||||
@@ -69,17 +69,17 @@ Public Class LayerTreeViewItem
|
||||
Return m_bOnOff
|
||||
End Get
|
||||
Set(value As Boolean)
|
||||
If Map.refProjectVM.GetController().GetStep() <> 0 Then Return
|
||||
'If Map.refProjectVM.GetController().GetStep() <> 0 Then Return
|
||||
If m_bOnOff <> value Then
|
||||
m_bOnOff = value
|
||||
' se abilitato, eseguo operazione
|
||||
If m_SendCmd Then
|
||||
Map.refProjectVM.SetLastInteger(Id)
|
||||
If value Then
|
||||
Map.refProjectVM.ExecuteCommand(Controller.CMD.SHOW)
|
||||
EgtSetStatus(Id, GDB_ST.ON_)
|
||||
Else
|
||||
Map.refProjectVM.ExecuteCommand(Controller.CMD.HIDE)
|
||||
EgtSetStatus(Id, GDB_ST.OFF)
|
||||
End If
|
||||
EgtDraw()
|
||||
End If
|
||||
Dim bOnOffGroup As Boolean = ((Keyboard.Modifiers And ModifierKeys.Shift) = ModifierKeys.Shift) AndAlso Items.Count > 0
|
||||
If bOnOffGroup Then
|
||||
|
||||
@@ -20,8 +20,8 @@
|
||||
<Button Content="{Binding NewLayerMsg}" Command="{Binding NewLayerCommand}" Height="30"/>
|
||||
<Button Content="{Binding ColorMsg}" Command="{Binding LayerColorCommand}" Height="30"/>
|
||||
</UniformGrid>
|
||||
|
||||
<TreeView Name="LayerTreeView" MinHeight="250" MaxHeight="400"
|
||||
|
||||
<TreeView x:Name="LayerTreeView" MinHeight="300" MaxHeight="400"
|
||||
ItemsSource="{Binding Path=LayerList}"
|
||||
VirtualizingStackPanel.IsVirtualizing = "True"
|
||||
VirtualizingStackPanel.VirtualizationMode = "Recycling">
|
||||
@@ -50,8 +50,8 @@
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
|
||||
<ToggleButton Style="{StaticResource EgtCAM5_LampToggleButton}" Grid.Column="0"
|
||||
IsChecked="{Binding OnOff}" Visibility="{Binding IsHidden}" Focusable="False" Height="15" Width="15" Margin="0,0,5,0"/>
|
||||
<ToggleButton Style="{StaticResource EgtCAM5_LampToggleButton}" Grid.Column="0"
|
||||
IsChecked="{Binding OnOff}" Visibility="{Binding IsHidden}" Focusable="True" Height="15" Width="15" Margin="0,0,5,0"/>
|
||||
<Image Grid.Column="1" Source="{Binding PictureString}" Height="15" Margin="0,0,5,0"/>
|
||||
<TextBlock Grid.Column="2" Text="{Binding Name}" Margin="0,0,5,0"/>
|
||||
<Ellipse Grid.Column="3" Height="10" Width="10" Fill="{Binding LayerColor}" />
|
||||
@@ -61,7 +61,7 @@
|
||||
</TreeView.Resources>
|
||||
|
||||
<!--Style dei nodi CathegoryItem che li riquadra di azzurro quando clicckati ed elimina l'ombra grigia
|
||||
che si presenta quando la categoria rimane vuota (ombra causata dal multibinding).-->
|
||||
che si presenta quando la categoria rimane vuota (ombra causata dal multibinding).-->
|
||||
<TreeView.ItemContainerStyle>
|
||||
<Style TargetType="{x:Type TreeViewItem}">
|
||||
<Setter Property="IsSelected" Value="{Binding IsSelected, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}" />
|
||||
|
||||
@@ -166,7 +166,7 @@ Public Class ManageLayerExpanderVM
|
||||
Public Sub NewPart(ByVal param As Object)
|
||||
Map.refProjectVM.ExecuteCommand(Controller.CMD.NEWPART)
|
||||
' Seleziono nell'albero il layer del pezzo appena creato
|
||||
SelectIdInObjTree(EgtGetCurrLayer(), False)
|
||||
SelectIdInObjTreeNoMark(EgtGetCurrLayer())
|
||||
End Sub
|
||||
|
||||
#End Region ' NewPartCommand
|
||||
@@ -191,7 +191,7 @@ Public Class ManageLayerExpanderVM
|
||||
Public Sub NewLayer(ByVal param As Object)
|
||||
Map.refProjectVM.ExecuteCommand(Controller.CMD.NEWLAYER)
|
||||
' Seleziono nell'albero il layer appena creato
|
||||
SelectIdInObjTree(EgtGetCurrLayer(), False)
|
||||
SelectIdInObjTreeNoMark(EgtGetCurrLayer())
|
||||
End Sub
|
||||
|
||||
#End Region ' NewLayerCommand
|
||||
@@ -492,7 +492,7 @@ Public Class ManageLayerExpanderVM
|
||||
Map.refProjectVM.SetLastInteger(RightClickedTreeItemId)
|
||||
Map.refProjectVM.ExecuteCommand(Controller.CMD.DELETE)
|
||||
' Seleziono prossimo
|
||||
SelectIdInObjTree(nNewId, False)
|
||||
SelectIdInObjTreeNoMark(nNewId)
|
||||
End Sub
|
||||
|
||||
#End Region ' DeleteCommand
|
||||
@@ -528,16 +528,18 @@ Public Class ManageLayerExpanderVM
|
||||
#Region "METHODS"
|
||||
|
||||
Private WithEvents ObjTreeTimer As New System.Windows.Threading.DispatcherTimer
|
||||
Private m_nObjTreeOldId As Integer = GDB_ID.NULL
|
||||
Friend m_nObjTreeOldId As Integer = GDB_ID.NULL
|
||||
Private m_nObjTreeMenuId As Integer = GDB_ID.NULL
|
||||
Private m_bEnableUpdateObjInObjTree As Boolean = True
|
||||
|
||||
Friend Sub SelectIdInObjTreeNoMark(nId As Integer)
|
||||
SelectIdInObjTree(nId, False)
|
||||
LayerTreeViewItem.m_MarkOnSel = False
|
||||
MySelectIdInObjTree(nId)
|
||||
LayerTreeViewItem.m_MarkOnSel = True
|
||||
End Sub
|
||||
|
||||
Friend Sub SelectIdInObjTree(nId As Integer)
|
||||
SelectIdInObjTree(nId, True)
|
||||
MySelectIdInObjTree(nId)
|
||||
End Sub
|
||||
|
||||
Friend Sub UpdateObjTreeOldId(ObjTreeOldId As Integer)
|
||||
@@ -581,7 +583,7 @@ Public Class ManageLayerExpanderVM
|
||||
AddGroupInObjTree(GDB_ID.ROOT, GDB_LV.USER, GDB_MD.STD, 0, LayerList)
|
||||
If nOldId <> GDB_ID.NULL Then
|
||||
m_bEnableUpdateObjInObjTree = False
|
||||
If Not SelectIdInObjTree(nOldId, True) Then
|
||||
If Not MySelectIdInObjTree(nOldId) Then
|
||||
Map.refInfoExpanderVM.SetInfoBox(String.Empty)
|
||||
End If
|
||||
m_bEnableUpdateObjInObjTree = True
|
||||
@@ -803,14 +805,11 @@ Public Class ManageLayerExpanderVM
|
||||
Return nOldId
|
||||
End Function
|
||||
|
||||
Private Function SelectIdInObjTree(nId As Integer, bMark As Boolean) As Boolean
|
||||
Private Function MySelectIdInObjTree(nId As Integer) As Boolean
|
||||
Dim tNode As LayerTreeViewItem = SearchIdInLayerList(LayerList, nId, True)
|
||||
If Not IsNothing(tNode) Then
|
||||
If Not bMark Then LayerTreeViewItem.m_MarkOnSel = False
|
||||
tNode.IsSelected = True
|
||||
tNode.NotifyPropertyChanged("IsSelected")
|
||||
If Not bMark Then LayerTreeViewItem.m_MarkOnSel = True
|
||||
tNode.IsExpanded = True
|
||||
m_nObjTreeOldId = nId
|
||||
Return True
|
||||
Else
|
||||
|
||||
@@ -1,30 +1,15 @@
|
||||
<UserControl x:Class="DrawOptionPanelV"
|
||||
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" Width="250"
|
||||
xmlns:EgtFloating="clr-namespace:EgtWPFLib5.EgtFloating;assembly=EgtWPFLib5">
|
||||
|
||||
<!--<StackPanel Name="ciao" Background="Transparent" MaxHeight="{Binding MaxHeight,RelativeSource={RelativeSource AncestorType={x:Type EgtFloating:EgtFloatingPanel}}}">
|
||||
--><!--ContentPresenter that contains the ManageLayerExpander--><!--
|
||||
<ContentPresenter Content="{Binding ManageLayerExpander,Mode=OneWay}"/>
|
||||
--><!--ContentPresenter that contains the InfoExpander--><!--
|
||||
<ContentPresenter Content="{Binding InfoExpander}"/>
|
||||
--><!--ContentPresenter that contains the InputExpander--><!--
|
||||
<ContentPresenter Content="{Binding InputExpander}"/>
|
||||
</StackPanel>-->
|
||||
<Grid Name="ciao" Background="Transparent" MaxHeight="{Binding MaxHeight,RelativeSource={RelativeSource AncestorType={x:Type EgtFloating:EgtFloatingPanel}}}">
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto"/>
|
||||
<RowDefinition Height="Auto"/>
|
||||
<RowDefinition Height="Auto"/>
|
||||
</Grid.RowDefinitions>
|
||||
<StackPanel Name="ciao" Background="Transparent" Margin="0,0,3.5001,0" MaxHeight="{Binding MaxHeight,RelativeSource={RelativeSource AncestorType={x:Type EgtFloating:EgtFloatingPanel}}}">
|
||||
<!--ContentPresenter that contains the ManageLayerExpander-->
|
||||
<ContentPresenter Content="{Binding ManageLayerExpander,Mode=OneWay}"/>
|
||||
<GridSplitter Grid.Row="0" Height="5" Background="Transparent" HorizontalAlignment="Stretch" VerticalAlignment="Bottom"/>
|
||||
<!--ContentPresenter that contains the InfoExpander-->
|
||||
<ContentPresenter Grid.Row="1" Content="{Binding InfoExpander}"/>
|
||||
<GridSplitter Grid.Row="1" Height="5" Background="Transparent" HorizontalAlignment="Stretch" VerticalAlignment="Bottom"/>
|
||||
<ContentPresenter Content="{Binding InfoExpander}"/>
|
||||
<!--ContentPresenter that contains the InputExpander-->
|
||||
<ContentPresenter Grid.Row="2" Content="{Binding InputExpander}"/>
|
||||
</Grid>
|
||||
<ContentPresenter Content="{Binding InputExpander}"/>
|
||||
</StackPanel>
|
||||
|
||||
</UserControl>
|
||||
|
||||
@@ -152,6 +152,8 @@ Public Class MachiningTreeExpanderVM
|
||||
Return EgtMsg(MSG_MACHININGSDBPAGE + 12)
|
||||
Case MCH_MY.FIVEAXISMILLING
|
||||
Return EgtMsg(31213)
|
||||
Case MCH_MY.PROBING
|
||||
Return EgtMsg(31220)
|
||||
Case Else
|
||||
Return "Mach"
|
||||
End Select
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
Imports EgtUILib
|
||||
Imports System.ComponentModel
|
||||
Imports System.Globalization
|
||||
Imports EgtUILib
|
||||
|
||||
Public Class DispositionParameterExpanderVM
|
||||
Inherits ViewModelBase
|
||||
@@ -273,7 +275,7 @@ Public Class DispositionParameterExpanderVM
|
||||
End If
|
||||
Select Case m_ActiveObject
|
||||
Case ObjectType.RAWPART
|
||||
' Abilito la selezione delle Fixture
|
||||
' Abilito la selezione dei Grezzi
|
||||
Map.refProjectVM.SceneSelType = SceneSelTypeOpt.RAWPART
|
||||
Case ObjectType.FIXTURE
|
||||
' Abilito la selezione delle Fixture
|
||||
@@ -329,14 +331,15 @@ Public Class DispositionParameterExpanderVM
|
||||
' imposto il riferimento della tavola
|
||||
Dim ptTableRef As Point3d
|
||||
EgtGetTableRef(1, ptTableRef)
|
||||
' calcolo il punto del grezzo da posizionar nelle coordinate di input
|
||||
' calcolo il punto del grezzo da posizionare nelle coordinate di input
|
||||
Dim ptRawRefPoint As Point3d = DispositionUtility.GetRawPartRefPoint(nFirstSelectedId, m_RawRefPosition)
|
||||
' creo un punto con le coordinate di input espresse rispetto alla tavola
|
||||
Dim TableRefInputPoint As New Point3d(InputPoint)
|
||||
TableRefInputPoint.LocToLoc(EgtGetGridFrame(), New Frame3d(ptTableRef))
|
||||
' calcolo il vettore di spostamento del grezzo
|
||||
vtMove = TableRefInputPoint - ptRawRefPoint
|
||||
' se è una ventosa
|
||||
vtMove.z = 0
|
||||
' se è una ventosa
|
||||
ElseIf EgtVerifyFixture(nFirstSelectedId) Then
|
||||
Dim SelObjFrame3d As New Frame3d(Frame3d.GLOB)
|
||||
EgtGetGroupGlobFrame(nFirstSelectedId, SelObjFrame3d)
|
||||
@@ -361,7 +364,7 @@ Public Class DispositionParameterExpanderVM
|
||||
DispositionUtility.MoveRawPartPartAndFixture(GDB_ID.SEL, New Vector3d(0, vtRemainingMove.y, 0), DispositionUtility.SelType.NULL)
|
||||
End If
|
||||
End If
|
||||
' se rotazione
|
||||
' se rotazione
|
||||
Else
|
||||
Dim nSelId As Integer = EgtGetFirstSelectedObj()
|
||||
If nSelId = GDB_ID.NULL Then Return
|
||||
@@ -371,7 +374,7 @@ Public Class DispositionParameterExpanderVM
|
||||
If EgtVerifyRawPartCurrPhase(nSelId) Then
|
||||
' Se primo carattere è nome asse
|
||||
If sVal(0) = "X"c Then
|
||||
sVal = sVal.Remove( 0, 1)
|
||||
sVal = sVal.Remove( 0, 1)
|
||||
vtRotAx = Vector3d.X_AX()
|
||||
ElseIf sVal(0) = "Y"c Then
|
||||
sVal = sVal.Remove( 0, 1)
|
||||
@@ -434,8 +437,16 @@ Public Class DispositionParameterExpanderVM
|
||||
''' Execute the Point. This method is invoked by the DoneCommand.
|
||||
''' </summary>
|
||||
Public Sub CheckedRawRef(ByVal param As Object)
|
||||
' Assegno corner di riferimento
|
||||
Dim nRawRef As MCH_CR = DirectCast(param, MCH_CR)
|
||||
m_RawRefPosition = nRawRef
|
||||
' Se grezzo selezionato, visualizzo sua posizione
|
||||
Dim nFirstSelectedId As Integer = EgtGetFirstSelectedObj()
|
||||
If EgtVerifyRawPartCurrPhase(nFirstSelectedId) Then
|
||||
Dim ptR As Point3d = DispositionUtility.GetRawPartRefPoint(nFirstSelectedId, m_RawRefPosition)
|
||||
m_InputValue = ptR.x.ToString("F1", CultureInfo.InvariantCulture) & "," & ptR.y.ToString("F1", CultureInfo.InvariantCulture)
|
||||
OnPropertyChanged( "InputValue")
|
||||
End If
|
||||
End Sub
|
||||
|
||||
#End Region ' CheckedRawRefCommand
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
Imports System.Windows.Forms.AxHost
|
||||
Imports EgtUILib
|
||||
Imports EgtUILib
|
||||
Imports Microsoft.VisualBasic.ApplicationServices
|
||||
|
||||
Public NotInheritable Class DispositionUtility
|
||||
@@ -323,11 +322,11 @@ Public NotInheritable Class DispositionUtility
|
||||
Dim dFixtureHeight As Double = 0
|
||||
EgtGetInfo(nFixtureId, "H", dFixtureHeight)
|
||||
' recupero altezza grezzo riferita alla tavola
|
||||
Dim dRawPartMin As Point3d = bboxRawPart.Min
|
||||
dRawPartMin.ToLoc(TableFrame)
|
||||
Dim ptRawPartMin As Point3d = bboxRawPart.Min
|
||||
ptRawPartMin.ToLoc(TableFrame)
|
||||
' se l'altezza grezzo è minore di quella della ventosa, lo sposto alla stessa altezza
|
||||
If dRawPartMin.z < dFixtureHeight - EPS_SMALL Then
|
||||
Dim vtMove As New Vector3d(0, 0, dFixtureHeight - dRawPartMin.z)
|
||||
If ptRawPartMin.z < dFixtureHeight - EPS_SMALL Then
|
||||
Dim vtMove As New Vector3d(0, 0, dFixtureHeight - ptRawPartMin.z)
|
||||
EgtMoveRawPart(nRawPartId, vtMove)
|
||||
' ricalcolo il BBox del solido del grezzo per averlo aggiornato con la nuova Z
|
||||
EgtGetBBoxGlob(nRawSolidId, GDB_BB.ONLY_VISIBLE, bboxRawPart)
|
||||
@@ -359,19 +358,19 @@ Public NotInheritable Class DispositionUtility
|
||||
nOtherFixtureId = EgtGetNextFixture(nOtherFixtureId)
|
||||
End While
|
||||
' recupero altezza grezzo riferita alla tavola
|
||||
Dim dRawPartMin As Point3d = bboxRawPart.Min
|
||||
dRawPartMin.ToLoc(TableFrame)
|
||||
Dim ptRawPartMin As Point3d = bboxRawPart.Min
|
||||
ptRawPartMin.ToLoc(TableFrame)
|
||||
' se non ci sono ventose sotto il grezzo
|
||||
If Not bIsFixtureUnderRawPart Then
|
||||
' verifico che il grezzo sia ad altezza tavola
|
||||
If dRawPartMin.z <> 0 Then
|
||||
Dim vtMove As New Vector3d(0, 0, -dRawPartMin.z)
|
||||
If ptRawPartMin.z <> 0 Then
|
||||
Dim vtMove As New Vector3d(0, 0, -ptRawPartMin.z)
|
||||
EgtMoveRawPart(nRawPartId, vtMove)
|
||||
End If
|
||||
Else
|
||||
' se ci sono verifico che l'altezza del grezzo sia quella della ventosa più alta
|
||||
If Math.Abs(dRawPartMin.z - dMaxFixtureHeight) > EPS_SMALL Then
|
||||
Dim vtMove As New Vector3d(0, 0, dMaxFixtureHeight - dRawPartMin.z)
|
||||
If Math.Abs(ptRawPartMin.z - dMaxFixtureHeight) > EPS_SMALL Then
|
||||
Dim vtMove As New Vector3d(0, 0, dMaxFixtureHeight - ptRawPartMin.z)
|
||||
EgtMoveRawPart(nRawPartId, vtMove)
|
||||
End If
|
||||
End If
|
||||
@@ -473,23 +472,30 @@ Public NotInheritable Class DispositionUtility
|
||||
' Recupero il solido del grezzo
|
||||
Dim nMovedRawSolidId As Integer = EgtGetFirstNameInGroup(nRawId, RAWSOLID)
|
||||
' definisco il box del solido del grezzo
|
||||
Dim bboxRawPartId As New BBox3d
|
||||
EgtGetBBoxGlob(nMovedRawSolidId, GDB_BB.ONLY_VISIBLE, bboxRawPartId)
|
||||
Dim bboxRawPart As New BBox3d
|
||||
EgtGetBBoxGlob(nMovedRawSolidId, GDB_BB.STANDARD, bboxRawPart)
|
||||
' aggiungo il box dell'eventuale supporto o sottopezzo
|
||||
Dim nSupportId As Integer = EgtGetFirstNameInGroup(nRawId, SUPPORT)
|
||||
If nSupportId <> GDB_ID.NULL Then
|
||||
Dim bboxSupport As New BBox3d
|
||||
EgtGetBBoxGlob(nSupportId, GDB_BB.STANDARD, bboxSupport)
|
||||
bboxRawPart.Add( bboxSupport)
|
||||
End If
|
||||
' Variabile che dice se c'è almeno una ventosa sotto il grezzo
|
||||
Dim bIsFixtureUnderRawPart As Boolean = False
|
||||
Dim bboxFixture As New BBox3d
|
||||
' variabile che contiene la massima altezza delle ventose sottostanti
|
||||
Dim dMaxFixtureHeight As Double = 0
|
||||
' recupero altezza grezzo riferita alla tavola
|
||||
Dim dRawPartMin As Point3d = bboxRawPartId.Min
|
||||
dRawPartMin.ToLoc(TableFrame)
|
||||
Dim ptRawPartMin As Point3d = bboxRawPart.Min
|
||||
ptRawPartMin.ToLoc(TableFrame)
|
||||
' Ciclo sui sottopezzi presenti per verificare le collisioni con il grezzo
|
||||
Dim nFixtureId As Integer = EgtGetFirstFixture()
|
||||
While nFixtureId <> GDB_ID.NULL
|
||||
' calcolo il BBox del sottopezzo
|
||||
EgtGetBBoxGlob(nFixtureId, GDB_BB.ONLY_VISIBLE, bboxFixture)
|
||||
' verifico se c'è sovrapposizione
|
||||
If bboxRawPartId.OverlapsXY(bboxFixture) Then
|
||||
If bboxRawPart.OverlapsXY(bboxFixture) Then
|
||||
' recupero il tipo di fixture
|
||||
Dim nFxtType As FIX_TYPE = FixtureType(nFixtureId)
|
||||
' Se è ventosa o morsa
|
||||
@@ -502,22 +508,22 @@ Public NotInheritable Class DispositionUtility
|
||||
dMaxFixtureHeight = dFixtureHeight
|
||||
End If
|
||||
' se l'altezza grezzo è diversa da quella della ventosa, lo sposto alla stessa altezza
|
||||
If dRawPartMin.z < dFixtureHeight - EPS_SMALL Then
|
||||
Dim vtMove As New Vector3d(0, 0, dFixtureHeight - dRawPartMin.z)
|
||||
If ptRawPartMin.z < dFixtureHeight - EPS_SMALL Then
|
||||
Dim vtMove As New Vector3d(0, 0, dFixtureHeight - ptRawPartMin.z)
|
||||
EgtMoveRawPart(nRawId, vtMove)
|
||||
' recupero il solido del grezzo
|
||||
Dim nRawSolidId As Integer = EgtGetFirstNameInGroup(nRawId, RAWSOLID)
|
||||
' ricalcolo il BBox del solido del grezzo per averlo aggiornato con la nuova Z
|
||||
EgtGetBBoxGlob(nRawSolidId, GDB_BB.ONLY_VISIBLE, bboxRawPartId)
|
||||
dRawPartMin = bboxRawPartId.Min
|
||||
dRawPartMin.ToLoc(TableFrame)
|
||||
EgtGetBBoxGlob(nRawSolidId, GDB_BB.ONLY_VISIBLE, bboxRawPart)
|
||||
ptRawPartMin = bboxRawPart.Min
|
||||
ptRawPartMin.ToLoc(TableFrame)
|
||||
End If
|
||||
bIsFixtureUnderRawPart = True
|
||||
End If
|
||||
' Se è morsa
|
||||
If nFxtType = FIX_TYPE.VISE Then
|
||||
' regolo la posizione in Z della morsa
|
||||
EgtSetFixtureMobile( nFixtureId, bboxRawPartId.DimZ())
|
||||
EgtSetFixtureMobile( nFixtureId, bboxRawPart.DimZ())
|
||||
End If
|
||||
' Se è un riferimento o una morsa
|
||||
If nFxtType = FIX_TYPE.REFERENCE Or nFxtType = FIX_TYPE.VISE Then
|
||||
@@ -526,7 +532,7 @@ Public NotInheritable Class DispositionUtility
|
||||
' calcolo bbox dell'arco di riferimento
|
||||
Dim bboxArcRef As New BBox3d
|
||||
EgtGetBBoxGlob(arcRefId, GDB_BB.STANDARD, bboxArcRef)
|
||||
If bboxRawPartId.OverlapsXY(bboxArcRef) Then
|
||||
If bboxRawPart.OverlapsXY(bboxArcRef) Then
|
||||
' recupero contorno del grezzo
|
||||
Dim ccompoRawPartOutlineId As Integer = EgtGetFirstNameInGroup(nRawId, RAWOUTLINE)
|
||||
'recupero il raggio dell'arco di riferimento
|
||||
@@ -588,14 +594,14 @@ Public NotInheritable Class DispositionUtility
|
||||
' se non ci sono ventose sotto il grezzo
|
||||
If Not bIsFixtureUnderRawPart Then
|
||||
' verifico che il grezzo sia ad altezza tavola
|
||||
If dRawPartMin.z <> 0 Then
|
||||
Dim vtMove As New Vector3d(0, 0, -dRawPartMin.z)
|
||||
If ptRawPartMin.z <> 0 Then
|
||||
Dim vtMove As New Vector3d(0, 0, -ptRawPartMin.z)
|
||||
EgtMoveRawPart(nRawId, vtMove)
|
||||
End If
|
||||
Else
|
||||
' se ci sono verifico che l'altezza del grezzo sia quella della ventosa più alta
|
||||
If Math.Abs(dRawPartMin.z - dMaxFixtureHeight) > EPS_SMALL Then
|
||||
Dim vtMove As New Vector3d(0, 0, dMaxFixtureHeight - dRawPartMin.z)
|
||||
If Math.Abs(ptRawPartMin.z - dMaxFixtureHeight) > EPS_SMALL Then
|
||||
Dim vtMove As New Vector3d(0, 0, dMaxFixtureHeight - ptRawPartMin.z)
|
||||
EgtMoveRawPart(nRawId, vtMove)
|
||||
End If
|
||||
End If
|
||||
@@ -775,6 +781,9 @@ Public NotInheritable Class DispositionUtility
|
||||
m_nUsedHookId = nNearestHookId
|
||||
' Segno hook come utilizzato
|
||||
SetHookUsed(m_nUsedHookId, nMoveId, True)
|
||||
Dim sLinkName As String = ""
|
||||
EgtGetName( EgtGetParent( m_nUsedHookId), sLinkName)
|
||||
EgtSetFixtureLink( nMoveId, sLinkName)
|
||||
Return True
|
||||
End Function
|
||||
|
||||
|
||||
@@ -62,8 +62,8 @@ Public Class FixtureParametersVM
|
||||
Dim nUsedFixtureId As Integer = EgtGetFirstFixture()
|
||||
While nUsedFixtureId <> GDB_ID.NULL
|
||||
Dim sUsedFixtureName As String = String.Empty
|
||||
EgtGetName(nUsedFixtureId, sUsedFixtureName)
|
||||
For Index = 0 To m_FixtureTypeList.Count - 1
|
||||
EgtGetName(nUsedFixtureId, sUsedFixtureName)
|
||||
If sUsedFixtureName = m_FixtureTypeList(Index).Name Then
|
||||
Dim CurrFixtureType As FixtureType = DirectCast(m_FixtureTypeList(Index), FixtureType)
|
||||
CurrFixtureType.UsedNumber += 1
|
||||
@@ -76,6 +76,7 @@ Public Class FixtureParametersVM
|
||||
|
||||
Friend Sub UpdateFixtureTypeList()
|
||||
m_FixtureTypeList = New ObservableCollection(Of FixtureListItem)(FixtureType.ReadFixtureTypeFromMachIni())
|
||||
UpdateFixtureCount()
|
||||
OnPropertyChanged("FixtureTypeList")
|
||||
End Sub
|
||||
|
||||
@@ -140,6 +141,7 @@ Public Class FixtureParametersVM
|
||||
If Not PositionFixtureOnNearestHook(nAddedFixtureId) Then
|
||||
' non ci sono punti liberi, quindi rimuovo la ventosa e segnalo
|
||||
EgtRemoveFixture(nAddedFixtureId)
|
||||
EgtSetFixtureLink( nAddedFixtureId, "")
|
||||
MessageBox.Show("No free hook point!", "ERROR")
|
||||
Return
|
||||
End If
|
||||
@@ -297,6 +299,7 @@ Public Class FixtureParametersVM
|
||||
Else
|
||||
DispositionUtility.AddHookUsed( nCurrHookId, nFixtureId)
|
||||
End If
|
||||
EgtSetFixtureLink( nFixtureId, "")
|
||||
Return True
|
||||
Else
|
||||
EgtStartPoint(nFixtHookId, GDB_ID.ROOT, ptFixtHook)
|
||||
@@ -320,6 +323,7 @@ Public Class FixtureParametersVM
|
||||
Else
|
||||
DispositionUtility.AddHookUsed( nCurrHookId, nFixtureId)
|
||||
End If
|
||||
EgtSetFixtureLink( nFixtureId, "")
|
||||
Return True
|
||||
Else
|
||||
EgtStartPoint(nFixtHookId, GDB_ID.ROOT, ptFixtHook)
|
||||
@@ -348,6 +352,7 @@ Public Class FixtureParametersVM
|
||||
Else
|
||||
DispositionUtility.AddHookUsed( nCurrHookId, nFixtureId)
|
||||
End If
|
||||
EgtSetFixtureLink( nFixtureId, sBarName)
|
||||
Return True
|
||||
Else
|
||||
EgtStartPoint(nFixtHookId, GDB_ID.ROOT, ptFixtHook)
|
||||
@@ -373,6 +378,7 @@ Public Class FixtureParametersVM
|
||||
Else
|
||||
DispositionUtility.AddHookUsed( nCurrHookId, nFixtureId)
|
||||
End If
|
||||
EgtSetFixtureLink( nFixtureId, sCharName)
|
||||
Return True
|
||||
Else
|
||||
EgtStartPoint(nFixtHookId, GDB_ID.ROOT, ptFixtHook)
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
<CheckBox Content="Move with Fixture" IsChecked="{Binding MoveWithFixture, Mode=TwoWay}"/>
|
||||
<UniformGrid Columns="2" Margin="0,5,0,0">
|
||||
<Button Content="New" Command="{Binding NewRawPartCommand}"/>
|
||||
<Button Content="Remove"/> <!--Command="{Binding RemoveRawPartCommand}"-->
|
||||
<Button Content="Remove" Command="{Binding RemoveRawPartCommand}"/>
|
||||
</UniformGrid>
|
||||
<Grid Visibility="{Binding RawPartParamVisibility, Mode=OneWay}">
|
||||
<Grid.RowDefinitions>
|
||||
|
||||
@@ -117,7 +117,7 @@ Public Class RawPartOptionVM
|
||||
End Property
|
||||
|
||||
''' <summary>
|
||||
''' Execute the Point. This method is invoked by the DoneCommand.
|
||||
''' Execute NewRawPart. This method is invoked by the DoneCommand.
|
||||
''' </summary>
|
||||
Public Sub NewRawPart()
|
||||
DispositionUtility.ShowParts()
|
||||
@@ -127,6 +127,36 @@ Public Class RawPartOptionVM
|
||||
|
||||
#End Region ' NewRawPartCommand
|
||||
|
||||
#Region "RemoveRawPartCommand"
|
||||
|
||||
''' <summary>
|
||||
''' Returns a command that do Done.
|
||||
''' </summary>
|
||||
Public ReadOnly Property RemoveRawPartCommand As ICommand
|
||||
Get
|
||||
If m_cmdRemoveRawPart Is Nothing Then
|
||||
m_cmdRemoveRawPart = New RelayCommand(AddressOf RemoveRawPart)
|
||||
End If
|
||||
Return m_cmdRemoveRawPart
|
||||
End Get
|
||||
End Property
|
||||
|
||||
''' <summary>
|
||||
''' Execute RemoveRawPart. This method is invoked by the DoneCommand.
|
||||
''' </summary>
|
||||
Public Sub RemoveRawPart()
|
||||
' ciclo sui grezzi selezionati
|
||||
Dim nSelRawPartId As Integer = EgtGetFirstSelectedObj()
|
||||
While nSelRawPartId <> GDB_ID.NULL
|
||||
' rimuovo il grezzo dalla disposizione
|
||||
EgtRemoveRawPart(nSelRawPartId)
|
||||
nSelRawPartId = EgtGetNextSelectedObj()
|
||||
End While
|
||||
EgtDraw()
|
||||
End Sub
|
||||
|
||||
#End Region ' RemoveRawPartCommand
|
||||
|
||||
#End Region ' Commands
|
||||
|
||||
End Class
|
||||
@@ -109,34 +109,6 @@
|
||||
Visibility="{Binding SysNotes_Visibility}"
|
||||
IsReadOnly="True"/>
|
||||
</UniformGrid>
|
||||
<EgtWPFLib5:CheckParamV ParamTxBl="{Binding InvertTxBl}"
|
||||
ParamChBx="{Binding Path=Invert,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
Style="{DynamicResource CheckParamV_Margin}"/>
|
||||
<EgtWPFLib5:ComboParamV ParamTxBl="{Binding WorkSideTxBl}"
|
||||
ParamCmBxList="{Binding Path=WorkSideList,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
ParamCmBxSelIndex="{Binding Path=SelectedWorkSide}"
|
||||
Style="{DynamicResource ComboParamV_Margin}"/>
|
||||
<UniformGrid Columns="2">
|
||||
<TextBlock Text="{Binding UserNotesTxBl}"
|
||||
Style="{DynamicResource MPExpander_UserNotesTxBlMargin}"/>
|
||||
<EgtWPFLib5:EgtTextBox Text="{Binding UserNotes, UpdateSourceTrigger=PropertyChanged}"
|
||||
Style="{DynamicResource MPExpander_UserNotesTxBxMargin}">
|
||||
<EgtWPFLib5:EgtTextBox.ToolTip>
|
||||
<TextBlock Text="{Binding UserNotesTooltip}"/>
|
||||
</EgtWPFLib5:EgtTextBox.ToolTip>
|
||||
</EgtWPFLib5:EgtTextBox>
|
||||
<TextBlock Text="{Binding SystemNotesTxBl}"
|
||||
Style="{DynamicResource MPExpander_UserNotesTxBlMargin}"
|
||||
Visibility="{Binding SysNotes_Visibility}"/>
|
||||
<EgtWPFLib5:EgtTextBox Text="{Binding SystemNotes, UpdateSourceTrigger=PropertyChanged}"
|
||||
Style="{DynamicResource MPExpander_UserNotesTxBxMargin}"
|
||||
Visibility="{Binding SysNotes_Visibility}"
|
||||
IsReadOnly="True"/>
|
||||
</UniformGrid>
|
||||
</StackPanel>
|
||||
<StackPanel Name="AutomaticCloseExpanderStackPanel">
|
||||
<Expander Header="{Binding GenericExpanderHeader}" Name="GenericExpander"
|
||||
@@ -264,7 +236,12 @@
|
||||
IsReadOnly="False"/>
|
||||
</TabItem>
|
||||
<TabItem Header="CHECKBOX">
|
||||
<CheckBox IsChecked="{Binding Value}"/>
|
||||
<CheckBox IsChecked="{Binding Value, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</TabItem>
|
||||
<TabItem Header="COMBOBOX">
|
||||
<ComboBox ItemsSource="{Binding ListKeyValue}"
|
||||
SelectedItem="{Binding SelKeyValue, UpdateSourceTrigger=PropertyChanged}"
|
||||
DisplayMemberPath="KeyValue"/>
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
<Button Command="{Binding RemoveItemNoteCommand}"
|
||||
@@ -294,43 +271,6 @@
|
||||
</Grid>
|
||||
</Expander>
|
||||
|
||||
<Expander Style="{StaticResource ExpanderStyle}">
|
||||
<Expander.Header>
|
||||
<EgtWPFLib5:ComboParamV ParamTxBl="{Binding LeadInTypeTxBl}"
|
||||
ParamCmBxList="{Binding Path=LeadInTypeList,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
ParamCmBxSelIndex="{Binding Path=SelectedLeadInType}"
|
||||
Style="{DynamicResource ComboParamV_Margin}"/>
|
||||
</Expander.Header>
|
||||
<StackPanel>
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding StartAddLenTxBl}"
|
||||
ParamTxBx="{Binding Path=StartAddLen,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding LiTangTxBl}"
|
||||
ParamTxBx="{Binding Path=LiTang,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding LiPerpTxBl}"
|
||||
ParamTxBx="{Binding Path=LiPerp,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding LiElevTxBl}"
|
||||
ParamTxBx="{Binding Path=LiElev,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding LiCompLenTxBl}"
|
||||
ParamTxBx="{Binding Path=LiCompLen,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
</StackPanel>
|
||||
</Expander>
|
||||
<Expander Style="{StaticResource ExpanderStyle}">
|
||||
<Expander.Header>
|
||||
<EgtWPFLib5:ComboParamV ParamTxBl="{Binding LeadInTypeTxBl}"
|
||||
@@ -369,43 +309,6 @@
|
||||
</StackPanel>
|
||||
</Expander>
|
||||
|
||||
<Expander Style="{StaticResource ExpanderStyle}">
|
||||
<Expander.Header>
|
||||
<EgtWPFLib5:ComboParamV ParamTxBl="{Binding LeadOutTypeTxBl}"
|
||||
ParamCmBxList="{Binding Path=LeadOutTypeList,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
ParamCmBxSelIndex="{Binding Path=SelectedLeadOutType}"
|
||||
Style="{DynamicResource ComboParamV_Margin}"/>
|
||||
</Expander.Header>
|
||||
<StackPanel>
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding EndAddLenTxBl}"
|
||||
ParamTxBx="{Binding Path=EndAddLen,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding LoTangTxBl}"
|
||||
ParamTxBx="{Binding Path=LoTang,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding LoPerpTxBl}"
|
||||
ParamTxBx="{Binding Path=LoPerp,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding LoElevTxBl}"
|
||||
ParamTxBx="{Binding Path=LoElev,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding LoCompLenTxBl}"
|
||||
ParamTxBx="{Binding Path=LoCompLen,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
</StackPanel>
|
||||
</Expander>
|
||||
<Expander Style="{StaticResource ExpanderStyle}">
|
||||
<Expander.Header>
|
||||
<EgtWPFLib5:ComboParamV ParamTxBl="{Binding LeadOutTypeTxBl}"
|
||||
@@ -444,53 +347,6 @@
|
||||
</StackPanel>
|
||||
</Expander>
|
||||
|
||||
<Expander Style="{StaticResource ExpanderStyle}">
|
||||
<Expander.Header>
|
||||
<EgtWPFLib5:CheckParamV ParamTxBl="{Binding LeaveTabTxBl}"
|
||||
ParamChBx="{Binding Path=LeaveTab,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
Style="{DynamicResource CheckParamV_Margin}"/>
|
||||
</Expander.Header>
|
||||
<StackPanel Margin="2">
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding TabLenTxBl}"
|
||||
ParamTxBx="{Binding Path=TabLen,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
ParamErrorMsg="{Binding Path=TabLenErrorMsg}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding TabHeightTxBl}"
|
||||
ParamTxBx="{Binding Path=TabHeight,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
ParamErrorMsg="{Binding Path=TabHeightErrorMsg}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding TabAngleTxBl}"
|
||||
ParamTxBx="{Binding Path=TabAngle,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
ParamErrorMsg="{Binding Path=TabAngleErrorMsg}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding TabDistTxBl}"
|
||||
ParamTxBx="{Binding Path=TabDist,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
ParamErrorMsg="{Binding Path=TabDistErrorMsg}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding TabMinTxBl}"
|
||||
ParamTxBx="{Binding Path=TabMin,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
ParamErrorMsg="{Binding Path=TabMinErrorMsg}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding TabMaxTxBl}"
|
||||
ParamTxBx="{Binding Path=TabMax,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
ParamErrorMsg="{Binding Path=TabMaxErrorMsg}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
</StackPanel>
|
||||
</Expander>
|
||||
<Expander Style="{StaticResource ExpanderStyle}">
|
||||
<Expander.Header>
|
||||
<EgtWPFLib5:CheckParamV ParamTxBl="{Binding LeaveTabTxBl}"
|
||||
@@ -571,7 +427,7 @@
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
</StackPanel>
|
||||
</Expander>
|
||||
|
||||
|
||||
<Interactivity:Interaction.Behaviors>
|
||||
<EgtCAM5:AutomaticCloseExpander/>
|
||||
</Interactivity:Interaction.Behaviors>
|
||||
|
||||
@@ -224,7 +224,12 @@
|
||||
IsReadOnly="False"/>
|
||||
</TabItem>
|
||||
<TabItem Header="CHECKBOX">
|
||||
<CheckBox IsChecked="{Binding Value}"/>
|
||||
<CheckBox IsChecked="{Binding Value, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</TabItem>
|
||||
<TabItem Header="COMBOBOX">
|
||||
<ComboBox ItemsSource="{Binding ListKeyValue}"
|
||||
SelectedItem="{Binding SelKeyValue, UpdateSourceTrigger=PropertyChanged}"
|
||||
DisplayMemberPath="KeyValue"/>
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
<Button Command="{Binding RemoveItemNoteCommand}"
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
<UserControl x:Class="FiveAxisMachinigParameterExpanderV"
|
||||
<UserControl x:Class="FiveAxisMachiningParameterExpanderV"
|
||||
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"
|
||||
@@ -216,6 +216,11 @@
|
||||
<TabItem Header="CHECKBOX">
|
||||
<CheckBox IsChecked="{Binding Value, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</TabItem>
|
||||
<TabItem Header="COMBOBOX">
|
||||
<ComboBox ItemsSource="{Binding ListKeyValue}"
|
||||
SelectedItem="{Binding SelKeyValue, UpdateSourceTrigger=PropertyChanged}"
|
||||
DisplayMemberPath="KeyValue"/>
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
<Button Command="{Binding RemoveItemNoteCommand}"
|
||||
Grid.Column="2"
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
Imports EgtWPFLib5.EgtFloating
|
||||
|
||||
Public Class FiveAxisMachinigParameterExpanderV
|
||||
Public Class FiveAxisMachiningParameterExpanderV
|
||||
|
||||
Private m_RightTrayV As RightTrayV
|
||||
Private EgtFloatingPanel As EgtFloatingPanel
|
||||
@@ -80,16 +80,4 @@ Public Class FiveAxisMachinigParameterExpanderV
|
||||
Return TryCast(target, T)
|
||||
End Function
|
||||
|
||||
Private Sub StackPanel_PreviewKeyDown(sender As Object, e As KeyEventArgs)
|
||||
If e.Key = Key.Tab Then
|
||||
Dim s As EgtWPFLib5.StringParamV = TryCast(e.OriginalSource, EgtWPFLib5.StringParamV)
|
||||
|
||||
If Not IsNothing(s) Then
|
||||
s.MoveFocus(New TraversalRequest(FocusNavigationDirection.Next))
|
||||
End If
|
||||
|
||||
e.Handled = True
|
||||
End If
|
||||
|
||||
End Sub
|
||||
End Class
|
||||
|
||||
@@ -214,7 +214,12 @@
|
||||
IsReadOnly="False"/>
|
||||
</TabItem>
|
||||
<TabItem Header="CHECKBOX">
|
||||
<CheckBox IsChecked="{Binding Value}"/>
|
||||
<CheckBox IsChecked="{Binding Value, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</TabItem>
|
||||
<TabItem Header="COMBOBOX">
|
||||
<ComboBox ItemsSource="{Binding ListKeyValue}"
|
||||
SelectedItem="{Binding SelKeyValue, UpdateSourceTrigger=PropertyChanged}"
|
||||
DisplayMemberPath="KeyValue"/>
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
<Button Command="{Binding RemoveItemNoteCommand}"
|
||||
|
||||
@@ -152,8 +152,9 @@ Public Class MachiningParameterExpanderVM
|
||||
Dim StoneDrillParamExpanderV As StoneDrillingParameterExpanderV
|
||||
Dim SurfFinishParamExpanderV As SurfFinishingParameterExpanderV
|
||||
Dim WjParamExpanderV As WaterjettingParameterExpanderV
|
||||
Dim FiveAxExpanderV As FiveAxisMachinigParameterExpanderV
|
||||
Dim FiveAxExpanderV As FiveAxisMachiningParameterExpanderV
|
||||
Dim SurfRoughExpanderV As SurfRoughingParameterExpanderV
|
||||
Dim ProbExpanderV As ProbingParameterExpanderV
|
||||
|
||||
Private Sub Dummy()
|
||||
|
||||
@@ -270,13 +271,17 @@ Public Class MachiningParameterExpanderVM
|
||||
WjParamExpanderV.DataContext = m_CurrOperation
|
||||
Return WjParamExpanderV
|
||||
Case MCH_OY.FIVEAXISMILLING
|
||||
If IsNothing(FiveAxExpanderV) Then FiveAxExpanderV = New FiveAxisMachinigParameterExpanderV
|
||||
If IsNothing(FiveAxExpanderV) Then FiveAxExpanderV = New FiveAxisMachiningParameterExpanderV
|
||||
FiveAxExpanderV.DataContext = m_CurrOperation
|
||||
Return FiveAxExpanderV
|
||||
Case MCH_OY.SURFROUGHING
|
||||
If IsNothing(SurfRoughExpanderV) Then SurfRoughExpanderV = New SurfRoughingParameterExpanderV
|
||||
SurfRoughExpanderV.DataContext = m_CurrOperation
|
||||
Return SurfRoughExpanderV
|
||||
Case MCH_OY.PROBING
|
||||
If IsNothing(ProbExpanderV) Then ProbExpanderV = New ProbingParameterExpanderV
|
||||
ProbExpanderV.DataContext = m_CurrOperation
|
||||
Return ProbExpanderV
|
||||
End Select
|
||||
|
||||
'MachiningParameterExpanderItem.ReadOperationParam()
|
||||
@@ -371,21 +376,12 @@ Public Class MachiningParameterExpanderVM
|
||||
Return
|
||||
End If
|
||||
|
||||
Dim bRecalc As Boolean = False
|
||||
If (Keyboard.Modifiers And ModifierKeys.Shift) = ModifierKeys.Shift Then
|
||||
bRecalc = True
|
||||
Else
|
||||
' Controllo se il tipo e' dr o sr o lr bRecalc e' true come quando viene selezionato Shift
|
||||
For Each ItemNote As NoteListBoxItem In m_CurrOperation.NotesList
|
||||
bRecalc = ItemNote.Type.Equals("dr") OrElse ItemNote.Type.Equals("lr") OrElse ItemNote.Type.Equals("sr") OrElse ItemNote.Type.Equals("br")
|
||||
If bRecalc Then Exit For
|
||||
Next
|
||||
End If
|
||||
' Verifico se forzato ricalcolo da interfaccia
|
||||
Dim bRecalc As Boolean = ((Keyboard.Modifiers And ModifierKeys.Shift) <> 0)
|
||||
|
||||
' La modifica di alcuni parametri forza il ricalcolo della geometria
|
||||
Dim ModifiedGeometry As Boolean = m_CurrOperation.m_IsModifiedSelectedFaceUseType
|
||||
' aggiorno valori modificati
|
||||
' Aggiorno parametri di lavorazione
|
||||
m_CurrOperation.WriteOperationParam()
|
||||
|
||||
' Carico tutta la geometria selezionata in una lista
|
||||
Dim SelectedGeometry As New List(Of Integer)
|
||||
Dim EntityIndex As Integer = EgtGetFirstSelectedObj()
|
||||
@@ -398,49 +394,19 @@ Public Class MachiningParameterExpanderVM
|
||||
(EgtGetType(SelectedGeometry(0)) = GDB_TY.SRF_MESH Or EgtGetType(SelectedGeometry(0)) = GDB_TY.SRF_FRGN) Then
|
||||
' Aggiorno lista speciale con facce
|
||||
SelData.VerifyIdSub()
|
||||
' Verifico se geometria cambiata, confrontando selezione attuale con facet con geometria di lavorazione
|
||||
Dim nInd As Integer = 0
|
||||
Dim nMchId, nMchSub As Integer
|
||||
EgtGetMachiningGeometry(nInd, nMchId, nMchSub)
|
||||
Dim nSelId, nSelSub As Integer
|
||||
SelData.GetIdSub(nInd, nSelId, nSelSub)
|
||||
While Not ModifiedGeometry And (nMchId <> GDB_ID.NULL Or nSelId <> GDB_ID.NULL)
|
||||
' Controllo uguaglianza
|
||||
If nMchId <> nSelId Or nMchSub <> nSelSub Then ModifiedGeometry = True
|
||||
' Passo al successivo
|
||||
nInd += 1
|
||||
EgtGetMachiningGeometry(nInd, nMchId, nMchSub)
|
||||
SelData.GetIdSub(nInd, nSelId, nSelSub)
|
||||
End While
|
||||
If ModifiedGeometry Then
|
||||
Dim vId() As Integer = Nothing
|
||||
Dim vSub() As Integer = Nothing
|
||||
SelData.GetAllIdSub(vId, vSub)
|
||||
EgtSetMachiningGeometry(vId, vSub)
|
||||
End If
|
||||
' Gestione standard per altre entità (curve, testi, ...)
|
||||
' Imposto geometria
|
||||
Dim vId() As Integer = Nothing
|
||||
Dim vSub() As Integer = Nothing
|
||||
SelData.GetAllIdSub(vId, vSub)
|
||||
EgtSetMachiningGeometry(vId, vSub)
|
||||
' Gestione standard per altre entità (curve, testi, ...)
|
||||
Else
|
||||
' Verifico se geometria cambiata, confrontando selezione attuale con geometria di lavorazione
|
||||
Dim nInd As Integer = 0
|
||||
Dim nMchId, nMchSub As Integer
|
||||
EgtGetMachiningGeometry(nInd, nMchId, nMchSub)
|
||||
Dim nSelId As Integer
|
||||
nSelId = If(nInd < SelectedGeometry.Count(), SelectedGeometry(nInd), GDB_ID.NULL)
|
||||
While Not ModifiedGeometry And (nMchId <> GDB_ID.NULL Or nSelId <> GDB_ID.NULL)
|
||||
' Controllo uguaglianza
|
||||
If nMchId <> nSelId Then ModifiedGeometry = True
|
||||
' Passo al successivo
|
||||
nInd += 1
|
||||
EgtGetMachiningGeometry(nInd, nMchId, nMchSub)
|
||||
nSelId = If(nInd < SelectedGeometry.Count(), SelectedGeometry(nInd), GDB_ID.NULL)
|
||||
End While
|
||||
' Imposto geometria selezionata come geometria di lavorazione
|
||||
If ModifiedGeometry Then
|
||||
EgtSetMachiningGeometry(SelectedGeometry.ToArray)
|
||||
End If
|
||||
' Imposto geometria
|
||||
EgtSetMachiningGeometry(SelectedGeometry.ToArray)
|
||||
End If
|
||||
' Ricalcolo la lavorazione
|
||||
If Not EgtApplyMachining(bRecalc Or ModifiedGeometry) Then
|
||||
|
||||
' Rigenero la lavorazione
|
||||
If Not EgtApplyMachining(bRecalc) Then
|
||||
If EgtGetLastMachMgrErrorId() <> 0 Then
|
||||
Dim sErr As String = EgtGetLastMachMgrErrorString()
|
||||
Dim sInfo As String = String.Empty
|
||||
@@ -459,6 +425,7 @@ Public Class MachiningParameterExpanderVM
|
||||
Map.refStatusBarVM.NotifyStatusOutput("")
|
||||
End If
|
||||
End If
|
||||
|
||||
' Restart visualizzazione utensile
|
||||
SetSliderScale( EgtGetPreviewMachiningToolStepCount())
|
||||
SetViewTool(True)
|
||||
|
||||
@@ -232,7 +232,12 @@
|
||||
IsReadOnly="False"/>
|
||||
</TabItem>
|
||||
<TabItem Header="CHECKBOX">
|
||||
<CheckBox IsChecked="{Binding Value}"/>
|
||||
<CheckBox IsChecked="{Binding Value, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</TabItem>
|
||||
<TabItem Header="COMBOBOX">
|
||||
<ComboBox ItemsSource="{Binding ListKeyValue}"
|
||||
SelectedItem="{Binding SelKeyValue, UpdateSourceTrigger=PropertyChanged}"
|
||||
DisplayMemberPath="KeyValue"/>
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
<Button Command="{Binding RemoveItemNoteCommand}"
|
||||
|
||||
@@ -129,13 +129,13 @@
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding OffsetSlTxBl}"
|
||||
ParamTxBx="{Binding Path=OffSl,
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding OffsetSrTxBl}"
|
||||
ParamTxBx="{Binding Path=OffSr,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding OffsetSrTxBl}"
|
||||
ParamTxBx="{Binding Path=OffSr,
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding OffsetSlTxBl}"
|
||||
ParamTxBx="{Binding Path=OffSl,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
@@ -241,7 +241,12 @@
|
||||
IsReadOnly="False"/>
|
||||
</TabItem>
|
||||
<TabItem Header="CHECKBOX">
|
||||
<CheckBox IsChecked="{Binding Value}"/>
|
||||
<CheckBox IsChecked="{Binding Value, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</TabItem>
|
||||
<TabItem Header="COMBOBOX">
|
||||
<ComboBox ItemsSource="{Binding ListKeyValue}"
|
||||
SelectedItem="{Binding SelKeyValue, UpdateSourceTrigger=PropertyChanged}"
|
||||
DisplayMemberPath="KeyValue"/>
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
<Button Command="{Binding RemoveItemNoteCommand}"
|
||||
|
||||
@@ -0,0 +1,275 @@
|
||||
<UserControl x:Class="ProbingParameterExpanderV"
|
||||
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:Interactivity="clr-namespace:System.Windows.Interactivity;assembly=System.Windows.Interactivity"
|
||||
xmlns:EgtCAM5="clr-namespace:EgtCAM5"
|
||||
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5">
|
||||
|
||||
<UserControl.Resources>
|
||||
<EgtCAM5:OperationParamVisibilityConverter x:Key="OperationParamVisibilityConverter"/>
|
||||
<EgtCAM5:DepthUnitConverter x:Key="DepthUnitConverter"/>
|
||||
<sys:Int32 x:Key="Invert">0</sys:Int32>
|
||||
<sys:Int32 x:Key="LeaveTab">1</sys:Int32>
|
||||
<sys:Int32 x:Key="WorkSide">2</sys:Int32>
|
||||
<sys:Int32 x:Key="HeadSide">3</sys:Int32>
|
||||
<sys:Int32 x:Key="LeadInType">4</sys:Int32>
|
||||
<sys:Int32 x:Key="ExtLinkType">5</sys:Int32>
|
||||
<sys:Int32 x:Key="LeadOutType">6</sys:Int32>
|
||||
<sys:Int32 x:Key="CurveUse">7</sys:Int32>
|
||||
<sys:Int32 x:Key="StepType">8</sys:Int32>
|
||||
<sys:Int32 x:Key="LeadLinkType">9</sys:Int32>
|
||||
<sys:Int32 x:Key="Speed">10</sys:Int32>
|
||||
<sys:Int32 x:Key="Feed">11</sys:Int32>
|
||||
<sys:Int32 x:Key="StartFeed">12</sys:Int32>
|
||||
<sys:Int32 x:Key="EndFeed">13</sys:Int32>
|
||||
<sys:Int32 x:Key="TipFeed">14</sys:Int32>
|
||||
<sys:Int32 x:Key="OffSr">15</sys:Int32>
|
||||
<sys:Int32 x:Key="OffSl">16</sys:Int32>
|
||||
<sys:Int32 x:Key="SideAngle">17</sys:Int32>
|
||||
<sys:Int32 x:Key="Approx">18</sys:Int32>
|
||||
<sys:Int32 x:Key="StartPos">19</sys:Int32>
|
||||
<sys:Int32 x:Key="StartSlowLen">20</sys:Int32>
|
||||
<sys:Int32 x:Key="EndSlowLen">21</sys:Int32>
|
||||
<sys:Int32 x:Key="ThrouAddLen">22</sys:Int32>
|
||||
<sys:Int32 x:Key="StepPar">23</sys:Int32>
|
||||
<sys:Int32 x:Key="ReturnPos">24</sys:Int32>
|
||||
<sys:Int32 x:Key="TabLen">25</sys:Int32>
|
||||
<sys:Int32 x:Key="TabDist">26</sys:Int32>
|
||||
<sys:Int32 x:Key="TabHeight">27</sys:Int32>
|
||||
<sys:Int32 x:Key="TabAngle">28</sys:Int32>
|
||||
<sys:Int32 x:Key="LiTang">29</sys:Int32>
|
||||
<sys:Int32 x:Key="LiPerp">30</sys:Int32>
|
||||
<sys:Int32 x:Key="LiElev">31</sys:Int32>
|
||||
<sys:Int32 x:Key="LiCompLen">32</sys:Int32>
|
||||
<sys:Int32 x:Key="LoTang">33</sys:Int32>
|
||||
<sys:Int32 x:Key="LoPerp">34</sys:Int32>
|
||||
<sys:Int32 x:Key="LoElev">35</sys:Int32>
|
||||
<sys:Int32 x:Key="LoCompLen">36</sys:Int32>
|
||||
<sys:Int32 x:Key="StartAddLen">37</sys:Int32>
|
||||
<sys:Int32 x:Key="EndAddLen">38</sys:Int32>
|
||||
<sys:Int32 x:Key="StepExtArc">39</sys:Int32>
|
||||
<sys:Int32 x:Key="StepIntArc">40</sys:Int32>
|
||||
<sys:Int32 x:Key="SideStep">41</sys:Int32>
|
||||
<sys:Int32 x:Key="VertFeed">42</sys:Int32>
|
||||
<sys:Int32 x:Key="NamePar">43</sys:Int32>
|
||||
<sys:Int32 x:Key="Tool">44</sys:Int32>
|
||||
<sys:Int32 x:Key="DepthStr">45</sys:Int32>
|
||||
<sys:Int32 x:Key="UserNotes">46</sys:Int32>
|
||||
<sys:Int32 x:Key="OverLapStr">47</sys:Int32>
|
||||
<sys:Int32 x:Key="OffsetStr">48</sys:Int32>
|
||||
<sys:Int32 x:Key="SubType">49</sys:Int32>
|
||||
<sys:Int32 x:Key="SolChoiceType">50</sys:Int32>
|
||||
<sys:Int32 x:Key="AxRotRef">51</sys:Int32>
|
||||
<sys:Int32 x:Key="BlockedAxesRef">52</sys:Int32>
|
||||
<sys:Int32 x:Key="FaceUseType">53</sys:Int32>
|
||||
<sys:Int32 x:Key="InvertToolDir">54</sys:Int32>
|
||||
<sys:Int32 x:Key="ExpanderLeadIn">55</sys:Int32>
|
||||
<sys:Int32 x:Key="ExpanderLeadOut">56</sys:Int32>
|
||||
<sys:Int32 x:Key="ApproxGen">57</sys:Int32>
|
||||
<sys:Int32 x:Key="OscEnable">58</sys:Int32>
|
||||
<sys:Int32 x:Key="OscHeight">59</sys:Int32>
|
||||
<sys:Int32 x:Key="OscRampLen">60</sys:Int32>
|
||||
<sys:Int32 x:Key="OscFlatLen">61</sys:Int32>
|
||||
</UserControl.Resources>
|
||||
|
||||
<StackPanel Name="OperationParametersStackPanel">
|
||||
<StackPanel Name="OperationFirstParametersStackPanel">
|
||||
<UniformGrid Columns="2">
|
||||
<TextBlock Text="{Binding DepthStrTxBl}" Style="{DynamicResource MPExpander_DepthTxBlMargin}"/>
|
||||
<EgtWPFLib5:EgtTextBox Text="{Binding DepthStr, UpdateSourceTrigger=PropertyChanged,
|
||||
Converter={StaticResource DepthUnitConverter}}"
|
||||
Style="{DynamicResource MPExpander_DepthTxBxMargin}"/>
|
||||
</UniformGrid>
|
||||
<EgtWPFLib5:CheckParamV ParamTxBl="{Binding InvertTxBl}"
|
||||
ParamChBx="{Binding Path=Invert,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
Style="{DynamicResource CheckParamV_Margin}"/>
|
||||
<UniformGrid Columns="2">
|
||||
<TextBlock Text="{Binding UserNotesTxBl}"
|
||||
Style="{DynamicResource MPExpander_UserNotesTxBlMargin}"/>
|
||||
<EgtWPFLib5:EgtTextBox Text="{Binding UserNotes, UpdateSourceTrigger=PropertyChanged}"
|
||||
Style="{DynamicResource MPExpander_UserNotesTxBxMargin}">
|
||||
<EgtWPFLib5:EgtTextBox.ToolTip>
|
||||
<TextBlock Text="{Binding UserNotesTooltip}"/>
|
||||
</EgtWPFLib5:EgtTextBox.ToolTip>
|
||||
</EgtWPFLib5:EgtTextBox>
|
||||
<TextBlock Text="{Binding SystemNotesTxBl}"
|
||||
Style="{DynamicResource MPExpander_UserNotesTxBlMargin}"
|
||||
Visibility="{Binding SysNotes_Visibility}"/>
|
||||
<EgtWPFLib5:EgtTextBox Text="{Binding SystemNotes, UpdateSourceTrigger=PropertyChanged}"
|
||||
Style="{DynamicResource MPExpander_UserNotesTxBxMargin}"
|
||||
Visibility="{Binding SysNotes_Visibility}"
|
||||
IsReadOnly="True"/>
|
||||
</UniformGrid>
|
||||
</StackPanel>
|
||||
<StackPanel Name="AutomaticCloseExpanderStackPanel">
|
||||
<Expander Header="{Binding GenericExpanderHeader}" Name="GenericExpander"
|
||||
Style="{StaticResource ExpanderStyle}" Margin="0,1,0,1">
|
||||
<StackPanel>
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding StartPosTxBl}"
|
||||
ParamTxBx="{Binding Path=StartPos,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
<EgtWPFLib5:ComboParamV ParamTxBl="{Binding SubTypeTxBl}"
|
||||
ParamCmBxList="{Binding Path=SubTypeList,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
ParamCmBxSelIndex="{Binding Path=SelectedSubType}"
|
||||
Style="{DynamicResource ComboParamV_Margin}"/>
|
||||
</StackPanel>
|
||||
</Expander>
|
||||
|
||||
<Expander Name="AdvancedParam" IsExpanded="{Binding AdvancedParamIsExpander}"
|
||||
Style="{StaticResource ExpanderStyle}" Margin="0,1,0,1">
|
||||
<Expander.Header>
|
||||
<UniformGrid Columns="2">
|
||||
<TextBlock Text="{Binding AdvancedParamMsg}"
|
||||
Margin="2.5"/>
|
||||
<Button Command="{Binding ShowNoteListComboCommand}"
|
||||
ToolTip="{Binding ShowNoteToolTip}"
|
||||
IsEnabled="{Binding ShowNoteListCombo_IsEnable}"
|
||||
Visibility="{Binding ShowNoteListCombo_Visibility}"
|
||||
Grid.Column="1"
|
||||
HorizontalAlignment="Right"
|
||||
Margin="2.5,2.5,7,2.5"
|
||||
Width="20">
|
||||
<Image Source="/Resources/Note/+.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</UniformGrid>
|
||||
</Expander.Header>
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="1*"/>
|
||||
<RowDefinition Height="Auto"/>
|
||||
</Grid.RowDefinitions>
|
||||
<StackPanel>
|
||||
<EgtWPFLib5:CheckParamV ParamTxBl="{Binding InvertToolDirTxBl}"
|
||||
ParamChBx="{Binding Path=InvertToolDir,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
Style="{DynamicResource CheckParamV_Margin}"/>
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding InitAngsTxBl}"
|
||||
ParamTxBx="{Binding Path=InitAngs,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding BlockedAxisTxBl}"
|
||||
ParamTxBx="{Binding Path=BlockedAxis,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
<EgtWPFLib5:ComboParamV ParamTxBl="{Binding SolChoiceTypeTxBl}"
|
||||
ParamCmBxList="{Binding Path=SolChoiceTypeList,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True,
|
||||
Mode=OneWay}"
|
||||
ParamCmBxSelIndex="{Binding Path=SelectedSolChoiceType}"
|
||||
Style="{DynamicResource ComboParamV_Margin}"/>
|
||||
</StackPanel>
|
||||
<Grid Grid.Row="1" Margin="0,5,0,0">
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="1*"/>
|
||||
<RowDefinition Height="Auto"/>
|
||||
</Grid.RowDefinitions>
|
||||
<ItemsControl ItemsSource="{Binding NotesList}">
|
||||
<ItemsControl.ItemTemplate>
|
||||
<DataTemplate>
|
||||
<Grid>
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<TextBlock Text="{Binding Description}"
|
||||
Margin="0,5.5,29,0"
|
||||
Width="82"
|
||||
Style="{DynamicResource MPExpander_UserNotesTxBlMargin}"/>
|
||||
<TabControl SelectedIndex="{Binding SelTypeValue}"
|
||||
Grid.Column="1"
|
||||
Background="Transparent"
|
||||
BorderBrush="Transparent">
|
||||
<TabControl.ItemContainerStyle>
|
||||
<Style TargetType="{x:Type TabItem}">
|
||||
<Setter Property="Visibility" Value="Collapsed"/>
|
||||
</Style>
|
||||
</TabControl.ItemContainerStyle>
|
||||
<TabItem Header="TEXT">
|
||||
<TextBox Text="{Binding Value, UpdateSourceTrigger=PropertyChanged}"
|
||||
IsReadOnly="False"/>
|
||||
</TabItem>
|
||||
<TabItem Header="CHECKBOX">
|
||||
<CheckBox IsChecked="{Binding Value, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</TabItem>
|
||||
<TabItem Header="COMBOBOX">
|
||||
<ComboBox ItemsSource="{Binding ListKeyValue}"
|
||||
SelectedItem="{Binding SelKeyValue, UpdateSourceTrigger=PropertyChanged}"
|
||||
DisplayMemberPath="KeyValue"/>
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
<Button Command="{Binding RemoveItemNoteCommand}"
|
||||
Grid.Column="2"
|
||||
Width="20"
|
||||
Height="20"
|
||||
Margin="5,0,0,0">
|
||||
<Image Source="/Resources/Note/-.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</Grid>
|
||||
</DataTemplate>
|
||||
</ItemsControl.ItemTemplate>
|
||||
</ItemsControl>
|
||||
<ComboBox ItemsSource="{Binding NotesListCombo}"
|
||||
SelectedItem="{Binding SelNoteItemCombo}"
|
||||
Grid.Row="1"
|
||||
Grid.ColumnSpan="1"
|
||||
Visibility="{Binding ComboAddVisibility}">
|
||||
<ComboBox.ItemTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Description}"
|
||||
Margin="2.5"/>
|
||||
</DataTemplate>
|
||||
</ComboBox.ItemTemplate>
|
||||
</ComboBox>
|
||||
</Grid>
|
||||
</Grid>
|
||||
</Expander>
|
||||
|
||||
<Expander Style="{StaticResource ExpanderStyle}">
|
||||
<Expander.Header>
|
||||
<TextBlock Text="{Binding ToolExpanderHeader}"/>
|
||||
</Expander.Header>
|
||||
<StackPanel>
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding FeedTxBl}"
|
||||
ParamTxBx="{Binding Path=Feed,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding TipFeedTxBl}"
|
||||
ParamTxBx="{Binding Path=TipFeed,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding StartFeedTxBl}"
|
||||
ParamTxBx="{Binding Path=StartFeed,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding EndFeedTxBl}"
|
||||
ParamTxBx="{Binding Path=EndFeed,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
</StackPanel>
|
||||
</Expander>
|
||||
<Interactivity:Interaction.Behaviors>
|
||||
<EgtCAM5:AutomaticCloseExpander/>
|
||||
</Interactivity:Interaction.Behaviors>
|
||||
</StackPanel>
|
||||
</StackPanel>
|
||||
|
||||
</UserControl>
|
||||
@@ -0,0 +1,83 @@
|
||||
Imports EgtWPFLib5.EgtFloating
|
||||
|
||||
Public Class ProbingParameterExpanderV
|
||||
|
||||
Private m_RightTrayV As RightTrayV
|
||||
Private EgtFloatingPanel As EgtFloatingPanel
|
||||
|
||||
Private m_bFirst As Boolean = True
|
||||
|
||||
Private Sub OperationExpanderView_Loaded(sender As Object, e As System.Windows.RoutedEventArgs) Handles Me.Loaded
|
||||
If m_bFirst Then
|
||||
m_RightTrayV = FindAncestor(Of RightTrayV)(Me)
|
||||
EgtFloatingPanel = FindAncestor(Of EgtFloatingPanel)(Me)
|
||||
AddHandler m_RightTrayV.SizeChanged, AddressOf RightTrayV_SizeChanged
|
||||
PanelHeight = EgtFloatingPanel.DesiredSize.Height
|
||||
Me.AutomaticCloseExpanderStackPanelHeight = AutomaticCloseExpanderStackPanel.ActualHeight
|
||||
m_bFirst = False
|
||||
End If
|
||||
CalculateOperationParametersStackPanelMaxHeight()
|
||||
End Sub
|
||||
|
||||
Dim m_bSizeChanging As Boolean = False
|
||||
|
||||
Private Sub RightTrayV_SizeChanged(sender As Object, e As System.Windows.SizeChangedEventArgs)
|
||||
If m_bSizeChanging Then Return
|
||||
m_bSizeChanging = True
|
||||
CalculateOperationParametersStackPanelMaxHeight()
|
||||
m_bSizeChanging = False
|
||||
End Sub
|
||||
|
||||
Dim PanelHeight As Double = 0
|
||||
Dim AutomaticCloseExpanderStackPanelHeight As Double = 0
|
||||
|
||||
' ricalcola spazio utilizzabile quando modificata dimensione finestra e quindi dimensione della tray
|
||||
Private Sub CalculateOperationParametersStackPanelMaxHeight()
|
||||
Dim AutomaticCloseExpanderStackPanelHeight As Double = 0
|
||||
Dim OpenedExpanderList As New List(Of Boolean)
|
||||
For Index = 0 To AutomaticCloseExpanderStackPanel.Children.Count - 1
|
||||
If TypeOf AutomaticCloseExpanderStackPanel.Children(Index) Is Expander Then
|
||||
Dim IndexedExpander As Expander = DirectCast(AutomaticCloseExpanderStackPanel.Children(Index), Expander)
|
||||
If IndexedExpander.IsExpanded Then
|
||||
OpenedExpanderList.Add(True)
|
||||
IndexedExpander.IsExpanded = False
|
||||
Dim CurrExpanderContent As FrameworkElement = DirectCast(IndexedExpander.Content, FrameworkElement)
|
||||
CurrExpanderContent.Measure(New Size(Double.PositiveInfinity, Double.PositiveInfinity))
|
||||
AutomaticCloseExpanderStackPanelHeight -= CurrExpanderContent.DesiredSize.Height
|
||||
' Sottraggo anche i padding
|
||||
AutomaticCloseExpanderStackPanelHeight -= (IndexedExpander.Padding.Top + IndexedExpander.Padding.Bottom)
|
||||
Else
|
||||
OpenedExpanderList.Add(False)
|
||||
End If
|
||||
Else
|
||||
OpenedExpanderList.Add(False)
|
||||
End If
|
||||
Next
|
||||
Dim RemainingHeight As Double = m_RightTrayV.ActualHeight - PanelHeight
|
||||
AutomaticCloseExpanderStackPanel.MaxHeight = Me.AutomaticCloseExpanderStackPanelHeight + RemainingHeight
|
||||
For Index = AutomaticCloseExpanderStackPanel.Children.Count - 1 To 0 Step -1
|
||||
If TypeOf AutomaticCloseExpanderStackPanel.Children(Index) Is Expander Then
|
||||
Dim IndexedExpander As Expander = DirectCast(AutomaticCloseExpanderStackPanel.Children(Index), Expander)
|
||||
If OpenedExpanderList(Index) Then
|
||||
IndexedExpander.IsExpanded = True
|
||||
End If
|
||||
End If
|
||||
Next
|
||||
End Sub
|
||||
|
||||
' Funzione che permette di trovare il primo contenitore di tipo T di un elemento grafico dependencyObject
|
||||
Public Function FindAncestor(Of T As Class)(dependencyObject As DependencyObject) As T
|
||||
Dim target As DependencyObject = dependencyObject
|
||||
Do
|
||||
target = LogicalTreeHelper.GetParent(target)
|
||||
Loop While target IsNot Nothing AndAlso Not (TypeOf target Is T)
|
||||
If IsNothing(target) Then
|
||||
target = dependencyObject
|
||||
Do
|
||||
target = VisualTreeHelper.GetParent(target)
|
||||
Loop While target IsNot Nothing AndAlso Not (TypeOf target Is T)
|
||||
End If
|
||||
Return TryCast(target, T)
|
||||
End Function
|
||||
|
||||
End Class
|
||||
@@ -213,7 +213,12 @@
|
||||
IsReadOnly="False"/>
|
||||
</TabItem>
|
||||
<TabItem Header="CHECKBOX">
|
||||
<CheckBox IsChecked="{Binding Value}"/>
|
||||
<CheckBox IsChecked="{Binding Value, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</TabItem>
|
||||
<TabItem Header="COMBOBOX">
|
||||
<ComboBox ItemsSource="{Binding ListKeyValue}"
|
||||
SelectedItem="{Binding SelKeyValue, UpdateSourceTrigger=PropertyChanged}"
|
||||
DisplayMemberPath="KeyValue"/>
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
<Button Command="{Binding RemoveItemNoteCommand}"
|
||||
|
||||
@@ -217,7 +217,12 @@
|
||||
IsReadOnly="False"/>
|
||||
</TabItem>
|
||||
<TabItem Header="CHECKBOX">
|
||||
<CheckBox IsChecked="{Binding Value}"/>
|
||||
<CheckBox IsChecked="{Binding Value, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</TabItem>
|
||||
<TabItem Header="COMBOBOX">
|
||||
<ComboBox ItemsSource="{Binding ListKeyValue}"
|
||||
SelectedItem="{Binding SelKeyValue, UpdateSourceTrigger=PropertyChanged}"
|
||||
DisplayMemberPath="KeyValue"/>
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
<Button Command="{Binding RemoveItemNoteCommand}"
|
||||
|
||||
@@ -211,7 +211,12 @@
|
||||
IsReadOnly="False"/>
|
||||
</TabItem>
|
||||
<TabItem Header="CHECKBOX">
|
||||
<CheckBox IsChecked="{Binding Value}"/>
|
||||
<CheckBox IsChecked="{Binding Value, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</TabItem>
|
||||
<TabItem Header="COMBOBOX">
|
||||
<ComboBox ItemsSource="{Binding ListKeyValue}"
|
||||
SelectedItem="{Binding SelKeyValue, UpdateSourceTrigger=PropertyChanged}"
|
||||
DisplayMemberPath="KeyValue"/>
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
<Button Command="{Binding RemoveItemNoteCommand}"
|
||||
|
||||
@@ -209,7 +209,12 @@
|
||||
IsReadOnly="False"/>
|
||||
</TabItem>
|
||||
<TabItem Header="CHECKBOX">
|
||||
<CheckBox IsChecked="{Binding Value}"/>
|
||||
<CheckBox IsChecked="{Binding Value, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</TabItem>
|
||||
<TabItem Header="COMBOBOX">
|
||||
<ComboBox ItemsSource="{Binding ListKeyValue}"
|
||||
SelectedItem="{Binding SelKeyValue, UpdateSourceTrigger=PropertyChanged}"
|
||||
DisplayMemberPath="KeyValue"/>
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
<Button Command="{Binding RemoveItemNoteCommand}"
|
||||
|
||||
@@ -217,7 +217,12 @@
|
||||
IsReadOnly="False"/>
|
||||
</TabItem>
|
||||
<TabItem Header="CHECKBOX">
|
||||
<CheckBox IsChecked="{Binding Value}"/>
|
||||
<CheckBox IsChecked="{Binding Value, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</TabItem>
|
||||
<TabItem Header="COMBOBOX">
|
||||
<ComboBox ItemsSource="{Binding ListKeyValue}"
|
||||
SelectedItem="{Binding SelKeyValue, UpdateSourceTrigger=PropertyChanged}"
|
||||
DisplayMemberPath="KeyValue"/>
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
<Button Command="{Binding RemoveItemNoteCommand}"
|
||||
|
||||
@@ -124,12 +124,6 @@
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
Style="{DynamicResource StringParamV_Margin}"/>
|
||||
<EgtWPFLib5:ComboParamV ParamTxBl="{Binding LeadLinkTypeTxBl}"
|
||||
ParamCmBxList="{Binding Path=LeadLinkTypeList,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
ValidatesOnDataErrors=True}"
|
||||
ParamCmBxSelIndex="{Binding Path=SelectedLeadLinkType}"
|
||||
Style="{DynamicResource ComboParamV_Margin}"/>
|
||||
<EgtWPFLib5:StringParamV ParamTxBl="{Binding SideAngleTxBl}"
|
||||
ParamTxBx="{Binding Path=SideAngle,
|
||||
UpdateSourceTrigger=PropertyChanged,
|
||||
@@ -230,7 +224,12 @@
|
||||
IsReadOnly="False"/>
|
||||
</TabItem>
|
||||
<TabItem Header="CHECKBOX">
|
||||
<CheckBox IsChecked="{Binding Value}"/>
|
||||
<CheckBox IsChecked="{Binding Value, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</TabItem>
|
||||
<TabItem Header="COMBOBOX">
|
||||
<ComboBox ItemsSource="{Binding ListKeyValue}"
|
||||
SelectedItem="{Binding SelKeyValue, UpdateSourceTrigger=PropertyChanged}"
|
||||
DisplayMemberPath="KeyValue"/>
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
<Button Command="{Binding RemoveItemNoteCommand}"
|
||||
|
||||
@@ -236,6 +236,11 @@
|
||||
<TabItem Header="CHECKBOX">
|
||||
<CheckBox IsChecked="{Binding Value, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</TabItem>
|
||||
<TabItem Header="COMBOBOX">
|
||||
<ComboBox ItemsSource="{Binding ListKeyValue}"
|
||||
SelectedItem="{Binding SelKeyValue, UpdateSourceTrigger=PropertyChanged}"
|
||||
DisplayMemberPath="KeyValue"/>
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
<Button Command="{Binding RemoveItemNoteCommand}"
|
||||
Grid.Column="2"
|
||||
|
||||
@@ -199,7 +199,12 @@
|
||||
IsReadOnly="False"/>
|
||||
</TabItem>
|
||||
<TabItem Header="CHECKBOX">
|
||||
<CheckBox IsChecked="{Binding Value}"/>
|
||||
<CheckBox IsChecked="{Binding Value, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</TabItem>
|
||||
<TabItem Header="COMBOBOX">
|
||||
<ComboBox ItemsSource="{Binding ListKeyValue}"
|
||||
SelectedItem="{Binding SelKeyValue, UpdateSourceTrigger=PropertyChanged}"
|
||||
DisplayMemberPath="KeyValue"/>
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
<Button Command="{Binding RemoveItemNoteCommand}"
|
||||
|
||||
@@ -218,7 +218,12 @@
|
||||
IsReadOnly="False"/>
|
||||
</TabItem>
|
||||
<TabItem Header="CHECKBOX">
|
||||
<CheckBox IsChecked="{Binding Value}"/>
|
||||
<CheckBox IsChecked="{Binding Value, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</TabItem>
|
||||
<TabItem Header="COMBOBOX">
|
||||
<ComboBox ItemsSource="{Binding ListKeyValue}"
|
||||
SelectedItem="{Binding SelKeyValue, UpdateSourceTrigger=PropertyChanged}"
|
||||
DisplayMemberPath="KeyValue"/>
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
<Button Command="{Binding RemoveItemNoteCommand}"
|
||||
|
||||
@@ -236,7 +236,12 @@
|
||||
IsReadOnly="False"/>
|
||||
</TabItem>
|
||||
<TabItem Header="CHECKBOX">
|
||||
<CheckBox IsChecked="{Binding Value}"/>
|
||||
<CheckBox IsChecked="{Binding Value, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</TabItem>
|
||||
<TabItem Header="COMBOBOX">
|
||||
<ComboBox ItemsSource="{Binding ListKeyValue}"
|
||||
SelectedItem="{Binding SelKeyValue, UpdateSourceTrigger=PropertyChanged}"
|
||||
DisplayMemberPath="KeyValue"/>
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
<Button Command="{Binding RemoveItemNoteCommand}"
|
||||
|
||||
@@ -226,7 +226,12 @@
|
||||
IsReadOnly="False"/>
|
||||
</TabItem>
|
||||
<TabItem Header="CHECKBOX">
|
||||
<CheckBox IsChecked="{Binding Value}"/>
|
||||
<CheckBox IsChecked="{Binding Value, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</TabItem>
|
||||
<TabItem Header="COMBOBOX">
|
||||
<ComboBox ItemsSource="{Binding ListKeyValue}"
|
||||
SelectedItem="{Binding SelKeyValue, UpdateSourceTrigger=PropertyChanged}"
|
||||
DisplayMemberPath="KeyValue"/>
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
<Button Command="{Binding RemoveItemNoteCommand}"
|
||||
|
||||
@@ -28,6 +28,31 @@ Public Class DispositionOpListBoxItem
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Public Property OnOffAll As Boolean?
|
||||
Get
|
||||
Dim OpIndexes As List(Of Integer) = GetOpIndexes()
|
||||
' Ritorno il valore specificato in base agli stati delle operazioni di cui abbiamo raccolto gli indici
|
||||
If OpIndexes.Count = 0 Then Return False
|
||||
Dim bTemp As Boolean = DirectCast(Map.refOperationsListExpanderVM.OperationList.Item(OpIndexes(0)), MachiningOpListBoxItem).OnOff
|
||||
For OpInDispIndex = 1 To OpIndexes.Count - 1
|
||||
If DirectCast(Map.refOperationsListExpanderVM.OperationList.Item(OpIndexes(OpInDispIndex)), MachiningOpListBoxItem).OnOff <> bTemp Then Return Nothing
|
||||
Next
|
||||
Return bTemp
|
||||
End Get
|
||||
Set(value As Boolean?)
|
||||
' Recupero gli indici delle operazioni della Disposizione corrente
|
||||
Dim OpIndexes As List(Of Integer) = GetOpIndexes()
|
||||
If OpIndexes.Count = 0 Then
|
||||
NotifyPropertyChanged(NameOf(OnOffAll))
|
||||
Return
|
||||
End If
|
||||
For Each OpInDispIndex In OpIndexes
|
||||
DirectCast(Map.refOperationsListExpanderVM.OperationList.Item(OpInDispIndex), MachiningOpListBoxItem).OnOff = If(IsNothing(value), False, CBool(value))
|
||||
Next
|
||||
End Set
|
||||
End Property
|
||||
|
||||
|
||||
Private m_Image As String = String.Empty
|
||||
Public Property Image As String
|
||||
Get
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
Imports System.ComponentModel
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports EgtUILib
|
||||
|
||||
Public Class MachiningOpListBoxItem
|
||||
@@ -126,6 +125,31 @@ Public Class MachiningOpListBoxItem
|
||||
End Get
|
||||
End Property
|
||||
|
||||
|
||||
Private m_bOnOff As Boolean = True
|
||||
Public Property OnOff As Boolean
|
||||
Get
|
||||
Return m_bOnOff
|
||||
End Get
|
||||
Set(value As Boolean)
|
||||
If m_bOnOff <> value Then
|
||||
m_bOnOff = value
|
||||
Dim bOldEnMod As Boolean = EgtGetEnableModified()
|
||||
EgtDisableModified()
|
||||
' se abilitato, eseguo operazione
|
||||
Dim status As Integer = GDB_ST.OFF
|
||||
If value Then
|
||||
status = GDB_ST.ON_
|
||||
End If
|
||||
ModifyStatusLamp()
|
||||
EgtSetStatus(Id, status)
|
||||
If bOldEnMod Then EgtEnableModified()
|
||||
EgtDraw()
|
||||
End If
|
||||
NotifyPropertyChanged(NameOf(OnOff))
|
||||
End Set
|
||||
End Property
|
||||
|
||||
' Definizione comandi
|
||||
Private m_cmdModifyNameEnter As ICommand
|
||||
Private m_cmdModifyNameEsc As ICommand
|
||||
@@ -177,6 +201,21 @@ Public Class MachiningOpListBoxItem
|
||||
End Select
|
||||
End Function
|
||||
|
||||
Private Sub ModifyStatusLamp()
|
||||
' Recupero l'indice dell'operazione a cui abbiamo appena modificato lo Status e l'indice della Disposizione che la contiene
|
||||
Dim DispIndex As Integer = 0
|
||||
Dim OpIndex As Integer = 0
|
||||
For Each OpItem In Map.refOperationsListExpanderVM.OperationList
|
||||
If EgtGetOperationType(OpItem.Id) = MCH_OY.DISP Then DispIndex = OpIndex
|
||||
If OpItem.Id = Id Then
|
||||
Exit For
|
||||
End If
|
||||
OpIndex += 1
|
||||
Next
|
||||
' Notifico StatusAll per calcolare lo stato della CheckBox della Disposizione
|
||||
Map.refOperationsListExpanderVM.OperationList(DispIndex).NotifyPropertyChanged(NameOf(DispositionOpListBoxItem.OnOffAll))
|
||||
End Sub
|
||||
|
||||
#Region "COMMANDS"
|
||||
|
||||
#Region "ModifyNameEnterCommand"
|
||||
|
||||
@@ -74,7 +74,7 @@ Public Class OperationListBoxItem
|
||||
Map.refOperationsListExpanderVM.OnPropertyChanged("MoveDown_IsEnabled")
|
||||
NotifyPropertyChanged("IsSelected")
|
||||
' Aggiorno visualizzazione
|
||||
EgtDraw()
|
||||
If Map.refOperationsListExpanderVM.ForceDrawInIsSelected Then EgtDraw()
|
||||
Return
|
||||
End If
|
||||
' Imposto la fase di lavorazione corrente
|
||||
@@ -124,7 +124,7 @@ Public Class OperationListBoxItem
|
||||
Map.refMachiningTreeExpanderVM.nSelectedOperationId = Me.Id
|
||||
End If
|
||||
' Aggiorno visualizzazione
|
||||
EgtDraw()
|
||||
If Map.refOperationsListExpanderVM.ForceDrawInIsSelected Then EgtDraw()
|
||||
End If
|
||||
' Resetto valori slider
|
||||
If Not IsNothing(Map.refMachiningParameterExpanderVM) Then
|
||||
|
||||
@@ -177,6 +177,8 @@ Public Class OperationParametersExpanderVM
|
||||
Map.refProjectVM.SceneSelMode = OptionModule.m_SelGeomWaterJetting
|
||||
Case MCH_OY.FIVEAXISMILLING
|
||||
Map.refProjectVM.SceneSelMode = OptionModule.m_SelGeomFiveAxMilling
|
||||
Case MCH_OY.PROBING
|
||||
Map.refProjectVM.SceneSelMode = OptionModule.m_SelGeomProbing
|
||||
End Select
|
||||
' Imposto visualizzazione utensile
|
||||
Map.refMachiningParameterExpanderVM.SetViewTool( True)
|
||||
|
||||
@@ -43,6 +43,7 @@
|
||||
</Border.InputBindings>
|
||||
<Grid Style="{StaticResource LayoutRoot}">
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
@@ -50,9 +51,12 @@
|
||||
</Grid.ColumnDefinitions>
|
||||
<CheckBox IsChecked="{Binding Status}" Margin="0,0,5,0"/>
|
||||
<Image Source="{Binding Image}" Height="15" Margin="0,0,5,0"/>
|
||||
<TextBlock Grid.Column="1" Text="{Binding Name}"
|
||||
<ToggleButton Style="{StaticResource EgtCAM5_LampToggleButton}" Grid.Column="1"
|
||||
IsChecked="{Binding OnOff}" Visibility="{Binding IsHidden}" Focusable="True" Height="15" Width="15" Margin="0,0,5,0"/>
|
||||
|
||||
<TextBlock Grid.Column="2" Text="{Binding Name}"
|
||||
Visibility="{Binding Name_Visibility}" Margin="0,0,5,0"/>
|
||||
<TextBox Grid.Column="1" Text="{Binding ModifiedName, UpdateSourceTrigger=PropertyChanged}"
|
||||
<TextBox Grid.Column="2" Text="{Binding ModifiedName, UpdateSourceTrigger=PropertyChanged}"
|
||||
Width="150"
|
||||
x:Name="Box"
|
||||
Visibility="{Binding ModifyName_Visibility}" Margin="0,0,5,0">
|
||||
@@ -63,7 +67,7 @@
|
||||
<KeyBinding Key="Escape" Command="{Binding ModifyNameEscCommand}"/>
|
||||
</TextBox.InputBindings>
|
||||
</TextBox>
|
||||
<TextBlock Grid.Column="2" Text="{Binding Info}"/>
|
||||
<TextBlock Grid.Column="3" Text="{Binding Info}"/>
|
||||
</Grid>
|
||||
</Border>
|
||||
</DataTemplate>
|
||||
@@ -76,6 +80,9 @@
|
||||
</Border.InputBindings>
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<CheckBox IsChecked="{Binding StatusAll}" VerticalAlignment="Center" Margin="0,0,5,0"/>
|
||||
<CheckBox IsChecked="{Binding OnOffAll}" VerticalAlignment="Center" Margin="0,0,5,0"/>
|
||||
<!--<ToggleButton Style="{StaticResource EgtCAM5_LampToggleButton}"
|
||||
IsChecked="{Binding OnOffAll}" Visibility="{Binding IsHidden}" Focusable="True" Height="15" Width="15" Margin="0,0,5,0"/>-->
|
||||
<Image Source="{Binding Image}" Height="15" Margin="0,0,5,0"/>
|
||||
<TextBlock Text="{Binding Name}" Foreground="White"
|
||||
FontSize="15" FontWeight="SemiBold"/>
|
||||
|
||||
@@ -84,6 +84,7 @@ Public Class OperationsListExpanderVM
|
||||
Set(value As Boolean)
|
||||
If value <> m_ListIsExpanded Then
|
||||
Map.refMachiningOptionPanelVM.Set_IsExpanded(MachiningOptionPanelVM.MachiningOptionPanelExpander.OPERATIONLIST, value)
|
||||
SetStatusOnLamp()
|
||||
End If
|
||||
End Set
|
||||
End Property
|
||||
@@ -111,6 +112,37 @@ Public Class OperationsListExpanderVM
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Private m_tmpOperationList As New ObservableCollection(Of MachiningOpListBoxItem)
|
||||
Public Property tmpOperationList As ObservableCollection(Of MachiningOpListBoxItem)
|
||||
Get
|
||||
Return m_tmpOperationList
|
||||
End Get
|
||||
Set(value As ObservableCollection(Of MachiningOpListBoxItem))
|
||||
m_tmpOperationList = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Private m_StatusLampList As New ObservableCollection(Of StatusLamp)
|
||||
Public Property StatusLampList As ObservableCollection(Of StatusLamp)
|
||||
Get
|
||||
Return m_StatusLampList
|
||||
End Get
|
||||
Set(value As ObservableCollection(Of StatusLamp))
|
||||
m_StatusLampList = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
' Forza il disegno quando seleziono la lampadina
|
||||
Private m_ForceDrawInIsSelected As Boolean = True
|
||||
Public Property ForceDrawInIsSelected As Boolean
|
||||
Get
|
||||
Return m_ForceDrawInIsSelected
|
||||
End Get
|
||||
Set(value As Boolean)
|
||||
m_ForceDrawInIsSelected = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Public ReadOnly Property DuplicateCmd_IsEnabled As Boolean
|
||||
Get
|
||||
Dim SelType As Integer = MCH_OY.NONE
|
||||
@@ -258,7 +290,7 @@ Public Class OperationsListExpanderVM
|
||||
#Region "CONSTRUCTOR"
|
||||
|
||||
Sub New()
|
||||
m_bMoveThroughDisps = ( GetPrivateProfileInt( S_MACH, K_MOVETHROUGHDISPS, 0) <> 0)
|
||||
m_bMoveThroughDisps = (GetPrivateProfileInt(S_MACH, K_MOVETHROUGHDISPS, 0) <> 0)
|
||||
' Creo riferimento a questa classe in Map
|
||||
Map.SetRefOperationsListExpanderVM(Me)
|
||||
Me.ListIsExpanded = True
|
||||
@@ -333,7 +365,7 @@ Public Class OperationsListExpanderVM
|
||||
For Each nId As Integer In vRawId
|
||||
EgtKeepRawPart(nId, nLastPhase)
|
||||
Next
|
||||
EgtKeepAllDispAxes( nLastPhase)
|
||||
EgtKeepAllDispAxes(nLastPhase)
|
||||
For Each nId As Integer In vFxtId
|
||||
EgtKeepFixture(nId, nLastPhase)
|
||||
Next
|
||||
@@ -435,7 +467,7 @@ Public Class OperationsListExpanderVM
|
||||
If EgtGetOperationMode(selOperation.Id) Then
|
||||
Map.refOperationParametersExpanderVM.ParametersIsExpanded = True
|
||||
If EgtGetOperationType(selOperation.Id) <> MCH_OY.DISP Then
|
||||
Map.refMachiningParameterExpanderVM.SetSliderScale( EgtGetPreviewMachiningToolStepCount())
|
||||
Map.refMachiningParameterExpanderVM.SetSliderScale(EgtGetPreviewMachiningToolStepCount())
|
||||
Map.refMachiningParameterExpanderVM.ResetSliderValue()
|
||||
End If
|
||||
End If
|
||||
@@ -462,55 +494,55 @@ Public Class OperationsListExpanderVM
|
||||
''' </summary>
|
||||
Public Sub MoveUp()
|
||||
' Verifico il numero di elementi selezionati
|
||||
Dim indexes As New List( Of Integer)()
|
||||
Dim indexes As New List(Of Integer)()
|
||||
For index As Integer = 0 To OperationList.Count - 1
|
||||
' Verifico gli elementi selezionati
|
||||
If OperationList.Item( index).IsSelected Then
|
||||
If OperationList.Item(index).IsSelected Then
|
||||
' Se presente una disposizione esco
|
||||
If EgtGetOperationType( OperationList.Item( index).Id) = MCH_OY.DISP Then Return
|
||||
If EgtGetOperationType(OperationList.Item(index).Id) = MCH_OY.DISP Then Return
|
||||
' Aggiungo l'operazione
|
||||
indexes.Add( index)
|
||||
indexes.Add(index)
|
||||
End If
|
||||
Next
|
||||
Dim lenIndexes As Integer = indexes.Count
|
||||
' Recupero Id ultima entità selezionata e precedente a quelle selezionate
|
||||
Dim LastSelectedId As Integer = OperationList( indexes( lenIndexes - 1)).Id
|
||||
Dim PreviousId As Integer = OperationList( indexes( 0) - 1).Id
|
||||
Dim LastSelectedId As Integer = OperationList(indexes(lenIndexes - 1)).Id
|
||||
Dim PreviousId As Integer = OperationList(indexes(0) - 1).Id
|
||||
' Sposto l'operazione precedente a quelle selezionate nell'ambiente Egt
|
||||
If EgtRelocate( PreviousId, LastSelectedId, GDB_POS.AFTER) Then
|
||||
If EgtRelocate(PreviousId, LastSelectedId, GDB_POS.AFTER) Then
|
||||
' Sposto l'operazione precedente a quelle selezionate nella grafica
|
||||
OperationList.Move( indexes(0) - 1, indexes( lenIndexes - 1)) ' + 1)
|
||||
OperationList.Move(indexes(0) - 1, indexes(lenIndexes - 1)) ' + 1)
|
||||
' Ricalcolo le lavorazioni selezionate e quella che era precedente (e ora è seguente)
|
||||
If Not m_bMoveThroughDisps Then
|
||||
For index As Integer = 0 To indexes.Count - 1
|
||||
EgtSetCurrMachining( OperationList( indexes( index)).Id)
|
||||
EgtApplyMachining( False)
|
||||
EgtSetCurrMachining(OperationList(indexes(index)).Id)
|
||||
EgtApplyMachining(False)
|
||||
Next
|
||||
EgtSetCurrMachining( PreviousId)
|
||||
EgtApplyMachining( False)
|
||||
EgtSetCurrMachining(PreviousId)
|
||||
EgtApplyMachining(False)
|
||||
EgtDraw()
|
||||
OnPropertyChanged( "MoveUp_IsEnabled")
|
||||
OnPropertyChanged( "MoveDown_IsEnabled")
|
||||
OnPropertyChanged("MoveUp_IsEnabled")
|
||||
OnPropertyChanged("MoveDown_IsEnabled")
|
||||
Map.refProjectVM.EmitTitle()
|
||||
Else
|
||||
Dim nCurrPhase As Integer = EgtGetOperationPhase(LastSelectedId)
|
||||
For index As Integer = 0 To indexes.Count - 1
|
||||
Dim nOpeId As Integer = OperationList( indexes( index) - 1).Id
|
||||
If EgtGetOperationType( nOpeId) <> MCH_OY.DISP Then
|
||||
EgtAdjustOperationPhase( nOpeId)
|
||||
EgtSetCurrMachining( nOpeId)
|
||||
EgtApplyMachining( False)
|
||||
Dim nOpeId As Integer = OperationList(indexes(index) - 1).Id
|
||||
If EgtGetOperationType(nOpeId) <> MCH_OY.DISP Then
|
||||
EgtAdjustOperationPhase(nOpeId)
|
||||
EgtSetCurrMachining(nOpeId)
|
||||
EgtApplyMachining(False)
|
||||
End If
|
||||
Next
|
||||
If EgtGetOperationType( PreviousId) <> MCH_OY.DISP Then
|
||||
EgtSetCurrMachining( PreviousId)
|
||||
EgtApplyMachining( False)
|
||||
If EgtGetOperationType(PreviousId) <> MCH_OY.DISP Then
|
||||
EgtSetCurrMachining(PreviousId)
|
||||
EgtApplyMachining(False)
|
||||
End If
|
||||
Dim nNewPhase As Integer = EgtGetOperationPhase(LastSelectedId)
|
||||
If nNewPhase <> nCurrPhase Then EgtSetCurrPhase( nNewPhase)
|
||||
If nNewPhase <> nCurrPhase Then EgtSetCurrPhase(nNewPhase)
|
||||
EgtDraw()
|
||||
OnPropertyChanged( NameOf(MoveUp_IsEnabled))
|
||||
OnPropertyChanged( NameOf(MoveDown_IsEnabled))
|
||||
OnPropertyChanged(NameOf(MoveUp_IsEnabled))
|
||||
OnPropertyChanged(NameOf(MoveDown_IsEnabled))
|
||||
Map.refProjectVM.EmitTitle()
|
||||
End If
|
||||
End If
|
||||
@@ -537,52 +569,52 @@ Public Class OperationsListExpanderVM
|
||||
''' </summary>
|
||||
Public Sub MoveDown()
|
||||
' Verifico il numero di elementi selezionati
|
||||
Dim indexes As New List( Of Integer)()
|
||||
Dim indexes As New List(Of Integer)()
|
||||
For index As Integer = 0 To OperationList.Count - 1
|
||||
' Verifico gli elementi selezionati
|
||||
If OperationList.Item( index).IsSelected Then
|
||||
If OperationList.Item(index).IsSelected Then
|
||||
' Se presente una disposizione esco
|
||||
If EgtGetOperationType( OperationList.Item( index).Id) = MCH_OY.DISP Then Return
|
||||
If EgtGetOperationType(OperationList.Item(index).Id) = MCH_OY.DISP Then Return
|
||||
' Aggiungo l'operazione
|
||||
indexes.Add( index)
|
||||
indexes.Add(index)
|
||||
End If
|
||||
Next
|
||||
Dim lenIndexes As Integer = indexes.Count
|
||||
' Recupero Id prima entità selezionata e successiva a quelle selezionate
|
||||
Dim FirstSelectedId As Integer = OperationList( indexes( 0)).Id
|
||||
Dim NextId As Integer = OperationList( indexes( lenIndexes - 1) + 1).Id
|
||||
Dim FirstSelectedId As Integer = OperationList(indexes(0)).Id
|
||||
Dim NextId As Integer = OperationList(indexes(lenIndexes - 1) + 1).Id
|
||||
' Sposto l'operazione successiva a quelle selezionate nell'ambiente Egt
|
||||
If EgtRelocate( NextId, FirstSelectedId, GDB_POS.BEFORE) Then
|
||||
If EgtRelocate(NextId, FirstSelectedId, GDB_POS.BEFORE) Then
|
||||
' Sposto l'operazione successiva a quelle selezionate nella grafica
|
||||
OperationList.Move( indexes( lenIndexes - 1) + 1, indexes( 0))
|
||||
OperationList.Move(indexes(lenIndexes - 1) + 1, indexes(0))
|
||||
' Ricalcolo la lavorazioni selezionate e quella che era seguente (e ora è precedente)
|
||||
If Not m_bMoveThroughDisps Then
|
||||
EgtSetCurrMachining( NextId)
|
||||
EgtApplyMachining( False)
|
||||
EgtSetCurrMachining(NextId)
|
||||
EgtApplyMachining(False)
|
||||
For index As Integer = 0 To indexes.Count - 1
|
||||
EgtSetCurrMachining( OperationList( indexes( index)).Id)
|
||||
EgtApplyMachining( False)
|
||||
EgtSetCurrMachining(OperationList(indexes(index)).Id)
|
||||
EgtApplyMachining(False)
|
||||
Next
|
||||
EgtDraw()
|
||||
OnPropertyChanged( "MoveUp_IsEnabled")
|
||||
OnPropertyChanged( "MoveDown_IsEnabled")
|
||||
OnPropertyChanged("MoveUp_IsEnabled")
|
||||
OnPropertyChanged("MoveDown_IsEnabled")
|
||||
Map.refProjectVM.EmitTitle()
|
||||
Else
|
||||
If EgtGetOperationType( NextId) <> MCH_OY.DISP Then
|
||||
EgtSetCurrMachining( NextId)
|
||||
EgtApplyMachining( False)
|
||||
If EgtGetOperationType(NextId) <> MCH_OY.DISP Then
|
||||
EgtSetCurrMachining(NextId)
|
||||
EgtApplyMachining(False)
|
||||
End If
|
||||
For index As Integer = 0 To indexes.Count - 1
|
||||
Dim nOpeId As Integer = OperationList( indexes( index) + 1).Id
|
||||
If EgtGetOperationType( nOpeId) <> MCH_OY.DISP Then
|
||||
EgtAdjustOperationPhase( nOpeId)
|
||||
EgtSetCurrMachining( nOpeId)
|
||||
EgtApplyMachining( False)
|
||||
Dim nOpeId As Integer = OperationList(indexes(index) + 1).Id
|
||||
If EgtGetOperationType(nOpeId) <> MCH_OY.DISP Then
|
||||
EgtAdjustOperationPhase(nOpeId)
|
||||
EgtSetCurrMachining(nOpeId)
|
||||
EgtApplyMachining(False)
|
||||
End If
|
||||
Next
|
||||
EgtDraw()
|
||||
OnPropertyChanged( NameOf( MoveUp_IsEnabled))
|
||||
OnPropertyChanged( NameOf( MoveDown_IsEnabled))
|
||||
OnPropertyChanged(NameOf(MoveUp_IsEnabled))
|
||||
OnPropertyChanged(NameOf(MoveDown_IsEnabled))
|
||||
Map.refProjectVM.EmitTitle()
|
||||
End If
|
||||
End If
|
||||
@@ -608,6 +640,8 @@ Public Class OperationsListExpanderVM
|
||||
''' Execute the Point. This method is invoked by the PointCommand.
|
||||
''' </summary>
|
||||
Public Sub Update()
|
||||
Dim tmpStatusLamp As New StatusLamp()
|
||||
Map.refOperationsListExpanderVM.StatusLampList = tmpStatusLamp.LoadStatusLamp()
|
||||
' Cursore di attesa
|
||||
Application.Current.MainWindow.ForceCursor = True
|
||||
Application.Current.MainWindow.Cursor = Cursors.Wait
|
||||
@@ -617,6 +651,7 @@ Public Class OperationsListExpanderVM
|
||||
Dim bOk As Boolean = EgtApplyAllMachinings(bRecalc, False, sErr)
|
||||
EgtSetModified()
|
||||
' Deseleziono l'Operazione selezionata e la de-evidenzio nel Disegno
|
||||
m_ForceDrawInIsSelected = False
|
||||
For Each Operation In OperationList
|
||||
If Operation.IsSelected Then
|
||||
Operation.IsSelected = False
|
||||
@@ -624,6 +659,9 @@ Public Class OperationsListExpanderVM
|
||||
Next
|
||||
' Ricarico la lista delle Operazioni
|
||||
LoadOperationList(GDB_ID.NULL)
|
||||
' Rimetto le lampadine in modo corretto
|
||||
tmpStatusLamp.UpdateStatusLamp()
|
||||
m_ForceDrawInIsSelected = True
|
||||
' Aggiorno visualizzazione e ritorno a cursore standard
|
||||
EgtDraw()
|
||||
Application.Current.MainWindow.ForceCursor = False
|
||||
@@ -633,7 +671,8 @@ Public Class OperationsListExpanderVM
|
||||
If Not String.IsNullOrEmpty(sErr) Then
|
||||
MessageBox.Show(sErr, EgtMsg(MSG_SIMULATION + 5), MessageBoxButton.OK, MessageBoxImage.Exclamation)
|
||||
Else
|
||||
MessageBox.Show(EgtMsg(MSG_SIMULATION + 6), EgtMsg(MSG_SIMULATION + 5), MessageBoxButton.OK, MessageBoxImage.Error)
|
||||
' Errore nell'aggiornamento delle lavorazioni!
|
||||
MessageBox.Show(EgtMsg(5346), EgtMsg(MSG_SIMULATION + 5), MessageBoxButton.OK, MessageBoxImage.Error)
|
||||
End If
|
||||
Else
|
||||
Map.refStatusBarVM.NotifyStatusOutput(EgtMsg(MSG_OPERATION + 11))
|
||||
@@ -999,7 +1038,9 @@ Public Class OperationsListExpanderVM
|
||||
|
||||
Private Sub LoadOperationList()
|
||||
OperationList.Clear()
|
||||
tmpOperationList.Clear()
|
||||
Dim Id As Integer
|
||||
Dim OpStatusOnOff As Integer
|
||||
Dim OpStatus As Boolean = True
|
||||
Dim OpName As String = String.Empty
|
||||
Dim OpType As Integer = 0
|
||||
@@ -1012,9 +1053,14 @@ Public Class OperationsListExpanderVM
|
||||
If IsValidMachiningType(OpType) Then
|
||||
EgtSetCurrMachining(Id)
|
||||
OpStatus = EgtGetOperationMode(Id)
|
||||
EgtGetStatus(Id, OpStatusOnOff)
|
||||
EgtGetMachiningParam(MCH_MP.TOOL, OpTool)
|
||||
EgtGetMachiningParam(MCH_MP.NAME, OpMach)
|
||||
OperationList.Add(New MachiningOpListBoxItem(Id, OpStatus, OpName, OpType, OpTool, OpMach))
|
||||
' Dichiarato per far si che le due liste operino in contemporaneo
|
||||
Dim local_MachiningOpListBoxItem As New MachiningOpListBoxItem(Id, OpStatus, OpName, OpType, OpTool, OpMach)
|
||||
OperationList.Add(local_MachiningOpListBoxItem)
|
||||
' Lista creata per lavorare solo su le operazioni di macchina, utilizzata per la gestione dello spegnimento e accensione delle lamp
|
||||
tmpOperationList.Add(local_MachiningOpListBoxItem)
|
||||
ElseIf IsValidDispositionType(OpType) Then
|
||||
OpStatus = True
|
||||
OpTool = String.Empty
|
||||
@@ -1256,7 +1302,7 @@ Public Class OperationsListExpanderVM
|
||||
If m_NewMachining Then EndNewMachining(GDB_ID.NULL)
|
||||
' Disabilito visualizzazione utensile
|
||||
If Not IsNothing(m_MachiningParameterExpander) Then
|
||||
Map.refMachiningParameterExpanderVM.SetViewTool( False)
|
||||
Map.refMachiningParameterExpanderVM.SetViewTool(False)
|
||||
End If
|
||||
' Deseleziono le operazioni correnti per eliminare il mark
|
||||
For Each Operation In OperationList
|
||||
@@ -1266,6 +1312,83 @@ Public Class OperationsListExpanderVM
|
||||
Next
|
||||
End Sub
|
||||
|
||||
Private Sub SetStatusOnLamp()
|
||||
If Not IsNothing(m_tmpOperationList) Then
|
||||
For Each ItemOp As MachiningOpListBoxItem In m_tmpOperationList
|
||||
If Not ItemOp.OnOff Then
|
||||
EgtSetStatus(ItemOp.Id, GDB_ST.OFF)
|
||||
End If
|
||||
Next
|
||||
End If
|
||||
EgtDraw()
|
||||
End Sub
|
||||
|
||||
#End Region ' Methods
|
||||
|
||||
End Class
|
||||
|
||||
Public Class StatusLamp
|
||||
|
||||
#Region "FIELDS & PROPERTIES"
|
||||
|
||||
Private m_nId As Integer
|
||||
Public Property nId As Integer
|
||||
Get
|
||||
Return m_nId
|
||||
End Get
|
||||
Set(value As Integer)
|
||||
m_nId = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Private m_bStatusLamp As Boolean
|
||||
Public Property bStatusLamp As Boolean
|
||||
Get
|
||||
Return m_bStatusLamp
|
||||
End Get
|
||||
Set(value As Boolean)
|
||||
m_bStatusLamp = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
#End Region ' Fields & Properties
|
||||
|
||||
#Region "CONSTRUCTOR"
|
||||
|
||||
Sub New(nId As Integer, bStatusLamp As Boolean)
|
||||
m_nId = nId
|
||||
m_bStatusLamp = bStatusLamp
|
||||
End Sub
|
||||
|
||||
Sub New()
|
||||
|
||||
End Sub
|
||||
|
||||
#End Region ' Constructor
|
||||
|
||||
#Region "METHODS"
|
||||
|
||||
Public Function LoadStatusLamp() As ObservableCollection(Of StatusLamp)
|
||||
Dim tmpStatusLampList As New ObservableCollection(Of StatusLamp)
|
||||
For Each ItemOp As MachiningOpListBoxItem In Map.refOperationsListExpanderVM.tmpOperationList
|
||||
tmpStatusLampList.Add(New StatusLamp(ItemOp.Id, ItemOp.OnOff))
|
||||
Next
|
||||
Return tmpStatusLampList
|
||||
End Function
|
||||
|
||||
Public Sub UpdateStatusLamp()
|
||||
Dim tmpStatusLamp As StatusLamp
|
||||
If Not IsNothing(Map.refOperationsListExpanderVM.tmpOperationList) Then
|
||||
For Each ItemOp As MachiningOpListBoxItem In Map.refOperationsListExpanderVM.tmpOperationList
|
||||
tmpStatusLamp = Map.refOperationsListExpanderVM.StatusLampList.FirstOrDefault(Function(x) x.nId = ItemOp.Id)
|
||||
If Not tmpStatusLamp.bStatusLamp Then
|
||||
EgtSetStatus(ItemOp.Id, GDB_ST.OFF)
|
||||
ItemOp.OnOff = False
|
||||
End If
|
||||
Next
|
||||
End If
|
||||
End Sub
|
||||
|
||||
#End Region ' Methods
|
||||
|
||||
End Class
|
||||
@@ -51,7 +51,14 @@
|
||||
<TextBlock Text="{Binding VMillMsg}" Margin="5,0,0,0"/>
|
||||
</StackPanel>
|
||||
|
||||
<Grid>
|
||||
<StackPanel Orientation="Horizontal" Visibility="{Binding Trace_Visibility}"
|
||||
IsEnabled="{Binding Trace_IsEnabled}" Margin="10,5,10,0">
|
||||
<CheckBox HorizontalAlignment="Left" VerticalAlignment="Center"
|
||||
IsChecked="{Binding TraceActive}"/>
|
||||
<TextBlock Text="{Binding TraceMsg}" Margin="5,0,0,0"/>
|
||||
</StackPanel>
|
||||
|
||||
<Grid>
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.IO
|
||||
Imports System.IO
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
|
||||
@@ -18,6 +17,9 @@ Public Class SimulationExpanderVM
|
||||
Set(value As Boolean)
|
||||
If value <> m_Simulation_IsExpanded Then
|
||||
Map.refMachiningOptionPanelVM.Set_IsExpanded(MachiningOptionPanelVM.MachiningOptionPanelExpander.SIMULATION, value)
|
||||
Map.refOperationsListExpanderVM.StatusLampList.Clear()
|
||||
Dim tmpStatusLamp As New StatusLamp()
|
||||
Map.refOperationsListExpanderVM.StatusLampList = tmpStatusLamp.LoadStatusLamp()
|
||||
End If
|
||||
End Set
|
||||
End Property
|
||||
@@ -246,7 +248,8 @@ Public Class SimulationExpanderVM
|
||||
Dim SliderVal As Double = GetPrivateProfileDouble(S_SIMUL, K_SLIDERVAL, 10)
|
||||
SliderValue = SliderVal
|
||||
' Gestione check VMill
|
||||
If IsKeyEnabledVirtualMilling() And EgtUILib.GetPrivateProfileInt(S_VMILL, K_VM_ENABLE, 0, m_sCurrMachIniFilePath) <> 0 Then
|
||||
If IsKeyEnabledVirtualMilling() And
|
||||
EgtUILib.GetPrivateProfileInt(S_VMILL, K_VM_ENABLE, 0, m_sCurrMachIniFilePath) <> 0 Then
|
||||
VMill_Visibility = Visibility.Visible
|
||||
VMill_IsEnabled = True
|
||||
Dim bVal As Boolean
|
||||
@@ -259,6 +262,16 @@ Public Class SimulationExpanderVM
|
||||
VMillActive = False
|
||||
EgtEnableModified()
|
||||
End If
|
||||
' Gestione check Trace
|
||||
If IniFile.GetPrivateProfileInt(S_SIMUL, K_TRACEENABLE, 0) <> 0 And
|
||||
EgtUILib.GetPrivateProfileInt(S_TOOLTRACE, K_TT_ENABLE, 0, m_sCurrMachIniFilePath) <> 0 Then
|
||||
Trace_Visibility = Visibility.Visible
|
||||
Trace_IsEnabled = True
|
||||
If TraceActive Then TraceActive = True
|
||||
Else
|
||||
Trace_Visibility = Visibility.Collapsed
|
||||
Trace_IsEnabled = False
|
||||
End If
|
||||
' Aggiorno visualizzazione dati macchina
|
||||
ShowCncData()
|
||||
StatusMsg = EgtMsg(MSG_SIMULATION + 14) ' HOME
|
||||
@@ -348,8 +361,10 @@ Public Class SimulationExpanderVM
|
||||
End If
|
||||
' Aggiorno stato visualizzazione macchina (dipende anche da utensile)
|
||||
UpdateMachView()
|
||||
' Aggiorno visualizzazione
|
||||
EgtDraw()
|
||||
' Aggiorno visualizzazione (solo se interfaccia non minimizzata, per aumentare velocità)
|
||||
If Application.Current.MainWindow.WindowState <> WindowState.Minimized Then
|
||||
EgtDraw()
|
||||
End If
|
||||
' Aggiorno dati CNC
|
||||
If nShowDataCounter = 5 Or GetSimulationStatus() = MCH_SIM_ST.UI_PAUSE Or GetSimulationStatus() = MCH_SIM_ST.UI_STOP Then
|
||||
ShowCncData()
|
||||
@@ -361,7 +376,7 @@ Public Class SimulationExpanderVM
|
||||
End If
|
||||
Else
|
||||
' Per evitare di ciclare rapidissimamente e consumare inutilmente CPU
|
||||
System.Threading.Thread.Sleep(4)
|
||||
System.Threading.Thread.Sleep(5)
|
||||
End If
|
||||
' Costringo ad aggiornare UI
|
||||
UpdateUI()
|
||||
@@ -393,6 +408,7 @@ Public Class SimulationExpanderVM
|
||||
MachineAxisList(Index).IsReadOnlyAxesValue = True
|
||||
Next
|
||||
End If
|
||||
Trace_IsEnabled = (value = MCH_SIM_ST.UI_PAUSE OrElse value = MCH_SIM_ST.UI_STOP)
|
||||
EgtSimSetUiStatus(GetStatus())
|
||||
End Sub
|
||||
|
||||
@@ -435,14 +451,15 @@ Public Class SimulationExpanderVM
|
||||
sCncFile = Path.GetDirectoryName(sCurrFilePath) & "\" & sCncFile
|
||||
Else
|
||||
sCncFile = Path.ChangeExtension(sCurrFilePath, Nothing)
|
||||
Dim sExt As String = ".cnc"
|
||||
EgtUILib.GetPrivateProfileString(S_PARTPROGRAM, K_EXTENSION, sExt, sExt, IniFile.m_sCurrMachIniFilePath)
|
||||
If IniFile.m_bMachiningGroup Then
|
||||
Dim sMGrpName As String = String.Empty
|
||||
If EgtGetMachGroupName(EgtGetCurrMachGroup(), sMGrpName) Then
|
||||
sCncFile &= "_" & sMGrpName & ".cnc"
|
||||
sCncFile &= "_" & sMGrpName
|
||||
sInfo &= "-" & sMGrpName
|
||||
End If
|
||||
Else
|
||||
sCncFile &= ".cnc"
|
||||
sCncFile = Path.ChangeExtension(sCncFile, sExt)
|
||||
End If
|
||||
End If
|
||||
Return True
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
<UserControl x:Class="MachiningOptionPanelV"
|
||||
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" Width="250"
|
||||
xmlns:EgtFloating="clr-namespace:EgtWPFLib5.EgtFloating;assembly=EgtWPFLib5">
|
||||
|
||||
<StackPanel Name="ciao" Background="Transparent" MaxHeight="{Binding MaxHeight,RelativeSource={RelativeSource AncestorType={x:Type EgtFloating:EgtFloatingPanel}}}">
|
||||
<StackPanel Name="ciao" Background="Transparent" Margin="0,0,3.5001,0" MaxHeight="{Binding MaxHeight,RelativeSource={RelativeSource AncestorType={x:Type EgtFloating:EgtFloatingPanel}}}">
|
||||
<!--ContentPresenter that contains the OperationsListExpander-->
|
||||
<ContentPresenter Content="{Binding OperationsListExpander,Mode=OneWay}"/>
|
||||
<!--ContentPresenter that contains the OperationParametersExpander-->
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<EgtFloating:EgtFloatingPanel x:Class="OptionPanelV"
|
||||
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" Width="250"
|
||||
xmlns:EgtFloating="clr-namespace:EgtWPFLib5.EgtFloating;assembly=EgtWPFLib5"
|
||||
TitleBarOrientation="Vertical"
|
||||
Visibility="{Binding Panel_Visibility}">
|
||||
|
||||
@@ -23,7 +23,10 @@ Friend Module OptionModule
|
||||
' Parametri per import
|
||||
Friend m_dDxfScaleFactor As Double
|
||||
Friend m_dStlScaleFactor As Double
|
||||
Friend m_dOffScaleFactor As Double
|
||||
Friend m_dPlyScaleFactor As Double
|
||||
Friend m_dImgScaleFactor As Double
|
||||
Friend m_dAdvImpTolerance As Double
|
||||
|
||||
' Parametri per export
|
||||
Friend m_nExportDxfFlag As Integer
|
||||
@@ -56,6 +59,7 @@ Friend Module OptionModule
|
||||
Friend m_SelGeomSurfRoughing As SceneSelModeOpt
|
||||
Friend m_SelGeomWaterJetting As SceneSelModeOpt
|
||||
Friend m_SelGeomFiveAxMilling As SceneSelModeOpt
|
||||
Friend m_SelGeomProbing As SceneSelModeOpt
|
||||
Friend m_SelVMillQuality As VMillSelTypeOpt
|
||||
' Flag per aggiungere una nuova lavorazione alla fine della fase o subito dopo la lavorazione selezionata
|
||||
Friend m_bNewMachiningIsLastOne As Boolean
|
||||
@@ -117,7 +121,10 @@ Friend Module OptionModule
|
||||
' Inizializzo variabili per import
|
||||
m_dDxfScaleFactor = GetPrivateProfileDouble(S_IMPORT, K_DXFSCALE, 1)
|
||||
m_dStlScaleFactor = GetPrivateProfileDouble(S_IMPORT, K_STLSCALE, 1)
|
||||
m_dOffScaleFactor = GetPrivateProfileDouble(S_IMPORT, K_OFFSCALE, 1)
|
||||
m_dPlyScaleFactor = GetPrivateProfileDouble(S_IMPORT, K_PLYSCALE, 1)
|
||||
m_dImgScaleFactor = GetPrivateProfileDouble(S_IMPORT, K_IMGSCALE, 1)
|
||||
m_dAdvImpTolerance = GetPrivateProfileDouble(S_IMPORT, K_ADVTOLER, 0.05)
|
||||
' Inizializzo variabili per export
|
||||
m_nExportDxfFlag = GetPrivateProfileInt(S_EXPORT, K_DXFFLAG, EEX_FL.COMP_LAYER)
|
||||
m_nImgWidth = GetPrivateProfileInt(S_EXPORT, K_IMGWIDTH, 400)
|
||||
@@ -148,6 +155,8 @@ Friend Module OptionModule
|
||||
m_SelGeomSurfRoughing = If(Temp < 0 Or Temp > 3, SceneSelModeOpt.PARTCURVESANDSURFACES, DirectCast(Temp, SceneSelModeOpt))
|
||||
Temp = GetPrivateProfileInt(S_MACH, K_SELGEOMFIVEAXMILLING, -1)
|
||||
m_SelGeomFiveAxMilling = If(Temp < 0 Or Temp > 3, SceneSelModeOpt.PARTCURVESANDSURFACES, DirectCast(Temp, SceneSelModeOpt))
|
||||
Temp = GetPrivateProfileInt(S_MACH, K_SELGEOMPROBING, -1)
|
||||
m_SelGeomProbing = If(Temp < 0 Or Temp > 3, SceneSelModeOpt.PARTCURVESANDSURFACES, DirectCast(Temp, SceneSelModeOpt))
|
||||
Temp = GetPrivateProfileInt(S_MACH, K_SELVMILLQUALITY, 0)
|
||||
m_SelVMillQuality = If(Temp < -2 Or Temp > 2, VMillSelTypeOpt.HIGHER, DirectCast(Temp, VMillSelTypeOpt))
|
||||
m_SelGeomWaterJetting = SceneSelModeOpt.PARTCURVES
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
WindowStyle="None" ResizeMode="NoResize" TitleBarHeight="30" IsResizable="False"
|
||||
IsMinimizable="False" WindowStartupLocation="CenterScreen" ShowInTaskbar="False"
|
||||
MinWidth="400" MinHeight="382"
|
||||
Width="400" Height="575"
|
||||
Width="400" Height="600"
|
||||
CloseCommand="{Binding CloseOptionsCommand,Mode=OneWay,UpdateSourceTrigger=PropertyChanged}">
|
||||
|
||||
<EgtWPFLib5:EgtCustomWindow.Resources>
|
||||
@@ -136,6 +136,9 @@
|
||||
</TabItem>
|
||||
<TabItem Header="{Binding ImportMsg}">
|
||||
<StackPanel Margin="5,5,5,0">
|
||||
<GroupBox Grid.Column="1" Grid.RowSpan="2"
|
||||
Header=""
|
||||
Margin="0,0,0,5">
|
||||
<Grid Margin="0,5,0,0">
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
@@ -147,10 +150,12 @@
|
||||
<RowDefinition Height="1*"/>
|
||||
<RowDefinition Height="1*"/>
|
||||
<RowDefinition Height="1*"/>
|
||||
<RowDefinition Height="1*"/>
|
||||
<RowDefinition Height="1*"/>
|
||||
</Grid.RowDefinitions>
|
||||
<TextBlock Grid.Row="0" Grid.Column="1"
|
||||
VerticalAlignment="Center" HorizontalAlignment="Center"
|
||||
Text="{Binding UnitScaleMsg}" />
|
||||
Text="{Binding UnitScaleMsg}"/>
|
||||
<TextBlock Grid.Row="0" Grid.Column="2"
|
||||
VerticalAlignment="Center" HorizontalAlignment="Center"
|
||||
Text="{Binding FactorScaleMsg}"/>
|
||||
@@ -159,12 +164,12 @@
|
||||
<ComboBox Grid.Row="1" Grid.Column="1"
|
||||
ItemsSource="{Binding ScaleDXFList, Mode=OneWay}"
|
||||
SelectedItem="{Binding SelectedDXFScale, UpdateSourceTrigger=PropertyChanged}" Height="25"
|
||||
Margin="10,0,0,5"/>
|
||||
Margin="10,5,0,5"/>
|
||||
<TextBox Grid.Row="1" Grid.Column="2"
|
||||
Text="{Binding DxfScaleFactor}" Height="25"
|
||||
IsEnabled="{Binding DXFScaleEnable, UpdateSourceTrigger=LostFocus}"
|
||||
VerticalContentAlignment="Center"
|
||||
Margin="10,0,0,5"/>
|
||||
Margin="10,5,0,5"/>
|
||||
<TextBlock Grid.Row="2" Grid.Column="0"
|
||||
Text="{Binding StlScaleFactorMsg}" VerticalAlignment="Center"/>
|
||||
<ComboBox Grid.Row="2" Grid.Column="1"
|
||||
@@ -177,17 +182,47 @@
|
||||
VerticalContentAlignment="Center"
|
||||
Margin="10,0,0,5"/>
|
||||
<TextBlock Grid.Row="3" Grid.Column="0"
|
||||
Text="{Binding ImageScaleFactorMsg}" VerticalAlignment="Center"/>
|
||||
Text="{Binding OffScaleFactorMsg}" VerticalAlignment="Center"/>
|
||||
<ComboBox Grid.Row="3" Grid.Column="1"
|
||||
ItemsSource="{Binding ScaleOffList, Mode=OneWay}"
|
||||
SelectedItem="{Binding SelectedOffScale, UpdateSourceTrigger=PropertyChanged}" Height="25"
|
||||
Margin="10,0,0,5"/>
|
||||
<TextBox Grid.Row="3" Grid.Column="2"
|
||||
Text="{Binding OffScaleFactor}" Height="25"
|
||||
IsEnabled="{Binding OffScaleEnable, UpdateSourceTrigger=LostFocus}"
|
||||
VerticalContentAlignment="Center"
|
||||
Margin="10,0,0,5"/>
|
||||
<TextBlock Grid.Row="4" Grid.Column="0"
|
||||
Text="{Binding PlyScaleFactorMsg}" VerticalAlignment="Center"/>
|
||||
<ComboBox Grid.Row="4" Grid.Column="1"
|
||||
ItemsSource="{Binding ScalePlyList, Mode=OneWay}"
|
||||
SelectedItem="{Binding SelectedPlyScale, UpdateSourceTrigger=PropertyChanged}" Height="25"
|
||||
Margin="10,0,0,5"/>
|
||||
<TextBox Grid.Row="4" Grid.Column="2"
|
||||
Text="{Binding PlyScaleFactor}" Height="25"
|
||||
IsEnabled="{Binding PlyScaleEnable, UpdateSourceTrigger=LostFocus}"
|
||||
VerticalContentAlignment="Center"
|
||||
Margin="10,0,0,5"/>
|
||||
<TextBlock Grid.Row="5" Grid.Column="0"
|
||||
Text="{Binding ImageScaleFactorMsg}" VerticalAlignment="Center"/>
|
||||
<ComboBox Grid.Row="5" Grid.Column="1"
|
||||
ItemsSource="{Binding ScaleImageList, Mode=OneWay}"
|
||||
SelectedItem="{Binding SelectedImageScale, UpdateSourceTrigger=PropertyChanged}" Height="25"
|
||||
Margin="10,0,0,5"/>
|
||||
<TextBox Grid.Row="3" Grid.Column="2"
|
||||
<TextBox Grid.Row="5" Grid.Column="2"
|
||||
Text="{Binding ImageScaleFactor}" Height="25"
|
||||
IsEnabled="{Binding ImageScaleEnable, UpdateSourceTrigger=LostFocus}"
|
||||
VerticalContentAlignment="Center"
|
||||
Margin="10,0,0,5"/>
|
||||
</Grid>
|
||||
</GroupBox>
|
||||
<UniformGrid Grid.ColumnSpan="2" Columns="2"
|
||||
Margin="0,5,0,5">
|
||||
<TextBlock Text="{Binding AdvImpToleranceMsg}" VerticalAlignment="Center"/>
|
||||
<TextBox Text="{Binding AdvImpTolerance}" Height="25"
|
||||
VerticalContentAlignment="Center"
|
||||
Margin="10,0,0,0"/>
|
||||
</UniformGrid>
|
||||
</StackPanel>
|
||||
</TabItem>
|
||||
<TabItem Header="{Binding ExportMsg}">
|
||||
@@ -214,6 +249,15 @@
|
||||
Header="{Binding MachiningSelGeomMsg}"
|
||||
Margin="5,5,5,0">
|
||||
<UniformGrid Columns="2">
|
||||
<TextBlock Text="{Binding GeomTypeProbingMsg}" VerticalAlignment="Center"/>
|
||||
<ComboBox ItemsSource="{Binding GeomTypeList, Mode=OneWay}"
|
||||
SelectedItem="{Binding SelectedProbingGeomType}" Height="25">
|
||||
<ComboBox.ItemTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Converter={StaticResource GeomTypeConverter}}"/>
|
||||
</DataTemplate>
|
||||
</ComboBox.ItemTemplate>
|
||||
</ComboBox>
|
||||
<TextBlock Text="{Binding GeomTypeDrillingMsg}" VerticalAlignment="Center"/>
|
||||
<ComboBox ItemsSource="{Binding GeomTypeList, Mode=OneWay}"
|
||||
SelectedItem="{Binding SelectedDrillingGeomType}" Height="25">
|
||||
@@ -359,9 +403,9 @@
|
||||
<StackPanel>
|
||||
<Grid Margin="5,20,5,0">
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="3*"/>
|
||||
<ColumnDefinition Width="2*"/>
|
||||
<ColumnDefinition Width="3*"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="1*"/>
|
||||
@@ -392,6 +436,9 @@
|
||||
Grid.Row="3" Grid.Column="0" Margin="0,5,0,5"/>
|
||||
<CheckBox IsChecked="{Binding DoorsOn}" IsEnabled="{Binding DoorsEnabled}"
|
||||
Grid.Row="3" Grid.Column="1" Margin="4,5,0,5" VerticalAlignment="Center"/>
|
||||
<Button Content="{Binding UpdateMsg}" IsEnabled="{Binding DoorsActive}"
|
||||
Command="{Binding UpdateDoors_Command}"
|
||||
Grid.Row="3" Grid.Column="2" Height="26"/>
|
||||
<TextBlock Text="{Binding GunstockMsg}" VerticalAlignment="Center"
|
||||
Grid.Row="4" Grid.Column="0" Margin="0,5,0,5"/>
|
||||
<CheckBox IsChecked="{Binding GunstockOn}" IsEnabled="{Binding GunstockEnabled}"
|
||||
|
||||
@@ -65,6 +65,20 @@ Public Class OptionWindowVM
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Private m_ScaleOffList As List(Of String) = New List(Of String)({"mm", "inch", EgtMsg(MSG_OPTIONPAGE + 46)})
|
||||
Public ReadOnly Property ScaleOffList As List(Of String)
|
||||
Get
|
||||
Return m_ScaleOffList
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Private m_ScalePlyList As List(Of String) = New List(Of String)({"mm", "inch", EgtMsg(MSG_OPTIONPAGE + 46)})
|
||||
Public ReadOnly Property ScalePlyList As List(Of String)
|
||||
Get
|
||||
Return m_ScalePlyList
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Private m_ScaleImageList As List(Of String) = New List(Of String)({"mm", "inch", EgtMsg(MSG_OPTIONPAGE + 46)})
|
||||
Public ReadOnly Property ScaleImageList As List(Of String)
|
||||
Get
|
||||
@@ -200,6 +214,17 @@ Public Class OptionWindowVM
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Public Property SelectedProbingGeomType As SceneSelModeOpt
|
||||
Get
|
||||
Return OptionModule.m_SelGeomProbing
|
||||
End Get
|
||||
Set(value As SceneSelModeOpt)
|
||||
If WritePrivateProfileString(S_MACH, K_SELGEOMPROBING, CInt(value).ToString()) Then
|
||||
OptionModule.m_SelGeomProbing = value
|
||||
End If
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Public Property SelectedVMillTypeType As VMillSelTypeOpt
|
||||
Get
|
||||
Return OptionModule.m_SelVMillQuality
|
||||
@@ -346,6 +371,36 @@ Public Class OptionWindowVM
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Public Property OffScaleFactor As String
|
||||
Get
|
||||
Return LenToString(OptionModule.m_dOffScaleFactor, 5)
|
||||
End Get
|
||||
Set(value As String)
|
||||
Dim dVal As Double = 0
|
||||
If StringToLen(value, dVal) AndAlso dVal > 0 Then
|
||||
OptionModule.m_dOffScaleFactor = dVal
|
||||
WritePrivateProfileString(S_IMPORT, K_OFFSCALE, DoubleToString(OptionModule.m_dOffScaleFactor, 5))
|
||||
Map.refProjectVM.GetController().SetScaleForOffImport(OptionModule.m_dOffScaleFactor)
|
||||
NotifyPropertyChanged("OffScaleFactor")
|
||||
End If
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Public Property PlyScaleFactor As String
|
||||
Get
|
||||
Return LenToString(OptionModule.m_dPlyScaleFactor, 5)
|
||||
End Get
|
||||
Set(value As String)
|
||||
Dim dVal As Double = 0
|
||||
If StringToLen(value, dVal) AndAlso dVal > 0 Then
|
||||
OptionModule.m_dPlyScaleFactor = dVal
|
||||
WritePrivateProfileString(S_IMPORT, K_PLYSCALE, DoubleToString(OptionModule.m_dPlyScaleFactor, 5))
|
||||
Map.refProjectVM.GetController().SetScaleForPLyImport(OptionModule.m_dPlyScaleFactor)
|
||||
NotifyPropertyChanged("PlyScaleFactor")
|
||||
End If
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Public Property ImageScaleFactor As String
|
||||
Get
|
||||
Return LenToString(OptionModule.m_dImgScaleFactor, 5)
|
||||
@@ -361,6 +416,20 @@ Public Class OptionWindowVM
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Public Property AdvImpTolerance As String
|
||||
Get
|
||||
Return LenToString(OptionModule.m_dAdvImpTolerance, 5)
|
||||
End Get
|
||||
Set(value As String)
|
||||
Dim dVal As Double = 0
|
||||
If StringToLen(value, dVal) AndAlso dVal > 0 Then
|
||||
OptionModule.m_dAdvImpTolerance = dVal
|
||||
Map.refProjectVM.GetController.SetAdvImpTolerance(OptionModule.m_dAdvImpTolerance)
|
||||
WritePrivateProfileString(S_IMPORT, K_ADVTOLER, DoubleToString(OptionModule.m_dAdvImpTolerance, 5))
|
||||
End If
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Public Property ImageWidth As String
|
||||
Get
|
||||
Return OptionModule.m_nImgWidth.ToString()
|
||||
@@ -515,6 +584,28 @@ Public Class OptionWindowVM
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Private m_OffScaleEnable As Boolean = False
|
||||
Public Property OffScaleEnable As Boolean
|
||||
Get
|
||||
Return m_OffScaleEnable
|
||||
End Get
|
||||
Set(value As Boolean)
|
||||
m_OffScaleEnable = value
|
||||
NotifyPropertyChanged("OffScaleEnable")
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Private m_PlyScaleEnable As Boolean = False
|
||||
Public Property PlyScaleEnable As Boolean
|
||||
Get
|
||||
Return m_PlyScaleEnable
|
||||
End Get
|
||||
Set(value As Boolean)
|
||||
m_PlyScaleEnable = value
|
||||
NotifyPropertyChanged("PlyScaleEnable")
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Private m_ImageScaleEnable As Boolean = False
|
||||
Public Property ImageScaleEnable As Boolean
|
||||
Get
|
||||
@@ -576,6 +667,56 @@ Public Class OptionWindowVM
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Public Property SelectedOffScale As String
|
||||
Get
|
||||
If Math.Abs(OptionModule.m_dOffScaleFactor - ONEMM) < EPS_SMALL * 10 Then
|
||||
Return ScaleOffList(ScaleOffList.IndexOf("mm"))
|
||||
ElseIf Math.Abs(OptionModule.m_dOffScaleFactor - ONEINCH) < EPS_SMALL * 10 Then
|
||||
Return ScaleOffList(ScaleOffList.IndexOf("inch"))
|
||||
Else
|
||||
OffScaleEnable = True
|
||||
Return ScaleOffList(ScaleOffList.IndexOf(EgtMsg(MSG_OPTIONPAGE + 46)))
|
||||
End If
|
||||
End Get
|
||||
Set(value As String)
|
||||
If value = "mm" Then
|
||||
OffScaleFactor = LenToString(ONEMM, 3)
|
||||
OffScaleEnable = False
|
||||
ElseIf value = "inch" Then
|
||||
OffScaleFactor = LenToString(ONEINCH, 4)
|
||||
OffScaleEnable = False
|
||||
Else
|
||||
OffScaleFactor = LenToString(OptionModule.m_dOffScaleFactor, 4)
|
||||
OffScaleEnable = True
|
||||
End If
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Public Property SelectedPlyScale As String
|
||||
Get
|
||||
If Math.Abs(OptionModule.m_dPlyScaleFactor - ONEMM) < EPS_SMALL * 10 Then
|
||||
Return ScalePlyList(ScalePlyList.IndexOf("mm"))
|
||||
ElseIf Math.Abs(OptionModule.m_dPlyScaleFactor - ONEINCH) < EPS_SMALL * 10 Then
|
||||
Return ScalePlyList(ScalePlyList.IndexOf("inch"))
|
||||
Else
|
||||
PlyScaleEnable = True
|
||||
Return ScalePlyList(ScalePlyList.IndexOf(EgtMsg(MSG_OPTIONPAGE + 46)))
|
||||
End If
|
||||
End Get
|
||||
Set(value As String)
|
||||
If value = "mm" Then
|
||||
PlyScaleFactor = LenToString(ONEMM, 3)
|
||||
PlyScaleEnable = False
|
||||
ElseIf value = "inch" Then
|
||||
PlyScaleFactor = LenToString(ONEINCH, 4)
|
||||
PLyScaleEnable = False
|
||||
Else
|
||||
PLyScaleFactor = LenToString(OptionModule.m_dPlyScaleFactor, 4)
|
||||
PLyScaleEnable = True
|
||||
End If
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Public Property SelectedImageScale As String
|
||||
Get
|
||||
If Math.Abs(OptionModule.m_dImgScaleFactor - ONEMM) < EPS_SMALL * 10 Then
|
||||
@@ -657,6 +798,11 @@ Public Class OptionWindowVM
|
||||
Return (IniFile.m_nKeyOptions And KEY_OPT.DOORS) <> 0
|
||||
End Get
|
||||
End Property
|
||||
Public ReadOnly Property DoorsActive As Boolean
|
||||
Get
|
||||
Return IniFile.IsActiveDoors()
|
||||
End Get
|
||||
End Property
|
||||
Public Property DoorsOn As Boolean
|
||||
Get
|
||||
Return DoorsEnabled AndAlso OptionModule.m_bDoorsOn
|
||||
@@ -694,6 +840,7 @@ Public Class OptionWindowVM
|
||||
Private m_cmdExportMachineCmd As ICommand
|
||||
Private m_cmdUpdateBeamCmd As ICommand
|
||||
Private m_cmdUpdateWallCmd As ICommand
|
||||
Private m_cmdUpdateDoorsCmd As ICommand
|
||||
|
||||
#Region "Messages"
|
||||
|
||||
@@ -808,28 +955,42 @@ Public Class OptionWindowVM
|
||||
|
||||
Public ReadOnly Property ImportMsg As String
|
||||
Get
|
||||
Return EgtMsg(MSG_OPTIONPAGE + 19)
|
||||
Return EgtMsg(6519) ' Import
|
||||
End Get
|
||||
End Property
|
||||
Public ReadOnly Property DxfScaleFactorMsg As String
|
||||
Get
|
||||
Return EgtMsg(MSG_OPTIONPAGE + 20)
|
||||
Return EgtMsg(6520) ' DXF
|
||||
End Get
|
||||
End Property
|
||||
Public ReadOnly Property StlScaleFactorMsg As String
|
||||
Get
|
||||
Return EgtMsg(MSG_OPTIONPAGE + 21)
|
||||
Return EgtMsg(6521) ' STL
|
||||
End Get
|
||||
End Property
|
||||
Public ReadOnly Property OffScaleFactorMsg As String
|
||||
Get
|
||||
Return EgtMsg(6561) ' OFF
|
||||
End Get
|
||||
End Property
|
||||
Public ReadOnly Property PlyScaleFactorMsg As String
|
||||
Get
|
||||
Return EgtMsg(6563) ' PLY
|
||||
End Get
|
||||
End Property
|
||||
Public ReadOnly Property ImageScaleFactorMsg As String
|
||||
Get
|
||||
Return EgtMsg(MSG_OPTIONPAGE + 22)
|
||||
Return EgtMsg(6522) ' Immagini
|
||||
End Get
|
||||
End Property
|
||||
Public ReadOnly Property AdvImpToleranceMsg As String
|
||||
Get
|
||||
Return EgtMsg(6562) ' Tolleranza di importazione
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Public ReadOnly Property ExportMsg As String
|
||||
Get
|
||||
Return EgtMsg(MSG_OPTIONPAGE + 23)
|
||||
Return EgtMsg(6523) ' Export
|
||||
End Get
|
||||
End Property
|
||||
Public ReadOnly Property UnitScaleMsg As String
|
||||
@@ -941,7 +1102,7 @@ Public Class OptionWindowVM
|
||||
End Property
|
||||
Public ReadOnly Property DoorsMsg As String
|
||||
Get
|
||||
Return "Doors"
|
||||
Return "Doors (" & Path.GetFileName( IniFile.m_sDoorsDirPath) & ")"
|
||||
End Get
|
||||
End Property
|
||||
Public ReadOnly Property GunstockMsg As String
|
||||
@@ -984,6 +1145,12 @@ Public Class OptionWindowVM
|
||||
Return EgtMsg(31212)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Public ReadOnly Property GeomTypeProbingMsg As String
|
||||
Get
|
||||
Return EgtMsg(31220)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Public ReadOnly Property VMillQualityMsg As String
|
||||
Get
|
||||
@@ -1205,10 +1372,18 @@ Public Class OptionWindowVM
|
||||
Dim sMachDir As String = Path.Combine(IniFile.m_sMachinesRoot, sMachName)
|
||||
' Preparo direttorio temporaneo
|
||||
Dim sTempDir As String = Path.Combine(IniFile.m_sMachinesRoot, "Temp")
|
||||
If My.Computer.FileSystem.DirectoryExists(sTempDir) Then
|
||||
My.Computer.FileSystem.DeleteDirectory(sTempDir, FileIO.DeleteDirectoryOption.DeleteAllContents)
|
||||
End If
|
||||
My.Computer.FileSystem.CreateDirectory(sTempDir)
|
||||
Try
|
||||
If My.Computer.FileSystem.DirectoryExists(sTempDir) Then
|
||||
My.Computer.FileSystem.DeleteDirectory(sTempDir, FileIO.DeleteDirectoryOption.DeleteAllContents)
|
||||
End If
|
||||
My.Computer.FileSystem.CreateDirectory(sTempDir)
|
||||
Catch
|
||||
' Problemi di accesso al direttorio delle macchine
|
||||
Dim sErr As String = EgtMsg(6564)
|
||||
EgtOutLog(sErr & " (" & sTempDir & ")")
|
||||
MessageBox.Show(sErr, EgtMsg(MSG_MESSAGEBOX + 3), MessageBoxButton.OK)
|
||||
Return
|
||||
End Try
|
||||
' Unzip nel direttorio temporaneo
|
||||
Using zip As New Ionic.Zip.ZipFile(sMachZip)
|
||||
zip.ExtractAll(sTempDir, Ionic.Zip.ExtractExistingFileAction.DoNotOverwrite)
|
||||
@@ -1256,7 +1431,7 @@ Public Class OptionWindowVM
|
||||
' L'aggiornamento della macchina "{0}" non è riuscito.
|
||||
Dim sKo As String = String.Format(EgtMsg(MSG_OPTIONPAGE + 35), sMachName)
|
||||
EgtOutLog(sKo)
|
||||
MessageBox.Show(sKo, EgtMsg(MSG_MESSAGEBOX + 1), MessageBoxButton.OK)
|
||||
MessageBox.Show(sKo, EgtMsg(MSG_MESSAGEBOX + 1), MessageBoxButton.OK, MessageBoxImage.Error)
|
||||
Return
|
||||
End Try
|
||||
End If
|
||||
@@ -1609,6 +1784,116 @@ Public Class OptionWindowVM
|
||||
|
||||
#End Region ' UpdateWall
|
||||
|
||||
|
||||
#Region "UpdateDoors"
|
||||
Public ReadOnly Property UpdateDoors_Command() As ICommand
|
||||
Get
|
||||
If m_cmdUpdateDoorsCmd Is Nothing Then
|
||||
m_cmdUpdateDoorsCmd = New RelayCommand(AddressOf UpdateDoorsCmd)
|
||||
End If
|
||||
Return m_cmdUpdateDoorsCmd
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Public Sub UpdateDoorsCmd()
|
||||
' Recupero la versione del programma in esecuzione
|
||||
Dim sExeVer As String = IniFile.GetProgramVersion()
|
||||
' Verifico presenza di una precedente installazione del Doors (file Version.lua oppure Main.lua)
|
||||
Dim sDoorsVer As String = ""
|
||||
IniFile.GetSpecialLuaVersion(IniFile.m_sDoorsDirPath, sDoorsVer)
|
||||
If String.IsNullOrEmpty(sDoorsVer) Then
|
||||
If My.Computer.FileSystem.FileExists(Path.Combine(IniFile.m_sDoorsDirPath, "Main.lua")) AndAlso
|
||||
My.Computer.FileSystem.FileExists(Path.Combine(IniFile.m_sDoorsDirPath, "Machining.lua")) Then
|
||||
sDoorsVer = "2.6l9"
|
||||
Else
|
||||
' Il modulo "{0}" non è stato trovato, impossibile aggiornare. - Avviso
|
||||
Dim sOut As String = String.Format(EgtMsg(6555), "Doors")
|
||||
MessageBox.Show(Application.Current.MainWindow, sOut, EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning)
|
||||
' Esco
|
||||
Return
|
||||
End If
|
||||
End If
|
||||
' Apro dialogo per richiesta file zip del Doors
|
||||
Dim DoorsDlg As New Microsoft.Win32.OpenFileDialog() With {
|
||||
.DefaultExt = ".zip",
|
||||
.Filter = "Doors (.zip)|*.zip",
|
||||
.CheckFileExists = True,
|
||||
.ValidateNames = True
|
||||
}
|
||||
If DoorsDlg.ShowDialog() <> True Then Return
|
||||
Dim sDoorsZip As String = DoorsDlg.FileName
|
||||
' Preparo direttorio temporaneo
|
||||
Dim sTempDir As String = Path.Combine(IniFile.m_sTempDir, "Doors")
|
||||
If My.Computer.FileSystem.DirectoryExists(sTempDir) Then
|
||||
My.Computer.FileSystem.DeleteDirectory(sTempDir, FileIO.DeleteDirectoryOption.DeleteAllContents)
|
||||
End If
|
||||
My.Computer.FileSystem.CreateDirectory(sTempDir)
|
||||
' Unzip nel direttorio temporaneo
|
||||
Using zip As New Ionic.Zip.ZipFile(sDoorsZip)
|
||||
zip.ExtractAll(sTempDir, Ionic.Zip.ExtractExistingFileAction.DoNotOverwrite)
|
||||
End Using
|
||||
' Recupero i dati del nuovo Doors
|
||||
Dim sNewName = ""
|
||||
Dim sNewVer = ""
|
||||
Dim sNewMinExe = ""
|
||||
IniFile.GetSpecialLuaData(sTempDir, sNewName, sNewVer, sNewMinExe)
|
||||
' Verifico che sia veramente il Doors
|
||||
If String.Compare(sNewName, "Doors") <> 0 Then
|
||||
' Il file zip non contiene il modulo "{0}". - Avviso
|
||||
Dim sOut As String = String.Format(EgtMsg(6556), "Doors")
|
||||
MessageBox.Show(Application.Current.MainWindow, sOut, EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning)
|
||||
' Rimuovo il direttorio temporaneo ed esco
|
||||
My.Computer.FileSystem.DeleteDirectory(sTempDir, FileIO.DeleteDirectoryOption.DeleteAllContents)
|
||||
Return
|
||||
End If
|
||||
' Verifico la versione minima del programma
|
||||
If String.Compare(sExeVer, sNewMinExe) < 0 Then
|
||||
' Il nuovo modulo "{0}" richiede un programma con versione minima {1}. - Avviso
|
||||
Dim sOut As String = String.Format(EgtMsg(6557), "Doors", sNewMinExe)
|
||||
MessageBox.Show(Application.Current.MainWindow, sOut, EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning)
|
||||
' Rimuovo il direttorio temporaneo ed esco
|
||||
My.Computer.FileSystem.DeleteDirectory(sTempDir, FileIO.DeleteDirectoryOption.DeleteAllContents)
|
||||
Return
|
||||
End If
|
||||
' Verifico la versione del Doors e se più vecchia chiedo cosa fare
|
||||
If String.Compare(sNewVer, sDoorsVer) < 0 Then
|
||||
' La versione del nuovo modulo "{0}" è più vecchia dell'attuale. Vuoi sovrascrivere lo stesso ?
|
||||
Dim sOut As String = String.Format(EgtMsg(6558), "Doors")
|
||||
If MessageBox.Show(Application.Current.MainWindow, sOut, EgtMsg(15003), MessageBoxButton.YesNo, MessageBoxImage.Question) = MessageBoxResult.No Then
|
||||
' Rimuovo il direttorio temporaneo ed esco
|
||||
My.Computer.FileSystem.DeleteDirectory(sTempDir, FileIO.DeleteDirectoryOption.DeleteAllContents)
|
||||
Return
|
||||
End If
|
||||
End If
|
||||
' Faccio una copia di backup del Doors corrente
|
||||
Dim sBackupDir As String = IniFile.m_sDoorsDirPath & ".old"
|
||||
If My.Computer.FileSystem.DirectoryExists(sBackupDir) Then
|
||||
My.Computer.FileSystem.DeleteDirectory(sBackupDir, FileIO.DeleteDirectoryOption.DeleteAllContents)
|
||||
End If
|
||||
Try
|
||||
My.Computer.FileSystem.CopyDirectory(IniFile.m_sDoorsDirPath, sBackupDir, True)
|
||||
Catch ex As Exception
|
||||
' L'aggiornamento del modulo "{0}" non è riuscito. - Errore
|
||||
Dim sOut As String = String.Format(EgtMsg(6559), "Doors")
|
||||
EgtOutLog(sOut)
|
||||
MessageBox.Show(Application.Current.MainWindow, sOut, EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error)
|
||||
' Rimuovo il direttorio temporaneo ed esco
|
||||
My.Computer.FileSystem.DeleteDirectory(sTempDir, FileIO.DeleteDirectoryOption.DeleteAllContents)
|
||||
Return
|
||||
End Try
|
||||
' Installo il Doors
|
||||
My.Computer.FileSystem.CopyDirectory(sTempDir, IniFile.m_sDoorsDirPath, True)
|
||||
' Rimuovo il direttorio temporaneo di installazione
|
||||
My.Computer.FileSystem.DeleteDirectory(sTempDir, FileIO.DeleteDirectoryOption.DeleteAllContents)
|
||||
' Il modulo "{0}" è stata aggiornato con successo. - Info
|
||||
Dim sOk As String = String.Format(EgtMsg(6560), "Doors")
|
||||
EgtOutLog(sOk)
|
||||
MessageBox.Show(Application.Current.MainWindow, sOk, EgtMsg(15003), MessageBoxButton.OK)
|
||||
End Sub
|
||||
|
||||
#End Region ' UpdateDoors
|
||||
|
||||
|
||||
#Region "CloseOptionsCommand"
|
||||
|
||||
''' <summary>
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
<Setter Property="DockPanel.Dock" Value="{Binding}" />
|
||||
</Style>
|
||||
</ItemsControl.ItemContainerStyle>
|
||||
|
||||
|
||||
<interactivity:Interaction.Triggers>
|
||||
<interactivity:EventTrigger EventName="Loaded">
|
||||
<interactivity:InvokeCommandAction Command="{Binding LoadedCommand}"/>
|
||||
|
||||
@@ -4,7 +4,6 @@ Imports System.IO
|
||||
Imports System.Globalization
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
Imports EgtWPFLib5.EgtFloating
|
||||
|
||||
Public Class ProjectVM
|
||||
Inherits TabViewModel
|
||||
@@ -58,22 +57,9 @@ Public Class ProjectVM
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Private m_DynamicGrid As New Grid()
|
||||
Public ReadOnly Property DynamicGrid As Grid
|
||||
Get
|
||||
Return m_DynamicGrid
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Private m_DynamicGridList As New List(Of Object)
|
||||
Public ReadOnly Property DynamicGridList As List(Of Object)
|
||||
Get
|
||||
Return m_DynamicGridList
|
||||
End Get
|
||||
End Property
|
||||
|
||||
#End Region
|
||||
|
||||
#Region "EGTUILIB FIELDS"
|
||||
|
||||
Private m_bCPlaneTypePos As Boolean
|
||||
@@ -93,17 +79,6 @@ Public Class ProjectVM
|
||||
TMDbParamVisibility.bFirst = True
|
||||
' Inizializza i parametri della scena
|
||||
'InitializeEgtProject()
|
||||
|
||||
Dim m_TopTrayV As New TopTrayV
|
||||
Dim m_LeftTrayV As New LeftTrayV
|
||||
Dim m_RightTrayV As New RightTrayV
|
||||
Dim m_BottomTrayV As New BottomTrayV
|
||||
Dim m_SceneContentControlV As New SceneContentControlV
|
||||
|
||||
CreateDynamicGrid()
|
||||
|
||||
Dim gridSplitter As GridSplitter = CreateGridSplitter()
|
||||
|
||||
' aggiungo componenti interfaccia
|
||||
Dim bPlugin As Boolean = False
|
||||
Dim PluginDirNameList() As String = {}
|
||||
@@ -130,57 +105,30 @@ Public Class ProjectVM
|
||||
Dim ConfigurationData As IPluginConfigData = Map.refMainWindowVM.GetConfigData(Of IPluginConfigData)(PluginName & ".ConfigurationData")
|
||||
If Not IsNothing(ConfigurationData) And ConfigurationData.ControlList.Count > 0 Then
|
||||
For Each Element In ConfigurationData.ControlList
|
||||
PopolateGridWithPlugIn(m_TopTrayV, m_RightTrayV, m_BottomTrayV, m_SceneContentControlV, gridSplitter)
|
||||
Select Case Element.Name
|
||||
Case PLUGIN_RIGHT_TRAY
|
||||
'm_PanelList.Add(New RightTrayV)
|
||||
'aggiungo RightTrayV alla griglia
|
||||
m_DynamicGrid.Children.Add(m_RightTrayV)
|
||||
m_PanelList.Add(New RightTrayV)
|
||||
Map.refOptionPanelVM.SetPanelViewState(Element.ViewPanelState)
|
||||
Case PLUGIN_LEFT_TRAY
|
||||
'm_PanelList.Add(New LeftTrayV)
|
||||
' aggiungo LeftTrayV alla griglia
|
||||
m_DynamicGrid.Children.Add(m_LeftTrayV)
|
||||
m_PanelList.Add(New LeftTrayV)
|
||||
Case Else
|
||||
m_PanelList.Add(Map.refMainWindowVM.GetControlByName(Of IPluginControl)(Element))
|
||||
' aggiungo LeftTrayV alla griglia
|
||||
'm_DynamicGrid.Children.Add(Map.refMainWindowVM.GetControlByName(Of IPluginControl)(Element))
|
||||
End Select
|
||||
Next
|
||||
End If
|
||||
End If
|
||||
Next
|
||||
' aggiungo gridSplitter alla griglia
|
||||
m_DynamicGrid.Children.Add(gridSplitter)
|
||||
'm_PanelList.Add(New BottomTrayV)
|
||||
' aggiungo BottomTrayV alla griglia
|
||||
m_DynamicGrid.Children.Add(m_BottomTrayV)
|
||||
'm_PanelList.Add(New TopTrayV)
|
||||
' aggiungo TopTrayV alla griglia
|
||||
m_DynamicGrid.Children.Add(m_TopTrayV)
|
||||
m_PanelList.Add(New BottomTrayV)
|
||||
m_PanelList.Add(New TopTrayV)
|
||||
' nascondo tasti gestione progetto se attivo plugin
|
||||
Map.refTopCommandBarVM.SetProjectManagerVisibility(False)
|
||||
Else
|
||||
PololateGrid(m_TopTrayV, m_LeftTrayV, m_RightTrayV, m_BottomTrayV, m_SceneContentControlV, gridSplitter)
|
||||
'm_PanelList.Add(New TopTrayV)
|
||||
'm_PanelList.Add(New LeftTrayV)
|
||||
'm_PanelList.Add(New RightTrayV)
|
||||
'm_PanelList.Add(New BottomTrayV)
|
||||
' aggiungo TopTrayV alla griglia
|
||||
m_DynamicGrid.Children.Add(m_TopTrayV)
|
||||
' aggiungo LeftTrayV alla griglia
|
||||
m_DynamicGrid.Children.Add(m_LeftTrayV)
|
||||
' aggiungo gridSplitter alla griglia
|
||||
m_DynamicGrid.Children.Add(gridSplitter)
|
||||
' aggiungo RightTrayV alla griglia
|
||||
m_DynamicGrid.Children.Add(m_RightTrayV)
|
||||
' aggiungo BottomTrayV alla griglia
|
||||
m_DynamicGrid.Children.Add(m_BottomTrayV)
|
||||
m_PanelList.Add(New TopTrayV)
|
||||
m_PanelList.Add(New LeftTrayV)
|
||||
m_PanelList.Add(New RightTrayV)
|
||||
m_PanelList.Add(New BottomTrayV)
|
||||
End If
|
||||
'm_PanelList.Add(New SceneContentControlV)
|
||||
' aggiungo SceneContentControlV alla griglia
|
||||
m_DynamicGrid.Children.Add(m_SceneContentControlV)
|
||||
m_PanelList.Add(m_DynamicGrid)
|
||||
m_PanelList.Add(New SceneContentControlV)
|
||||
End Sub
|
||||
|
||||
#End Region
|
||||
@@ -344,125 +292,6 @@ Public Class ProjectVM
|
||||
|
||||
#Region "METHODS"
|
||||
|
||||
''' <summary>
|
||||
''' Funzione per popolare la griglia
|
||||
''' </summary>
|
||||
''' <param name="m_TopTrayV"></param>
|
||||
''' <param name="m_LeftTrayV"></param>
|
||||
''' <param name="m_RightTrayV"></param>
|
||||
''' <param name="m_BottomTrayV"></param>
|
||||
''' <param name="m_SceneContentControlV"></param>
|
||||
''' <param name="gridSplitter"></param>
|
||||
Private Shared Sub PololateGrid(m_TopTrayV As TopTrayV, m_LeftTrayV As LeftTrayV, m_RightTrayV As RightTrayV, m_BottomTrayV As BottomTrayV, m_SceneContentControlV As SceneContentControlV, gridSplitter As GridSplitter)
|
||||
' aggiungo TopTrayV
|
||||
Grid.SetRow(m_TopTrayV, 0)
|
||||
Grid.SetColumnSpan(m_TopTrayV, 3)
|
||||
|
||||
' aggiungo LeftTrayV
|
||||
Grid.SetRow(m_LeftTrayV, 1)
|
||||
Grid.SetColumn(m_LeftTrayV, 0)
|
||||
Grid.SetRowSpan(m_LeftTrayV, 2)
|
||||
|
||||
' aggiungo RightTrayV
|
||||
Grid.SetRow(m_RightTrayV, 1)
|
||||
Grid.SetColumn(m_RightTrayV, 2)
|
||||
Grid.SetRowSpan(m_RightTrayV, 2)
|
||||
|
||||
'aggiungo gridSplitter
|
||||
Grid.SetRow(gridSplitter, 1)
|
||||
Grid.SetColumn(gridSplitter, 2)
|
||||
|
||||
' aggiungo BottomTrayV
|
||||
Grid.SetRow(m_BottomTrayV, 2)
|
||||
Grid.SetColumn(m_BottomTrayV, 1)
|
||||
|
||||
' aggiungo Scena
|
||||
Grid.SetRow(m_SceneContentControlV, 1)
|
||||
Grid.SetColumn(m_SceneContentControlV, 1)
|
||||
End Sub
|
||||
|
||||
''' <summary>
|
||||
''' Funzione per popolare la griglia con PlugIn
|
||||
''' </summary>
|
||||
''' <param name="m_TopTrayV"></param>
|
||||
''' <param name="m_RightTrayV"></param>
|
||||
''' <param name="m_BottomTrayV"></param>
|
||||
''' <param name="m_SceneContentControlV"></param>
|
||||
''' <param name="gridSplitter"></param>
|
||||
Private Shared Sub PopolateGridWithPlugIn(m_TopTrayV As TopTrayV, m_RightTrayV As RightTrayV, m_BottomTrayV As BottomTrayV, m_SceneContentControlV As SceneContentControlV, gridSplitter As GridSplitter)
|
||||
' aggiungo TopTrayV
|
||||
Grid.SetRow(m_TopTrayV, 0)
|
||||
Grid.SetColumn(m_TopTrayV, 1)
|
||||
|
||||
' aggiungo RightTrayV
|
||||
Grid.SetRow(m_RightTrayV, 0)
|
||||
Grid.SetColumn(m_RightTrayV, 2)
|
||||
Grid.SetRowSpan(m_RightTrayV, 2)
|
||||
|
||||
'aggiungo gridSplitter
|
||||
Grid.SetRow(gridSplitter, 0)
|
||||
Grid.SetColumn(gridSplitter, 2)
|
||||
Grid.SetRowSpan(gridSplitter, 2)
|
||||
|
||||
' aggiungo BottomTrayV
|
||||
Grid.SetRow(m_BottomTrayV, 2)
|
||||
Grid.SetColumn(m_BottomTrayV, 1)
|
||||
|
||||
' aggiungo Scena
|
||||
Grid.SetRow(m_SceneContentControlV, 1)
|
||||
Grid.SetColumn(m_SceneContentControlV, 1)
|
||||
End Sub
|
||||
|
||||
''' <summary>
|
||||
''' Creazione GridSplitter
|
||||
''' </summary>
|
||||
''' <returns></returns>
|
||||
Private Shared Function CreateGridSplitter() As GridSplitter
|
||||
' creo gridsplitter
|
||||
Return New GridSplitter With {
|
||||
.Width = 30,
|
||||
.HorizontalAlignment = HorizontalAlignment.Left,
|
||||
.VerticalAlignment = VerticalAlignment.Stretch,
|
||||
.Background = Brushes.Transparent
|
||||
}
|
||||
End Function
|
||||
|
||||
''' <summary>
|
||||
''' Creazione Griglia Dinamica
|
||||
''' </summary>
|
||||
Private Sub CreateDynamicGrid()
|
||||
' creo colonne griglia dinamica
|
||||
Dim gridCol1 As New ColumnDefinition With {
|
||||
.Width = New GridLength(1, GridUnitType.Auto)
|
||||
}
|
||||
'.Width = New GridLength(1, GridUnitType.Auto)
|
||||
Dim gridCol2 As New ColumnDefinition With {
|
||||
.Width = New GridLength(1, GridUnitType.Star)
|
||||
}
|
||||
Dim gridCol3 As New ColumnDefinition With {
|
||||
.Width = New GridLength(250)
|
||||
}
|
||||
' aggiungo le colonne alla griglia
|
||||
m_DynamicGrid.ColumnDefinitions.Add(gridCol1)
|
||||
m_DynamicGrid.ColumnDefinitions.Add(gridCol2)
|
||||
m_DynamicGrid.ColumnDefinitions.Add(gridCol3)
|
||||
|
||||
' creo righe griglia dinamica
|
||||
Dim gridRow1 As New RowDefinition With {
|
||||
.Height = New GridLength(1, GridUnitType.Auto)
|
||||
}
|
||||
Dim gridRow2 As New RowDefinition With {
|
||||
.Height = New GridLength(1, GridUnitType.Star)
|
||||
}
|
||||
Dim gridRow3 As New RowDefinition With {
|
||||
.Height = New GridLength(1, GridUnitType.Auto)
|
||||
}
|
||||
' aggiungo righe alla griglia
|
||||
m_DynamicGrid.RowDefinitions.Add(gridRow1)
|
||||
m_DynamicGrid.RowDefinitions.Add(gridRow2)
|
||||
m_DynamicGrid.RowDefinitions.Add(gridRow3)
|
||||
End Sub
|
||||
|
||||
Private Sub PreInitializeScene()
|
||||
' imposto colore di default
|
||||
Dim DefColor As New Color3d(0, 0, 0)
|
||||
@@ -519,6 +348,7 @@ Public Class ProjectVM
|
||||
End If
|
||||
End If
|
||||
m_Controller.SetSurfTmTolerance(OptionModule.m_dGeometryTolerance)
|
||||
m_Controller.SetAdvImpTolerance(OptionModule.m_dAdvImpTolerance)
|
||||
m_Controller.SetUseCustomColors(True, S_SCENE, K_CUSTOMCOLORS)
|
||||
' imposto unità di misura per interfaccia utente
|
||||
IniFile.m_bMmUnits = (GetPrivateProfileInt(S_SCENE, K_MMUNITS, 1) <> 0)
|
||||
@@ -576,6 +406,8 @@ Public Class ProjectVM
|
||||
' Imposto default per import
|
||||
m_Controller.SetScaleForDxfImport(OptionModule.m_dDxfScaleFactor)
|
||||
m_Controller.SetScaleForStlImport(OptionModule.m_dStlScaleFactor)
|
||||
m_Controller.SetScaleForOffImport(OptionModule.m_dOffScaleFactor)
|
||||
m_Controller.SetScaleForPlyImport(OptionModule.m_dPlyScaleFactor)
|
||||
m_Controller.SetScaleForImageImport(OptionModule.m_dImgScaleFactor)
|
||||
' Imposto default per export
|
||||
m_Controller.SetDefaultForDxfExport(OptionModule.m_nExportDxfFlag)
|
||||
@@ -601,7 +433,7 @@ Public Class ProjectVM
|
||||
Dim nFlag As Integer = 1
|
||||
If Environment.GetCommandLineArgs.Count() > 4 Then Integer.TryParse(Environment.GetCommandLineArgs(4), nFlag)
|
||||
' Modalità cieco con valori 0, 3 e 4
|
||||
Return (nFlag <> 0 And nFlag <> 3 And nFlag <> 4)
|
||||
Return (nFlag <> 0 And nFlag <> 3 And nFlag <> 4 And nFlag <> 8)
|
||||
End If
|
||||
If sExt = ".ddf" And Environment.GetCommandLineArgs.Count() > 2 Then
|
||||
' Flag
|
||||
@@ -710,7 +542,13 @@ Public Class ProjectVM
|
||||
' Esecuzione
|
||||
OpenDoorFile(sFile, bNcGen, bExit, nProbing)
|
||||
' Se richiesta uscita immediata
|
||||
If bExit Then Map.refMainWindowVM.CloseApplicationCmd()
|
||||
If bExit Then
|
||||
Map.refMainWindowVM.CloseApplicationCmd()
|
||||
End If
|
||||
' Se applicate lavorazioni, vado in modalità Lavora
|
||||
If EgtGetCurrMachGroup() <> GDB_ID.NULL Then
|
||||
Map.refTopCommandBarVM.SetMachiningMode()
|
||||
End If
|
||||
Return
|
||||
End If
|
||||
' Se file tol, gestione aggiornamento dei dati degli utensili
|
||||
@@ -759,7 +597,7 @@ Public Class ProjectVM
|
||||
bOk = ExecWall(sFile, sMachine, nFlag, False)
|
||||
End If
|
||||
' Se richiesta uscita immediata
|
||||
If nFlag = 0 Or nFlag = 3 Or nFlag = 4 Then
|
||||
If nFlag = 0 Or nFlag = 3 Or nFlag = 4 Or nFlag = 8 Then
|
||||
Map.refMachinePanelVM.SaveCurrentMachine()
|
||||
Map.refMainWindowVM.CloseApplicationCmd()
|
||||
' Altrimenti se errore
|
||||
@@ -778,7 +616,7 @@ Public Class ProjectVM
|
||||
Select Case nFileType
|
||||
Case FT.NGE, FT.NFE
|
||||
Return m_Controller.OpenProject(sFile, False)
|
||||
Case FT.DXF, FT.STL, FT._3MF, FT._3DM, FT.OBJ, FT.CNC, FT.CSF, FT.BTL, FT.BTLX, FT.IMG, FT.PNT, FT.IGES, FT.STEP_, FT.ACIS, FT.PARASOLID, FT.JT, FT.VRML, FT.C3D
|
||||
Case FT.DXF, FT.STL, FT._3MF, FT._3DM, FT.OFF, FT.PLY, FT.OBJ, FT.CNC, FT.CSF, FT.BTL, FT.BTLX, FT.IMG, FT.PNT, FT.IGES, FT.STEP_, FT.ACIS, FT.PARASOLID, FT.JT, FT.VRML, FT.C3D
|
||||
Return m_Controller.ImportProject(sFile, False)
|
||||
Case FT.TSC, FT.LUA
|
||||
Return m_Controller.Exec(sFile, False)
|
||||
@@ -791,7 +629,6 @@ Public Class ProjectVM
|
||||
' Formato descrizione porte
|
||||
If Path.GetExtension(sFile).ToLower() = ".ddf" Then
|
||||
nErr = ExecDoors(m_ProjectScene, sFile, bNcGen, bBatch, nProbing)
|
||||
'CreateDoors(sFile, bNcGen, bBatch, nProbing)
|
||||
Map.refProjectVM.EmitTitle()
|
||||
Return True
|
||||
End If
|
||||
@@ -1292,7 +1129,7 @@ Public Class ProjectVM
|
||||
EgtGetPlaneSnapPoint(e.Location, Vector3d.Z_AX, TableRef.z, ptCurr)
|
||||
DispositionUtility.VtHookFinder(nFixtureId, ptCurr)
|
||||
Exit While
|
||||
ElseIf DispositionUtility.VerifyTableAxis(nFixtureId) Then
|
||||
ElseIf DispositionUtility.VerifyTableAxis( nFixtureId) Then
|
||||
m_SelType = DispositionUtility.SelType.BARS
|
||||
m_nIdToSel = nFixtureId
|
||||
' Drag possibile
|
||||
@@ -1390,7 +1227,7 @@ Public Class ProjectVM
|
||||
m_nIdToDesel = GDB_ID.NULL
|
||||
EgtDraw()
|
||||
Return
|
||||
' altrimenti verifico il tipo del primo oggetto selezionato
|
||||
' altrimenti verifico il tipo del primo oggetto selezionato
|
||||
Else
|
||||
Dim nFirstSelId As Integer = EgtGetFirstSelectedObj()
|
||||
' se è un riferimento resetto lo stato di selezione ed esco
|
||||
@@ -1489,6 +1326,15 @@ Public Class ProjectVM
|
||||
ElseIf IniFile.m_ProjectMode = ProjectModeOpt.MACHINING And m_SceneSelType = SceneSelTypeOpt.MACHINING And
|
||||
(EgtGetType(nId) = GDB_TY.SRF_MESH Or EgtGetType(nId) = GDB_TY.SRF_FRGN) Then
|
||||
If Not EgtIsSelectedObj(nId) Then m_Controller.MouseSelectedObj(nId, bLast)
|
||||
ElseIf Not Keyboard.IsKeyDown(Key.LeftShift) Then
|
||||
m_Controller.MouseSelectedObj(nId, False)
|
||||
If EgtIsSelectedObj(nId) Then
|
||||
' Selezione layer in albero
|
||||
Map.refManageLayerExpanderVM.UpdateObjInObjTreeNoMark(nId)
|
||||
Map.refManageLayerExpanderVM.SelectIdInObjTreeNoMark(nId)
|
||||
Map.refManageLayerExpanderVM.UpdateObjTree()
|
||||
End If
|
||||
EgtDraw()
|
||||
Else
|
||||
m_Controller.MouseSelectedObj(nId, bLast)
|
||||
End If
|
||||
@@ -1718,6 +1564,8 @@ Public Class ProjectVM
|
||||
nFlag = GetPrivateProfileInt(S_IMPORT, K_CNCFLAG, EIC_FL.NONE)
|
||||
ElseIf nType = FT.BTL Or nType = FT.BTLX Then
|
||||
nFlag = GetPrivateProfileInt(S_IMPORT, K_BTLFLAG, EIB_FL.NONE)
|
||||
ElseIf nType = FT._3MF
|
||||
nFlag = GetPrivateProfileInt(S_IMPORT, K_3MFFLAG, EI3_FL.NONE)
|
||||
ElseIf nType = FT.OBJ Or nType = FT.IGES Or nType = FT.STEP_ Or nType = FT.ACIS Or
|
||||
nType = FT.PARASOLID Or nType = FT.JT Or nType = FT.VRML Or nType = FT.C3D Then
|
||||
nFlag = GetPrivateProfileInt(S_IMPORT, K_ADVFLAG, 0)
|
||||
|
||||
|
Before Width: | Height: | Size: 951 B |
|
Before Width: | Height: | Size: 688 B |
|
Before Width: | Height: | Size: 1.4 KiB |
|
After Width: | Height: | Size: 665 B |
|
Before Width: | Height: | Size: 1.5 KiB |
|
Before Width: | Height: | Size: 875 B |
|
After Width: | Height: | Size: 809 B |
|
Before Width: | Height: | Size: 1.4 KiB |
|
Before Width: | Height: | Size: 640 B |
|
Before Width: | Height: | Size: 1.0 KiB |
|
Before Width: | Height: | Size: 1.3 KiB |
|
Before Width: | Height: | Size: 614 B |
|
Before Width: | Height: | Size: 842 B |
|
Before Width: | Height: | Size: 837 B |
|
Before Width: | Height: | Size: 821 B |
|
Before Width: | Height: | Size: 397 B |
|
Before Width: | Height: | Size: 1.2 KiB |
|
Before Width: | Height: | Size: 1.3 KiB |
|
Before Width: | Height: | Size: 1.5 KiB |
|
Before Width: | Height: | Size: 498 B |
|
Before Width: | Height: | Size: 885 B |
|
Before Width: | Height: | Size: 996 B |
@@ -2,8 +2,6 @@
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:local="clr-namespace:EgtCAM5"
|
||||
DockPanel.Dock="Right"
|
||||
Margin="0.5,0,0,0">
|
||||
|
||||
DockPanel.Dock="Right">
|
||||
<local:OptionPanelV DataContext="{StaticResource OptionPanelViewModel}"/>
|
||||
</Grid>
|
||||
|
||||
@@ -139,254 +139,265 @@
|
||||
<TabControl Grid.Row="1" Margin="5,0,5,5" SelectionChanged="TabControl_SelectionChanged">
|
||||
<TabItem Header="Association Table">
|
||||
<TabItem.Content>
|
||||
<DataGrid Name="AssociationDataGrid"
|
||||
ItemsSource="{Binding Path=SelectedItem.AssociationList,
|
||||
ElementName=TablesListBox}"
|
||||
SelectedItem="{Binding Path=SelectedItem.SelectedAssociation,
|
||||
ElementName=TablesListBox,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||
IsSynchronizedWithCurrentItem="False"
|
||||
AutoGenerateColumns="False"
|
||||
CanUserSortColumns="False"
|
||||
CanUserResizeColumns="False"
|
||||
CanUserResizeRows="False"
|
||||
CanUserReorderColumns="False"
|
||||
SelectionMode="Single"
|
||||
ScrollViewer.CanContentScroll="True"
|
||||
ScrollViewer.VerticalScrollBarVisibility="Auto"
|
||||
ScrollViewer.HorizontalScrollBarVisibility="Hidden"
|
||||
VirtualizingStackPanel.IsVirtualizing="False">
|
||||
<Interactivity:Interaction.Behaviors>
|
||||
<EgtCAM5:ScrollIntoViewForDataGrid/>
|
||||
</Interactivity:Interaction.Behaviors>
|
||||
<DataGrid.InputBindings>
|
||||
<KeyBinding Key="F3" Modifiers="Control" Command="{Binding SearchNextCommand}"/>
|
||||
<KeyBinding Key="F3" Modifiers="Shift" Command="{Binding SearchPreviousCommand}"/>
|
||||
</DataGrid.InputBindings>
|
||||
<DataGrid.RowStyle>
|
||||
<Style TargetType="DataGridRow">
|
||||
<Style.Resources>
|
||||
<SolidColorBrush x:Key="{x:Static SystemColors.ControlBrushKey}" Color="{x:Static SystemColors.HighlightColor}"/>
|
||||
<SolidColorBrush x:Key="{x:Static SystemColors.ControlTextBrushKey}" Color="{x:Static SystemColors.HighlightTextColor}"/>
|
||||
</Style.Resources>
|
||||
<Setter Property="IsSelected" Value="{Binding IsSelected,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"/>
|
||||
<EventSetter Event="PreviewMouseDown" Handler="LeftTableMouseDown"/>
|
||||
<Style.Triggers>
|
||||
<DataTrigger Binding="{Binding IsValidForSearch}" Value="True">
|
||||
<Setter Property="Background" Value="{StaticResource EgaltechGreen}"></Setter>
|
||||
</DataTrigger>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
</DataGrid.RowStyle>
|
||||
<DataGrid.Columns>
|
||||
<Grid>
|
||||
<FrameworkElement x:Name="dummyElement" Visibility="Collapsed"/>
|
||||
<DataGrid Name="AssociationDataGrid"
|
||||
ItemsSource="{Binding Path=SelectedItem.AssociationList,
|
||||
ElementName=TablesListBox}"
|
||||
EgtCAM5:MultiSelectorBehaviours.SynchronizedSelectedItems="{Binding SelectedItem.SelectedAssociations,
|
||||
ElementName=TablesListBox}"
|
||||
IsSynchronizedWithCurrentItem="False"
|
||||
AutoGenerateColumns="False"
|
||||
CanUserSortColumns="False"
|
||||
CanUserResizeColumns="False"
|
||||
CanUserResizeRows="False"
|
||||
CanUserReorderColumns="False"
|
||||
SelectionMode="Extended"
|
||||
PreviewMouseDown="DataGrid_PreviewMouseDown"
|
||||
PreviewMouseUp="DataGrid_PreviewMouseUp"
|
||||
PreviewMouseMove="DataGrid_PreviewMouseMove"
|
||||
ScrollViewer.CanContentScroll="True"
|
||||
ScrollViewer.VerticalScrollBarVisibility="Auto"
|
||||
ScrollViewer.HorizontalScrollBarVisibility="Hidden"
|
||||
VirtualizingStackPanel.IsVirtualizing="False">
|
||||
<Interactivity:Interaction.Behaviors>
|
||||
<EgtCAM5:ScrollIntoViewForDataGrid/>
|
||||
</Interactivity:Interaction.Behaviors>
|
||||
<DataGrid.InputBindings>
|
||||
<KeyBinding Key="F3" Modifiers="Control" Command="{Binding SearchNextCommand}"/>
|
||||
<KeyBinding Key="F3" Modifiers="Shift" Command="{Binding SearchPreviousCommand}"/>
|
||||
</DataGrid.InputBindings>
|
||||
<DataGrid.RowStyle>
|
||||
<Style TargetType="DataGridRow">
|
||||
<Style.Resources>
|
||||
<SolidColorBrush x:Key="{x:Static SystemColors.ControlBrushKey}" Color="{x:Static SystemColors.HighlightColor}"/>
|
||||
<SolidColorBrush x:Key="{x:Static SystemColors.ControlTextBrushKey}" Color="{x:Static SystemColors.HighlightTextColor}"/>
|
||||
</Style.Resources>
|
||||
<Setter Property="IsSelected" Value="{Binding IsSelected,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"/>
|
||||
<EventSetter Event="PreviewMouseDown" Handler="LeftTableMouseDown"/>
|
||||
<Style.Triggers>
|
||||
<DataTrigger Binding="{Binding IsValidForSearch}" Value="True">
|
||||
<Setter Property="Background" Value="{StaticResource EgaltechGreen}"></Setter>
|
||||
</DataTrigger>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
</DataGrid.RowStyle>
|
||||
<DataGrid.Columns>
|
||||
|
||||
<!--Colonna On-->
|
||||
<DataGridCheckBoxColumn Width="Auto" Binding="{Binding OnPar}">
|
||||
<DataGridCheckBoxColumn.Header>
|
||||
<TextBlock Text="{Binding Path=DataContext.OnHdr,RelativeSource={RelativeSource AncestorType={x:Type EgtWPFLib5:EgtCustomWindow}}}"/>
|
||||
</DataGridCheckBoxColumn.Header>
|
||||
</DataGridCheckBoxColumn>
|
||||
<!--Colonna On-->
|
||||
<DataGridCheckBoxColumn Width="Auto" Binding="{Binding OnPar}">
|
||||
<DataGridCheckBoxColumn.Header>
|
||||
<TextBlock Text="{Binding Path=DataContext.OnHdr,RelativeSource={RelativeSource AncestorType={x:Type EgtWPFLib5:EgtCustomWindow}}}"/>
|
||||
</DataGridCheckBoxColumn.Header>
|
||||
</DataGridCheckBoxColumn>
|
||||
|
||||
<!--Colonna Name-->
|
||||
<DataGridTemplateColumn Width="1*">
|
||||
<DataGridTemplateColumn.Header>
|
||||
<TextBlock Text="{Binding Path=DataContext.GeomNameHdr,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}"
|
||||
ToolTip="{Binding Path=Name,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
<!--Colonna Name-->
|
||||
<DataGridTemplateColumn Width="1*">
|
||||
<DataGridTemplateColumn.Header>
|
||||
<TextBlock Text="{Binding Path=DataContext.GeomNameHdr,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}"
|
||||
ToolTip="{Binding Path=Name,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
|
||||
<!--Colonna Operation-->
|
||||
<DataGridTemplateColumn Width="0.75*">
|
||||
<DataGridTemplateColumn.Header>
|
||||
<TextBlock Text="{Binding Path=DataContext.OperationHdr,RelativeSource={RelativeSource AncestorType={x:Type EgtWPFLib5:EgtCustomWindow}}}"/>
|
||||
</DataGridTemplateColumn.Header>
|
||||
<DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataTemplate>
|
||||
<ComboBox IsEditable="False"
|
||||
SelectedItem="{Binding Oper,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||
ItemsSource="{Binding Path=OperationsList, Mode=OneWay, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=Oper,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}" />
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
<!--Colonna Operation-->
|
||||
<DataGridTemplateColumn Width="0.75*">
|
||||
<DataGridTemplateColumn.Header>
|
||||
<TextBlock Text="{Binding Path=DataContext.OperationHdr,RelativeSource={RelativeSource AncestorType={x:Type EgtWPFLib5:EgtCustomWindow}}}"/>
|
||||
</DataGridTemplateColumn.Header>
|
||||
<DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataTemplate>
|
||||
<ComboBox IsEditable="False"
|
||||
SelectedItem="{Binding Oper,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||
ItemsSource="{Binding Path=OperationsList, Mode=OneWay, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=Oper,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}" />
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
|
||||
<!--Colonna Machine Id-->
|
||||
<DataGridTemplateColumn Width="38">
|
||||
<DataGridTemplateColumn.Header>
|
||||
<TextBlock Text="{Binding Path=DataContext.MIdHdr,RelativeSource={RelativeSource AncestorType={x:Type EgtWPFLib5:EgtCustomWindow}}}"/>
|
||||
</DataGridTemplateColumn.Header>
|
||||
<DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataTemplate>
|
||||
<ComboBox IsEditable="False"
|
||||
SelectedItem="{Binding MachId,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||
ItemsSource="{Binding Source={x:Reference TablesListBox}, Path=SelectedItem.MachIdList, Mode=OneWay, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=MachId,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||
HorizontalAlignment="Center"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
<!--Colonna Machine Id-->
|
||||
<DataGridTemplateColumn Width="38">
|
||||
<DataGridTemplateColumn.Header>
|
||||
<TextBlock Text="{Binding Path=DataContext.MIdHdr,RelativeSource={RelativeSource AncestorType={x:Type EgtWPFLib5:EgtCustomWindow}}}"/>
|
||||
</DataGridTemplateColumn.Header>
|
||||
<DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataTemplate>
|
||||
<ComboBox IsEditable="False"
|
||||
SelectedItem="{Binding MachId,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||
ItemsSource="{Binding Source={x:Reference TablesListBox}, Path=SelectedItem.MachIdList, Mode=OneWay, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=MachId,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||
HorizontalAlignment="Center"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
|
||||
<!--Colonna Shift-->
|
||||
<DataGridTemplateColumn Width="38">
|
||||
<DataGridTemplateColumn.Header>
|
||||
<TextBlock Text="{Binding Path=DataContext.ShiftHdr,RelativeSource={RelativeSource AncestorType={x:Type EgtWPFLib5:EgtCustomWindow}}}"/>
|
||||
</DataGridTemplateColumn.Header>
|
||||
<DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataTemplate>
|
||||
<ComboBox IsEditable="False"
|
||||
SelectedItem="{Binding Shift,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||
ItemsSource="{Binding Path=ShiftList,Mode=OneWay, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=Shift,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||
HorizontalAlignment="Center"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
<!--Colonna Shift-->
|
||||
<DataGridTemplateColumn Width="38">
|
||||
<DataGridTemplateColumn.Header>
|
||||
<TextBlock Text="{Binding Path=DataContext.ShiftHdr,RelativeSource={RelativeSource AncestorType={x:Type EgtWPFLib5:EgtCustomWindow}}}"/>
|
||||
</DataGridTemplateColumn.Header>
|
||||
<DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataTemplate>
|
||||
<ComboBox IsEditable="False"
|
||||
SelectedItem="{Binding Shift,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||
ItemsSource="{Binding Path=ShiftList,Mode=OneWay, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=Shift,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||
HorizontalAlignment="Center"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
|
||||
<!--Colonna MachiningType-->
|
||||
<DataGridTemplateColumn Width="0.5*">
|
||||
<DataGridTemplateColumn.Header>
|
||||
<TextBlock Text="{Binding Path=DataContext.MachTypeHdr,RelativeSource={RelativeSource AncestorType={x:Type EgtWPFLib5:EgtCustomWindow}}}"/>
|
||||
</DataGridTemplateColumn.Header>
|
||||
<DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataTemplate>
|
||||
<ComboBox IsEditable="False"
|
||||
SelectedItem="{Binding SelectedMachType,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||
ItemsSource="{Binding Path=MachTypeList, Mode=OneWay, UpdateSourceTrigger=PropertyChanged}"
|
||||
DisplayMemberPath="TypeName"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=SelectedMachType.TypeName,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}" />
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
<!--Colonna MachiningType-->
|
||||
<DataGridTemplateColumn Width="0.5*">
|
||||
<DataGridTemplateColumn.Header>
|
||||
<TextBlock Text="{Binding Path=DataContext.MachTypeHdr,RelativeSource={RelativeSource AncestorType={x:Type EgtWPFLib5:EgtCustomWindow}}}"/>
|
||||
</DataGridTemplateColumn.Header>
|
||||
<DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataTemplate>
|
||||
<ComboBox IsEditable="False"
|
||||
SelectedItem="{Binding SelectedMachType,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||
ItemsSource="{Binding Path=MachTypeList, Mode=OneWay, UpdateSourceTrigger=PropertyChanged}"
|
||||
DisplayMemberPath="TypeName"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=SelectedMachType.TypeName,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}" />
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
|
||||
<!--Colonna Machining-->
|
||||
<DataGridTemplateColumn Width="1*">
|
||||
<DataGridTemplateColumn.Header>
|
||||
<TextBlock Text="{Binding Path=DataContext.MachHdr,RelativeSource={RelativeSource AncestorType={x:Type EgtWPFLib5:EgtCustomWindow}}}"/>
|
||||
</DataGridTemplateColumn.Header>
|
||||
<DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataTemplate>
|
||||
<ComboBox IsEditable="False"
|
||||
SelectedItem="{Binding Mach, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
|
||||
ItemsSource="{Binding Path=MachList, Mode=OneWay, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=Mach, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
|
||||
ToolTip="{Binding Path=Mach, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
<!--Colonna Machining-->
|
||||
<DataGridTemplateColumn Width="1*">
|
||||
<DataGridTemplateColumn.Header>
|
||||
<TextBlock Text="{Binding Path=DataContext.MachHdr,RelativeSource={RelativeSource AncestorType={x:Type EgtWPFLib5:EgtCustomWindow}}}"/>
|
||||
</DataGridTemplateColumn.Header>
|
||||
<DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataTemplate>
|
||||
<ComboBox IsEditable="False"
|
||||
SelectedItem="{Binding Mach, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
|
||||
ItemsSource="{Binding Path=MachList, Mode=OneWay, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=Mach, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
|
||||
ToolTip="{Binding Path=Mach, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
|
||||
<!--Colonna MachiningUpType-->
|
||||
<DataGridTemplateColumn Width="0.5*">
|
||||
<DataGridTemplateColumn.Header>
|
||||
<TextBlock Text="{Binding Path=DataContext.MachTypeHdr,RelativeSource={RelativeSource AncestorType={x:Type EgtWPFLib5:EgtCustomWindow}}}"/>
|
||||
</DataGridTemplateColumn.Header>
|
||||
<DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataTemplate>
|
||||
<ComboBox IsEditable="False"
|
||||
SelectedItem="{Binding SelectedMachUpType,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||
ItemsSource="{Binding Path=MachTypeList, Mode=OneWay, UpdateSourceTrigger=PropertyChanged}"
|
||||
DisplayMemberPath="TypeName"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=SelectedMachUpType.TypeName,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}" />
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
<!--Colonna MachiningUpType-->
|
||||
<DataGridTemplateColumn Width="0.5*">
|
||||
<DataGridTemplateColumn.Header>
|
||||
<TextBlock Text="{Binding Path=DataContext.MachTypeHdr,RelativeSource={RelativeSource AncestorType={x:Type EgtWPFLib5:EgtCustomWindow}}}"/>
|
||||
</DataGridTemplateColumn.Header>
|
||||
<DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataTemplate>
|
||||
<ComboBox IsEditable="False"
|
||||
SelectedItem="{Binding SelectedMachUpType,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||
ItemsSource="{Binding Path=MachTypeList, Mode=OneWay, UpdateSourceTrigger=PropertyChanged}"
|
||||
DisplayMemberPath="TypeName"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=SelectedMachUpType.TypeName,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}" />
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
|
||||
<!--Colonna Machining Up-->
|
||||
<DataGridTemplateColumn Width="1*">
|
||||
<DataGridTemplateColumn.Header>
|
||||
<TextBlock Text="{Binding Path=DataContext.MachUpHdr,RelativeSource={RelativeSource AncestorType={x:Type EgtWPFLib5:EgtCustomWindow}}}"/>
|
||||
</DataGridTemplateColumn.Header>
|
||||
<DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataTemplate>
|
||||
<ComboBox IsEditable="False"
|
||||
SelectedItem="{Binding MachUp,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||
ItemsSource="{Binding Path=MachUpList, Mode=OneWay, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=MachUp,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||
ToolTip="{Binding Path=MachUp,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
<!--Colonna Machining Up-->
|
||||
<DataGridTemplateColumn Width="1*">
|
||||
<DataGridTemplateColumn.Header>
|
||||
<TextBlock Text="{Binding Path=DataContext.MachUpHdr,RelativeSource={RelativeSource AncestorType={x:Type EgtWPFLib5:EgtCustomWindow}}}"/>
|
||||
</DataGridTemplateColumn.Header>
|
||||
<DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataTemplate>
|
||||
<ComboBox IsEditable="False"
|
||||
SelectedItem="{Binding MachUp,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||
ItemsSource="{Binding Path=MachUpList, Mode=OneWay, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=MachUp,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||
ToolTip="{Binding Path=MachUp,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
|
||||
<!--Colonna MachiningDownType-->
|
||||
<DataGridTemplateColumn Width="0.5*">
|
||||
<DataGridTemplateColumn.Header>
|
||||
<TextBlock Text="{Binding Path=DataContext.MachTypeHdr,RelativeSource={RelativeSource AncestorType={x:Type EgtWPFLib5:EgtCustomWindow}}}"/>
|
||||
</DataGridTemplateColumn.Header>
|
||||
<DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataTemplate>
|
||||
<ComboBox IsEditable="False"
|
||||
SelectedItem="{Binding SelectedMachDownType,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||
ItemsSource="{Binding Path=MachTypeList, Mode=OneWay, UpdateSourceTrigger=PropertyChanged}"
|
||||
DisplayMemberPath="TypeName"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=SelectedMachDownType.TypeName,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}" />
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
<!--Colonna MachiningDownType-->
|
||||
<DataGridTemplateColumn Width="0.5*">
|
||||
<DataGridTemplateColumn.Header>
|
||||
<TextBlock Text="{Binding Path=DataContext.MachTypeHdr,RelativeSource={RelativeSource AncestorType={x:Type EgtWPFLib5:EgtCustomWindow}}}"/>
|
||||
</DataGridTemplateColumn.Header>
|
||||
<DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataTemplate>
|
||||
<ComboBox IsEditable="False"
|
||||
SelectedItem="{Binding SelectedMachDownType,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||
ItemsSource="{Binding Path=MachTypeList, Mode=OneWay, UpdateSourceTrigger=PropertyChanged}"
|
||||
DisplayMemberPath="TypeName"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=SelectedMachDownType.TypeName,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}" />
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
|
||||
<!--Colonna Machining Down-->
|
||||
<DataGridTemplateColumn Width="1*">
|
||||
<DataGridTemplateColumn.Header>
|
||||
<TextBlock Text="{Binding Path=DataContext.MachDownHdr,RelativeSource={RelativeSource AncestorType={x:Type EgtWPFLib5:EgtCustomWindow}}}"/>
|
||||
</DataGridTemplateColumn.Header>
|
||||
<DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataTemplate>
|
||||
<ComboBox IsEditable="False"
|
||||
SelectedItem="{Binding MachDw,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||
ItemsSource="{Binding Path=MachDownList, Mode=OneWay, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=MachDw,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||
ToolTip="{Binding Path=MachDw,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
</DataGrid.Columns>
|
||||
<!--Colonna Machining Down-->
|
||||
<DataGridTemplateColumn Width="1*">
|
||||
<DataGridTemplateColumn.Header>
|
||||
<TextBlock Text="{Binding Path=DataContext.MachDownHdr,RelativeSource={RelativeSource AncestorType={x:Type EgtWPFLib5:EgtCustomWindow}}}"/>
|
||||
</DataGridTemplateColumn.Header>
|
||||
<DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataTemplate>
|
||||
<ComboBox IsEditable="False"
|
||||
SelectedItem="{Binding MachDw,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||
ItemsSource="{Binding Path=MachDownList, Mode=OneWay, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellEditingTemplate>
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=MachDw,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"
|
||||
ToolTip="{Binding Path=MachDw,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
<DataGridTextColumn Header="Link"
|
||||
Binding="{Binding Path=Link}"
|
||||
Foreground="Black"
|
||||
IsReadOnly="True"
|
||||
Visibility="{Binding Path=DataContext.Link_Visibility, Source={x:Reference dummyElement}}"/>
|
||||
</DataGrid.Columns>
|
||||
|
||||
</DataGrid>
|
||||
</DataGrid>
|
||||
</Grid>
|
||||
</TabItem.Content>
|
||||
</TabItem>
|
||||
|
||||
@@ -548,6 +559,18 @@
|
||||
<ColumnDefinition Width="2*"/>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition >
|
||||
<ColumnDefinition.Style>
|
||||
<Style TargetType="{x:Type ColumnDefinition}">
|
||||
<Setter Property="Width" Value="1*"/>
|
||||
<Style.Triggers>
|
||||
<DataTrigger Binding="{Binding Visibility, ElementName=LinkBtn}" Value="Collapsed">
|
||||
<Setter Property="Width" Value="Auto"/>
|
||||
</DataTrigger>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
</ColumnDefinition.Style>
|
||||
</ColumnDefinition>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="2*"/>
|
||||
@@ -594,20 +617,25 @@
|
||||
CommandParameter="{Binding Path=SelectedItem, ElementName=TablesListBox}"
|
||||
IsEnabled="{Binding MoveRow_IsEnabled}"
|
||||
Grid.Column="4"/>
|
||||
<Button x:Name="LinkBtn" Content="Link" Command="{Binding LinkCommand}"
|
||||
CommandParameter="{Binding Path=SelectedItem, ElementName=TablesListBox}"
|
||||
IsEnabled="{Binding Link_IsEnabled}"
|
||||
Visibility="{Binding Link_Visibility}"
|
||||
Grid.Column="5"/>
|
||||
<Button Content="Group" Command="{Binding GroupCommand}"
|
||||
CommandParameter="{Binding Path=SelectedItem, ElementName=TablesListBox}"
|
||||
IsEnabled="{Binding Group_IsEnabled}"
|
||||
Grid.Column="5"/>
|
||||
Grid.Column="6"/>
|
||||
<Button Content="Position" Command="{Binding PositionCommand}"
|
||||
CommandParameter="{Binding Path=SelectedItem, ElementName=TablesListBox}"
|
||||
IsEnabled="{Binding Position_IsEnabled}"
|
||||
Grid.Column="6"/>
|
||||
Grid.Column="7"/>
|
||||
<Button Content="{Binding AddMachBtn}" Command="{Binding AddMachCommand}"
|
||||
CommandParameter="{Binding Path=SelectedItem, ElementName=TablesListBox}"
|
||||
Grid.Column="7"/>
|
||||
CommandParameter="{Binding Path=SelectedItem, ElementName=TablesListBox}"
|
||||
Grid.Column="8"/>
|
||||
<Button Content="{Binding RemoveMachBtn}" Command="{Binding RemoveMachCommand}"
|
||||
CommandParameter="{Binding Path=SelectedItem, ElementName=TablesListBox}"
|
||||
Grid.Column="8"/>
|
||||
CommandParameter="{Binding Path=SelectedItem, ElementName=TablesListBox}"
|
||||
Grid.Column="9"/>
|
||||
</Grid>
|
||||
|
||||
</Grid>
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
Imports System.Windows
|
||||
Imports System.Windows.Controls.Primitives
|
||||
Imports EgtWPFLib5
|
||||
Imports EgtUILib
|
||||
|
||||
Public Class MTableDbV
|
||||
|
||||
@@ -155,4 +156,31 @@ Public Class MTableDbV
|
||||
WinPosFromWindowToIni(Me, S_DOORS, K_MTABLEWINPLACE)
|
||||
End Sub
|
||||
|
||||
|
||||
Public Sub DataGrid_PreviewMouseDown(sender As Object, e As MouseButtonEventArgs)
|
||||
If e.ChangedButton = MouseButton.Left Then
|
||||
If (Keyboard.Modifiers And ModifierKeys.Shift) = ModifierKeys.Shift Then
|
||||
e.Handled = True
|
||||
End If
|
||||
If (Keyboard.Modifiers And ModifierKeys.Control) = ModifierKeys.Control AndAlso TypeOf sender Is DataGrid AndAlso DirectCast(sender, DataGrid).SelectedItems.Count >= 2 Then
|
||||
e.Handled = True
|
||||
End If
|
||||
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Public Sub DataGrid_PreviewMouseUp(sender As Object, e As MouseButtonEventArgs)
|
||||
End Sub
|
||||
|
||||
Public Sub DataGrid_PreviewMouseMove(sender As Object, e As MouseEventArgs)
|
||||
Dim Element As Object = e.OriginalSource
|
||||
While Not IsNothing(Element) AndAlso Not TypeOf Element Is ScrollBar
|
||||
Element = VisualTreeHelper.GetParent(Element)
|
||||
End While
|
||||
' verifico che non sia ScrollBar, di modo che questa continui a funzionare, ma non possa selezionare piu' righe trascinando
|
||||
If IsNothing(Element) OrElse Not TypeOf Element Is ScrollBar Then
|
||||
e.Handled = True
|
||||
End If
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.Collections.Specialized
|
||||
Imports System.ComponentModel
|
||||
Imports System.IO
|
||||
Imports System.Text.RegularExpressions
|
||||
Imports System.Windows.Forms.LinkLabel
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
|
||||
@@ -156,6 +158,24 @@ Public Class MTableDbVM
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Private m_Link_Visibility As Visibility = Visibility.Collapsed
|
||||
Public ReadOnly Property Link_Visibility As Visibility
|
||||
Get
|
||||
Return m_Link_Visibility
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Private m_Link_IsEnabled As Boolean
|
||||
Public Property Link_IsEnabled As Boolean
|
||||
Get
|
||||
Return m_Link_IsEnabled
|
||||
End Get
|
||||
Set(value As Boolean)
|
||||
m_Link_IsEnabled = value
|
||||
NotifyPropertyChanged(NameOf(Link_IsEnabled))
|
||||
End Set
|
||||
End Property
|
||||
|
||||
#Region "Messages"
|
||||
|
||||
Public ReadOnly Property Title As String
|
||||
@@ -359,6 +379,7 @@ Public Class MTableDbVM
|
||||
Private m_cmdMoveRowDown As ICommand
|
||||
Private m_cmdGroup As ICommand
|
||||
Private m_cmdPosition As ICommand
|
||||
Private m_cmdLink As ICommand
|
||||
Private m_cmdCloseMTableWindow As ICommand
|
||||
|
||||
#Region "CONSTRUCTOR"
|
||||
@@ -385,6 +406,9 @@ Public Class MTableDbVM
|
||||
' Altrimenti recupero macchina corrente all'apertura della finestra per poterla ripristinare alla fine
|
||||
EgtGetCurrMachineName(m_sPreviousActiveMachine)
|
||||
End If
|
||||
' leggo abilitazione link
|
||||
m_Link_Visibility = If(GetMainPrivateProfileInt(S_DOORS, K_OPTIMIZEMACHFORLINE, 0) = 1, Visibility.Visible, Visibility.Collapsed)
|
||||
NotifyPropertyChanged(NameOf(Link_Visibility))
|
||||
' Azzero indice per nome tabella di default
|
||||
MTableListBoxItem.NewMTableIndex = 0
|
||||
' Creo liste operazioni e proprietà
|
||||
@@ -404,17 +428,29 @@ Public Class MTableDbVM
|
||||
If EgtVerifyMachinesDir() AndAlso Not bActiveMTableFound AndAlso m_TablesList.Count > 0 Then
|
||||
m_TablesList(0).IsSelected = True
|
||||
If Not m_TablesList(0).IsSelected Then
|
||||
m_TablesList.RemoveAt( 0)
|
||||
return
|
||||
End If
|
||||
m_TablesList.RemoveAt(0)
|
||||
Return
|
||||
End If
|
||||
m_TablesList(0).SelMachine = m_TablesList(0).ActiveMachinesList(0)
|
||||
End If
|
||||
For Each Table In TablesList
|
||||
AddHandler Table.SelectedAssociations.CollectionChanged, AddressOf SelectedAssociations_CollectionChanged
|
||||
Next
|
||||
End Sub
|
||||
|
||||
#End Region
|
||||
|
||||
#Region "METHODS"
|
||||
|
||||
Private Sub SelectedAssociations_CollectionChanged(sender As Object, e As NotifyCollectionChangedEventArgs)
|
||||
For Each Table In TablesList
|
||||
If Table.IsSelected Then
|
||||
AddRemoveRow_IsEnabled = Table.SelectedAssociations.Count = 1
|
||||
Link_IsEnabled = Table.SelectedAssociations.Count = 2
|
||||
End If
|
||||
Next
|
||||
End Sub
|
||||
|
||||
Private Sub UpdateTables()
|
||||
m_TablesList.Clear()
|
||||
' se trovo la cartella carico la lista di tabelle
|
||||
@@ -1220,7 +1256,7 @@ Public Class MTableDbVM
|
||||
Dim SelectedMTable As MTableListBoxItem = DirectCast(param, MTableListBoxItem)
|
||||
If Not IsNothing(SelectedMTable) AndAlso Not IsNothing(SelectedMTable.SelectedAssociation) Then
|
||||
Dim SelectedIndex As Integer = SelectedMTable.AssociationList.IndexOf(SelectedMTable.SelectedAssociation)
|
||||
Dim NewEmptyRow As MTableAssociationGridBoxItem = New MTableAssociationGridBoxItem(False, String.Empty, 1, 0, String.Empty, Nothing, String.Empty, Nothing, String.Empty, Nothing, String.Empty, SelectedMTable.ActiveMachinesList, SelectedMTable.AssociationList)
|
||||
Dim NewEmptyRow As MTableAssociationGridBoxItem = New MTableAssociationGridBoxItem(False, String.Empty, 1, 0, String.Empty, Nothing, String.Empty, Nothing, String.Empty, Nothing, String.Empty, 0, SelectedMTable.ActiveMachinesList, SelectedMTable.AssociationList)
|
||||
SelectedMTable.AssociationList.Insert(SelectedIndex + 1, NewEmptyRow)
|
||||
SelectedMTable.SelectedAssociation = NewEmptyRow
|
||||
SelectedMTable.NotifyPropertyChanged("SelectedAssociation")
|
||||
@@ -1319,10 +1355,21 @@ Public Class MTableDbVM
|
||||
|
||||
' Left table Movement
|
||||
Public Sub LeftTableMoveRowUp(SelectedMTable As MTableListBoxItem)
|
||||
Dim SelectedIndex As Integer = SelectedMTable.AssociationList.IndexOf(SelectedMTable.SelectedAssociation)
|
||||
If SelectedIndex >= 1 Then
|
||||
SelectedMTable.AssociationList.Move(SelectedIndex, SelectedIndex - 1)
|
||||
If SelectedMTable.SelectedAssociations.Count < 2 Then
|
||||
Dim SelectedIndex As Integer = SelectedMTable.AssociationList.IndexOf(SelectedMTable.SelectedAssociation)
|
||||
If SelectedIndex >= 1 Then
|
||||
SelectedMTable.AssociationList.Move(SelectedIndex, SelectedIndex - 1)
|
||||
End If
|
||||
ElseIf SelectedMTable.SelectedAssociations.Count > 2 Then
|
||||
Return
|
||||
Else
|
||||
Dim MoveIndex As Integer = SelectedMTable.AssociationList.IndexOf(SelectedMTable.SelectedAssociations(0))
|
||||
Dim DestinationIndex As Integer = SelectedMTable.AssociationList.IndexOf(SelectedMTable.SelectedAssociations(1))
|
||||
If DestinationIndex >= 0 Then
|
||||
SelectedMTable.AssociationList.Move(MoveIndex, If(MoveIndex > DestinationIndex, DestinationIndex, Math.Max(0, DestinationIndex - 1)))
|
||||
End If
|
||||
End If
|
||||
|
||||
End Sub
|
||||
|
||||
Public Sub RightTableMoveRowUp(SelectedMTable As MTableListBoxItem)
|
||||
@@ -1572,9 +1619,19 @@ Public Class MTableDbVM
|
||||
|
||||
' Spostamento sulla tabella delle associazioni
|
||||
Public Sub LeftTableMoveRowDown(SelectedMTable As MTableListBoxItem)
|
||||
Dim SelectedIndex As Integer = SelectedMTable.AssociationList.IndexOf(SelectedMTable.SelectedAssociation)
|
||||
If SelectedIndex < SelectedMTable.AssociationList.Count - 1 Then
|
||||
SelectedMTable.AssociationList.Move(SelectedIndex, SelectedIndex + 1)
|
||||
If SelectedMTable.SelectedAssociations.Count < 2 Then
|
||||
Dim SelectedIndex As Integer = SelectedMTable.AssociationList.IndexOf(SelectedMTable.SelectedAssociation)
|
||||
If SelectedIndex < SelectedMTable.AssociationList.Count - 1 Then
|
||||
SelectedMTable.AssociationList.Move(SelectedIndex, SelectedIndex + 1)
|
||||
End If
|
||||
ElseIf SelectedMTable.SelectedAssociations.Count > 2 Then
|
||||
Return
|
||||
Else
|
||||
Dim MoveIndex As Integer = SelectedMTable.AssociationList.IndexOf(SelectedMTable.SelectedAssociations(0))
|
||||
Dim DestinationIndex As Integer = SelectedMTable.AssociationList.IndexOf(SelectedMTable.SelectedAssociations(1))
|
||||
If DestinationIndex < SelectedMTable.AssociationList.Count Then
|
||||
SelectedMTable.AssociationList.Move(MoveIndex, If(MoveIndex > DestinationIndex, DestinationIndex + 1, DestinationIndex))
|
||||
End If
|
||||
End If
|
||||
End Sub
|
||||
|
||||
@@ -1586,6 +1643,39 @@ Public Class MTableDbVM
|
||||
|
||||
#End Region ' MoveRowDownCommand
|
||||
|
||||
#Region "Link"
|
||||
|
||||
''' <summary>
|
||||
''' Returns a command that do Exec.
|
||||
''' </summary>
|
||||
Public ReadOnly Property LinkCommand As ICommand
|
||||
Get
|
||||
If m_cmdLink Is Nothing Then
|
||||
m_cmdLink = New Command(AddressOf Link)
|
||||
End If
|
||||
Return m_cmdLink
|
||||
End Get
|
||||
End Property
|
||||
|
||||
''' <summary>
|
||||
''' Execute the Exec. This method is invoked by the ExecCommand.
|
||||
''' </summary>
|
||||
Public Sub Link(param As Object)
|
||||
Dim SelectedMTable As MTableListBoxItem = DirectCast(param, MTableListBoxItem)
|
||||
If IsNothing(SelectedMTable) OrElse SelectedMTable.SelectedAssociations.Count <> 2 Then Return
|
||||
'If (SelectedMTable.SelectedAssociations(0).nLink = 0 AndAlso SelectedMTable.SelectedAssociations(1).nLink <> 0) OrElse (SelectedMTable.SelectedAssociations(0).nLink <> 0 AndAlso SelectedMTable.SelectedAssociations(1).nLink = 0) Then Return
|
||||
If SelectedMTable.SelectedAssociations(0).nLink = 0 AndAlso SelectedMTable.SelectedAssociations(1).nLink = 0 Then
|
||||
Dim nNewIndex As Integer = SelectedMTable.AssociationList.Max(Function(x) x.nLink) + 1
|
||||
SelectedMTable.SelectedAssociations(0).SetLink(nNewIndex)
|
||||
SelectedMTable.SelectedAssociations(1).SetLink(-nNewIndex)
|
||||
ElseIf SelectedMTable.SelectedAssociations(0).nLink = Math.Abs(SelectedMTable.SelectedAssociations(1).nLink) OrElse SelectedMTable.SelectedAssociations(1).nLink = Math.Abs(SelectedMTable.SelectedAssociations(0).nLink) Then
|
||||
SelectedMTable.SelectedAssociations(0).SetLink(0)
|
||||
SelectedMTable.SelectedAssociations(1).SetLink(0)
|
||||
End If
|
||||
End Sub
|
||||
|
||||
#End Region ' MoveRowDownCommand
|
||||
|
||||
#Region "GroupCommand"
|
||||
|
||||
''' <summary>
|
||||
|
||||
@@ -5,6 +5,7 @@ Imports System.IO
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
Imports EgtCAM5.MachineModel
|
||||
Imports System.Collections.Specialized
|
||||
|
||||
Public Class MTableListBoxItem
|
||||
Inherits VMBase
|
||||
@@ -148,10 +149,30 @@ Public Class MTableListBoxItem
|
||||
Private m_SelectedAssociation As MTableAssociationGridBoxItem
|
||||
Public Property SelectedAssociation As MTableAssociationGridBoxItem
|
||||
Get
|
||||
Return m_SelectedAssociation
|
||||
Return m_SelectedAssociations(0)
|
||||
End Get
|
||||
Set(value As MTableAssociationGridBoxItem)
|
||||
m_SelectedAssociation = value
|
||||
Dim bFound As Boolean = False
|
||||
For ItemIndex = m_SelectedAssociations.Count - 1 To 0 Step -1
|
||||
If m_SelectedAssociations(ItemIndex) Is value Then
|
||||
bFound = True
|
||||
Else
|
||||
m_SelectedAssociations.RemoveAt(ItemIndex)
|
||||
End If
|
||||
If Not bFound Then
|
||||
m_SelectedAssociations.Add(value)
|
||||
End If
|
||||
Next
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Private m_SelectedAssociations As New ObservableCollection(Of MTableAssociationGridBoxItem)
|
||||
Public Property SelectedAssociations As ObservableCollection(Of MTableAssociationGridBoxItem)
|
||||
Get
|
||||
Return m_SelectedAssociations
|
||||
End Get
|
||||
Set(value As ObservableCollection(Of MTableAssociationGridBoxItem))
|
||||
m_SelectedAssociations = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
@@ -169,6 +190,11 @@ Public Class MTableListBoxItem
|
||||
Sub New(sTableName As String, sTableNamePath As String)
|
||||
TableName = sTableName
|
||||
m_TableNamePath = sTableNamePath
|
||||
AddHandler m_SelectedAssociations.CollectionChanged, AddressOf SelectedAssociations_CollectionChanged
|
||||
End Sub
|
||||
|
||||
Private Sub SelectedAssociations_CollectionChanged(sender As Object, e As NotifyCollectionChangedEventArgs)
|
||||
|
||||
End Sub
|
||||
|
||||
Private Function ReadMTableFile() As Boolean
|
||||
@@ -176,7 +202,7 @@ Public Class MTableListBoxItem
|
||||
SharedMachIndex += 1
|
||||
ActiveMachinesList.Add(New MTableMachineListBoxItem(String.Empty, False, False, SharedMachIndex))
|
||||
m_MachIdList.Add(SharedMachIndex)
|
||||
AssociationList.Add(New MTableAssociationGridBoxItem(False, String.Empty, Nothing, 0, String.Empty, Nothing, String.Empty, Nothing, String.Empty, Nothing, String.Empty, ActiveMachinesList, m_AssociationList))
|
||||
AssociationList.Add(New MTableAssociationGridBoxItem(False, String.Empty, Nothing, 0, String.Empty, Nothing, String.Empty, Nothing, String.Empty, Nothing, String.Empty, 0, ActiveMachinesList, m_AssociationList))
|
||||
Return True
|
||||
End If
|
||||
' resetto indici macchine impostati in tabella
|
||||
@@ -836,7 +862,7 @@ Public Class MTableAssociationGridBoxItem
|
||||
If Not IsNothing(m_SelectedMachType) Then
|
||||
m_RefMachItem = ManageOrderedMachining(Mach, nOldMachId, RefMachItem)
|
||||
If String.IsNullOrWhiteSpace(m_Mach) Then NotifyPropertyChanged("Mach")
|
||||
End If
|
||||
End If
|
||||
If Not IsNothing(m_SelectedMachUpType) Then
|
||||
m_RefMachUpItem = ManageOrderedMachining(MachUp, nOldMachId, RefMachUpItem)
|
||||
If String.IsNullOrWhiteSpace(m_MachUp) Then NotifyPropertyChanged("MachUp")
|
||||
@@ -1074,8 +1100,33 @@ Public Class MTableAssociationGridBoxItem
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Private m_Link As Integer
|
||||
Public Property Link As String
|
||||
Get
|
||||
Return m_Link.ToString()
|
||||
End Get
|
||||
Set(value As String)
|
||||
Dim nValue As Integer = 0
|
||||
If Integer.TryParse(value, nValue) Then
|
||||
m_IsModified = True
|
||||
m_Link = nValue
|
||||
Else
|
||||
NotifyPropertyChanged(NameOf(Link))
|
||||
End If
|
||||
End Set
|
||||
End Property
|
||||
Public ReadOnly Property nLink As Integer
|
||||
Get
|
||||
Return m_Link
|
||||
End Get
|
||||
End Property
|
||||
Public Sub SetLink(value As Integer)
|
||||
m_Link = value
|
||||
NotifyPropertyChanged(NameOf(Link))
|
||||
End Sub
|
||||
|
||||
Sub New(bOn As Boolean, sName As String, nMachId As Integer, nShift As Integer, sOper As String,
|
||||
RefMachItem As MTableMachiningGridBoxItem, sMach As String, RefMachUpItem As MTableMachiningGridBoxItem, sMachUp As String, RefMachDwItem As MTableMachiningGridBoxItem, sMachDw As String,
|
||||
RefMachItem As MTableMachiningGridBoxItem, sMach As String, RefMachUpItem As MTableMachiningGridBoxItem, sMachUp As String, RefMachDwItem As MTableMachiningGridBoxItem, sMachDw As String, nLink As Integer,
|
||||
ByRef ActiveMachinesList As ObservableCollection(Of MTableMachineListBoxItem), ByRef AssociationList As ObservableCollection(Of MTableAssociationGridBoxItem))
|
||||
|
||||
OnPar = bOn
|
||||
@@ -1118,7 +1169,7 @@ Public Class MTableAssociationGridBoxItem
|
||||
' Assegno l'operazione
|
||||
Oper = sOper
|
||||
' dall'MId recupero la macchina a cui si riferisce questa associazione e la imposto come corrente
|
||||
If not IsNothing(m_ActiveMachinesList(m_MachId - 1).SelectedMachine) Then
|
||||
If Not IsNothing(m_ActiveMachinesList(m_MachId - 1).SelectedMachine) Then
|
||||
EgtSetCurrMachine(m_ActiveMachinesList(m_MachId - 1).SelectedMachine.Name)
|
||||
' Imposto MachType selezionato cercando il tipo delle lavorazioni
|
||||
If EgtMdbSetCurrMachining(sMach) Then
|
||||
@@ -1191,6 +1242,7 @@ Public Class MTableAssociationGridBoxItem
|
||||
m_RefMachDwItem = RefMachDwItem
|
||||
End If
|
||||
End If
|
||||
m_Link = nLink
|
||||
m_IsModified = False
|
||||
End Sub
|
||||
|
||||
@@ -1207,7 +1259,7 @@ Public Class MTableAssociationGridBoxItem
|
||||
End If
|
||||
Next
|
||||
End If
|
||||
' Se il nuovo valore è valido
|
||||
' Se il nuovo valore è valido
|
||||
Else
|
||||
' Se non esiste già il rispettivo item nella lista lavorazioni ordinata lo creo
|
||||
If IsNothing(RefMachItem) Then
|
||||
@@ -1223,7 +1275,7 @@ Public Class MTableAssociationGridBoxItem
|
||||
m_ActiveMachinesList(MachIndex).MachiningList.Insert(0, RefMachItem)
|
||||
End If
|
||||
Next
|
||||
' altrimenti lo aggiorno con la nuova lavorazione
|
||||
' altrimenti lo aggiorno con la nuova lavorazione
|
||||
Else
|
||||
RefMachItem.Machining = Mach
|
||||
End If
|
||||
|
||||
@@ -26,6 +26,7 @@ Module TableUtility
|
||||
Private Const MACHDW As String = "MachDw"
|
||||
Private Const MACHID As String = "MachId"
|
||||
Private Const SHIFT As String = "Shift"
|
||||
Private Const LINK As String = "Link"
|
||||
Private Const PROPERTYTABLE As String = "PropertyTable"
|
||||
Private Const OPER As String = "Oper"
|
||||
Private Const GROUP As String = "Group"
|
||||
@@ -93,6 +94,7 @@ Module TableUtility
|
||||
Dim nMachId As Integer = 1
|
||||
Dim nShift As Integer = 0
|
||||
Dim sOper As String = String.Empty
|
||||
Dim nLink As Integer = 0
|
||||
If Not String.IsNullOrEmpty(sName) Then
|
||||
Dim sOn As String = SearchKey(FileContent(LineIndex), ONCONST)
|
||||
If Not String.IsNullOrEmpty(sOn) Then
|
||||
@@ -166,7 +168,9 @@ Module TableUtility
|
||||
End If
|
||||
End If
|
||||
Next
|
||||
Table.AssociationList.Add(New MTableAssociationGridBoxItem(bOn, sName, nMachId, nShift, sOper, MachItem, sMach, MachUpItem, sMachUp, MachDwItem, sMachDw, Table.ActiveMachinesList, Table.AssociationList))
|
||||
Dim sLink As String = SearchKey(FileContent(LineIndex), LINK)
|
||||
Integer.TryParse(sLink, nLink)
|
||||
Table.AssociationList.Add(New MTableAssociationGridBoxItem(bOn, sName, nMachId, nShift, sOper, MachItem, sMach, MachUpItem, sMachUp, MachDwItem, sMachDw, nLink, Table.ActiveMachinesList, Table.AssociationList))
|
||||
End If
|
||||
End If
|
||||
If bPropertyTable Then
|
||||
@@ -237,7 +241,7 @@ Module TableUtility
|
||||
End If
|
||||
' se nessuna lavorazione, ne aggiungo una vuota
|
||||
If Table.AssociationList.Count = 0 Then
|
||||
Table.AssociationList.Add(New MTableAssociationGridBoxItem(False, String.Empty, 0, 0, String.Empty, Nothing, String.Empty, Nothing, String.Empty, Nothing, String.Empty, Table.ActiveMachinesList, Table.AssociationList))
|
||||
Table.AssociationList.Add(New MTableAssociationGridBoxItem(False, String.Empty, 0, 0, String.Empty, Nothing, String.Empty, Nothing, String.Empty, Nothing, String.Empty, 0, Table.ActiveMachinesList, Table.AssociationList))
|
||||
End If
|
||||
Return True
|
||||
End Function
|
||||
@@ -476,7 +480,8 @@ Module TableUtility
|
||||
", MachUp = '" & SelectedTable.AssociationList(Index).MachUp & "'", String.Empty) &
|
||||
If(Not String.IsNullOrEmpty(SelectedTable.AssociationList(Index).MachDw), ", MachDwOrd = '" & SelectedTable.AssociationList(Index).RefMachDwItem.RWGroupId & "'" &
|
||||
", MachDwJoin = '" & If(SelectedTable.AssociationList(Index).RefMachDwItem.Join, 1, 0) & "'" &
|
||||
", MachDw = '" & SelectedTable.AssociationList(Index).MachDw & "'", String.Empty) & " }"
|
||||
", MachDw = '" & SelectedTable.AssociationList(Index).MachDw & "'", String.Empty) &
|
||||
If(Not String.IsNullOrEmpty(SelectedTable.AssociationList(Index).Link), ", Link = '" & SelectedTable.AssociationList(Index).Link & "'", String.Empty) & " }"
|
||||
If Index < SelectedTable.AssociationList.Count - 1 Then
|
||||
CurrentLine &= " ,"
|
||||
End If
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
Imports EgtWPFLib5.MachiningTreeViewItem
|
||||
|
||||
Public Class PrepareInputBoxParam
|
||||
Friend sTitle As String
|
||||
@@ -62,4 +64,112 @@ Public Class NewMachOpParam
|
||||
Me.SelMachOpId = SelMachOpId
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
|
||||
Public Class InfoItem
|
||||
Inherits VMBase
|
||||
|
||||
#Region "FIELDS & PROPERTIES"
|
||||
|
||||
Friend nId As Integer
|
||||
''' <summary>
|
||||
''' Indice lista info note
|
||||
''' </summary>
|
||||
Public ReadOnly Property Id As Integer
|
||||
Get
|
||||
Return Id
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Friend sKey As String
|
||||
''' <summary>
|
||||
''' Chiave lista info note
|
||||
''' </summary>
|
||||
Public ReadOnly Property Key As String
|
||||
Get
|
||||
Return sKey
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Friend sValour As String
|
||||
''' <summary>
|
||||
''' Valore lista info note
|
||||
''' </summary>
|
||||
Public Property Valour As String
|
||||
Get
|
||||
Return sValour
|
||||
End Get
|
||||
Set(value As String)
|
||||
sValour = value
|
||||
NotifyPropertyChanged(NameOf(Valour))
|
||||
End Set
|
||||
End Property
|
||||
|
||||
#End Region ' Fields & Properties
|
||||
|
||||
' Comandi
|
||||
Private m_cmdRemoveInfoItem As ICommand
|
||||
Private m_cmdDoneInfo As ICommand
|
||||
|
||||
#Region "CONSTRUCTORS"
|
||||
|
||||
Sub New(nId As Integer, sKey As String, sValue As String)
|
||||
Me.nId = nId
|
||||
Me.sKey = sKey
|
||||
Me.sValour = sValue
|
||||
End Sub
|
||||
|
||||
#End Region ' Constructors
|
||||
|
||||
#Region "COMMANDS"
|
||||
|
||||
#Region "RemoveItemNoteCommand"
|
||||
|
||||
''' <summary>
|
||||
''' Comando per rimuovere l'informazione selezionata dalla combobox
|
||||
''' </summary>
|
||||
Public ReadOnly Property RemoveInfoItemCommand As ICommand
|
||||
Get
|
||||
If m_cmdRemoveInfoItem Is Nothing Then
|
||||
m_cmdRemoveInfoItem = New Command(AddressOf RemoveInfoItem)
|
||||
End If
|
||||
Return m_cmdRemoveInfoItem
|
||||
End Get
|
||||
End Property
|
||||
|
||||
''' <summary>
|
||||
''' Rimuove l'informazione selezionata dalla combobox
|
||||
''' </summary>
|
||||
''' <param name="param"></param>
|
||||
Public Sub RemoveInfoItem(ByVal param As Object)
|
||||
Map.refInputExpanderVM.RemoveItemInfo(Me)
|
||||
End Sub
|
||||
|
||||
#End Region ' RemoveItemNoteCommand
|
||||
|
||||
#Region "DoneInfoCommand"
|
||||
|
||||
''' <summary>
|
||||
''' Comando per la conferma modifica o aggiunta nuova informazione
|
||||
''' </summary>
|
||||
Public ReadOnly Property DoneInfoCommand As ICommand
|
||||
Get
|
||||
If m_cmdDoneInfo Is Nothing Then
|
||||
m_cmdDoneInfo = New Command(AddressOf DoneInfo)
|
||||
End If
|
||||
Return m_cmdDoneInfo
|
||||
End Get
|
||||
End Property
|
||||
|
||||
''' <summary>
|
||||
''' Conferma modifica o aggiunta nuova informazione
|
||||
''' </summary>
|
||||
Public Sub DoneInfo(ByVal param As Object)
|
||||
Map.refInputExpanderVM.Done(Me)
|
||||
End Sub
|
||||
|
||||
#End Region ' DoneInfoCommand
|
||||
|
||||
#End Region ' Commands
|
||||
|
||||
End Class
|
||||
@@ -219,8 +219,12 @@ Public Class TopCommandBarVM
|
||||
Dim bAllowEmpty As Boolean = (Keyboard.IsKeyDown(Key.LeftShift) OrElse Keyboard.IsKeyDown(Key.RightShift))
|
||||
' Cerco di preimpostare come corrente la macchina opportuna
|
||||
If Not bAllowEmpty AndAlso EgtGetSelectedObjCount() = 0 AndAlso EgtGetMachGroupCount() > 0 Then
|
||||
Dim nMchGrpId As Integer = EgtGetCurrMachGroup()
|
||||
If nMchGrpId = GDB_ID.NULL Then
|
||||
nMchGrpId = EgtGetFirstMachGroup()
|
||||
End If
|
||||
Dim sMachineName As String = ""
|
||||
if EgtGetMachGroupMachineName( EgtGetFirstMachGroup(), sMachineName) Then
|
||||
If EgtGetMachGroupMachineName(nMchGrpId, sMachineName) Then
|
||||
Map.refMachinePanelVM.SelectedMachine = Map.refMachinePanelVM.MachinesList.FirstOrDefault(Function(x) x.Name = sMachineName)
|
||||
End If
|
||||
End If
|
||||
@@ -232,7 +236,7 @@ Public Class TopCommandBarVM
|
||||
If EgtGetCurrMachGroup() = GDB_ID.NULL Then
|
||||
ExecExitMachScript()
|
||||
EgtDraw()
|
||||
' altrimenti, aggiusto...
|
||||
' altrimenti, aggiusto...
|
||||
Else
|
||||
' se parametri di una lavorazione aperti, disattivo database utensili, lavorazioni e setup
|
||||
Dim bIsEnabled As Boolean = Not IsNothing(Map.refOperationParametersExpanderVM) AndAlso Not Map.refOperationParametersExpanderVM.ParametersIsExpanded
|
||||
|
||||
@@ -38,7 +38,6 @@
|
||||
<EgtCAM5:DoorPanelVM x:Key="DoorsPanelViewModel"/>
|
||||
<EgtCAM5:GunStockPanelVM x:Key="GunStockPanelViewModel"/>
|
||||
<EgtCAM5:MyMachGroupPanelVM x:Key="MachGroupPanelViewModel"/>
|
||||
<EgtCAM5:WinFormPluginControlVM x:Key="WinFormPluginControlViewModel"/>
|
||||
<!--<EgtCAM5:MachGroupPanelVM x:Key="MachGroupPanelViewModel"/>-->
|
||||
<!--<EgtCAM5:OperationExpanderVM x:Key="OperationExpanderViewModel"/>-->
|
||||
|
||||
@@ -459,10 +458,6 @@
|
||||
<Style x:Key="DrawPanelButton" TargetType="{x:Type Button}" BasedOn="{StaticResource {x:Type Button}}">
|
||||
<Setter Property="Height" Value="30"/>
|
||||
<Setter Property="Width" Value="30"/>
|
||||
<Setter Property="ToolTipService.ShowOnDisabled" Value="True"/>
|
||||
<Setter Property="ContextMenuService.Placement" Value="Right"/>
|
||||
<Setter Property="ContextMenuService.HorizontalOffset" Value="-1.5"/>
|
||||
<Setter Property="ContextMenuService.VerticalOffset" Value="-3.5"/>
|
||||
</Style>
|
||||
|
||||
<Style x:Key="MachiningsTextBlock" TargetType="{x:Type TextBlock}" BasedOn="{StaticResource {x:Type TextBlock}}">
|
||||
@@ -1228,9 +1223,9 @@
|
||||
<Setter Property="Margin" Value="1,0,0,0"/>
|
||||
</Style>
|
||||
|
||||
<Style x:Key="MPExpander_UserNotesTxBxMargin" TargetType="{x:Type EgtWPFLib5:EgtTextBox}">
|
||||
<Setter Property="Margin" Value="-1,0,0,0"/>
|
||||
</Style>
|
||||
<Style x:Key="MPExpander_UserNotesTxBxMargin" TargetType="{x:Type EgtWPFLib5:EgtTextBox}">
|
||||
<Setter Property="Margin" Value="-1,0,0,0"/>
|
||||
</Style>
|
||||
|
||||
<!-- ______________________________________________________________________________________________________________________________________________ -->
|
||||
|
||||
@@ -1263,26 +1258,6 @@
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
|
||||
<Style x:Key="ListBoxItemStyle" TargetType="ListBoxItem">
|
||||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate TargetType="ListBoxItem">
|
||||
<Border Name="_Border"
|
||||
SnapsToDevicePixels="True"
|
||||
BorderBrush="{StaticResource EgaltechWhite}"
|
||||
BorderThickness="1">
|
||||
<ContentPresenter />
|
||||
</Border>
|
||||
<ControlTemplate.Triggers>
|
||||
<Trigger Property="IsSelected" Value="True">
|
||||
<Setter TargetName="_Border" Property="Background" Value="{StaticResource Button.Pressed.Background}"/>
|
||||
</Trigger>
|
||||
</ControlTemplate.Triggers>
|
||||
</ControlTemplate>
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
</Style>
|
||||
|
||||
<!-- ______________________________________________________________________________________________________________________________________________ -->
|
||||
|
||||
<!-- Style CheckBox -->
|
||||
@@ -1297,20 +1272,4 @@
|
||||
</Style.Triggers>-->
|
||||
</Style>
|
||||
|
||||
|
||||
<!-- ______________________________________________________________________________________________________________________________________________ -->
|
||||
|
||||
|
||||
<ItemsPanelTemplate x:Key="MenuItemPanelTemplate">
|
||||
<StackPanel Margin="-38,0,0,0" Background="Transparent" />
|
||||
</ItemsPanelTemplate>
|
||||
|
||||
<Style x:Key="ContextMenu_Button" TargetType="{x:Type ContextMenu}">
|
||||
<Setter Property="ItemsPanel" Value="{StaticResource MenuItemPanelTemplate}"/>
|
||||
<Setter Property="Background" Value="Transparent"/>
|
||||
<Setter Property="BorderBrush" Value="Transparent"/>
|
||||
<Setter Property="BorderThickness" Value="0"/>
|
||||
<Setter Property="Width" Value="37"/>
|
||||
</Style>
|
||||
|
||||
</ResourceDictionary>
|
||||
|
||||
@@ -288,7 +288,11 @@ Public Module IniFile
|
||||
|
||||
Friend Function IsActiveDoors() As Boolean
|
||||
Dim bIsActive As Boolean = (IniFile.m_nKeyOptions And KEY_OPT.DOORS) <> 0 And (GetPrivateProfileInt(S_DOORS, K_DDFENABLE, 0) <> 0)
|
||||
If bIsActive Then GetPrivateProfileString(S_DOORS, K_BASEDIR, "", m_sDoorsDirPath)
|
||||
If bIsActive Then
|
||||
Dim sTemp As String = ""
|
||||
GetPrivateProfileString(S_DOORS, K_BASEDIR, "", sTemp)
|
||||
m_sDoorsDirPath = sTemp.TrimEnd( "\"c)
|
||||
End If
|
||||
Return bIsActive
|
||||
End Function
|
||||
|
||||
|
||||
@@ -11,6 +11,9 @@ Public Module MachineModel
|
||||
''' </summary>
|
||||
Friend Function ReadActiveMachiningsFamilies() As MachiningsType()
|
||||
Dim ActiveMachiningsFamiliesList As New List(Of MachiningsType)
|
||||
If EgtUILib.GetPrivateProfileInt(S_MACHININGS, K_PROBING, 0, m_sCurrMachIniFilePath) <> 0 Then
|
||||
ActiveMachiningsFamiliesList.Add(New MachiningsType With {.TypeId = MCH_MY.PROBING, .TypeName = EgtMsg(31220)})
|
||||
End If
|
||||
If EgtUILib.GetPrivateProfileInt(S_MACHININGS, K_DRILLING, 0, m_sCurrMachIniFilePath) <> 0 Then
|
||||
ActiveMachiningsFamiliesList.Add(New MachiningsType With {.TypeId = MCH_MY.DRILLING, .TypeName = EgtMsg(MSG_MACHININGSDBPAGE + 1)})
|
||||
End If
|
||||
@@ -38,16 +41,16 @@ Public Module MachineModel
|
||||
If EgtUILib.GetPrivateProfileInt(S_MACHININGS, K_CHISELING, 0, m_sCurrMachIniFilePath) <> 0 Then
|
||||
ActiveMachiningsFamiliesList.Add(New MachiningsType With {.TypeId = MCH_MY.CHISELING, .TypeName = EgtMsg(MSG_MACHININGSDBPAGE + 9)})
|
||||
End If
|
||||
If EgtUILib.GetPrivateProfileInt(S_MACHININGS, K_WATERJETTING, 0, m_sCurrMachIniFilePath) <> 0 Then
|
||||
ActiveMachiningsFamiliesList.Add(New MachiningsType With {.TypeId = MCH_MY.WATERJETTING, .TypeName = EgtMsg(MSG_MACHININGSDBPAGE + 12)})
|
||||
End If
|
||||
If IniFile.IsKeyEnabledAdvancedMachining() AndAlso EgtUILib.GetPrivateProfileInt(S_MACHININGS, K_SURFROUGHING, 0, m_sCurrMachIniFilePath) <> 0 Then
|
||||
ActiveMachiningsFamiliesList.Add(New MachiningsType With {.TypeId = MCH_MY.SURFROUGHING, .TypeName = EgtMsg(31212)})
|
||||
End If
|
||||
If IniFile.IsKeyEnabledAdvancedMachining() AndAlso EgtUILib.GetPrivateProfileInt(S_MACHININGS, K_SURFFINISHING, 0, m_sCurrMachIniFilePath) <> 0 Then
|
||||
ActiveMachiningsFamiliesList.Add(New MachiningsType With {.TypeId = MCH_MY.SURFFINISHING, .TypeName = EgtMsg(31211)})
|
||||
End If
|
||||
If EgtUILib.GetPrivateProfileInt(S_MACHININGS, K_WATERJETTING, 0, m_sCurrMachIniFilePath) <> 0 Then
|
||||
ActiveMachiningsFamiliesList.Add(New MachiningsType With {.TypeId = MCH_MY.WATERJETTING, .TypeName = EgtMsg(MSG_MACHININGSDBPAGE + 12)})
|
||||
End If
|
||||
If EgtUILib.GetPrivateProfileInt(S_MACHININGS, K_5AXMILLING, 0, m_sCurrMachIniFilePath) <> 0 Then
|
||||
If IniFile.IsKeyEnabledAdvancedMachining() AndAlso EgtUILib.GetPrivateProfileInt(S_MACHININGS, K_5AXMILLING, 0, m_sCurrMachIniFilePath) <> 0 Then
|
||||
ActiveMachiningsFamiliesList.Add(New MachiningsType With {.TypeId = MCH_MY.FIVEAXISMILLING, .TypeName = EgtMsg(31213)})
|
||||
End If
|
||||
Return ActiveMachiningsFamiliesList.ToArray
|
||||
@@ -163,6 +166,9 @@ Public Module MachineModel
|
||||
''' </summary>
|
||||
Friend Function ReadActiveToolsFamilies() As ToolsFamily()
|
||||
Dim ActiveToolsFamiliesList As New List(Of ToolsFamily)
|
||||
If EgtUILib.GetPrivateProfileInt(S_TOOLS, K_PROBE, 0, m_sCurrMachIniFilePath) <> 0 Then
|
||||
ActiveToolsFamiliesList.Add(New ToolsFamily(MCH_TF.PROBE, EgtMsg(31011))) ' Tastatore
|
||||
End If
|
||||
If EgtUILib.GetPrivateProfileInt(S_TOOLS, K_DRILLBIT, 0, m_sCurrMachIniFilePath) <> 0 Then
|
||||
ActiveToolsFamiliesList.Add(New ToolsFamily(MCH_TF.DRILLBIT, EgtMsg(MSG_TOOLSDBPAGE + 1)))
|
||||
End If
|
||||
|
||||
@@ -21,6 +21,7 @@ Module SelData
|
||||
|
||||
Private m_IdSub As New List(Of SelData)
|
||||
Private m_SelGrpId As Integer = GDB_ID.NULL
|
||||
Private Const AUX_ID As String = "AuxId"
|
||||
|
||||
Friend Sub ClearIdSub()
|
||||
RemoveSelGroup()
|
||||
@@ -32,6 +33,8 @@ Module SelData
|
||||
Dim i As Integer = 0
|
||||
Do While i < m_IdSub.Count() - 1
|
||||
If Not EgtIsSelectedObj( m_IdSub( i).m_nId) Then
|
||||
Dim nAuxId As Integer = GDB_ID.NULL
|
||||
If EgtGetInfo( m_IdSub( i).m_nSel, AUX_ID, nAuxId) Then EgtErase( nAuxId)
|
||||
EgtErase( m_IdSub( i).m_nSel)
|
||||
m_IdSub.RemoveAt( i)
|
||||
Else
|
||||
@@ -56,6 +59,8 @@ Module SelData
|
||||
' Ricerca ed eliminazione del record con la coppia Id,Sub da rimuovere
|
||||
For i As Integer = 0 To m_IdSub.Count() - 1
|
||||
If m_IdSub( i).m_nId = nId And m_IdSub( i).m_nSub = nSub Then
|
||||
Dim nAuxId As Integer = GDB_ID.NULL
|
||||
If EgtGetInfo( m_IdSub( i).m_nSel, AUX_ID, nAuxId) Then EgtErase( nAuxId)
|
||||
EgtErase( m_IdSub( i).m_nSel)
|
||||
m_IdSub.RemoveAt( i)
|
||||
Exit For
|
||||
@@ -68,6 +73,8 @@ Module SelData
|
||||
' Ricerca ed eliminazione di record con identificativo da rimuovere
|
||||
For i As Integer = m_IdSub.Count() - 1 To 0 Step -1
|
||||
If m_IdSub( i).m_nId = nId Then
|
||||
Dim nAuxId As Integer = GDB_ID.NULL
|
||||
If EgtGetInfo( m_IdSub( i).m_nSel, AUX_ID, nAuxId) Then EgtErase( nAuxId)
|
||||
EgtErase( m_IdSub( i).m_nSel)
|
||||
m_IdSub.RemoveAt( i)
|
||||
End If
|
||||
@@ -153,6 +160,11 @@ Module SelData
|
||||
For nCrvId As Integer = nFirstId + 1 To nFirstId + nCount - 1
|
||||
EgtErase( nCrvId)
|
||||
Next
|
||||
Dim ptZM As New Point3d()
|
||||
EgtAtParamPoint( nFirstId, 0.5, m_SelGrpId, ptZM)
|
||||
Dim nSpheId = EgtCreateSurfTmSphere( m_SelGrpId, ptZM, 1, 0.1, GDB_RT.LOC)
|
||||
EgtSetColor( nSpheId, New Color3d( 255, 0,0))
|
||||
EgtSetInfo( nFirstId, AUX_ID, nSpheId)
|
||||
End If
|
||||
If bEnMod Then EgtEnableModified()
|
||||
Return nFirstId
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
<Grid x:Class="WinFormPluginControlV"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:EgtCAM5="clr-namespace:EgtCAM5"
|
||||
xmlns:EgtFloating="clr-namespace:EgtWPFLib5.EgtFloating;assembly=EgtWPFLib5"
|
||||
DockPanel.Dock="{Binding DockSide}"
|
||||
Height="{Binding Height}"
|
||||
Width="{Binding Width}"
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<assembly manifestVersion="1.0" xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||
<assemblyIdentity version="1.0.0.0" name="MyApplication.app"/>
|
||||
<trustInfo xmlns="urn:schemas-microsoft-com:asm.v2">
|
||||
<security>
|
||||
<requestedPrivileges xmlns="urn:schemas-microsoft-com:asm.v3">
|
||||
<!-- UAC Manifest Options
|
||||
<assemblyIdentity version="1.0.0.0" name="MyApplication.app"/>
|
||||
<trustInfo xmlns="urn:schemas-microsoft-com:asm.v2">
|
||||
<security>
|
||||
<requestedPrivileges xmlns="urn:schemas-microsoft-com:asm.v3">
|
||||
<!-- UAC Manifest Options
|
||||
If you want to change the Windows User Account Control level replace the
|
||||
requestedExecutionLevel node with one of the following.
|
||||
|
||||
@@ -16,49 +16,49 @@
|
||||
Remove this element if your application requires this virtualization for backwards
|
||||
compatibility.
|
||||
-->
|
||||
<requestedExecutionLevel level="asInvoker" uiAccess="false" />
|
||||
</requestedPrivileges>
|
||||
</security>
|
||||
</trustInfo>
|
||||
<requestedExecutionLevel level="asInvoker" uiAccess="false" />
|
||||
</requestedPrivileges>
|
||||
</security>
|
||||
</trustInfo>
|
||||
|
||||
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
|
||||
<application>
|
||||
<!-- A list of the Windows versions that this application has been tested on
|
||||
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
|
||||
<application>
|
||||
<!-- A list of the Windows versions that this application has been tested on
|
||||
and is designed to work with. Uncomment the appropriate elements
|
||||
and Windows will automatically select the most compatible environment. -->
|
||||
|
||||
<!-- Windows Vista -->
|
||||
<supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}" />
|
||||
<!-- Windows Vista -->
|
||||
<supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}" />
|
||||
|
||||
<!-- Windows 7 -->
|
||||
<supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}" />
|
||||
<!-- Windows 7 -->
|
||||
<supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}" />
|
||||
|
||||
<!-- Windows 8 -->
|
||||
<supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}" />
|
||||
<!-- Windows 8 -->
|
||||
<supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}" />
|
||||
|
||||
<!-- Windows 8.1 -->
|
||||
<supportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}" />
|
||||
<!-- Windows 8.1 -->
|
||||
<supportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}" />
|
||||
|
||||
<!-- Windows 10 -->
|
||||
<supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}" />
|
||||
<!-- Windows 10 -->
|
||||
<supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}" />
|
||||
|
||||
</application>
|
||||
</compatibility>
|
||||
</application>
|
||||
</compatibility>
|
||||
|
||||
<!-- Indicates that the application is DPI-aware and will not be automatically scaled by Windows at higher
|
||||
<!-- Indicates that the application is DPI-aware and will not be automatically scaled by Windows at higher
|
||||
DPIs. Windows Presentation Foundation (WPF) applications are automatically DPI-aware and do not need
|
||||
to opt in. Windows Forms applications targeting .NET Framework 4.6 that opt into this setting, should
|
||||
also set the 'EnableWindowsFormsHighDpiAutoResizing' setting to 'true' in their app.config. -->
|
||||
<!--
|
||||
<application xmlns="urn:schemas-microsoft-com:asm.v3">
|
||||
<windowsSettings>
|
||||
<dpiAware xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">true</dpiAware>
|
||||
</windowsSettings>
|
||||
</application>
|
||||
-->
|
||||
|
||||
<application xmlns="urn:schemas-microsoft-com:asm.v3">
|
||||
<windowsSettings>
|
||||
<dpiAware xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">true/PM</dpiAware>
|
||||
</windowsSettings>
|
||||
</application>
|
||||
|
||||
|
||||
<!-- Enable themes for Windows common controls and dialogs (Windows XP and later) -->
|
||||
<!--
|
||||
<!-- Enable themes for Windows common controls and dialogs (Windows XP and later) -->
|
||||
<!--
|
||||
<dependency>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity
|
||||
|
||||