- riattivata visualizzazione macchina su simulazione
- aggiornata icona vista tool - gestita visualizzazione strati dopo calcolo slice - uniformata textbox assi macchina in simulazione
This commit is contained in:
@@ -7,7 +7,7 @@
|
||||
Width="40"
|
||||
Style="{StaticResource SelViewSlider_ComboBox}">
|
||||
<ComboBoxItem>
|
||||
<Image Source="\Resources\SimulationPanel\HeadMode.png"
|
||||
<Image Source="\Resources\SimulationPanel\ToolMode.png"
|
||||
Style="{StaticResource ComboBox.Image}"/>
|
||||
</ComboBoxItem>
|
||||
<ComboBoxItem>
|
||||
|
||||
@@ -4,32 +4,27 @@ Imports EgtWPFLib5
|
||||
Public Class MachineViewPanelVM
|
||||
Inherits VMBase
|
||||
|
||||
Private m_nSelMachView As MCH_LOOK
|
||||
Public Property ghSelMachView As Integer
|
||||
Get
|
||||
Return m_nSelMachView - 1
|
||||
Return If(Not IsNothing(Map.refSimulationPanelVM) AndAlso Not IsNothing(Map.refSimulationPanelVM.MySimul), Map.refSimulationPanelVM.MySimul.GetMachLook() - 1, Nothing)
|
||||
End Get
|
||||
Set(value As Integer)
|
||||
m_nSelMachView = value + 1
|
||||
If Not IsNothing(Map.refSimulationPanelVM) Then
|
||||
Dim MySimul As SimulationVM = Map.refSimulationPanelVM.MySimul
|
||||
MySimul.SetMachLook(m_nSelMachView)
|
||||
If Not IsNothing(Map.refSimulationPanelVM) AndAlso Not IsNothing(Map.refSimulationPanelVM.MySimul) Then
|
||||
Map.refSimulationPanelVM.MySimul.SetMachLook(value + 1)
|
||||
' aggiorno lo stato della macchina e la sua visualizzazione
|
||||
EgtSetMachineLook(MySimul.GetMachLook())
|
||||
WriteMainPrivateProfileString(S_SIMUL, K_MACHVIEWMODE, m_nSelMachView)
|
||||
EgtSetMachineLook(Map.refSimulationPanelVM.MySimul.GetMachLook())
|
||||
WriteMainPrivateProfileString(S_SIMUL, K_MACHVIEWMODE, value + 1)
|
||||
End If
|
||||
EgtDraw()
|
||||
End Set
|
||||
End Property
|
||||
Friend Sub SetSelViewSlider(value As MCH_LOOK)
|
||||
m_nSelMachView = value
|
||||
Friend Sub RefreshSelViewSlider()
|
||||
NotifyPropertyChanged(NameOf(ghSelMachView))
|
||||
End Sub
|
||||
|
||||
Sub New()
|
||||
' leggo vista macchina da ini e la imposto
|
||||
Dim DefaultMachViewMode As Integer = GetMainPrivateProfileInt(S_SIMUL, K_MACHVIEWMODE, 3)
|
||||
SetSelViewSlider(DefaultMachViewMode)
|
||||
' Creo riferimento a questa classe in OmagOFFICEMap
|
||||
Map.SetRefMachineViewPanelVM(Me)
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
|
||||
@@ -2,146 +2,154 @@
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
|
||||
Width="310"
|
||||
xmlns:PrintApp="clr-namespace:Icarus"
|
||||
VerticalAlignment="Center">
|
||||
<Grid.Resources>
|
||||
<SolidColorBrush x:Key="SliderThumb.Track.Background" Color="{StaticResource Icarus_Blue_Color}"/>
|
||||
<SolidColorBrush x:Key="SliderThumb.Track.Border" Color="{StaticResource Icarus_Blue_Color}"/>
|
||||
</Grid.Resources>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto"/>
|
||||
<RowDefinition Height="1*"/>
|
||||
</Grid.RowDefinitions>
|
||||
<Border Margin="0,0,0,2.5"
|
||||
Style="{StaticResource Title_Border}">
|
||||
<TextBlock Text="SIMULATION"
|
||||
Style="{StaticResource Title_TextBlock}"/>
|
||||
</Border>
|
||||
<Border Grid.Row="1"
|
||||
Margin="0,2.5,0,0"
|
||||
Style="{StaticResource BottomGrayRow_Border}">
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto"/>
|
||||
<RowDefinition Height="Auto"/>
|
||||
<RowDefinition Height="Auto"/>
|
||||
</Grid.RowDefinitions>
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<PrintApp:MachineViewPanelV DataContext="{StaticResource MachineViewPanelVM}"
|
||||
Margin="0,0,5,0"/>
|
||||
<Grid Grid.Column="1"
|
||||
Width="310">
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto"/>
|
||||
<RowDefinition Height="1*"/>
|
||||
</Grid.RowDefinitions>
|
||||
<Border Margin="0,0,0,2.5"
|
||||
Style="{StaticResource Title_Border}">
|
||||
<TextBlock Text="SIMULATION"
|
||||
Style="{StaticResource Title_TextBlock}"/>
|
||||
</Border>
|
||||
<Border Grid.Row="1"
|
||||
Margin="0,2.5,0,0"
|
||||
Style="{StaticResource BottomGrayRow_Border}">
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto"/>
|
||||
<RowDefinition Height="Auto"/>
|
||||
<RowDefinition Height="Auto"/>
|
||||
</Grid.RowDefinitions>
|
||||
|
||||
<StackPanel DataContext="{Binding MySimul}"
|
||||
Margin="2.5">
|
||||
<UniformGrid Columns="3"
|
||||
Margin="0,2.5,0,2.5">
|
||||
<Button Grid.Column="0"
|
||||
Grid.Row="3"
|
||||
Command="{Binding StepCommand}"
|
||||
ToolTip="{Binding OneStepToolTip}"
|
||||
Margin="2.5,0,2.5,0"
|
||||
Style="{StaticResource SimulationPanel_Button}">
|
||||
<Image Source="/Resources/SimulationPanel/PlayStep.png"
|
||||
Style="{StaticResource SimulationButton_Image}"/>
|
||||
</Button>
|
||||
<Button Grid.Column="1"
|
||||
Grid.Row="3"
|
||||
Command="{Binding PlayPauseCommand}"
|
||||
ToolTip="{Binding PlayPauseToolTip}"
|
||||
Margin="2.5,0,2.5,0"
|
||||
Style="{StaticResource SimulationPanel_Button}">
|
||||
<Image Source="{Binding PlayPauseImage}"
|
||||
Style="{StaticResource SimulationButton_Image}"/>
|
||||
</Button>
|
||||
<Button Grid.Column="2" Grid.Row="3"
|
||||
Command="{Binding StopCommand}"
|
||||
ToolTip="{Binding StopHomeToolTip}"
|
||||
Margin="2.5,0,2.5,0"
|
||||
Style="{StaticResource SimulationPanel_Button}">
|
||||
<Image Source="/Resources/SimulationPanel/Stop.png"
|
||||
Style="{StaticResource SimulationButton_Image}"/>
|
||||
</Button>
|
||||
<StackPanel DataContext="{Binding MySimul}"
|
||||
Margin="2.5">
|
||||
<UniformGrid Columns="3"
|
||||
Margin="0,2.5,0,2.5">
|
||||
<Button Grid.Column="0"
|
||||
Grid.Row="3"
|
||||
Command="{Binding StepCommand}"
|
||||
ToolTip="{Binding OneStepToolTip}"
|
||||
Margin="2.5,0,2.5,0"
|
||||
Style="{StaticResource SimulationPanel_Button}">
|
||||
<Image Source="/Resources/SimulationPanel/PlayStep.png"
|
||||
Style="{StaticResource SimulationButton_Image}"/>
|
||||
</Button>
|
||||
<Button Grid.Column="1"
|
||||
Grid.Row="3"
|
||||
Command="{Binding PlayPauseCommand}"
|
||||
ToolTip="{Binding PlayPauseToolTip}"
|
||||
Margin="2.5,0,2.5,0"
|
||||
Style="{StaticResource SimulationPanel_Button}">
|
||||
<Image Source="{Binding PlayPauseImage}"
|
||||
Style="{StaticResource SimulationButton_Image}"/>
|
||||
</Button>
|
||||
<Button Grid.Column="2" Grid.Row="3"
|
||||
Command="{Binding StopCommand}"
|
||||
ToolTip="{Binding StopHomeToolTip}"
|
||||
Margin="2.5,0,2.5,0"
|
||||
Style="{StaticResource SimulationPanel_Button}">
|
||||
<Image Source="/Resources/SimulationPanel/Stop.png"
|
||||
Style="{StaticResource SimulationButton_Image}"/>
|
||||
</Button>
|
||||
|
||||
</UniformGrid>
|
||||
<TextBlock Text="{Binding StatusMsg}"
|
||||
TextAlignment="Center"
|
||||
Margin="2.5"
|
||||
Style="{StaticResource Simulation_TextBlock}"/>
|
||||
<Slider Name="SpeedSlider"
|
||||
Foreground="{StaticResource Icarus_Gray}"
|
||||
Value="{Binding SliderValue}"
|
||||
Minimum="1"
|
||||
Maximum="100"
|
||||
TickPlacement="TopLeft"
|
||||
TickFrequency="5"
|
||||
Margin="2.5"
|
||||
Style="{StaticResource LayerIndex_Slider}"/>
|
||||
<Grid Margin="2.5">
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="1*"/>
|
||||
<RowDefinition Height="1*"/>
|
||||
</Grid.RowDefinitions>
|
||||
<Border Style="{StaticResource SimulPanel_KeyValue_Border}">
|
||||
<TextBlock Text="{Binding TName}"
|
||||
Margin="2.5,2.5,2.5,2.5"
|
||||
Style="{StaticResource Simulation_TextBlock}"/>
|
||||
</Border>
|
||||
<Border Grid.Column="1"
|
||||
Style="{StaticResource SimulPanel_KeyValue_Border}">
|
||||
<TextBlock Text="{Binding SValue}"
|
||||
Margin="2.5,2.5,2.5,2.5"
|
||||
Style="{StaticResource Simulation_TextBlock}"/>
|
||||
</Border>
|
||||
<Border Grid.Row="1"
|
||||
Style="{StaticResource SimulPanel_KeyValue_Border}">
|
||||
<TextBlock Text="{Binding GCode}"
|
||||
Margin="2.5,2.5,2.5,2.5"
|
||||
Style="{StaticResource Simulation_TextBlock}"/>
|
||||
</Border>
|
||||
<Border Grid.Column="1"
|
||||
Grid.Row="1"
|
||||
Style="{StaticResource SimulPanel_KeyValue_Border}">
|
||||
<TextBlock Text="{Binding FValue}"
|
||||
Margin="2.5,2.5,2.5,2.5"
|
||||
Style="{StaticResource Simulation_TextBlock}"/>
|
||||
</Border>
|
||||
|
||||
</Grid>
|
||||
<ItemsControl ItemsSource="{Binding MachineAxisList}"
|
||||
</UniformGrid>
|
||||
<TextBlock Text="{Binding StatusMsg}"
|
||||
TextAlignment="Center"
|
||||
Margin="2.5"
|
||||
BorderThickness="0"
|
||||
Padding="0">
|
||||
<ItemsControl.ItemTemplate>
|
||||
<DataTemplate>
|
||||
<Border Style="{StaticResource SimulPanel_KeyValue_Border}"
|
||||
Margin="0,1,0,1">
|
||||
<Grid>
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<TextBlock Text="{Binding Token}"
|
||||
Style="{StaticResource Simulation_TextBlock}"/>
|
||||
<EgtWPFLib5:EgtTextBox Grid.Column="1"
|
||||
BorderThickness="0"
|
||||
Text="{Binding Value, UpdateSourceTrigger=Explicit}"
|
||||
IsReadOnly="{Binding IsReadOnlyAxesValue}"
|
||||
IsEnabled="{Binding IsEnabledAxesValue}"
|
||||
Style="{StaticResource SimulationPanel_Axes_TextBox}">
|
||||
</EgtWPFLib5:EgtTextBox>
|
||||
</Grid>
|
||||
</Border>
|
||||
</DataTemplate>
|
||||
</ItemsControl.ItemTemplate>
|
||||
</ItemsControl>
|
||||
</StackPanel>
|
||||
<Button Grid.Row="3"
|
||||
Command="{Binding Ok_Command}"
|
||||
Style="{StaticResource RightPanel_HalfRound_Button}">
|
||||
<Image Source="\Resources\Common\Ok.png"
|
||||
Style="{StaticResource Button_Image}"/>
|
||||
</Button>
|
||||
</Grid>
|
||||
</Border>
|
||||
Style="{StaticResource Simulation_TextBlock}"/>
|
||||
<Slider Name="SpeedSlider"
|
||||
Foreground="{StaticResource Icarus_Gray}"
|
||||
Value="{Binding SliderValue}"
|
||||
Minimum="1"
|
||||
Maximum="100"
|
||||
TickPlacement="TopLeft"
|
||||
TickFrequency="5"
|
||||
Margin="2.5"
|
||||
Style="{StaticResource LayerIndex_Slider}"/>
|
||||
<Grid Margin="2.5">
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="1*"/>
|
||||
<RowDefinition Height="1*"/>
|
||||
</Grid.RowDefinitions>
|
||||
<Border Style="{StaticResource SimulPanel_KeyValue_Border}">
|
||||
<TextBlock Text="{Binding TName}"
|
||||
Margin="2.5,2.5,2.5,2.5"
|
||||
Style="{StaticResource Simulation_TextBlock}"/>
|
||||
</Border>
|
||||
<Border Grid.Column="1"
|
||||
Style="{StaticResource SimulPanel_KeyValue_Border}">
|
||||
<TextBlock Text="{Binding SValue}"
|
||||
Margin="2.5,2.5,2.5,2.5"
|
||||
Style="{StaticResource Simulation_TextBlock}"/>
|
||||
</Border>
|
||||
<Border Grid.Row="1"
|
||||
Style="{StaticResource SimulPanel_KeyValue_Border}">
|
||||
<TextBlock Text="{Binding GCode}"
|
||||
Margin="2.5,2.5,2.5,2.5"
|
||||
Style="{StaticResource Simulation_TextBlock}"/>
|
||||
</Border>
|
||||
<Border Grid.Column="1"
|
||||
Grid.Row="1"
|
||||
Style="{StaticResource SimulPanel_KeyValue_Border}">
|
||||
<TextBlock Text="{Binding FValue}"
|
||||
Margin="2.5,2.5,2.5,2.5"
|
||||
Style="{StaticResource Simulation_TextBlock}"/>
|
||||
</Border>
|
||||
|
||||
</Grid>
|
||||
<ItemsControl ItemsSource="{Binding MachineAxisList}"
|
||||
Margin="2.5"
|
||||
BorderThickness="0"
|
||||
Padding="0">
|
||||
<ItemsControl.ItemTemplate>
|
||||
<DataTemplate>
|
||||
<Border Style="{StaticResource SimulPanel_KeyValue_Border}"
|
||||
Margin="0,1,0,1">
|
||||
<Grid>
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<TextBlock Text="{Binding Token}"
|
||||
Style="{StaticResource Simulation_TextBlock}"/>
|
||||
<EgtWPFLib5:EgtTextBox2 Grid.Column="1"
|
||||
BorderThickness="0"
|
||||
Text="{Binding Value, UpdateSourceTrigger=Explicit}"
|
||||
IsReadOnly="{Binding IsReadOnlyAxesValue}"
|
||||
IsEnabled="{Binding IsEnabledAxesValue}"
|
||||
Style="{StaticResource SimulationPanel_Axes_TextBox}">
|
||||
</EgtWPFLib5:EgtTextBox2>
|
||||
</Grid>
|
||||
</Border>
|
||||
</DataTemplate>
|
||||
</ItemsControl.ItemTemplate>
|
||||
</ItemsControl>
|
||||
</StackPanel>
|
||||
<Button Grid.Row="3"
|
||||
Command="{Binding Ok_Command}"
|
||||
Style="{StaticResource RightPanel_HalfRound_Button}">
|
||||
<Image Source="\Resources\Common\Ok.png"
|
||||
Style="{StaticResource Button_Image}"/>
|
||||
</Button>
|
||||
</Grid>
|
||||
</Border>
|
||||
</Grid>
|
||||
</Grid>
|
||||
|
||||
@@ -52,6 +52,10 @@ Public Class SimulationPanelVM
|
||||
' Creo riferimento a questa classe in OmagOFFICEMap
|
||||
Map.SetRefSimulationPanelVM(Me)
|
||||
MySimul = New MySimulation
|
||||
' leggo vista macchina da ini e la imposto
|
||||
Dim DefaultMachViewMode As Integer = GetMainPrivateProfileInt(S_SIMUL, K_MACHVIEWMODE, 3)
|
||||
MySimul.SetMachLook(DefaultMachViewMode)
|
||||
Map.refMachineViewPanelVM.RefreshSelViewSlider()
|
||||
End Sub
|
||||
|
||||
#End Region ' CONSTRUCTOR
|
||||
@@ -76,7 +80,6 @@ Public Class SimulationPanelVM
|
||||
'Cambio la vista della scena
|
||||
EgtGetGenericView(m_dPrevAngVertDegView, m_dPrevAngHorizDegView)
|
||||
EgtSetView(VT.ISO_SW, False)
|
||||
MySimul.SetMachLook(MCH_LOOK.ALL)
|
||||
EgtSetMachineLook(MySimul.GetMachLook())
|
||||
' Nascondo griglia
|
||||
EgtSetGridShow(False, False)
|
||||
@@ -111,6 +114,7 @@ Public Class SimulationPanelVM
|
||||
Map.refSliderManagerVM.SetLayerIndexIsEnabled(False)
|
||||
Map.refSliderManagerVM.SetLayerAdvancementIsEnabled(False)
|
||||
Map.refInstrumentPanelVM.SetEdgeAnalysisIsEnabled(False)
|
||||
EgtDraw()
|
||||
End Sub
|
||||
|
||||
Private Function LoadCurrTools() As Boolean
|
||||
@@ -138,9 +142,6 @@ Public Class SimulationPanelVM
|
||||
Map.refMyStatusBarVM.ClearOutputMessage()
|
||||
' Mi assicuro di terminare la simulazione
|
||||
MySimul.ResetSimulation()
|
||||
' Ripristino visibilità standard
|
||||
MySimul.SetMachLook(MCH_LOOK.TAB)
|
||||
EgtSetMachineLook(MySimul.GetMachLook())
|
||||
'' Nascondo tutte le lavorazioni
|
||||
'CamAuto.HideAllMachinings()
|
||||
' Abilito impostazione modificato
|
||||
|
||||
@@ -36,6 +36,11 @@ Public Class SliceManagerVM
|
||||
Private m_bStopScriptToManage As Boolean = False
|
||||
|
||||
Private m_bSlice As Boolean = False
|
||||
Friend ReadOnly Property bSlice As Boolean
|
||||
Get
|
||||
Return m_bSlice
|
||||
End Get
|
||||
End Property
|
||||
Private m_bCalcTFS As Boolean = False
|
||||
Private m_bGenerate As Boolean = False
|
||||
Private m_bCalcSolid As Boolean = False
|
||||
@@ -433,9 +438,6 @@ Public Class SliceManagerVM
|
||||
Map.refSliderManagerVM.SetLayerIndexIsEnabled(True)
|
||||
Map.refSliderManagerVM.SetLayerAdvancementIsEnabled(True)
|
||||
SetButtonsIsEnabled(True)
|
||||
m_bSlice = False
|
||||
m_bCalcTFS = False
|
||||
m_bGenerate = False
|
||||
Return bOk
|
||||
End Function
|
||||
|
||||
@@ -543,8 +545,6 @@ Public Class SliceManagerVM
|
||||
m_bCalculating = False
|
||||
Return
|
||||
End If
|
||||
'' esco da altre pagine
|
||||
'Dim PreviousPage As Pages = Map.refTopPanelVM.SelPage
|
||||
' eseguo calcoli
|
||||
CalcSlice(False)
|
||||
' se non ho interrotto calcoli
|
||||
@@ -554,11 +554,16 @@ Public Class SliceManagerVM
|
||||
Map.refSliderManagerVM.SetLayerIndexToMax()
|
||||
NotifyPropertyChanged(NameOf(Time_Visibility))
|
||||
NotifyPropertyChanged(NameOf(Mass_Visibility))
|
||||
'Else
|
||||
' Map.refTopPanelVM.SelPage = PreviousPage
|
||||
' se ricalcolato slice attivo vista SliceToolpath e modo TillSelected
|
||||
If m_bSlice Then
|
||||
Map.refSliderManagerVM.SetSelViewSlider(SliderManagerVM.ViewSliderType.UNTIL_SELECTED)
|
||||
End If
|
||||
Else
|
||||
m_bStopScriptToManage = False
|
||||
End If
|
||||
m_bSlice = False
|
||||
m_bCalcTFS = False
|
||||
m_bGenerate = False
|
||||
m_bCalculating = False
|
||||
End Sub
|
||||
|
||||
|
||||
@@ -368,7 +368,7 @@ Public Class SliderManagerVM
|
||||
End Set
|
||||
End Property
|
||||
Friend Sub SetSelViewSlider(value As ViewSliderType)
|
||||
m_nSelViewSlider = value
|
||||
ghSelViewSlider = value - 1
|
||||
NotifyPropertyChanged(NameOf(ghSelViewSlider))
|
||||
End Sub
|
||||
|
||||
@@ -381,7 +381,8 @@ Public Class SliderManagerVM
|
||||
Map.SetRefSliderManagerVM(Me)
|
||||
' leggo valore default ViewSlider
|
||||
Dim nViewSlider As Integer = GetMainPrivateProfileInt(S_PRINTING3D, K_VIEWSLIDER, 1)
|
||||
SetSelViewSlider(nViewSlider)
|
||||
m_nSelViewSlider = nViewSlider
|
||||
NotifyPropertyChanged(NameOf(ghSelViewSlider))
|
||||
End Sub
|
||||
|
||||
#End Region ' CONSTRUCTOR
|
||||
|
||||
@@ -832,6 +832,9 @@
|
||||
|
||||
<!-- TextBox -->
|
||||
|
||||
<SolidColorBrush x:Key="TextBox.MouseOver.Border" Color="#FF7EB4EA"/>
|
||||
<SolidColorBrush x:Key="TextBox.Focus.Border" Color="#FF569DE5"/>
|
||||
|
||||
<Style TargetType="{x:Type EgtWPFLib5:EgtTextBox}" BasedOn="{StaticResource {x:Type EgtWPFLib5:EgtTextBox}}">
|
||||
<Setter Property="Height" Value="22"/>
|
||||
<Setter Property="FontFamily" Value="/Resources/Fonts/#Roboto"/>
|
||||
@@ -918,11 +921,116 @@
|
||||
<Setter Property="TextAlignment" Value="Center"/>
|
||||
</Style>
|
||||
|
||||
<Style x:Key="SimulationPanel_Axes_TextBox" TargetType="{x:Type EgtWPFLib5:EgtTextBox}" BasedOn="{StaticResource {x:Type EgtWPFLib5:EgtTextBox}}">
|
||||
<Style x:Key="SimulationPanel_Axes_TextBox" TargetType="{x:Type EgtWPFLib5:EgtTextBox2}" BasedOn="{StaticResource {x:Type EgtWPFLib5:EgtTextBox2}}">
|
||||
<Setter Property="FontSize" Value="18"/>
|
||||
<Setter Property="BorderThickness" Value="0"/>
|
||||
<Setter Property="VerticalAlignment" Value="Center"/>
|
||||
<Setter Property="TextAlignment" Value="Center"/>
|
||||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate TargetType="{x:Type EgtWPFLib5:EgtTextBox2}">
|
||||
<TextBox Name="PART_TextBox"
|
||||
AcceptsReturn="{TemplateBinding AcceptsReturn}"
|
||||
AcceptsTab="{TemplateBinding AcceptsTab}"
|
||||
AllowDrop="{TemplateBinding AllowDrop}"
|
||||
Background="{TemplateBinding Background}"
|
||||
BorderBrush="{TemplateBinding BorderBrush}"
|
||||
BorderThickness="{TemplateBinding BorderThickness}"
|
||||
CacheMode="{TemplateBinding CacheMode}"
|
||||
CaretBrush="{TemplateBinding CaretBrush}"
|
||||
CharacterCasing="{TemplateBinding CharacterCasing}"
|
||||
Clip="{TemplateBinding Clip}"
|
||||
ClipToBounds="{TemplateBinding ClipToBounds}"
|
||||
ContextMenu="{TemplateBinding ContextMenu}"
|
||||
Cursor="{TemplateBinding Cursor}"
|
||||
DataContext="{TemplateBinding DataContext}"
|
||||
Effect="{TemplateBinding Effect}"
|
||||
FlowDirection="{TemplateBinding FlowDirection}"
|
||||
Focusable="{TemplateBinding Focusable}"
|
||||
FocusVisualStyle="{TemplateBinding FocusVisualStyle}"
|
||||
FontFamily="{TemplateBinding FontFamily}"
|
||||
FontSize="{TemplateBinding FontSize}"
|
||||
FontStretch="{TemplateBinding FontStretch}"
|
||||
FontWeight="{TemplateBinding FontWeight}"
|
||||
ForceCursor="{TemplateBinding ForceCursor}"
|
||||
Foreground="{TemplateBinding Foreground}"
|
||||
Height="{TemplateBinding Height}"
|
||||
HorizontalAlignment="{TemplateBinding HorizontalAlignment}"
|
||||
HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}"
|
||||
HorizontalScrollBarVisibility="{TemplateBinding HorizontalScrollBarVisibility}"
|
||||
InputScope="{TemplateBinding InputScope}"
|
||||
IsEnabled="{TemplateBinding IsEnabled}"
|
||||
IsHitTestVisible="{TemplateBinding IsHitTestVisible}"
|
||||
IsManipulationEnabled="{TemplateBinding IsManipulationEnabled}"
|
||||
IsReadOnly="{TemplateBinding IsReadOnly}"
|
||||
IsTabStop="{TemplateBinding IsTabStop}"
|
||||
IsReadOnlyCaretVisible="{TemplateBinding IsReadOnlyCaretVisible}"
|
||||
IsUndoEnabled="{TemplateBinding IsUndoEnabled}"
|
||||
Language="{TemplateBinding Language}"
|
||||
LayoutTransform="{TemplateBinding LayoutTransform}"
|
||||
Margin="0"
|
||||
MaxHeight="{TemplateBinding MaxHeight}"
|
||||
MaxLength="{TemplateBinding MaxLength}"
|
||||
MaxLines="{TemplateBinding MaxLines}"
|
||||
MaxWidth="{TemplateBinding MaxWidth}"
|
||||
MinHeight="{TemplateBinding MinHeight}"
|
||||
MinLines="{TemplateBinding MinLines}"
|
||||
MinWidth="{TemplateBinding MinWidth}"
|
||||
Opacity="{TemplateBinding Opacity}"
|
||||
OpacityMask="{TemplateBinding OpacityMask}"
|
||||
OverridesDefaultStyle="{TemplateBinding OverridesDefaultStyle}"
|
||||
Padding="{TemplateBinding Padding}"
|
||||
RenderTransform="{TemplateBinding RenderTransform}"
|
||||
RenderTransformOrigin="{TemplateBinding RenderTransformOrigin}"
|
||||
SelectionBrush="{TemplateBinding SelectionBrush}"
|
||||
SelectionOpacity="{TemplateBinding SelectionOpacity}"
|
||||
SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"
|
||||
TabIndex="{TemplateBinding TabIndex}"
|
||||
Tag="{TemplateBinding Tag}"
|
||||
TextAlignment="{TemplateBinding TextAlignment}"
|
||||
TextDecorations="{TemplateBinding TextDecorations}"
|
||||
TextWrapping="{TemplateBinding TextWrapping}"
|
||||
ToolTip="{TemplateBinding ToolTip}"
|
||||
Uid="{TemplateBinding Uid}"
|
||||
UndoLimit="{TemplateBinding UndoLimit}"
|
||||
UseLayoutRounding="{TemplateBinding UseLayoutRounding}"
|
||||
VerticalAlignment="{TemplateBinding VerticalAlignment}"
|
||||
VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}"
|
||||
VerticalScrollBarVisibility="{TemplateBinding VerticalScrollBarVisibility}"
|
||||
Visibility="{TemplateBinding Visibility}"
|
||||
Width="{TemplateBinding Width}">
|
||||
<TextBox.Style>
|
||||
<Style TargetType="{x:Type TextBox}">
|
||||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate TargetType="{x:Type TextBox}">
|
||||
<Border x:Name="border" Background="{TemplateBinding Background}"
|
||||
BorderBrush="{TemplateBinding BorderBrush}"
|
||||
BorderThickness="{TemplateBinding BorderThickness}"
|
||||
SnapsToDevicePixels="True">
|
||||
<ScrollViewer x:Name="PART_ContentHost"
|
||||
Focusable="false"
|
||||
HorizontalScrollBarVisibility="Hidden"
|
||||
VerticalScrollBarVisibility="Hidden"/>
|
||||
</Border>
|
||||
<ControlTemplate.Triggers>
|
||||
<Trigger Property="IsMouseOver" Value="true">
|
||||
<Setter Property="BorderBrush" TargetName="border" Value="{StaticResource TextBox.MouseOver.Border}"/>
|
||||
</Trigger>
|
||||
<Trigger Property="IsKeyboardFocused" Value="true">
|
||||
<Setter Property="BorderBrush" TargetName="border" Value="{StaticResource TextBox.Focus.Border}"/>
|
||||
</Trigger>
|
||||
</ControlTemplate.Triggers>
|
||||
</ControlTemplate>
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
</Style>
|
||||
</TextBox.Style>
|
||||
</TextBox>
|
||||
</ControlTemplate>
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
|
||||
</Style>
|
||||
|
||||
<Style x:Key="AboutBox_TextBox" TargetType="{x:Type TextBox}" BasedOn="{StaticResource {x:Type TextBox}}">
|
||||
|
||||
@@ -33,6 +33,7 @@ Module Map
|
||||
Private m_refFilledSolidParamPanelVM As FilledSolidParamPanelVM
|
||||
Private m_refSplashScreen As SplashScreen
|
||||
Private m_refManagePartPanelVM As ManagePartPanelVM
|
||||
Private m_refMachineViewPanelVM As MachineViewPanelVM
|
||||
|
||||
#Region "Get"
|
||||
|
||||
@@ -233,6 +234,12 @@ Module Map
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Public ReadOnly Property refMachineViewPanelVM As MachineViewPanelVM
|
||||
Get
|
||||
Return m_refMachineViewPanelVM
|
||||
End Get
|
||||
End Property
|
||||
|
||||
#End Region ' Get
|
||||
|
||||
#Region "Set"
|
||||
@@ -391,6 +398,11 @@ Module Map
|
||||
Return Not IsNothing(m_refManagePartPanelVM)
|
||||
End Function
|
||||
|
||||
Friend Function SetRefMachineViewPanelVM(MachineViewPanelVM As MachineViewPanelVM) As Boolean
|
||||
m_refMachineViewPanelVM = MachineViewPanelVM
|
||||
Return Not IsNothing(m_refMachineViewPanelVM)
|
||||
End Function
|
||||
|
||||
#End Region ' Set
|
||||
|
||||
#Region "Init"
|
||||
|
||||
@@ -133,20 +133,15 @@ Public Class ViewLayer
|
||||
Return
|
||||
End If
|
||||
m_IsVisible = If(value, VisibilityType.ON_, VisibilityType.OFF)
|
||||
'If Not bIsVisible AndAlso ((m_Type = ViewLayerType.REFERENCE AndAlso Map.refTopPanelVM.SelModifyMode.ModifyMode = ModifyModes.REFERENCE) OrElse
|
||||
' (m_Type = ViewLayerType.START_MACHINING AndAlso Map.refTopPanelVM.SelModifyMode.ModifyMode = ModifyModes.STARTMACH) OrElse
|
||||
' (m_Type = ViewLayerType.RIBS AndAlso Map.refTopPanelVM.SelModifyMode.ModifyMode = ModifyModes.RIBS) OrElse
|
||||
' (m_Type = ViewLayerType.SHELL_NUMBER AndAlso Map.refTopPanelVM.SelModifyMode.ModifyMode = ModifyModes.SHELLNUMBER) OrElse
|
||||
' (m_Type = ViewLayerType.AUX_SOLIDS AndAlso Map.refTopPanelVM.SelModifyMode.ModifyMode = ModifyModes.AUXSOLIDS)) Then
|
||||
' m_bIsVisible = True
|
||||
' NotifyPropertyChanged(NameOf(bIsVisible))
|
||||
'Else
|
||||
UpdateVisibility(m_IsVisible)
|
||||
WriteIsVisibleToIni()
|
||||
EgtDraw()
|
||||
'End If
|
||||
End Set
|
||||
End Property
|
||||
Friend Sub SetIsVisible(value As Boolean?)
|
||||
bIsVisible = value
|
||||
NotifyPropertyChanged(NameOf(bIsVisible))
|
||||
End Sub
|
||||
|
||||
Sub New(Type As ViewLayerType, sName As String, bIsVisible As Boolean)
|
||||
m_Type = Type
|
||||
@@ -313,9 +308,17 @@ Public Class ViewLayer
|
||||
Case ViewLayerType.AUX_SOLIDS
|
||||
nStatus = GetMainPrivateProfileInt(S_VIEWLAYER, K_SLC_AUXSOLIDS, 1)
|
||||
Case ViewLayerType.SOLID_SLICE
|
||||
nStatus = GetMainPrivateProfileInt(S_VIEWLAYER, K_SLC_SOLIDSLICE, 1)
|
||||
If Map.refSliceManagerVM.bCalculating AndAlso Map.refSliceManagerVM.bSlice Then
|
||||
nStatus = 1
|
||||
Else
|
||||
nStatus = GetMainPrivateProfileInt(S_VIEWLAYER, K_SLC_SOLIDSLICE, 1)
|
||||
End If
|
||||
Case ViewLayerType.SLICE_TOOLPATH
|
||||
nStatus = GetMainPrivateProfileInt(S_VIEWLAYER, K_SLC_SLICETOOLPATH, 1)
|
||||
If Map.refSliceManagerVM.bCalculating AndAlso Map.refSliceManagerVM.bSlice Then
|
||||
nStatus = 1
|
||||
Else
|
||||
nStatus = GetMainPrivateProfileInt(S_VIEWLAYER, K_SLC_SLICETOOLPATH, 1)
|
||||
End If
|
||||
Case ViewLayerType.OTHERS
|
||||
nStatus = GetMainPrivateProfileInt(S_VIEWLAYER, K_SLC_OTHERS, 1)
|
||||
End Select
|
||||
|
||||
Reference in New Issue
Block a user