refactor behavior pager and fragment