mirror of
https://github.com/bitwarden/mobile
synced 2025-12-11 13:53:29 +00:00
user dialogs on UWP for loading
This commit is contained in:
@@ -1,4 +1,5 @@
|
|||||||
using Bit.App.Abstractions;
|
using Acr.UserDialogs;
|
||||||
|
using Bit.App.Abstractions;
|
||||||
using Bit.App.Models.Page;
|
using Bit.App.Models.Page;
|
||||||
using Coding4Fun.Toolkit.Controls;
|
using Coding4Fun.Toolkit.Controls;
|
||||||
using System;
|
using System;
|
||||||
@@ -18,6 +19,13 @@ namespace Bit.UWP.Services
|
|||||||
{
|
{
|
||||||
public class DeviceActionService : IDeviceActionService
|
public class DeviceActionService : IDeviceActionService
|
||||||
{
|
{
|
||||||
|
private readonly IUserDialogs _userDialogs;
|
||||||
|
|
||||||
|
public DeviceActionService(IUserDialogs userDialogs)
|
||||||
|
{
|
||||||
|
_userDialogs = userDialogs;
|
||||||
|
}
|
||||||
|
|
||||||
public bool CanOpenFile(string fileName) => true;
|
public bool CanOpenFile(string fileName) => true;
|
||||||
|
|
||||||
public void ClearCache()
|
public void ClearCache()
|
||||||
@@ -143,5 +151,20 @@ namespace Bit.UWP.Services
|
|||||||
IsHitTestVisible = false
|
IsHitTestVisible = false
|
||||||
}.Show();
|
}.Show();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void ShowLoading(string text)
|
||||||
|
{
|
||||||
|
_userDialogs.ShowLoading(text, MaskType.Black);
|
||||||
|
}
|
||||||
|
|
||||||
|
public void HideLoading()
|
||||||
|
{
|
||||||
|
_userDialogs.HideLoading();
|
||||||
|
}
|
||||||
|
|
||||||
|
public Task LaunchAppAsync(string appName, Xamarin.Forms.Page page)
|
||||||
|
{
|
||||||
|
throw new NotImplementedException();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -188,6 +188,9 @@
|
|||||||
</Page>
|
</Page>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
<PackageReference Include="Acr.UserDialogs">
|
||||||
|
<Version>6.5.1</Version>
|
||||||
|
</PackageReference>
|
||||||
<PackageReference Include="Microsoft.NETCore.UniversalWindowsPlatform">
|
<PackageReference Include="Microsoft.NETCore.UniversalWindowsPlatform">
|
||||||
<Version>6.0.5</Version>
|
<Version>6.0.5</Version>
|
||||||
</PackageReference>
|
</PackageReference>
|
||||||
|
|||||||
Reference in New Issue
Block a user