mirror of
https://github.com/bitwarden/android.git
synced 2024-12-24 01:48:25 +03:00
pop page on delete success
This commit is contained in:
parent
3f8f29dfe7
commit
46a8ffa5ae
4 changed files with 10 additions and 5 deletions
|
@ -145,7 +145,10 @@ namespace Bit.App.Pages
|
|||
{
|
||||
if(DoOnce())
|
||||
{
|
||||
await _vm.DeleteAsync();
|
||||
if(await _vm.DeleteAsync())
|
||||
{
|
||||
await Navigation.PopModalAsync();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -424,7 +424,7 @@ namespace Bit.App.Pages
|
|||
public async Task<bool> DeleteAsync()
|
||||
{
|
||||
var confirmed = await _platformUtilsService.ShowDialogAsync(AppResources.DoYouReallyWantToDelete,
|
||||
null, AppResources.Yes, AppResources.No);
|
||||
null, AppResources.Yes, AppResources.Cancel);
|
||||
if(!confirmed)
|
||||
{
|
||||
return false;
|
||||
|
@ -436,7 +436,6 @@ namespace Bit.App.Pages
|
|||
await _deviceActionService.HideLoadingAsync();
|
||||
_platformUtilsService.ShowToast("success", null, AppResources.ItemDeleted);
|
||||
_messagingService.Send("deletedCipher");
|
||||
await Page.Navigation.PopModalAsync();
|
||||
return true;
|
||||
}
|
||||
catch(ApiException e)
|
||||
|
|
|
@ -127,7 +127,10 @@ namespace Bit.App.Pages
|
|||
{
|
||||
if(DoOnce())
|
||||
{
|
||||
await _vm.DeleteAsync();
|
||||
if(await _vm.DeleteAsync())
|
||||
{
|
||||
await Navigation.PopModalAsync();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -251,7 +251,7 @@ namespace Bit.App.Pages
|
|||
public async Task<bool> DeleteAsync()
|
||||
{
|
||||
var confirmed = await _platformUtilsService.ShowDialogAsync(AppResources.DoYouReallyWantToDelete,
|
||||
null, AppResources.Yes, AppResources.No);
|
||||
null, AppResources.Yes, AppResources.Cancel);
|
||||
if(!confirmed)
|
||||
{
|
||||
return false;
|
||||
|
|
Loading…
Reference in a new issue