aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/PPC/Tango.PPC.UI
diff options
context:
space:
mode:
authorRoy Ben Shabat <Roy.mail.net@gmail.com>2024-05-27 15:02:11 +0300
committerRoy Ben Shabat <Roy.mail.net@gmail.com>2024-05-27 15:02:11 +0300
commitd7a39774fcbdab671c1e4796ba78a3ae29e75b77 (patch)
tree88e7bf083d6a041a7d392dd6947d4bbc90166777 /Software/Visual_Studio/PPC/Tango.PPC.UI
parent5b634129f69b00f6df777a3e5e5203977d71062a (diff)
downloadTango-d7a39774fcbdab671c1e4796ba78a3ae29e75b77.tar.gz
Tango-d7a39774fcbdab671c1e4796ba78a3ae29e75b77.zip
Changed X4 Dryer Air Behavior.
Updated events table to rev 13.
Diffstat (limited to 'Software/Visual_Studio/PPC/Tango.PPC.UI')
-rw-r--r--Software/Visual_Studio/PPC/Tango.PPC.UI/Models/MachineOverviewItem.cs7
-rw-r--r--Software/Visual_Studio/PPC/Tango.PPC.UI/Models/MachineOverviewModel.cs13
-rw-r--r--Software/Visual_Studio/PPC/Tango.PPC.UI/Views/MachineStatusView.xaml43
-rw-r--r--Software/Visual_Studio/PPC/Tango.PPC.UI/app.manifest2
4 files changed, 59 insertions, 6 deletions
diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Models/MachineOverviewItem.cs b/Software/Visual_Studio/PPC/Tango.PPC.UI/Models/MachineOverviewItem.cs
index 42f6bd180..d1e7127cc 100644
--- a/Software/Visual_Studio/PPC/Tango.PPC.UI/Models/MachineOverviewItem.cs
+++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/Models/MachineOverviewItem.cs
@@ -54,6 +54,13 @@ namespace Tango.PPC.UI.Models
set { _value = value; RaisePropertyChangedAuto(); }
}
+ private bool _isReady;
+ public bool IsReady
+ {
+ get { return _isReady; }
+ set { _isReady = value; RaisePropertyChangedAuto(); }
+ }
+
public MachineOverviewItem()
{
Color = Colors.Gray;
diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Models/MachineOverviewModel.cs b/Software/Visual_Studio/PPC/Tango.PPC.UI/Models/MachineOverviewModel.cs
index 24ad6576d..aaa609c73 100644
--- a/Software/Visual_Studio/PPC/Tango.PPC.UI/Models/MachineOverviewModel.cs
+++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/Models/MachineOverviewModel.cs
@@ -155,15 +155,22 @@ namespace Tango.PPC.UI.Models
if (currentvalue < targetValue)
{
DryerAir.Status = "Heating Up";
- DryerAir.Color = Colors.Orange;
+ DryerAir.Color = Colors.Red;
DryerAir.DisplayValue = currentvalue.ToString("N1");
+ DryerAir.MaxValue = targetValue;
+ DryerAir.DisplayMaxValue = ((int)targetValue).ToString();
+ DryerAir.IsReady = false;
}
else if (currentvalue >= targetValue)
{
- DryerAir.Status = "Operational";
+ DryerAir.Status = "";
DryerAir.Color = Colors.Green;
- DryerAir.DisplayValue = currentvalue.ToString("N1");
+ DryerAir.DisplayValue = ((int)currentvalue).ToString();
+ DryerAir.MaxValue = targetValue;
+ DryerAir.DisplayMaxValue = ((int)targetValue).ToString();
+ DryerAir.IsReady = true;
}
+
DryerAir.Value = currentvalue;
}
diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/MachineStatusView.xaml b/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/MachineStatusView.xaml
index ada513879..60584bc15 100644
--- a/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/MachineStatusView.xaml
+++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/Views/MachineStatusView.xaml
@@ -1084,7 +1084,7 @@
<SolidColorBrush Color="{Binding DryerZone3.Color}"/>
</Run.Foreground>
</Run>
- <Run Text="{Binding DryerZone3.DisplayMaxValue}" ></Run>
+ <Run Text="{Binding DryerZone3.DisplayMaxValue}"></Run>
</TextBlock>
<TextBlock VerticalAlignment="Bottom" HorizontalAlignment="Center" Margin="0 0 0 20" FontSize="{StaticResource TangoDefaultFontSize}" >&#186;C</TextBlock>
@@ -1099,7 +1099,46 @@
<SolidColorBrush Color="{Binding DryerAir.Color}"/>
</touch:TouchArcProgress.Foreground>
</touch:TouchArcProgress>
- <TextBlock VerticalAlignment="Center" HorizontalAlignment="Center" FontSize="{StaticResource TangoDefaultFontSize}" FontWeight="SemiBold" Text="{Binding DryerAir.DisplayValue}">
+
+ <ContentControl Content="{Binding DryerAir}">
+ <ContentControl.Style>
+ <Style TargetType="ContentControl">
+ <Setter Property="ContentTemplate">
+ <Setter.Value>
+ <DataTemplate>
+ <TextBlock VerticalAlignment="Center" HorizontalAlignment="Center" FontSize="{StaticResource TangoDefaultFontSize}" FontWeight="Bold" >
+ <Run Text="{Binding DisplayValue}">
+ <Run.Foreground>
+ <SolidColorBrush Color="{Binding Color}"/>
+ </Run.Foreground>
+ </Run>
+ <Run>/</Run>
+ <Run Text="{Binding DisplayMaxValue}"></Run>
+ </TextBlock>
+ </DataTemplate>
+ </Setter.Value>
+ </Setter>
+ <Style.Triggers>
+ <DataTrigger Binding="{Binding DryerAir.IsReady}" Value="True">
+ <Setter Property="ContentTemplate">
+ <Setter.Value>
+ <DataTemplate>
+ <TextBlock VerticalAlignment="Center" HorizontalAlignment="Center" FontSize="{StaticResource TangoDefaultFontSize}" FontWeight="Bold" >
+ <Run Text="Ready">
+ <Run.Foreground>
+ <SolidColorBrush Color="{Binding Color}"/>
+ </Run.Foreground>
+ </Run>
+ </TextBlock>
+ </DataTemplate>
+ </Setter.Value>
+ </Setter>
+ </DataTrigger>
+ </Style.Triggers>
+ </Style>
+ </ContentControl.Style>
+ </ContentControl>
+ <TextBlock VerticalAlignment="Center" HorizontalAlignment="Center" FontSize="{StaticResource TangoDefaultFontSize}" FontWeight="SemiBold">
<TextBlock.Foreground>
<SolidColorBrush Color="{Binding DryerAir.Color}"/>
</TextBlock.Foreground>
diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/app.manifest b/Software/Visual_Studio/PPC/Tango.PPC.UI/app.manifest
index d72e75011..efc5f8179 100644
--- a/Software/Visual_Studio/PPC/Tango.PPC.UI/app.manifest
+++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/app.manifest
@@ -16,7 +16,7 @@
Remove this element if your application requires this virtualization for backwards
compatibility.
-->
- <requestedExecutionLevel level="requireAdministrator" uiAccess="false" />
+ <!--<requestedExecutionLevel level="requireAdministrator" uiAccess="false" />-->
</requestedPrivileges>
</security>
</trustInfo>