Situation: Building an application using Xamarin Forms and MasterDetail component.
Question: How Can I render a specific page on Android based on a PageRender? and keep the Drawer?
Edit
public class MasterBacASable : MasterDetailPage
{
public MasterBacASable ()
{
Icon = null;
Title = "The title";
Detail = (new FirstPage ());
Master = new AppMenuPage ();
}
}
[assembly:ExportRenderer (typeof(BacASable.FirstPage), typeof(BacASable.Droid.FirstPageContentRennderer))]
namespace BacASable.Droid
{
public class FirstPageContentRennderer : PageRenderer
{
public FirstPageContentRennderer ()
{
}
protected override void OnElementChanged (ElementChangedEventArgs<Page> e)
{
base.OnElementChanged (e);
var activity = this.Context as Activity;
var v = activity.LayoutInflater.Inflate (Resource.Layout.AndroidView,this,false);
AddView (v);
}
}
}