diff --git a/FlyoutNavigation/FlyoutNavigation.csproj b/FlyoutNavigation/FlyoutNavigation.csproj index 3ec2aae..8824ac4 100644 --- a/FlyoutNavigation/FlyoutNavigation.csproj +++ b/FlyoutNavigation/FlyoutNavigation.csproj @@ -36,16 +36,11 @@ + - - - {3FFBFFF8-5560-4EDE-82E5-3FFDFBBA8A50} - MonoTouch.Dialog - - diff --git a/FlyoutNavigation/FlyoutNavigationController.cs b/FlyoutNavigation/FlyoutNavigationController.cs index 1aa5243..9a4f11e 100644 --- a/FlyoutNavigation/FlyoutNavigationController.cs +++ b/FlyoutNavigation/FlyoutNavigationController.cs @@ -209,12 +209,16 @@ private void NavigationItemSelected (int index) SelectedIndexChanged (); return; } + + var isOpen = false; - if (mainView != null) + if (mainView != null) { mainView.RemoveFromSuperview (); + isOpen = IsOpen; + } CurrentViewController = ViewControllers [SelectedIndex]; var frame = View.Bounds; - if (IsOpen || ShouldStayOpen) + if (isOpen || ShouldStayOpen) frame.X = menuWidth; setViewSize ();