From 0c0ef2118b3fcc2f9d302da5f399ea445ca6b40e Mon Sep 17 00:00:00 2001 From: luevard Date: Mon, 14 Nov 2022 16:50:20 +0100 Subject: [PATCH] =?UTF-8?q?Bug=20retour=20lors=20de=20la=20d=C3=A9connexio?= =?UTF-8?q?n=20r=C3=A9solu?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Sources/IHM/MainPage.xaml.cs | 6 +++++- Sources/IHM/Settings.xaml.cs | 6 ++++++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/Sources/IHM/MainPage.xaml.cs b/Sources/IHM/MainPage.xaml.cs index 9aae00c..7056a7a 100644 --- a/Sources/IHM/MainPage.xaml.cs +++ b/Sources/IHM/MainPage.xaml.cs @@ -50,7 +50,11 @@ namespace IHM { await DisplayAlert(s, s1, s2); } - + protected override bool OnBackButtonPressed() + { + return true; + } + public ICommand TapCommand => new Command(async (page) => await Shell.Current.GoToAsync(page)); } } \ No newline at end of file diff --git a/Sources/IHM/Settings.xaml.cs b/Sources/IHM/Settings.xaml.cs index 52f390b..4227d77 100644 --- a/Sources/IHM/Settings.xaml.cs +++ b/Sources/IHM/Settings.xaml.cs @@ -1,5 +1,8 @@ namespace IHM; + using Model; +using System.Diagnostics; + public partial class Settings : ContentPage { public Manager Mgr => (App.Current as App).Manager; @@ -14,6 +17,9 @@ public partial class Settings : ContentPage } private async void NavigateTo() { + OnBackButtonPressed(); + Debug.WriteLine(base.OnBackButtonPressed()); await Navigation.PushModalAsync(new MainPage()); } + } \ No newline at end of file