mirror of
https://github.com/holgerb83/ModernWpfPlayground.git
synced 2025-06-30 09:40:52 +02:00
removed warnings
This commit is contained in:
@ -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;
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user