You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: Microsoft.Toolkit.Uwp/Helpers/DispatcherHelper.cs
+4-4Lines changed: 4 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -22,7 +22,7 @@ public static class DispatcherHelper
22
22
/// <param name="priority">Dispatcher execution priority, default is normal.</param>
23
23
/// <returns>An awaitable <see cref="Task"/> for the operation.</returns>
24
24
/// <remarks>If the current thread has UI access, <paramref name="function"/> will be invoked directly.</remarks>
25
-
[Obsolete("This method should be replaced with CoreApplication.MainView.DispatcherQueue.EnqueueAsync(function, priority).")]
25
+
[Obsolete("This method should be replaced with dispatcherQueue.EnqueueAsync(function, priority), where dispatcherQueue is a DispatcherQueue instance that was retrieved from the UI thread and stored for later use.")]
@@ -36,7 +36,7 @@ public static Task ExecuteOnUIThreadAsync(Action function, CoreDispatcherPriorit
36
36
/// <param name="priority">Dispatcher execution priority, default is normal.</param>
37
37
/// <returns>An awaitable <see cref="Task{T}"/> for the operation.</returns>
38
38
/// <remarks>If the current thread has UI access, <paramref name="function"/> will be invoked directly.</remarks>
39
-
[Obsolete("This method should be replaced with CoreApplication.MainView.DispatcherQueue.EnqueueAsync(function, priority).")]
39
+
[Obsolete("This method should be replaced with dispatcherQueue.EnqueueAsync(function, priority), where dispatcherQueue is a DispatcherQueue instance that was retrieved from the UI thread and stored for later use.")]
@@ -49,7 +49,7 @@ public static Task<T> ExecuteOnUIThreadAsync<T>(Func<T> function, CoreDispatcher
49
49
/// <param name="function">Asynchronous function to be executed asynchronously on UI thread.</param>
50
50
/// <param name="priority">Dispatcher execution priority, default is normal.</param>
51
51
/// <returns>An awaitable <see cref="Task"/> for the operation.</returns>
52
-
[Obsolete("This method should be replaced with CoreApplication.MainView.DispatcherQueue.EnqueueAsync(function, priority).")]
52
+
[Obsolete("This method should be replaced with dispatcherQueue.EnqueueAsync(function, priority), where dispatcherQueue is a DispatcherQueue instance that was retrieved from the UI thread and stored for later use.")]
@@ -63,7 +63,7 @@ public static Task ExecuteOnUIThreadAsync(Func<Task> function, CoreDispatcherPri
63
63
/// <param name="function">Asynchronous function to be executed asynchronously on UI thread.</param>
64
64
/// <param name="priority">Dispatcher execution priority, default is normal.</param>
65
65
/// <returns>An awaitable <see cref="Task{T}"/> for the operation.</returns>
66
-
[Obsolete("This method should be replaced with CoreApplication.MainView.DispatcherQueue.EnqueueAsync(function, priority).")]
66
+
[Obsolete("This method should be replaced with dispatcherQueue.EnqueueAsync(function, priority), where dispatcherQueue is a DispatcherQueue instance that was retrieved from the UI thread and stored for later use.")]
0 commit comments