Rename to 'SetPropertyAndInvalidateEffectGraph'

このコミットが含まれているのは:
Sergio Pedri committed 2024-10-21 10:13:09 -07:00
1 親 ce23fb4eec
コミット 38116e6e46
7ファイル変更
+24 -15

検索条件に一致するファイルはありません

+10 -1
ファイルの表示
@@ -1,5 +1,6 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Diagnostics.CodeAnalysis;
using Microsoft.Graphics.Canvas;
@@ -144,7 +145,7 @@ public abstract partial class CanvasEffect : ICanvasImage, ICanvasImageInterop
/// <param name="storage">The storage for the effect property value.</param>
/// <param name="value">The new effect property value to set.</param>
/// <param name="invalidationType">The invalidation type to request.</param>
protected void SetAndInvalidateEffectGraph<T>([NotNullIfNotNull(nameof(value))] ref T storage, T value, CanvasEffectInvalidationType invalidationType = CanvasEffectInvalidationType.Update)
protected void SetPropertyAndInvalidateEffectGraph<T>([NotNullIfNotNull(nameof(value))] ref T storage, T value, CanvasEffectInvalidationType invalidationType = CanvasEffectInvalidationType.Update)
{
if (EqualityComparer<T>.Default.Equals(storage, value))
{
@@ -156,6 +157,14 @@ public abstract partial class CanvasEffect : ICanvasImage, ICanvasImageInterop
InvalidateEffectGraph(invalidationType);
}
/// <inheritdoc cref="SetPropertyAndInvalidateEffectGraph"/>
[Obsolete("Use 'SetPropertyAndInvalidateEffectGraph' instead.")]
[EditorBrowsable(EditorBrowsableState.Never)]
protected void SetAndInvalidateEffectGraph<T>([NotNullIfNotNull(nameof(value))] ref T storage, T value, CanvasEffectInvalidationType invalidationType = CanvasEffectInvalidationType.Update)
{
SetPropertyAndInvalidateEffectGraph(ref storage, value, invalidationType);
}
/// <summary>
/// Disposes any disposable resources in the current instance.
/// </summary>