예제 #1
0
 public ArticlesAdapter(Activity context, ArticlesFragment fragment)
 {
     try
     {
         HasStableIds    = true;
         ActivityContext = context;
         AFragment       = fragment;
     }
     catch (Exception e)
     {
         Console.WriteLine(e);
     }
 }
예제 #2
0
 public void SwitchHome()
 {
     FragmentTransaction transaction = fm.BeginTransaction();
     if (articlesFragment == null)
     {
         articlesFragment = new ArticlesFragment();
         transaction.Add(Resource.Id.frameContent, articlesFragment).Commit();
     }
     else
     {
         transaction.Show(articlesFragment).Commit();
     }
 }
예제 #3
0
        public void SwitchHome()
        {
            FragmentTransaction transaction = SupportFragmentManager.BeginTransaction();

            if (articlesFragment == null)
            {
                articlesFragment = new ArticlesFragment();
                transaction.Add(Resource.Id.frameContent, articlesFragment).CommitNowAllowingStateLoss();
            }
            else
            {
                transaction.Show(articlesFragment).CommitNowAllowingStateLoss();
            }
        }
예제 #4
0
        public void SwitchArticles()
        {
            FragmentTransaction transaction = fm.BeginTransaction();

            if (articleaFragment == null)
            {
                articleaFragment = new ArticlesFragment();
                transaction.Add(Resource.Id.frameContent, articleaFragment).Commit();
            }
            else
            {
                transaction.Show(articleaFragment).Commit();
            }
            toolbar.Title = Resources.GetString(Resource.String.article);
        }