0

My app should work only on Landscape mode, till iOS 13 release it was working fine. After iOS 13, I noticed that the Master page (menu page) is visible on iPad screen as if I used split-screen. I tried MasterPage.MasterBehavior = popover and also tried MasterPage.IsPresented = false; none of these are working.

I tried MasterPage.MasterBehavior = popover and also tried MasterPage.IsPresented = false; none of these are working.

Also, I wanted to know how to catch the click event of the "Menu" button.

enter image description here

ritu_o0o
  • 49
  • 6

1 Answers1

0

I wanted to know how to catch the click event of the "Menu" button.

You can listen to the IsPresentedChanged event:

 public partial class MainPage : MasterDetailPage
    {
        public MainPage()
        {
            InitializeComponent();

            masterPage.listView.ItemSelected += OnItemSelected;

            this.IsPresentedChanged += MainPage_IsPresentedChanged;

        }

        private void MainPage_IsPresentedChanged(object sender, EventArgs e)
        {
            Console.WriteLine("Menu Click");
        }
    }
nevermore
  • 15,432
  • 1
  • 12
  • 30
  • Thank you Jack, any lights on hiding on master page (menu page)?? – ritu_o0o Sep 30 '19 at 23:56
  • Are you using the latest Xamarin.forms version? It only happens when you use used split-screen? – nevermore Oct 01 '19 at 06:16
  • Yes, I am using the latest Xamarin.forms. As I mentioned MasterPage.MasterBehavior = popover is already there. JFYI: I am noticing this behaviour since iOS 13, before that it was working as expected. – ritu_o0o Oct 01 '19 at 23:45
  • I've the same problem: my app works until iOS 12 but with iOS 13 (only on iPad) the menu don't disappear. – Stefano Oct 07 '19 at 07:21
  • You guys can open an issue in Github if the problem still exist in the latest version. – nevermore Oct 08 '19 at 07:12
  • @JackHua-MSFT How you want me to open a ticket? also, how can I check the latest version ? – ritu_o0o Oct 19 '19 at 00:40
  • Is there a way that I an use iOS 12's runtime to run the code from xamarin, as if I built my app prior to iOS 13 release? – ritu_o0o Oct 19 '19 at 00:41
  • @user3496276 You can open a free Xamarin support case here:[xamarin support](https://support.microsoft.com/en-us/supportforbusiness/productselection?sapId=211dd84f-3474-c3c5-79bf-66db630c92a6) – nevermore Oct 21 '19 at 02:10
  • Any update on this issue? I am also facing this issue and trying to find a solution. – Dharmendra Kumar May 09 '20 at 18:39