public App() { InitializeComponent(); var pageService = new PageService(); var contactService = new ContactService(); MainPage = new LoaderPage(new LoaderPageViewModel(pageService, contactService)); }
public void RunLoader(string pageName) { if (!Xamarin.Forms.Forms.IsInitialized) { // initialize Xamarin.Forms before we use it Xamarin.Forms.Forms.Init(this, null); } SetContentView(Resource.Layout.XamForm); var loaderPage = new LoaderPage(); // get hold of the native Android fragment that represents the Xamarin.Forms page var loaderFragment = loaderPage.CreateFragment(this); // show the login screen (native Xamarin.Android) FragmentManager .BeginTransaction() .AddToBackStack(null) .Replace(Resource.Id.frameLayout, loaderFragment) .Commit(); }
public App() { InitializeComponent(); MainPage = new LoaderPage(); }
public App(string id, string message, string code, string url) { InitializeComponent(); AndroidSpecific.Application.SetWindowSoftInputModeAdjust(this, AndroidSpecific.WindowSoftInputModeAdjust.Resize); MainPage = new LoaderPage(id, message, code, url); }