summaryrefslogtreecommitdiff
path: root/Gestor.Common/Gestor.Common.Converters/SaldoWeightConverter.cs
diff options
context:
space:
mode:
Diffstat (limited to 'Gestor.Common/Gestor.Common.Converters/SaldoWeightConverter.cs')
-rw-r--r--Gestor.Common/Gestor.Common.Converters/SaldoWeightConverter.cs27
1 files changed, 27 insertions, 0 deletions
diff --git a/Gestor.Common/Gestor.Common.Converters/SaldoWeightConverter.cs b/Gestor.Common/Gestor.Common.Converters/SaldoWeightConverter.cs
new file mode 100644
index 0000000..51fb8b4
--- /dev/null
+++ b/Gestor.Common/Gestor.Common.Converters/SaldoWeightConverter.cs
@@ -0,0 +1,27 @@
+using System;
+using System.Globalization;
+using System.Windows;
+using System.Windows.Data;
+using System.Windows.Markup;
+
+namespace Gestor.Common.Converters;
+
+public class SaldoWeightConverter : MarkupExtension, IValueConverter
+{
+ public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
+ {
+ //IL_000b: Unknown result type (might be due to invalid IL or missing references)
+ //IL_0012: Unknown result type (might be due to invalid IL or missing references)
+ return (value != null && !(bool)value) ? FontWeights.Regular : FontWeights.Bold;
+ }
+
+ public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
+ {
+ return null;
+ }
+
+ public override object ProvideValue(IServiceProvider serviceProvider)
+ {
+ return this;
+ }
+}