using System; using System.Globalization; using System.Windows.Data; using System.Windows.Markup; namespace Gestor.Application.Converters { public class ExcluidoStringConverter : MarkupExtension, IValueConverter { public ExcluidoStringConverter() { } public object Convert(object value, Type targetType, object parameter, CultureInfo culture) { if (value is bool && (bool)value) { return "EXCLUÍDO"; } return ""; } public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture) { return null; } public override object ProvideValue(IServiceProvider serviceProvider) { return this; } } }