Esempio n. 1
0
        private void mLeftDrawer_ItemClick(object sender, AdapterView.ItemClickEventArgs e)
        {
            Fragment            fragment = null;
            FragmentTransaction ft       = SupportFragmentManager.BeginTransaction();

            if (mDrawerLayout.IsDrawerOpen(mLeftDrawer))
            {
                //Right Drawer is already open, close it
                mDrawerLayout.CloseDrawer(mLeftDrawer);
            }
            switch (e.Position)
            {
            case 0:
                fragment = new OrdersFragment();
                break;

            //case 2:
            //    StartActivity(typeof(OrderInDayActivity));
            //    break;
            //case 3:
            //    StartActivity(typeof(CustomerCheckinActivity));
            //    break;
            case 3:
                apre.DeleteAccessKey(AppPreferences.m_workContextKey);
                StartActivity(typeof(MainActivity));
                break;

            default:
                break;
            }
            ft.Replace(Resource.Id.fragment, fragment).Commit();
        }