Skip to content

Commit 19207d0

Browse files
committed
Update UpdateService.cs
1 parent 9a267d6 commit 19207d0

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/Files.App/Services/UpdateService.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
using Microsoft.UI.Xaml.Controls;
77
using System.IO;
88
using System.Net.Http;
9+
using Windows.Foundation.Metadata;
910
using Windows.Services.Store;
1011
using Windows.Storage;
1112
using WinRT.Interop;
@@ -146,6 +147,9 @@ private static async Task<bool> ShowDialogAsync()
146147
PrimaryButtonText = "ConsentDialogPrimaryButtonText".GetLocalizedResource()
147148
};
148149

150+
if (ApiInformation.IsApiContractPresent("Windows.Foundation.UniversalApiContract", 8))
151+
dialog.XamlRoot = MainWindow.Instance.Content.XamlRoot;
152+
149153
ContentDialogResult result = await dialog.TryShowAsync();
150154

151155
return result == ContentDialogResult.Primary;

0 commit comments

Comments
 (0)