|
@@ -3,12 +3,16 @@
|
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
|
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
|
|
- xmlns:i="http://schemas.microsoft.com/expression/2010/interactivity"
|
|
|
+ xmlns:i="clr-namespace:System.Windows.Interactivity;assembly=System.Windows.Interactivity"
|
|
|
xmlns:cal="http://www.caliburn.org"
|
|
|
+ xmlns:unity="clr-namespace:Venus_MainPages.Unity"
|
|
|
+ xmlns:userControls="clr-namespace:Venus_Themes.UserControls;assembly=Venus_Themes"
|
|
|
+ xmlns:wfi ="clr-namespace:System.Windows.Forms.Integration;assembly=WindowsFormsIntegration"
|
|
|
prism:ViewModelLocator.AutoWireViewModel="True"
|
|
|
xmlns:prism="http://prismlibrary.com/"
|
|
|
xmlns:ctrl="http://OpenSEMI.Ctrlib.com/presentation"
|
|
|
- mc:Ignorable="d" >
|
|
|
+ mc:Ignorable="d"
|
|
|
+ x:Name="stastic">
|
|
|
<Grid HorizontalAlignment="Left">
|
|
|
<Grid.RowDefinitions>
|
|
|
<RowDefinition Height="300"/>
|
|
@@ -17,8 +21,7 @@
|
|
|
<TabControl Grid.Row="0">
|
|
|
<TabItem Header="Statistic Item List ">
|
|
|
|
|
|
- <DataGrid Grid.Row="1" AlternationCount="2" HorizontalAlignment="Left" CanUserAddRows="False" AutoGenerateColumns="False" RowHeaderWidth="0"
|
|
|
- VirtualizingPanel.IsVirtualizing="True" VirtualizingPanel.VirtualizationMode="Recycling"
|
|
|
+ <DataGrid Grid.Row="1" AlternationCount="2" HorizontalAlignment="Left" CanUserAddRows="False" AutoGenerateColumns="False" RowHeaderWidth="0"
|
|
|
ItemsSource="{Binding StatData}" Margin="0,5,0,0" >
|
|
|
|
|
|
<DataGrid.Columns>
|
|
@@ -50,14 +53,8 @@
|
|
|
<DataGridTemplateColumn Width="130">
|
|
|
<DataGridTemplateColumn.CellTemplate>
|
|
|
<DataTemplate>
|
|
|
- <Button Content="Reset Value" Width="120" Height="25" FontSize="12">
|
|
|
- <i:Interaction.Triggers>
|
|
|
- <i:EventTrigger EventName="Click">
|
|
|
- <cal:ActionMessage MethodName="ResetValue">
|
|
|
- <cal:Parameter Value="{Binding }" />
|
|
|
- </cal:ActionMessage>
|
|
|
- </i:EventTrigger>
|
|
|
- </i:Interaction.Triggers>
|
|
|
+ <Button Content="Reset Value" Command="{Binding DataContext.ResetValueCommnad, ElementName=stastic}" Width="120" Height="25" FontSize="12">
|
|
|
+ <!--Command="{Binding DataContext.ResetValueCommnad,RelativeSource={RelativeSource Mode=FindAncestor,AncestorType=UserControl}}"-->
|
|
|
</Button>
|
|
|
</DataTemplate>
|
|
|
</DataGridTemplateColumn.CellTemplate>
|
|
@@ -66,17 +63,13 @@
|
|
|
<DataGridTemplateColumn Header="Enable Warning" Width="120">
|
|
|
<DataGridTemplateColumn.CellTemplate>
|
|
|
<DataTemplate>
|
|
|
- <CheckBox Height="35" Width="35" VerticalContentAlignment="Center" IsChecked="{Binding WarningEnable, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}">
|
|
|
+ <CheckBox IsChecked="{Binding WarningEnable,Mode=TwoWay}" VerticalAlignment="Center" HorizontalAlignment="Center" >
|
|
|
<i:Interaction.Triggers>
|
|
|
<i:EventTrigger EventName="Checked">
|
|
|
- <cal:ActionMessage MethodName="ResetEnableWarning">
|
|
|
- <cal:Parameter Value="{Binding }" />
|
|
|
- </cal:ActionMessage>
|
|
|
+ <i:InvokeCommandAction Command="{Binding DataContext.ResetEnableValueCommnad, ElementName=stastic}" CommandParameter="{Binding }" />
|
|
|
</i:EventTrigger>
|
|
|
<i:EventTrigger EventName="Unchecked">
|
|
|
- <cal:ActionMessage MethodName="ResetEnableWarning">
|
|
|
- <cal:Parameter Value="{Binding }" />
|
|
|
- </cal:ActionMessage>
|
|
|
+ <i:InvokeCommandAction Command="{Binding DataContext.ResetEnableValueCommnad, ElementName=stastic}" CommandParameter="{Binding }"/>
|
|
|
</i:EventTrigger>
|
|
|
</i:Interaction.Triggers>
|
|
|
</CheckBox>
|
|
@@ -104,15 +97,8 @@
|
|
|
<DataGridTemplateColumn Width="80">
|
|
|
<DataGridTemplateColumn.CellTemplate>
|
|
|
<DataTemplate>
|
|
|
- <Button Content="Set" Width="60" Height="25" FontSize="12">
|
|
|
- <i:Interaction.Triggers>
|
|
|
- <i:EventTrigger EventName="Click">
|
|
|
- <cal:ActionMessage MethodName="SetWarningValue">
|
|
|
- <cal:Parameter Value="{Binding }" />
|
|
|
- </cal:ActionMessage>
|
|
|
- </i:EventTrigger>
|
|
|
- </i:Interaction.Triggers>
|
|
|
- </Button>
|
|
|
+ <Button Content="Set" Width="60" Command="{Binding DataContext.SetWarningValueCommnad, ElementName=stastic}" Height="25" FontSize="12"/>
|
|
|
+
|
|
|
</DataTemplate>
|
|
|
</DataGridTemplateColumn.CellTemplate>
|
|
|
</DataGridTemplateColumn>
|
|
@@ -120,17 +106,13 @@
|
|
|
<DataGridTemplateColumn Header="Enable Alarm" Width="120">
|
|
|
<DataGridTemplateColumn.CellTemplate>
|
|
|
<DataTemplate>
|
|
|
- <CheckBox Height="35" Width="35" VerticalContentAlignment="Center" IsChecked="{Binding AlarmEnable, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}">
|
|
|
+ <CheckBox IsChecked="{Binding AlarmEnable,Mode=TwoWay}" VerticalAlignment="Center" HorizontalAlignment="Center" >
|
|
|
<i:Interaction.Triggers>
|
|
|
<i:EventTrigger EventName="Checked">
|
|
|
- <cal:ActionMessage MethodName="ResetEnableAlarm">
|
|
|
- <cal:Parameter Value="{Binding }" />
|
|
|
- </cal:ActionMessage>
|
|
|
+ <i:InvokeCommandAction Command="{Binding DataContext.ResetEnableAlarmCommnad, ElementName=stastic}" CommandParameter="{Binding }" />
|
|
|
</i:EventTrigger>
|
|
|
<i:EventTrigger EventName="Unchecked">
|
|
|
- <cal:ActionMessage MethodName="ResetEnableAlarm">
|
|
|
- <cal:Parameter Value="{Binding }" />
|
|
|
- </cal:ActionMessage>
|
|
|
+ <i:InvokeCommandAction Command="{Binding DataContext.ResetEnableAlarmCommnad, ElementName=stastic}" CommandParameter="{Binding }"/>
|
|
|
</i:EventTrigger>
|
|
|
</i:Interaction.Triggers>
|
|
|
</CheckBox>
|
|
@@ -158,14 +140,7 @@
|
|
|
<DataGridTemplateColumn Width="80">
|
|
|
<DataGridTemplateColumn.CellTemplate>
|
|
|
<DataTemplate>
|
|
|
- <Button Content="Set" Width="60" Height="25" FontSize="12">
|
|
|
- <i:Interaction.Triggers>
|
|
|
- <i:EventTrigger EventName="Click">
|
|
|
- <cal:ActionMessage MethodName="SetAlarmValue">
|
|
|
- <cal:Parameter Value="{Binding }" />
|
|
|
- </cal:ActionMessage>
|
|
|
- </i:EventTrigger>
|
|
|
- </i:Interaction.Triggers>
|
|
|
+ <Button Content="Set" Width="60" Command="{Binding DataContext.SetAlarmValueCommnad, ElementName=stastic}" Height="25" FontSize="12">
|
|
|
</Button>
|
|
|
</DataTemplate>
|
|
|
</DataGridTemplateColumn.CellTemplate>
|
|
@@ -191,14 +166,7 @@
|
|
|
<DataGridTemplateColumn Width="130" >
|
|
|
<DataGridTemplateColumn.CellTemplate>
|
|
|
<DataTemplate>
|
|
|
- <Button Content="Reset Total" Width="120" Height="25" FontSize="12">
|
|
|
- <i:Interaction.Triggers>
|
|
|
- <i:EventTrigger EventName="Click">
|
|
|
- <cal:ActionMessage MethodName="ResetTotalValue">
|
|
|
- <cal:Parameter Value="{Binding }" />
|
|
|
- </cal:ActionMessage>
|
|
|
- </i:EventTrigger>
|
|
|
- </i:Interaction.Triggers>
|
|
|
+ <Button Content="Reset Total" Command="{Binding DataContext.ResetTotalValue, ElementName=stastic}" Width="120" Height="25" FontSize="12">
|
|
|
</Button>
|
|
|
</DataTemplate>
|
|
|
</DataGridTemplateColumn.CellTemplate>
|
|
@@ -246,14 +214,7 @@
|
|
|
<DataGridTemplateColumn Width="130">
|
|
|
<DataGridTemplateColumn.CellTemplate>
|
|
|
<DataTemplate>
|
|
|
- <Button Content="Reset Value" Width="120" Height="25" FontSize="12">
|
|
|
- <i:Interaction.Triggers>
|
|
|
- <i:EventTrigger EventName="Click">
|
|
|
- <cal:ActionMessage MethodName="ResetTimeValue">
|
|
|
- <cal:Parameter Value="{Binding }" />
|
|
|
- </cal:ActionMessage>
|
|
|
- </i:EventTrigger>
|
|
|
- </i:Interaction.Triggers>
|
|
|
+ <Button Content="Reset Value" Command="{Binding DataContext.ResetTimeValueCommnad, ElementName=stastic}" Width="120" Height="25" FontSize="12">
|
|
|
</Button>
|
|
|
</DataTemplate>
|
|
|
</DataGridTemplateColumn.CellTemplate>
|
|
@@ -286,14 +247,7 @@
|
|
|
<DataGridTemplateColumn Width="80">
|
|
|
<DataGridTemplateColumn.CellTemplate>
|
|
|
<DataTemplate>
|
|
|
- <Button Content="Set" Width="60" Height="25" FontSize="12">
|
|
|
- <i:Interaction.Triggers>
|
|
|
- <i:EventTrigger EventName="Click">
|
|
|
- <cal:ActionMessage MethodName="SetPMIntervalValue">
|
|
|
- <cal:Parameter Value="{Binding }" />
|
|
|
- </cal:ActionMessage>
|
|
|
- </i:EventTrigger>
|
|
|
- </i:Interaction.Triggers>
|
|
|
+ <Button Content="Set" Width="60" Command="{Binding DataContext.SetPMIntervalValueCommnad, ElementName=stastic}" Height="25" FontSize="12">
|
|
|
</Button>
|
|
|
</DataTemplate>
|
|
|
</DataGridTemplateColumn.CellTemplate>
|
|
@@ -302,17 +256,13 @@
|
|
|
<DataGridTemplateColumn Header="Enable Alarm" Width="120">
|
|
|
<DataGridTemplateColumn.CellTemplate>
|
|
|
<DataTemplate>
|
|
|
- <CheckBox Height="35" Width="35" VerticalContentAlignment="Center" IsChecked="{Binding AlarmEnable, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}">
|
|
|
+ <CheckBox IsChecked="{Binding AlarmEnable,Mode=TwoWay}" VerticalAlignment="Center" HorizontalAlignment="Center" >
|
|
|
<i:Interaction.Triggers>
|
|
|
<i:EventTrigger EventName="Checked">
|
|
|
- <cal:ActionMessage MethodName="ResetRFEnableAlarm">
|
|
|
- <cal:Parameter Value="{Binding }" />
|
|
|
- </cal:ActionMessage>
|
|
|
+ <i:InvokeCommandAction Command="{Binding DataContext.ResetRFEnableAlarmCommnad, ElementName=stastic}" CommandParameter="{Binding }" />
|
|
|
</i:EventTrigger>
|
|
|
<i:EventTrigger EventName="Unchecked">
|
|
|
- <cal:ActionMessage MethodName="ResetRFEnableAlarm">
|
|
|
- <cal:Parameter Value="{Binding }" />
|
|
|
- </cal:ActionMessage>
|
|
|
+ <i:InvokeCommandAction Command="{Binding DataContext.ResetRFEnableAlarmCommnad, ElementName=stastic}" CommandParameter="{Binding }"/>
|
|
|
</i:EventTrigger>
|
|
|
</i:Interaction.Triggers>
|
|
|
</CheckBox>
|