init
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
using System;
|
||||
using System.Linq;
|
||||
using System.Windows.Data;
|
||||
|
||||
namespace DTS.Common.Converters
|
||||
{
|
||||
public class BooleanOrMultiConverter : IMultiValueConverter
|
||||
{
|
||||
public object Convert(object[] values, Type targetType, object parameter, System.Globalization.CultureInfo culture)
|
||||
{
|
||||
return !Array.TrueForAll(values, val => val is bool) ? false : (object)Array.Exists(values, val => (bool)val);
|
||||
}
|
||||
|
||||
public object[] ConvertBack(object value, Type[] targetTypes, object parameter, System.Globalization.CultureInfo culture)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,8 @@
|
||||
namespace DTS.Common.Interface.TestDefinition
|
||||
{
|
||||
public interface ITestMetadata
|
||||
{
|
||||
ITestRunMetadata TestRun { get; set; }
|
||||
ITestSetupMetadata TestSetup { get; set; }
|
||||
}
|
||||
}
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 13 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 1.2 KiB |
@@ -0,0 +1,6 @@
|
||||
using DTS.Common.Base;
|
||||
|
||||
namespace DTS.Common.Interface
|
||||
{
|
||||
public interface IFilterView : IBaseView { }
|
||||
}
|
||||
@@ -0,0 +1,52 @@
|
||||
using System;
|
||||
using System.Windows.Data;
|
||||
using System.Windows;
|
||||
|
||||
namespace DTS.Common.Converters
|
||||
{
|
||||
public class VisibilityToRowHeightConverter : DependencyObject, IValueConverter
|
||||
{
|
||||
/// <summary>
|
||||
/// inverts the source prior to conversion
|
||||
/// </summary>
|
||||
public bool InvertSource
|
||||
{
|
||||
get => (bool)GetValue(InvertSourceProperty);
|
||||
set => SetValue(InvertSourceProperty, value);
|
||||
}
|
||||
public static readonly DependencyProperty InvertSourceProperty =
|
||||
DependencyProperty.Register("InvertSource", typeof(bool), typeof(VisibilityToRowHeightConverter), new PropertyMetadata(false));
|
||||
|
||||
public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
|
||||
{
|
||||
if (value is Visibility vis)
|
||||
{
|
||||
if (InvertSource)
|
||||
{
|
||||
switch (vis)
|
||||
{
|
||||
case Visibility.Visible:
|
||||
vis = Visibility.Collapsed;
|
||||
break;
|
||||
case Visibility.Hidden:
|
||||
case Visibility.Collapsed:
|
||||
vis = Visibility.Visible;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (vis == Visibility.Collapsed)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
//return parameter;
|
||||
return parameter ?? 0;
|
||||
}
|
||||
|
||||
public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
namespace DTS.Common.Enums.Sensors.SensorsList
|
||||
{
|
||||
public enum SquibFields
|
||||
{
|
||||
Included,
|
||||
SerialNumber,
|
||||
Description,
|
||||
ResistanceLow,
|
||||
ResistanceHigh,
|
||||
Id,
|
||||
Mode,
|
||||
Delay,
|
||||
Current,
|
||||
Duration,
|
||||
ModifiedBy,
|
||||
LastModified
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
using System.Windows.Controls;
|
||||
|
||||
|
||||
namespace DTS.Common.RibbonControl
|
||||
{
|
||||
public class RibbonView : UserControl, IRibbonView { }
|
||||
}
|
||||
Reference in New Issue
Block a user