summaryrefslogtreecommitdiff
path: root/Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Bugzilla38105.cs
diff options
context:
space:
mode:
Diffstat (limited to 'Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Bugzilla38105.cs')
-rw-r--r--Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Bugzilla38105.cs59
1 files changed, 59 insertions, 0 deletions
diff --git a/Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Bugzilla38105.cs b/Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Bugzilla38105.cs
new file mode 100644
index 00000000..ebb353f6
--- /dev/null
+++ b/Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Bugzilla38105.cs
@@ -0,0 +1,59 @@
+using System;
+
+using Xamarin.Forms.CustomAttributes;
+
+#if UITEST
+using Xamarin.UITest;
+using NUnit.Framework;
+#endif
+
+namespace Xamarin.Forms.Controls
+{
+ [Preserve (AllMembers = true)]
+ [Issue (IssueTracker.Bugzilla, 38105, "RemovePage does not cause back arrow to go away on Android",
+ NavigationBehavior.PushModalAsync)]
+ internal class Bugzilla38105 : TestMasterDetailPage
+ {
+ protected override void Init ()
+ {
+ Detail = new NavigationPage (new ViewA ());
+
+ var button = new Button () { Text = "Click me" };
+ button.Clicked += (o, e) => {
+ var navPage = (NavigationPage)Detail;
+
+ var rootPage = navPage.CurrentPage;
+
+ navPage.PopToRootAsync (false);
+
+ navPage.Navigation.PushAsync (new ViewB ());
+
+ navPage.Navigation.RemovePage (rootPage);
+
+ IsPresented = false;
+ };
+
+ Master = new ContentPage () {
+ Title = "test",
+ Content = button
+ };
+ }
+
+ public class ViewA : ContentPage
+ {
+ public ViewA ()
+ {
+ Title = "View A";
+ }
+ }
+
+ public class ViewB : ContentPage
+ {
+ public ViewB ()
+ {
+ Title = "View B";
+ }
+ }
+ }
+}
+