From 795f3ab6ea36551281ec6442aa16b9547af96adc Mon Sep 17 00:00:00 2001 From: Roy Date: Mon, 20 Feb 2023 02:28:15 +0200 Subject: Incorporated machine type into machine creation and management + job runs. --- .../ViewModels/MainViewVM.cs | 3 + .../Views/MainView.xaml | 12 +- .../Models/MachineModel.cs | 3 + .../ViewModels/MachineCreationDialogVM.cs | 3 + .../ViewModels/MainViewVM.cs | 11 ++ .../Views/MachineCreationDialog.xaml | 16 +- .../Views/MachinesView.xaml | 3 +- .../Images/eureka_full.png | Bin 0 -> 1038958 bytes .../Images/eureka_small.png | Bin 0 -> 33703 bytes .../Tango.MachineStudio.Common/Images/machines.png | Bin 0 -> 394373 bytes .../Resources/MaterialDesign.xaml | 3 + .../Tango.MachineStudio.Common.csproj | 7 +- .../Tango.BL/DTO/HardwareVersionDTOBase.cs | 16 ++ .../Visual_Studio/Tango.BL/DTO/JobRunDTOBase.cs | 8 + .../Tango.BL/DTO/MachinePrototypeDTOBase.cs | 8 + .../Tango.BL/Entities/HardwareVersion.cs | 17 +- .../Tango.BL/Entities/HardwareVersionBase.cs | 76 +++++++++ .../Visual_Studio/Tango.BL/Entities/JobRunBase.cs | 38 +++++ .../Tango.BL/Entities/MachinePrototype.cs | 1 + .../Tango.BL/Entities/MachinePrototypeBase.cs | 38 +++++ .../Tango.DAL.Remote/DB/HARDWARE_VERSIONS.cs | 2 + .../Visual_Studio/Tango.DAL.Remote/DB/JOB_RUNS.cs | 1 + .../Tango.DAL.Remote/DB/MACHINE_PROTOTYPES.cs | 1 + .../Tango.DAL.Remote/DB/RemoteADO.edmx | 12 ++ .../Tango.DAL.Remote/DB/RemoteADO.edmx.diagram | 182 ++++++++++----------- .../JobRuns/BasicJobRunsLogger.cs | 15 +- .../SQLExaminer/Configurations/OverrideData.xml | Bin 94118 -> 94280 bytes .../IsNullToVisibilityInverseConverter.cs | 24 +++ .../NullObjectToBooleanInverseConverter.cs | 45 +++++ .../Tango.SharedUI/Tango.SharedUI.csproj | 4 +- 30 files changed, 444 insertions(+), 105 deletions(-) create mode 100644 Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Common/Images/eureka_full.png create mode 100644 Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Common/Images/eureka_small.png create mode 100644 Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Common/Images/machines.png create mode 100644 Software/Visual_Studio/Tango.SharedUI/Converters/IsNullToVisibilityInverseConverter.cs create mode 100644 Software/Visual_Studio/Tango.SharedUI/Converters/NullObjectToBooleanInverseConverter.cs (limited to 'Software/Visual_Studio') diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.HardwareDesigner/ViewModels/MainViewVM.cs b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.HardwareDesigner/ViewModels/MainViewVM.cs index 47fe19a05..ab86d8356 100644 --- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.HardwareDesigner/ViewModels/MainViewVM.cs +++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.HardwareDesigner/ViewModels/MainViewVM.cs @@ -19,6 +19,7 @@ using System.IO; using Tango.BL.ActionLogs; using Tango.MachineStudio.Common.Authentication; using Tango.BL.DTO; +using Tango.BL.Enumerations; namespace Tango.MachineStudio.HardwareDesigner.ViewModels { @@ -445,6 +446,8 @@ namespace Tango.MachineStudio.HardwareDesigner.ViewModels await Task.Factory.StartNew(() => { CurrentVersion.LastUpdated = DateTime.UtcNow; + CurrentVersion.UserName = _authentication.CurrentUser.Email; + _db.SaveChanges(); var dtoAfter = HardwareVersionDTO.FromObservable(CurrentVersion); diff --git a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.HardwareDesigner/Views/MainView.xaml b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.HardwareDesigner/Views/MainView.xaml index 9ee2ffee7..134d5d455 100644 --- a/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.HardwareDesigner/Views/MainView.xaml +++ b/Software/Visual_Studio/MachineStudio/Modules/Tango.MachineStudio.HardwareDesigner/Views/MainView.xaml @@ -14,13 +14,14 @@ xmlns:vm="clr-namespace:Tango.MachineStudio.HardwareDesigner.ViewModels" xmlns:observables="clr-namespace:Tango.BL.Entities;assembly=Tango.BL" xmlns:global="clr-namespace:Tango.MachineStudio.HardwareDesigner" + xmlns:enumerations="clr-namespace:Tango.BL.Enumerations;assembly=Tango.BL" mc:Ignorable="d" d:DesignHeight="2000" d:DesignWidth="1280" d:DataContext="{d:DesignInstance Type=vm:MainViewVM, IsDesignTimeCreatable=False}" DataContext="{x:Static global:ViewModelLocator.MainViewVM}"> - + + diff --git a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Common/Images/eureka_full.png b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Common/Images/eureka_full.png new file mode 100644 index 000000000..484bb2ac1 Binary files /dev/null and b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Common/Images/eureka_full.png differ diff --git a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Common/Images/eureka_small.png b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Common/Images/eureka_small.png new file mode 100644 index 000000000..c9da4ae29 Binary files /dev/null and b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Common/Images/eureka_small.png differ diff --git a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Common/Images/machines.png b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Common/Images/machines.png new file mode 100644 index 000000000..788d1e67b Binary files /dev/null and b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Common/Images/machines.png differ diff --git a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Common/Resources/MaterialDesign.xaml b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Common/Resources/MaterialDesign.xaml index d8e2017ec..bd35677d2 100644 --- a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Common/Resources/MaterialDesign.xaml +++ b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Common/Resources/MaterialDesign.xaml @@ -73,6 +73,9 @@ + + + diff --git a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Common/Tango.MachineStudio.Common.csproj b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Common/Tango.MachineStudio.Common.csproj index 91a8b5930..af0d6aab8 100644 --- a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Common/Tango.MachineStudio.Common.csproj +++ b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.Common/Tango.MachineStudio.Common.csproj @@ -448,10 +448,15 @@ + + + + + - + diff --git a/Software/Visual_Studio/Tango.BL/DTO/HardwareVersionDTOBase.cs b/Software/Visual_Studio/Tango.BL/DTO/HardwareVersionDTOBase.cs index 84f75210e..6ef629488 100644 --- a/Software/Visual_Studio/Tango.BL/DTO/HardwareVersionDTOBase.cs +++ b/Software/Visual_Studio/Tango.BL/DTO/HardwareVersionDTOBase.cs @@ -37,5 +37,21 @@ namespace Tango.BL.DTO get; set; } + /// + /// machine type + /// + public Int32 MachineType + { + get; set; + } + + /// + /// user name + /// + public String UserName + { + get; set; + } + } } diff --git a/Software/Visual_Studio/Tango.BL/DTO/JobRunDTOBase.cs b/Software/Visual_Studio/Tango.BL/DTO/JobRunDTOBase.cs index 3f3efb015..45aa02514 100644 --- a/Software/Visual_Studio/Tango.BL/DTO/JobRunDTOBase.cs +++ b/Software/Visual_Studio/Tango.BL/DTO/JobRunDTOBase.cs @@ -333,5 +333,13 @@ namespace Tango.BL.DTO get; set; } + /// + /// machine type + /// + public Int32 MachineType + { + get; set; + } + } } diff --git a/Software/Visual_Studio/Tango.BL/DTO/MachinePrototypeDTOBase.cs b/Software/Visual_Studio/Tango.BL/DTO/MachinePrototypeDTOBase.cs index 1629bbbd0..ac97ccc50 100644 --- a/Software/Visual_Studio/Tango.BL/DTO/MachinePrototypeDTOBase.cs +++ b/Software/Visual_Studio/Tango.BL/DTO/MachinePrototypeDTOBase.cs @@ -21,6 +21,14 @@ namespace Tango.BL.DTO public abstract class MachinePrototypeDTOBase : ObservableEntityDTO { + /// + /// machine type + /// + public Int32 MachineType + { + get; set; + } + /// /// name /// diff --git a/Software/Visual_Studio/Tango.BL/Entities/HardwareVersion.cs b/Software/Visual_Studio/Tango.BL/Entities/HardwareVersion.cs index bc65c33ce..1688e87fc 100644 --- a/Software/Visual_Studio/Tango.BL/Entities/HardwareVersion.cs +++ b/Software/Visual_Studio/Tango.BL/Entities/HardwareVersion.cs @@ -5,12 +5,27 @@ using System.ComponentModel.DataAnnotations.Schema; using System.Linq; using System.Text; using System.Threading.Tasks; +using Tango.BL.Enumerations; using Tango.BL.Serialization; namespace Tango.BL.Entities { public partial class HardwareVersion : HardwareVersionBase { + [NotMapped] + [JsonIgnore] + public MachineTypes ForMachineType + { + get + { + return (MachineTypes)MachineType; + } + set + { + MachineType = value.ToInt32(); + } + } + public override HardwareVersion Clone() { var cloned = base.Clone(); @@ -99,7 +114,7 @@ namespace Tango.BL.Entities [JsonIgnore] public String FullName { - get { return $"{Name} v{Version}"; } + get { return $"{Name} v{Version} {ForMachineType}"; } } /// diff --git a/Software/Visual_Studio/Tango.BL/Entities/HardwareVersionBase.cs b/Software/Visual_Studio/Tango.BL/Entities/HardwareVersionBase.cs index 3d7d555dc..e30903baa 100644 --- a/Software/Visual_Studio/Tango.BL/Entities/HardwareVersionBase.cs +++ b/Software/Visual_Studio/Tango.BL/Entities/HardwareVersionBase.cs @@ -31,6 +31,10 @@ namespace Tango.BL.Entities public event EventHandler NameChanged; + public event EventHandler MachineTypeChanged; + + public event EventHandler UserNameChanged; + public event EventHandler> ConfigurationsChanged; public event EventHandler> HardwareBlowersChanged; @@ -101,6 +105,60 @@ namespace Tango.BL.Entities } } + protected Int32 _machinetype; + + /// + /// Gets or sets the hardwareversionbase machine type. + /// + + [Column("MACHINE_TYPE")] + + public Int32 MachineType + { + get + { + return _machinetype; + } + + set + { + if (_machinetype != value) + { + _machinetype = value; + + OnMachineTypeChanged(value); + + } + } + } + + protected String _username; + + /// + /// Gets or sets the hardwareversionbase user name. + /// + + [Column("USER_NAME")] + + public String UserName + { + get + { + return _username; + } + + set + { + if (_username != value) + { + _username = value; + + OnUserNameChanged(value); + + } + } + } + protected SynchronizedObservableCollection _configurations; /// @@ -319,6 +377,24 @@ namespace Tango.BL.Entities RaisePropertyChanged(nameof(Name)); } + /// + /// Called when the MachineType has changed. + /// + protected virtual void OnMachineTypeChanged(Int32 machinetype) + { + MachineTypeChanged?.Invoke(this, machinetype); + RaisePropertyChanged(nameof(MachineType)); + } + + /// + /// Called when the UserName has changed. + /// + protected virtual void OnUserNameChanged(String username) + { + UserNameChanged?.Invoke(this, username); + RaisePropertyChanged(nameof(UserName)); + } + /// /// Called when the Configurations has changed. /// diff --git a/Software/Visual_Studio/Tango.BL/Entities/JobRunBase.cs b/Software/Visual_Studio/Tango.BL/Entities/JobRunBase.cs index da3ff6f5b..ddb33e7d2 100644 --- a/Software/Visual_Studio/Tango.BL/Entities/JobRunBase.cs +++ b/Software/Visual_Studio/Tango.BL/Entities/JobRunBase.cs @@ -95,6 +95,8 @@ namespace Tango.BL.Entities public event EventHandler FineTuningStringChanged; + public event EventHandler MachineTypeChanged; + protected String _machineguid; /// @@ -1140,6 +1142,33 @@ namespace Tango.BL.Entities } } + protected Int32 _machinetype; + + /// + /// Gets or sets the jobrunbase machine type. + /// + + [Column("MACHINE_TYPE")] + + public Int32 MachineType + { + get + { + return _machinetype; + } + + set + { + if (_machinetype != value) + { + _machinetype = value; + + OnMachineTypeChanged(value); + + } + } + } + /// /// Called when the JobName has changed. /// @@ -1446,6 +1475,15 @@ namespace Tango.BL.Entities RaisePropertyChanged(nameof(FineTuningString)); } + /// + /// Called when the MachineType has changed. + /// + protected virtual void OnMachineTypeChanged(Int32 machinetype) + { + MachineTypeChanged?.Invoke(this, machinetype); + RaisePropertyChanged(nameof(MachineType)); + } + /// /// Initializes a new instance of the class. /// diff --git a/Software/Visual_Studio/Tango.BL/Entities/MachinePrototype.cs b/Software/Visual_Studio/Tango.BL/Entities/MachinePrototype.cs index a1dee5a5d..d93c80f8c 100644 --- a/Software/Visual_Studio/Tango.BL/Entities/MachinePrototype.cs +++ b/Software/Visual_Studio/Tango.BL/Entities/MachinePrototype.cs @@ -129,6 +129,7 @@ namespace Tango.BL.Entities prototype.Name = name; prototype.Description = description; prototype.LastUpdated = DateTime.UtcNow; + prototype.MachineType = machine.MachineType; prototype.SetPrototypeMachine(machine); return prototype; diff --git a/Software/Visual_Studio/Tango.BL/Entities/MachinePrototypeBase.cs b/Software/Visual_Studio/Tango.BL/Entities/MachinePrototypeBase.cs index 2ecaad7e4..863496860 100644 --- a/Software/Visual_Studio/Tango.BL/Entities/MachinePrototypeBase.cs +++ b/Software/Visual_Studio/Tango.BL/Entities/MachinePrototypeBase.cs @@ -27,12 +27,41 @@ namespace Tango.BL.Entities public abstract class MachinePrototypeBase : ObservableEntity { + public event EventHandler MachineTypeChanged; + public event EventHandler NameChanged; public event EventHandler DescriptionChanged; public event EventHandler PrototypeJsonChanged; + protected Int32 _machinetype; + + /// + /// Gets or sets the machineprototypebase machine type. + /// + + [Column("MACHINE_TYPE")] + + public Int32 MachineType + { + get + { + return _machinetype; + } + + set + { + if (_machinetype != value) + { + _machinetype = value; + + OnMachineTypeChanged(value); + + } + } + } + protected String _name; /// @@ -114,6 +143,15 @@ namespace Tango.BL.Entities } } + /// + /// Called when the MachineType has changed. + /// + protected virtual void OnMachineTypeChanged(Int32 machinetype) + { + MachineTypeChanged?.Invoke(this, machinetype); + RaisePropertyChanged(nameof(MachineType)); + } + /// /// Called when the Name has changed. /// diff --git a/Software/Visual_Studio/Tango.DAL.Remote/DB/HARDWARE_VERSIONS.cs b/Software/Visual_Studio/Tango.DAL.Remote/DB/HARDWARE_VERSIONS.cs index 190ed45e6..77541c90a 100644 --- a/Software/Visual_Studio/Tango.DAL.Remote/DB/HARDWARE_VERSIONS.cs +++ b/Software/Visual_Studio/Tango.DAL.Remote/DB/HARDWARE_VERSIONS.cs @@ -32,6 +32,8 @@ namespace Tango.DAL.Remote.DB public System.DateTime LAST_UPDATED { get; set; } public double VERSION { get; set; } public string NAME { get; set; } + public int MACHINE_TYPE { get; set; } + public string USER_NAME { get; set; } [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")] public virtual ICollection CONFIGURATIONS { get; set; } diff --git a/Software/Visual_Studio/Tango.DAL.Remote/DB/JOB_RUNS.cs b/Software/Visual_Studio/Tango.DAL.Remote/DB/JOB_RUNS.cs index 069498e77..090263ff2 100644 --- a/Software/Visual_Studio/Tango.DAL.Remote/DB/JOB_RUNS.cs +++ b/Software/Visual_Studio/Tango.DAL.Remote/DB/JOB_RUNS.cs @@ -56,5 +56,6 @@ namespace Tango.DAL.Remote.DB public string CE_VERSION { get; set; } public string PROCESS_PARAMETERS_TABLE_GUID { get; set; } public string FINE_TUNING_STRING { get; set; } + public int MACHINE_TYPE { get; set; } } } diff --git a/Software/Visual_Studio/Tango.DAL.Remote/DB/MACHINE_PROTOTYPES.cs b/Software/Visual_Studio/Tango.DAL.Remote/DB/MACHINE_PROTOTYPES.cs index 4fdfe0e0e..63930b0a3 100644 --- a/Software/Visual_Studio/Tango.DAL.Remote/DB/MACHINE_PROTOTYPES.cs +++ b/Software/Visual_Studio/Tango.DAL.Remote/DB/MACHINE_PROTOTYPES.cs @@ -17,6 +17,7 @@ namespace Tango.DAL.Remote.DB public int ID { get; set; } public string GUID { get; set; } public System.DateTime LAST_UPDATED { get; set; } + public int MACHINE_TYPE { get; set; } public string NAME { get; set; } public string DESCRIPTION { get; set; } public string PROTOTYPE_JSON { get; set; } diff --git a/Software/Visual_Studio/Tango.DAL.Remote/DB/RemoteADO.edmx b/Software/Visual_Studio/Tango.DAL.Remote/DB/RemoteADO.edmx index 889a6ded6..5215bc6de 100644 --- a/Software/Visual_Studio/Tango.DAL.Remote/DB/RemoteADO.edmx +++ b/Software/Visual_Studio/Tango.DAL.Remote/DB/RemoteADO.edmx @@ -693,6 +693,8 @@ + + @@ -791,6 +793,7 @@ + @@ -893,6 +896,7 @@ + @@ -6289,6 +6293,8 @@ + + @@ -6405,6 +6411,7 @@ + @@ -6525,6 +6532,7 @@ + @@ -9748,6 +9756,8 @@ + + @@ -9814,6 +9824,7 @@ + @@ -9964,6 +9975,7 @@ + diff --git a/Software/Visual_Studio/Tango.DAL.Remote/DB/RemoteADO.edmx.diagram b/Software/Visual_Studio/Tango.DAL.Remote/DB/RemoteADO.edmx.diagram index 1d22ffc93..cddf04151 100644 --- a/Software/Visual_Studio/Tango.DAL.Remote/DB/RemoteADO.edmx.diagram +++ b/Software/Visual_Studio/Tango.DAL.Remote/DB/RemoteADO.edmx.diagram @@ -5,102 +5,102 @@ - - - - - - + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - + + + + + + + + + - - - - - - - - - - + + + + + + + + + + - - - - - + + + + + - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + diff --git a/Software/Visual_Studio/Tango.Integration/JobRuns/BasicJobRunsLogger.cs b/Software/Visual_Studio/Tango.Integration/JobRuns/BasicJobRunsLogger.cs index 68565679a..6285bb7b0 100644 --- a/Software/Visual_Studio/Tango.Integration/JobRuns/BasicJobRunsLogger.cs +++ b/Software/Visual_Studio/Tango.Integration/JobRuns/BasicJobRunsLogger.cs @@ -158,11 +158,20 @@ namespace Tango.Integration.JobRuns run.IsGradient = _job.Segments.Any(x => x.BrushStops.Count > 1); run.GradientResolutionCm = MachineOperator.GradientGenerationConfiguration.ResolutionCM; + if (_defaultMachine != null) + { + run.MachineType = _defaultMachine.MachineType; + } + else if (_job.Machine != null) + { + run.MachineType = _job.Machine.MachineType; + } + var jobFile = e.Job.ToJobFileWhenLoaded(); - try - { - if (_job.Designation == JobDesignations.FineTuning) + try + { + if (_job.Designation == JobDesignations.FineTuning) { jobFile.Segments.First().BrushStops.First().ColorSpaceGuid = colorSpaces.First(x => x.Code == (int)ColorSpaces.LAB).Guid; } diff --git a/Software/Visual_Studio/Tango.SQLExaminer/SQLExaminer/Configurations/OverrideData.xml b/Software/Visual_Studio/Tango.SQLExaminer/SQLExaminer/Configurations/OverrideData.xml index 763d6b078..305aed9b9 100644 Binary files a/Software/Visual_Studio/Tango.SQLExaminer/SQLExaminer/Configurations/OverrideData.xml and b/Software/Visual_Studio/Tango.SQLExaminer/SQLExaminer/Configurations/OverrideData.xml differ diff --git a/Software/Visual_Studio/Tango.SharedUI/Converters/IsNullToVisibilityInverseConverter.cs b/Software/Visual_Studio/Tango.SharedUI/Converters/IsNullToVisibilityInverseConverter.cs new file mode 100644 index 000000000..ef284b12c --- /dev/null +++ b/Software/Visual_Studio/Tango.SharedUI/Converters/IsNullToVisibilityInverseConverter.cs @@ -0,0 +1,24 @@ +using System; +using System.Collections.Generic; +using System.Globalization; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows; +using System.Windows.Data; + +namespace Tango.SharedUI.Converters +{ + public class IsNullToVisibilityInverseConverter : IValueConverter + { + public object Convert(object value, Type targetType, object parameter, CultureInfo culture) + { + return value == null ? Visibility.Visible : Visibility.Collapsed; + } + + public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture) + { + throw new NotImplementedException(); + } + } +} diff --git a/Software/Visual_Studio/Tango.SharedUI/Converters/NullObjectToBooleanInverseConverter.cs b/Software/Visual_Studio/Tango.SharedUI/Converters/NullObjectToBooleanInverseConverter.cs new file mode 100644 index 000000000..73e41beea --- /dev/null +++ b/Software/Visual_Studio/Tango.SharedUI/Converters/NullObjectToBooleanInverseConverter.cs @@ -0,0 +1,45 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows.Data; + +namespace Tango.SharedUI.Converters +{ + /// + /// Represents a binding converter for returning true for valid object instances and false for null object reference. + /// + public class NullObjectToBooleanInverseConverter : IValueConverter + { + /// + /// Converts a value. + /// + /// The value produced by the binding source. + /// The type of the binding target property. + /// The converter parameter to use. + /// The culture to use in the converter. + /// + /// A converted value. If the method returns null, the valid null value is used. + /// + public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture) + { + return (value == null); + } + + /// + /// Converts a value. + /// + /// The value that is produced by the binding target. + /// The type to convert to. + /// The converter parameter to use. + /// The culture to use in the converter. + /// + /// A converted value. If the method returns null, the valid null value is used. + /// + public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture) + { + return value; + } + } +} diff --git a/Software/Visual_Studio/Tango.SharedUI/Tango.SharedUI.csproj b/Software/Visual_Studio/Tango.SharedUI/Tango.SharedUI.csproj index c2071d296..c7eccab9f 100644 --- a/Software/Visual_Studio/Tango.SharedUI/Tango.SharedUI.csproj +++ b/Software/Visual_Studio/Tango.SharedUI/Tango.SharedUI.csproj @@ -119,12 +119,14 @@ + + @@ -262,7 +264,7 @@ - + \ No newline at end of file -- cgit v1.3.1