[A] Fix regression on NavAnimationInProgress (#341)
authorPaul DiPietro <pauldipietro@users.noreply.github.com>
Tue, 13 Sep 2016 11:39:02 +0000 (06:39 -0500)
committerRui Marinho <me@ruimarinho.net>
Tue, 13 Sep 2016 11:39:02 +0000 (12:39 +0100)
Xamarin.Forms.Platform.Android/AppCompat/NavigationPageRenderer.cs

index 396fe13..b2b9108 100644 (file)
@@ -607,8 +607,6 @@ namespace Xamarin.Forms.Platform.Android.AppCompat
                                                transaction.Show(toShow);
                                        else
                                                transaction.Add(Id, toShow);
-
-                                       ((Platform)Element.Platform).NavAnimationInProgress = false;
                                }
                                else
                                {
@@ -617,7 +615,6 @@ namespace Xamarin.Forms.Platform.Android.AppCompat
                                        transaction.Hide(currentToHide);
                                        transaction.Add(Id, fragment);
                                        fragments.Add(fragment);
-                                       ((Platform)Element.Platform).NavAnimationInProgress = false;
                                }
                        }
                        transaction.Commit();
@@ -657,6 +654,7 @@ namespace Xamarin.Forms.Platform.Android.AppCompat
                        }
 
                        Context.HideKeyboard(this);
+                       ((Platform)Element.Platform).NavAnimationInProgress = false;
 
                        // 200ms is how long the animations are, and they are "reversible" in the sense that starting another one slightly before it's done is fine