diff --git a/HKCardOUT/Converter/TextForegroundConvert.cs b/HKCardOUT/Converter/TextForegroundConvert.cs index 5b046a1..e1ec79a 100644 --- a/HKCardOUT/Converter/TextForegroundConvert.cs +++ b/HKCardOUT/Converter/TextForegroundConvert.cs @@ -23,6 +23,33 @@ namespace Converter return default; } + public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture) + { + throw new NotImplementedException(); + } + } + public class LocationConvert : IValueConverter + { + public object Convert(object value, Type targetType, object parameter, CultureInfo culture) + { + if (value != null) + { + if (value.ToString().Contains("6")) + return value.ToString().Replace("6", "1"); + else if (value.ToString().Contains("5")) + return value.ToString().Replace("5", "2"); + else if (value.ToString().Contains("4")) + return value.ToString().Replace("4", "3"); + else if (value.ToString().Contains("3")) + return value.ToString().Replace("3", "4"); + else if (value.ToString().Contains("2")) + return value.ToString().Replace("2", "5"); + else if (value.ToString().Contains("1")) + return value.ToString().Replace("1", "6"); + } + return default; + } + public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture) { throw new NotImplementedException(); diff --git a/HKCardOUT/Views/AdWindow.xaml b/HKCardOUT/Views/AdWindow.xaml index d8cb8e5..964c39e 100644 --- a/HKCardOUT/Views/AdWindow.xaml +++ b/HKCardOUT/Views/AdWindow.xaml @@ -16,6 +16,7 @@ mc:Ignorable="d"> +