using System; using System.Globalization; using Xamarin.Forms; namespace TINK.View { /// Inverts a bool. public class BoolInverterConverter : IValueConverter { /// Inverts a bool. /// Bool to invert. /// Inverted bool. public object Convert(object value, Type targetType, object parameter, CultureInfo culture) => value is bool flag && !flag; public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture) => value is bool flag && !flag; } }