18 lines
523 B
C#
18 lines
523 B
C#
using System;
|
|
using System.Windows.Data;
|
|
|
|
|
|
namespace WPFluent.Converters;
|
|
|
|
/// <summary>
|
|
/// 判断值是否为空
|
|
/// </summary>
|
|
internal class StringIsEmptyConverter : IValueConverter
|
|
{
|
|
public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
|
|
{ return string.IsNullOrEmpty(System.Convert.ToString(value)); }
|
|
|
|
public object? ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
|
|
{ return null; }
|
|
}
|