removed warnings

This commit is contained in:
2020-02-18 22:22:07 +01:00
parent ca000aac74
commit d130364643
13 changed files with 29 additions and 69 deletions

View File

@ -11,7 +11,7 @@ using Brushes = System.Windows.Media.Brushes;
using FontFamily = System.Windows.Media.FontFamily;
using Point = System.Windows.Point;
namespace LsBricks.Controls
namespace ModernWpfPlayground.PropertyPresenter2
{
/// <summary>
/// Makes an Bitmap from every Imageformat.
@ -97,28 +97,4 @@ namespace LsBricks.Controls
/// <inheritdoc />
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture) => Binding.DoNothing;
}
/// <summary>
/// negate double converter
/// </summary>
[ValueConversion(typeof(double), typeof(double))]
public class NegateDoubleConverter : IValueConverter
{
/// <summary>Converts a value. </summary>
/// <returns>A converted value. If the method returns null, the valid null value is used.</returns>
/// <param name="value">The value produced by the binding source.</param>
/// <param name="targetType">The type of the binding target property.</param>
/// <param name="parameter">The converter parameter to use.</param>
/// <param name="culture">The culture to use in the converter.</param>
public object Convert(object value, Type targetType, object parameter, CultureInfo culture) =>
value is double d ? -d : throw new ArgumentException(nameof(value) + " is not a doubles");
/// <summary>Converts a value. </summary>
/// <returns>A converted value. If the method returns null, the valid null value is used.</returns>
/// <param name="value">The value that is produced by the binding target.</param>
/// <param name="targetType">The type to convert to.</param>
/// <param name="parameter">The converter parameter to use.</param>
/// <param name="culture">The culture to use in the converter.</param>
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture) => Binding.DoNothing;
}
}