From cb29cb5312091252911de4e3395cd0a51a256090 Mon Sep 17 00:00:00 2001 From: Giuseppe Lippolis Date: Fri, 24 Feb 2023 17:20:19 +0100 Subject: [PATCH] fix: Address Rule AVP1040 Type mismatch: CLR property type differs from the value type of {type} ```bash Avalonia.Media.IPen? Avalonia.Base (net6.0) .\src\Avalonia.Base\Media\GeometryDrawing.cs 55 Active ``` --- src/Avalonia.Base/Media/GeometryDrawing.cs | 4 ++-- src/Avalonia.Base/Media/PolyLineSegment.cs | 3 +-- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/src/Avalonia.Base/Media/GeometryDrawing.cs b/src/Avalonia.Base/Media/GeometryDrawing.cs index ac2dce1e42..abfd2e33ac 100644 --- a/src/Avalonia.Base/Media/GeometryDrawing.cs +++ b/src/Avalonia.Base/Media/GeometryDrawing.cs @@ -27,8 +27,8 @@ namespace Avalonia.Media /// /// Defines the property. /// - public static readonly StyledProperty PenProperty = - AvaloniaProperty.Register(nameof(Pen)); + public static readonly StyledProperty PenProperty = + AvaloniaProperty.Register(nameof(Pen)); /// /// Gets or sets the that describes the shape of this . diff --git a/src/Avalonia.Base/Media/PolyLineSegment.cs b/src/Avalonia.Base/Media/PolyLineSegment.cs index 55bfb33041..5c48c11e19 100644 --- a/src/Avalonia.Base/Media/PolyLineSegment.cs +++ b/src/Avalonia.Base/Media/PolyLineSegment.cs @@ -1,5 +1,4 @@ using System.Collections.Generic; -using Avalonia.Collections; namespace Avalonia.Media { @@ -20,7 +19,7 @@ namespace Avalonia.Media /// /// The points. /// - public AvaloniaList Points + public Points Points { get => GetValue(PointsProperty); set => SetValue(PointsProperty, value);