13 lines
330 B
C#
13 lines
330 B
C#
using System;
|
|
using Windows.UI.Xaml.Controls;
|
|
|
|
namespace UWPClient
|
|
{
|
|
public static class PageExtension
|
|
{
|
|
public static async void InvokeIfRequired(this Page page, Action action)
|
|
{
|
|
await page.Dispatcher.RunAsync(Windows.UI.Core.CoreDispatcherPriority.High, () => action());
|
|
}
|
|
}
|
|
}
|