From fda700a8d392d3ca3b61a2daa5a80fec3820c2e5 Mon Sep 17 00:00:00 2001 From: Yan Maniez Date: Thu, 26 Sep 2019 16:59:47 +0200 Subject: [PATCH] Tests shell en comm --- .../AideDeJeu/Views/Library/ItemsPage.xaml.cs | 6 ++ AideDeJeu/AideDeJeu/Views/MainShell.xaml | 100 +++++++++++++++++- AideDeJeu/AideDeJeu/Views/MainShell.xaml.cs | 15 ++- 3 files changed, 116 insertions(+), 5 deletions(-) diff --git a/AideDeJeu/AideDeJeu/Views/Library/ItemsPage.xaml.cs b/AideDeJeu/AideDeJeu/Views/Library/ItemsPage.xaml.cs index 7842ea77..fa20f2f5 100644 --- a/AideDeJeu/AideDeJeu/Views/Library/ItemsPage.xaml.cs +++ b/AideDeJeu/AideDeJeu/Views/Library/ItemsPage.xaml.cs @@ -34,6 +34,12 @@ namespace AideDeJeu.Views.Library //mdMarkdown.NavigateToLink = async (s) => await itemsViewModel.Main.Navigator.NavigateToLinkAsync(s); } + + public ItemsPage(string id) + { + InitializeComponent(); + + } public ItemsPage() { InitializeComponent(); diff --git a/AideDeJeu/AideDeJeu/Views/MainShell.xaml b/AideDeJeu/AideDeJeu/Views/MainShell.xaml index 78fab567..109adb87 100644 --- a/AideDeJeu/AideDeJeu/Views/MainShell.xaml +++ b/AideDeJeu/AideDeJeu/Views/MainShell.xaml @@ -1,13 +1,105 @@  - + xmlns:pc="clr-namespace:AideDeJeu.Views.PlayerCharacter" + xmlns:library="clr-namespace:AideDeJeu.Views.Library" + x:Class="AideDeJeu.Views.MainShell"> + + + + + + + + + + + + + + + + + + + + + + l5r_index_hd.md + + + + + + + + + + + l5r_index_hd.md + + + + + + + + + + + l5r_index_hd.md + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/AideDeJeu/AideDeJeu/Views/MainShell.xaml.cs b/AideDeJeu/AideDeJeu/Views/MainShell.xaml.cs index e812c15a..2e5c08df 100644 --- a/AideDeJeu/AideDeJeu/Views/MainShell.xaml.cs +++ b/AideDeJeu/AideDeJeu/Views/MainShell.xaml.cs @@ -3,7 +3,7 @@ using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; - +using System.Windows.Input; using Xamarin.Forms; using Xamarin.Forms.Xaml; @@ -15,6 +15,19 @@ namespace AideDeJeu.Views public MainShell() { InitializeComponent(); + BindingContext = this; + } + + public ICommand ShellNavigateCommand + { + get + { + return new Command(async (path) => await ExecuteShellNavigateCommandAsync(path)); + } + } + private async Task ExecuteShellNavigateCommandAsync(string path) + { + await Shell.Current.GoToAsync(path); } } } \ No newline at end of file