1
0
mirror of https://github.com/bitwarden/mobile synced 2025-12-18 01:03:24 +00:00

fab on view page

This commit is contained in:
Kyle Spearrin
2019-05-09 14:12:30 -04:00
parent da2ec4a38e
commit 056b9fd2de
2 changed files with 609 additions and 574 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -17,7 +17,18 @@ namespace Bit.App.Pages
_vm = BindingContext as ViewPageViewModel; _vm = BindingContext as ViewPageViewModel;
_vm.Page = this; _vm.Page = this;
_vm.CipherId = cipherId; _vm.CipherId = cipherId;
SetActivityIndicator(); SetActivityIndicator(_mainContent);
if(Device.RuntimePlatform == Device.iOS)
{
_absLayout.Children.Remove(_fab);
}
else
{
ToolbarItems.RemoveAt(0);
_fab.Clicked = EditButton_Clicked;
_mainLayout.Padding = new Thickness(0, 0, 0, 75);
}
} }
protected override async void OnAppearing() protected override async void OnAppearing()
@@ -38,7 +49,7 @@ namespace Bit.App.Pages
} }
} }
}); });
await LoadOnAppearedAsync(_scrollView, true, () => _vm.LoadAsync()); await LoadOnAppearedAsync(_scrollView, true, () => _vm.LoadAsync(), _mainContent);
} }
protected override void OnDisappearing() protected override void OnDisappearing()
@@ -63,5 +74,10 @@ namespace Bit.App.Pages
await Navigation.PushModalAsync(new NavigationPage(new AddEditPage(_vm.CipherId))); await Navigation.PushModalAsync(new NavigationPage(new AddEditPage(_vm.CipherId)));
} }
} }
private void EditButton_Clicked(object sender, System.EventArgs e)
{
EditToolbarItem_Clicked(sender, e);
}
} }
} }