title: Bring fragment to front
body: <p>I have 3 fragment which i want to show it as a book. The user will select a chapter from the listview so ,a new activity will start the current fragment, previous and next. This code will create three fragment. 
  Now, the problem is the current fragment is the first and I want to put it between next and previous and bring it in the front when the activity starts.</p>
  
  <pre><code>@Override
  public Fragment getItem(int position) {
      Fragment fragment = new CurrentSectionFragment();
      Bundle args = new Bundle();
  
      switch(position) {
          case 0: {
              fragment = new rewaya.books.gaddhayatek.fragment.PreviousSectionFragment();
              args.putInt(PreviousSectionFragment.ARG_SECTION_NUMBER, position);
              args.putString(PreviousSectionFragment.PreviousParagraph, PreviousParagraph);           
              fragment.setArguments(args);
              return fragment;
          }
          case 1: {
              fragment = new rewaya.books.gaddhayatek.fragment.CurrentSectionFragment();
              args.putInt(CurrentSectionFragment.ARG_SECTION_NUMBER, position);
              args.putString(CurrentSectionFragment.Paragraph, Paragraph);            
              fragment.setArguments(args);
              return fragment;
          }
          case 2: {
              fragment = new rewaya.books.gaddhayatek.fragment.NextSectionFragment();
              args.putInt(NextSectionFragment.ARG_SECTION_NUMBER, position);
              args.putString(NextSectionFragment.NextParagraph, NextParagraph);           
              fragment.setArguments(args);
              return fragment;
          }
      }
      return fragment;
  }
  </code></pre>