public override bool OnOptionsItemSelected(Xamarin.ActionbarSherlockBinding.Views.IMenuItem item) { switch (item.ItemId) { case Resource.Id.homeAsUp: // TODO handle clicking the app icon/logo return false; case Resource.Id.menu_refresh: // switch to a progress animation item.SetActionView(Resource.Layout.indeterminate_progress_action); return true; case Resource.Id.menu_both: // rotation animation of green fragment RotateLeftFrag(); return true; case Resource.Id.menu_text: // alpha animation of blue fragment ObjectAnimator alpha = ObjectAnimator.OfFloat(rightFrag.View, "alpha", 1f, 0f); alpha.RepeatMode = ValueAnimatorRepeatMode.Reverse; alpha.RepeatCount = 1; alpha.SetDuration(800); alpha.Start(); return true; case Resource.Id.menu_logo: useLogo = !useLogo; item.SetChecked(useLogo); base.SupportActionBar.SetDisplayUseLogoEnabled(useLogo); return true; case Resource.Id.menu_up: showHomeUp = !showHomeUp; item.SetChecked(showHomeUp); base.SupportActionBar.SetDisplayHomeAsUpEnabled(showHomeUp); return true; case Resource.Id.menu_nav_tabs: item.SetChecked(true); ShowTabsNav(); return true; case Resource.Id.menu_nav_label: item.SetChecked(true); ShowStandardNav(); return true; case Resource.Id.menu_nav_drop_down: item.SetChecked(true); ShowDropDownNav(); return true; case Resource.Id.menu_bak_none: item.SetChecked(true); base.SupportActionBar.SetBackgroundDrawable(null); return true; case Resource.Id.menu_bak_gradient: item.SetChecked(true); base.SupportActionBar.SetBackgroundDrawable(Resources.GetDrawable(Resource.Drawable.ad_action_bar_gradient_bak)); return true; default: return base.OnOptionsItemSelected(item); } }