Search in sources :

Example 1 with CourseFragment

use of com.tevinjeffrey.rutgersct.ui.course.CourseFragment in project Rutgers-Course-Tracker by tevjef.

the class SubjectFragment method startCourseFragement.

private void startCourseFragement(Bundle b) {
    CourseFragment courseFragment = new CourseFragment();
    courseFragment.setArguments(b);
    FragmentTransaction ft = getFragmentManager().beginTransaction();
    if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) {
        Transition sfTransition = TransitionInflater.from(getParentActivity()).inflateTransition(R.transition.sf_exit);
        setExitTransition(sfTransition.excludeTarget(Toolbar.class, true));
        courseFragment.setAllowEnterTransitionOverlap(false);
    } else {
        ft.setCustomAnimations(R.anim.enter, R.anim.exit, R.anim.pop_enter, R.anim.pop_exit);
    }
    startFragment(this, courseFragment, ft);
}
Also used : FragmentTransaction(android.app.FragmentTransaction) CourseFragment(com.tevinjeffrey.rutgersct.ui.course.CourseFragment) Transition(android.transition.Transition) Toolbar(android.support.v7.widget.Toolbar)

Aggregations

FragmentTransaction (android.app.FragmentTransaction)1 Toolbar (android.support.v7.widget.Toolbar)1 Transition (android.transition.Transition)1 CourseFragment (com.tevinjeffrey.rutgersct.ui.course.CourseFragment)1