void OnBackPressed(object sender, ActivityEventArgs e) { if ((sender as IMenuItem).ItemId == global::Android.Resource.Id.Home) { FragmentManager.PopBackStack(); } }
public override bool OnOptionsItemSelected(IMenuItem item) { EventHandler <ActivityEventArgs> handler = OptionsItemSelected; if (handler != null) { var args = new ActivityEventArgs(); foreach (EventHandler <ActivityEventArgs> @delegate in handler.GetInvocationList()) { @delegate(item, args); if (args.Handled) { break; } } } return(base.OnOptionsItemSelected(item)); }