Beispiel #1
0
 /**
  * Adds a new slide
  *
  * @param fragment Instance of Fragment which should be added as slide
  */
 public void addSlide(@NonNull Fragment fragment) {
   fragments.add(fragment);
   if (isWizardMode) {
     setOffScreenPageLimit(fragments.size());
   }
   mPagerAdapter.notifyDataSetChanged();
 }
Beispiel #2
0
 public void addSlide(@NonNull MyFragment fragment) {
   fragments.add(fragment);
   mPagerAdapter.notifyDataSetChanged();
 }
Beispiel #3
0
 public void addSlide(@NonNull Fragment fragment, @NonNull Context context) {
   fragments.add(Fragment.instantiate(context, fragment.getClass().getName()));
   mPagerAdapter.notifyDataSetChanged();
 }