2023-07-12 22:41:31 +00:00
|
|
|
|
using System;
|
|
|
|
|
using System.Windows.Data;
|
|
|
|
|
|
2024-02-28 02:44:21 +00:00
|
|
|
|
namespace MSFSPopoutPanelManager.MainApp.Converter
|
2023-07-12 22:41:31 +00:00
|
|
|
|
{
|
|
|
|
|
public class InverseBooleanOrConverter : IMultiValueConverter
|
|
|
|
|
{
|
|
|
|
|
public object Convert(object[] values, Type targetType, object parameter, System.Globalization.CultureInfo culture)
|
|
|
|
|
{
|
2024-02-28 02:44:21 +00:00
|
|
|
|
if (values.LongLength <= 0)
|
|
|
|
|
return true;
|
|
|
|
|
|
|
|
|
|
foreach (var value in values)
|
2023-07-12 22:41:31 +00:00
|
|
|
|
{
|
2024-02-28 02:44:21 +00:00
|
|
|
|
if (value is true)
|
2023-07-12 22:41:31 +00:00
|
|
|
|
{
|
2024-02-28 02:44:21 +00:00
|
|
|
|
return false;
|
2023-07-12 22:41:31 +00:00
|
|
|
|
}
|
|
|
|
|
}
|
2024-02-28 02:44:21 +00:00
|
|
|
|
|
2023-07-12 22:41:31 +00:00
|
|
|
|
return true;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public object[] ConvertBack(object value, Type[] targetTypes, object parameter, System.Globalization.CultureInfo culture)
|
|
|
|
|
{
|
|
|
|
|
return new object[] { false };
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|