This commit is contained in:
艾竹
2022-12-12 22:33:17 +08:00
parent 02f428d61a
commit 4b798f75a0
60 changed files with 330 additions and 277 deletions

View File

@@ -0,0 +1,24 @@
using System;
using System.Windows.Data;
namespace AIStudio.Wpf.DiagramDesigner.Converters
{
public class IntToBoolConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
{
if (object.Equals(value, 0d))
return false;
else
return true;
}
public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
{
if (object.Equals(value, false))
return 0d;
else
return 1d;
}
}
}