| ofs | hex dump | ascii |
|---|
| 0000 | 00 00 01 00 06 00 00 00 00 00 01 00 20 00 6b 81 00 00 66 00 00 00 80 80 00 00 01 00 20 00 28 08 | ..............k...f...........(. |
| 0020 | 01 00 d1 81 00 00 40 40 00 00 01 00 20 00 28 42 00 00 f9 89 01 00 30 30 00 00 01 00 20 00 a8 25 | ......@@......(B......00.......% |
| 0040 | 00 00 21 cc 01 00 20 20 00 00 01 00 20 00 a8 10 00 00 c9 f1 01 00 10 10 00 00 01 00 20 00 68 04 | ..!...........................h. |
| 0060 | 00 00 71 02 02 00 89 50 4e 47 0d 0a 1a 0a 00 00 00 0d 49 48 44 52 00 00 01 00 00 00 01 00 08 06 | ..q....PNG........IHDR.......... |
| 0080 | 00 00 00 5c 72 a8 66 00 00 80 00 49 44 41 54 78 da ec fd 77 94 64 67 79 e0 8f 3f 6f b8 b9 62 77 | ...\r.f....IDATx...w.dgy..?o..bw |
| 00a0 | 55 77 75 9c ee 99 9e 9e ac 09 1a 66 94 b3 50 32 42 08 10 c6 18 8c 39 df af d7 6b bc 66 6d ff bc | Uwu........f..P2B.....9...k.fm.. |
| 00c0 | 6b 9f 5d 07 be 7b ec e3 65 17 af bd 06 af 2d 03 06 2f 46 d8 60 10 59 c1 ca 79 a4 19 4d 9e 9e d0 | k.]..{..e.....-../F.`.Y..y..M... |
| 00e0 | 3d 9d 63 75 c5 5b 37 be e1 f7 47 55 89 46 08 34 a1 47 93 ee e7 9c 7b aa ba ba aa 6e a8 fb 3c ef | =.cu.[7...GU.F.4.G....{....n..<. |
| 0100 | f3 3e ef 13 00 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 | .>...""""""""""""""""""""""""""" |
| 0120 | 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 | """""""""""""""""""""""""""""""" |
| 0140 | 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 22 | """""""""""""""""""""""""""""""" |
| 0160 | ce 31 e8 7c 1f 40 c4 69 83 01 80 00 80 02 00 6a 63 d3 00 40 6f 3c 36 9f 9b 00 10 6b fc 6d 36 36 | .1.|.@.i.......jc..@o<6....k.m66 |
| 0180 | ab b1 35 df ab 34 9e d3 25 df a7 37 9e bf f9 fb 9b fb a4 8d 63 50 a1 7e ff 34 5f 07 00 00 5d d7 | ..5..4..%..7........cP.~.4_...]. |
| 01a0 | a9 61 18 8a a2 28 e4 67 9d 00 e7 5c f8 be cf 6c db 0e 1a 2f 49 00 60 00 c0 1b 5b d8 d8 82 c6 a3 | .a...(.g...\...l.../I.`...[..... |
| 01c0 | d7 d8 fc 25 cf 9b 9b 0b 00 0e 00 14 00 a0 04 00 55 00 b0 1b 8f d5 c6 ff 9b ef 75 1a df c1 01 40 | ...%............U.........u....@ |
| 01e0 | 34 f6 7b 59 13 29 80 f3 0f 82 ba 40 29 50 17 b4 14 00 b4 00 40 a2 b1 c5 1b 7f b7 34 fe 17 83 ba | 4.{Y.).....@)P......@......4.... |
| 0200 | 90 1a 50 17 c6 e6 46 30 c6 38 93 c9 90 d6 d6 56 a4 aa 2a 50 4a 81 10 02 84 10 84 31 c6 94 52 42 | ..P...F0.8.....V..*PJ......1..RB |
| 0220 | 08 21 18 63 8c 10 92 18 63 8e 10 0a 0c c3 c0 3d 3d 3d 66 6f 6f af d5 fc 0c c6 18 30 c6 a8 f1 1c | .!.c....c......===foo......0.... |
| 0240 | 63 8c 9b c7 ba 74 83 37 3d 07 d3 34 63 86 61 c4 08 21 3f 53 01 08 21 44 10 04 5e a5 52 29 02 00 | c....t.7=..4c.a..!?S..!D..^.R).. |
| 0260 | 20 84 40 4a 29 e1 c7 02 29 00 00 a4 94 42 4a 29 39 e7 92 31 26 19 63 10 04 81 2c 97 cb 62 df be | ..@J)...)....BJ)9..1&.c...,..b.. |
| 0280 | 7d 85 20 08 88 10 82 70 ce 11 63 2c 0c c3 90 35 df 17 86 21 8c using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Media;
using System.Xml.Serialization;
using Tango.BL.Entities;
using Tango.Core.Commands;
using Tango.PMR.Diagnostics;
using Tango.SharedUI.Helpers;
namespace Tango.MachineStudio.Technician.TechItems
{
/// <summary>
/// Represents a heater controller.
/// </summary>
/// <seealso cref="Tango.MachineStudio.Technician.TechItems.TechItem" />
[TechItem(10)]
public class HeaterItem : TechItem
{
public event Action SetCommandClicked;
private TechHeater _techHeater;
/// <summary>
/// Gets or sets the db tech monitor.
/// </summary>
[XmlIgnore]
public TechHeater TechHeater
{
get { return _techHeater; }
set { _techHeater = value; RaisePropertyChangedAuto(); TechName = _techHeater != null ? _techHeater.Description : null; ItemGuid = value != null ? value.Guid : null; }
}
/// <summary>
/// Gets or sets the set command.
/// </summary>
[XmlIgnore]
public RelayCommand SetCommand { get; set; }
/// <summary>
/// Initializes a new instance of the <see cref="HeaterItem"/> class.
/// </summary>
public HeaterItem() : base()
{
Name = "Heater Controller";
Color = Colors.White;
Description = "Heater Controller";
Image = ResourceHelper.GetImageFromResources("Images/heater-controller.png");
SetCommand = new RelayCommand(() =>
{
SetCommandClicked?.Invoke();
IsEditing = false;
}, (x) => HeaterState.CurrentValue != SetPoint);
HeaterState = new HeaterState();
}
/// <summary>
/// Initializes a new instance of the <see cref="HeaterItem"/> class.
/// </summary>
/// <param name="TechHeater">The db tech monitor.</param>
public HeaterItem(TechHeater techHeater) : this()
{
TechHeater = techHeater;
}
private HeaterState _heaterState;
/// <summary>
/// Gets or sets the state of the heater.
/// </summary>
public HeaterState HeaterState
{
get { return _heaterState; }
set
{
_heaterState = value;
RaisePropertyChangedAuto();
if (!IsEditing)
{
SetPoint = _heaterState.SetPoint;
}
InvokeUI(() =>
{
SetCommand.RaiseCanExecuteChanged();
});
}
}
private double _setPoint;
/// <summary>
/// Gets or sets the set point.
/// </summary>
public double SetPoint
{
get { return _setPoint; }
set { _setPoint = value; RaisePropertyChangedAuto(); }
}
private bool _isEditing;
[XmlIgnore]
public bool IsEditing
{
get { return _isEditing; }
set { _isEditing = value; RaisePropertyChangedAuto(); }
}
/// <summary>
/// Clones this instance.
/// </summary>
/// <returns></returns>
public override TechItem Clone()
{
HeaterItem cloned = base.Clone() as HeaterItem;
cloned.TechHeater = TechHeater;
return cloned;
}
}
}
|