|
|
|
@ -23,17 +23,24 @@ namespace BookApp.ViewModel
|
|
|
|
|
public INavigation Navigation { get; set; }
|
|
|
|
|
|
|
|
|
|
public ICommand MenuItemsFiltre { get; private set; }
|
|
|
|
|
public ICommand MenuItemsCommand { get; private set; }
|
|
|
|
|
public ICommand BookSelected { get; private set; }
|
|
|
|
|
|
|
|
|
|
public ICommand BackButtonCommand { get; private set; }
|
|
|
|
|
|
|
|
|
|
// Command du menu
|
|
|
|
|
private ICommand _itemTappedCommand;
|
|
|
|
|
public ICommand ItemTappedCommand =>
|
|
|
|
|
_itemTappedCommand ??= new CommandPersonnal<ViewModelMenuItem>(
|
|
|
|
|
async (item) => await OnItemSelected(item)
|
|
|
|
|
);
|
|
|
|
|
|
|
|
|
|
public ViewModelNavigation()
|
|
|
|
|
{
|
|
|
|
|
MenuItemsFiltre = new CommandPersonnal(async () => await OnItemSelected(SelectedItem));
|
|
|
|
|
MenuItemsCommand = new CommandPersonnal(async () => await OnItemSelected(SelectedItem));
|
|
|
|
|
|
|
|
|
|
BackButtonCommand = new CommandPersonnal(async () => await BackButton(this, EventArgs.Empty));
|
|
|
|
|
BackButtonCommand = new CommandPersonnal(
|
|
|
|
|
async () => await BackButton(this, EventArgs.Empty)
|
|
|
|
|
);
|
|
|
|
|
|
|
|
|
|
BookSelected = new CommandPersonnal(async () => await OnBookSelected(SelectedBook));
|
|
|
|
|
}
|
|
|
|
|