Skip to content

Commit 0b4a5f0

Browse files
Sergio0694Copilot
andcommitted
Put REFERENCE_ASSEMBLY branch first in conditional attribute blocks
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
1 parent 37375ee commit 0b4a5f0

14 files changed

Lines changed: 49 additions & 49 deletions

src/WinRT.Runtime2/Windows.Foundation/AsyncActionProgressHandler{TProgress}.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@ namespace Windows.Foundation;
1414
/// <typeparam name="TProgress">The type of progress information.</typeparam>
1515
/// <param name="asyncInfo">The asynchronous action.</param>
1616
/// <param name="progressInfo">The progress information.</param>
17-
#if WINDOWS_RUNTIME_IMPLEMENTATION_ASSEMBLY
18-
[WindowsRuntimeMetadata("Windows.Foundation.FoundationContract")]
19-
#elif WINDOWS_RUNTIME_REFERENCE_ASSEMBLY
17+
#if WINDOWS_RUNTIME_REFERENCE_ASSEMBLY
2018
[ContractVersion(typeof(FoundationContract), 65536u)]
19+
#elif WINDOWS_RUNTIME_IMPLEMENTATION_ASSEMBLY
20+
[WindowsRuntimeMetadata("Windows.Foundation.FoundationContract")]
2121
#endif
2222
public delegate void AsyncActionProgressHandler<TProgress>(IAsyncActionWithProgress<TProgress> asyncInfo, TProgress progressInfo);

src/WinRT.Runtime2/Windows.Foundation/AsyncActionWithProgressCompletedHandler{TProgress}.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@ namespace Windows.Foundation;
1414
/// <typeparam name="TProgress">The type of progress information.</typeparam>
1515
/// <param name="asyncInfo">The asynchronous action.</param>
1616
/// <param name="asyncStatus">One of the enumeration values.</param>
17-
#if WINDOWS_RUNTIME_IMPLEMENTATION_ASSEMBLY
18-
[WindowsRuntimeMetadata("Windows.Foundation.FoundationContract")]
19-
#elif WINDOWS_RUNTIME_REFERENCE_ASSEMBLY
17+
#if WINDOWS_RUNTIME_REFERENCE_ASSEMBLY
2018
[ContractVersion(typeof(FoundationContract), 65536u)]
19+
#elif WINDOWS_RUNTIME_IMPLEMENTATION_ASSEMBLY
20+
[WindowsRuntimeMetadata("Windows.Foundation.FoundationContract")]
2121
#endif
2222
public delegate void AsyncActionWithProgressCompletedHandler<TProgress>(IAsyncActionWithProgress<TProgress> asyncInfo, AsyncStatus asyncStatus);

src/WinRT.Runtime2/Windows.Foundation/AsyncOperationCompletedHandler{TResult}.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@ namespace Windows.Foundation;
1414
/// <typeparam name="TResult">The result type.</typeparam>
1515
/// <param name="asyncInfo">The asynchronous action.</param>
1616
/// <param name="asyncStatus">One of the enumeration values.</param>
17-
#if WINDOWS_RUNTIME_IMPLEMENTATION_ASSEMBLY
18-
[WindowsRuntimeMetadata("Windows.Foundation.FoundationContract")]
19-
#elif WINDOWS_RUNTIME_REFERENCE_ASSEMBLY
17+
#if WINDOWS_RUNTIME_REFERENCE_ASSEMBLY
2018
[ContractVersion(typeof(FoundationContract), 65536u)]
19+
#elif WINDOWS_RUNTIME_IMPLEMENTATION_ASSEMBLY
20+
[WindowsRuntimeMetadata("Windows.Foundation.FoundationContract")]
2121
#endif
2222
public delegate void AsyncOperationCompletedHandler<TResult>(IAsyncOperation<TResult> asyncInfo, AsyncStatus asyncStatus);

src/WinRT.Runtime2/Windows.Foundation/AsyncOperationProgressHandler{TResult, TProgress}.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,9 @@ namespace Windows.Foundation;
1515
/// <typeparam name="TProgress">The type of progress information.</typeparam>
1616
/// <param name="asyncInfo">The asynchronous action.</param>
1717
/// <param name="progressInfo">The progress information.</param>
18-
#if WINDOWS_RUNTIME_IMPLEMENTATION_ASSEMBLY
19-
[WindowsRuntimeMetadata("Windows.Foundation.FoundationContract")]
20-
#elif WINDOWS_RUNTIME_REFERENCE_ASSEMBLY
18+
#if WINDOWS_RUNTIME_REFERENCE_ASSEMBLY
2119
[ContractVersion(typeof(FoundationContract), 65536u)]
20+
#elif WINDOWS_RUNTIME_IMPLEMENTATION_ASSEMBLY
21+
[WindowsRuntimeMetadata("Windows.Foundation.FoundationContract")]
2222
#endif
2323
public delegate void AsyncOperationProgressHandler<TResult, TProgress>(IAsyncOperationWithProgress<TResult, TProgress> asyncInfo, TProgress progressInfo);

src/WinRT.Runtime2/Windows.Foundation/AsyncOperationWithProgressCompletedHandler{TResult, TProgress}.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,9 @@ namespace Windows.Foundation;
1515
/// <typeparam name="TProgress">The type of progress information.</typeparam>
1616
/// <param name="asyncInfo">The asynchronous action.</param>
1717
/// <param name="asyncStatus">One of the enumeration values.</param>
18-
#if WINDOWS_RUNTIME_IMPLEMENTATION_ASSEMBLY
19-
[WindowsRuntimeMetadata("Windows.Foundation.FoundationContract")]
20-
#elif WINDOWS_RUNTIME_REFERENCE_ASSEMBLY
18+
#if WINDOWS_RUNTIME_REFERENCE_ASSEMBLY
2119
[ContractVersion(typeof(FoundationContract), 65536u)]
20+
#elif WINDOWS_RUNTIME_IMPLEMENTATION_ASSEMBLY
21+
[WindowsRuntimeMetadata("Windows.Foundation.FoundationContract")]
2222
#endif
2323
public delegate void AsyncOperationWithProgressCompletedHandler<TResult, TProgress>(IAsyncOperationWithProgress<TResult, TProgress> asyncInfo, AsyncStatus asyncStatus);

src/WinRT.Runtime2/Windows.Foundation/AsyncStatus.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,14 +13,14 @@ namespace Windows.Foundation;
1313
/// Represents the status for an asynchronous operation.
1414
/// </summary>
1515
/// <see href="https://learn.microsoft.com/windows/win32/api/asyncinfo/ne-asyncinfo-asyncstatus"/>
16-
#if WINDOWS_RUNTIME_IMPLEMENTATION_ASSEMBLY
16+
#if WINDOWS_RUNTIME_REFERENCE_ASSEMBLY
17+
[SupportedOSPlatform("Windows10.0.10240.0")]
18+
[ContractVersion(typeof(FoundationContract), 65536u)]
19+
#elif WINDOWS_RUNTIME_IMPLEMENTATION_ASSEMBLY
1720
[WindowsRuntimeMetadata("Windows.Foundation.FoundationContract")]
1821
[WindowsRuntimeClassName("Windows.Foundation.IReference`1<Windows.Foundation.AsyncStatus>")]
1922
[WindowsRuntimeReferenceType(typeof(AsyncStatus?))]
2023
[ABI.Windows.Foundation.AsyncStatusComWrappersMarshaller]
21-
#elif WINDOWS_RUNTIME_REFERENCE_ASSEMBLY
22-
[SupportedOSPlatform("Windows10.0.10240.0")]
23-
[ContractVersion(typeof(FoundationContract), 65536u)]
2424
#endif
2525
public enum AsyncStatus
2626
{

src/WinRT.Runtime2/Windows.Foundation/Collections/CollectionChange.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,15 +19,15 @@ namespace Windows.Foundation.Collections;
1919
/// <see cref="IMapChangedEventArgs{K}.Key"/> property to determine the location of the change.
2020
/// </remarks>
2121
/// <see href="https://learn.microsoft.com/uwp/api/windows.foundation.collections.collectionchange"/>
22-
#if WINDOWS_RUNTIME_IMPLEMENTATION_ASSEMBLY
22+
#if WINDOWS_RUNTIME_REFERENCE_ASSEMBLY
23+
[SupportedOSPlatform("Windows10.0.10240.0")]
24+
[ContractVersion(typeof(FoundationContract), 65536u)]
25+
#elif WINDOWS_RUNTIME_IMPLEMENTATION_ASSEMBLY
2326
[WindowsRuntimeMetadata("Windows.Foundation.FoundationContract")]
2427
[WindowsRuntimeClassName("Windows.Foundation.IReference`1<Windows.Foundation.Collections.CollectionChange>")]
2528
[WindowsRuntimeMetadataTypeName("Windows.Foundation.Collections.CollectionChange")]
2629
[WindowsRuntimeReferenceType(typeof(CollectionChange?))]
2730
[ABI.Windows.Foundation.Collections.CollectionChangeComWrappersMarshaller]
28-
#elif WINDOWS_RUNTIME_REFERENCE_ASSEMBLY
29-
[SupportedOSPlatform("Windows10.0.10240.0")]
30-
[ContractVersion(typeof(FoundationContract), 65536u)]
3131
#endif
3232
public enum CollectionChange
3333
{

src/WinRT.Runtime2/Windows.Foundation/Collections/MapChangedEventHandler{K, V}.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,9 @@ namespace Windows.Foundation.Collections;
1515
/// <typeparam name="V">The type of values in the observable map.</typeparam>
1616
/// <param name="sender">The observable map that changed.</param>
1717
/// <param name="event">The description of the change that occurred in the map.</param>
18-
#if WINDOWS_RUNTIME_IMPLEMENTATION_ASSEMBLY
19-
[WindowsRuntimeMetadata("Windows.Foundation.FoundationContract")]
20-
#elif WINDOWS_RUNTIME_REFERENCE_ASSEMBLY
18+
#if WINDOWS_RUNTIME_REFERENCE_ASSEMBLY
2119
[ContractVersion(typeof(FoundationContract), 65536u)]
20+
#elif WINDOWS_RUNTIME_IMPLEMENTATION_ASSEMBLY
21+
[WindowsRuntimeMetadata("Windows.Foundation.FoundationContract")]
2222
#endif
2323
public delegate void MapChangedEventHandler<K, V>(IObservableMap<K, V> sender, IMapChangedEventArgs<K> @event);

src/WinRT.Runtime2/Windows.Foundation/Collections/VectorChangedEventHandler{T}.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@ namespace Windows.Foundation.Collections;
1414
/// <typeparam name="T">The type of elements in the observable vector.</typeparam>
1515
/// <param name="sender">The observable vector that changed.</param>
1616
/// <param name="event">The description of the change that occurred in the vector.</param>
17-
#if WINDOWS_RUNTIME_IMPLEMENTATION_ASSEMBLY
18-
[WindowsRuntimeMetadata("Windows.Foundation.FoundationContract")]
19-
#elif WINDOWS_RUNTIME_REFERENCE_ASSEMBLY
17+
#if WINDOWS_RUNTIME_REFERENCE_ASSEMBLY
2018
[ContractVersion(typeof(FoundationContract), 65536u)]
19+
#elif WINDOWS_RUNTIME_IMPLEMENTATION_ASSEMBLY
20+
[WindowsRuntimeMetadata("Windows.Foundation.FoundationContract")]
2121
#endif
2222
public delegate void VectorChangedEventHandler<T>(IObservableVector<T> sender, IVectorChangedEventArgs @event);

src/WinRT.Runtime2/Windows.Foundation/Point.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,14 +19,14 @@ namespace Windows.Foundation;
1919
/// Represents X and Y coordinate values that define a point in a two-dimensional plane.
2020
/// </summary>
2121
/// <see href="https://learn.microsoft.com/uwp/api/windows.foundation.point"/>
22-
#if WINDOWS_RUNTIME_IMPLEMENTATION_ASSEMBLY
22+
#if WINDOWS_RUNTIME_REFERENCE_ASSEMBLY
23+
[SupportedOSPlatform("Windows10.0.10240.0")]
24+
[ContractVersion(typeof(FoundationContract), 65536u)]
25+
#elif WINDOWS_RUNTIME_IMPLEMENTATION_ASSEMBLY
2326
[WindowsRuntimeMetadata("Windows.Foundation.FoundationContract")]
2427
[WindowsRuntimeClassName("Windows.Foundation.IReference`1<Windows.Foundation.Point>")]
2528
[WindowsRuntimeReferenceType(typeof(Point?))]
2629
[ABI.Windows.Foundation.PointComWrappersMarshaller]
27-
#elif WINDOWS_RUNTIME_REFERENCE_ASSEMBLY
28-
[SupportedOSPlatform("Windows10.0.10240.0")]
29-
[ContractVersion(typeof(FoundationContract), 65536u)]
3030
#endif
3131
public struct Point : IEquatable<Point>, IFormattable
3232
{

0 commit comments

Comments
 (0)