protected void handleViews(int level) {
   mAdapter.swapData(null);
   switch (level) {
     case 0:
       mRegisterEventButton.hide();
       mUpcomingEventsButton.hide();
       mQueryTrackedEntityInstancesButton.hide();
       break;
     case 1:
       mRegisterEventButton.show();
       mUpcomingEventsButton.show();
       mQueryTrackedEntityInstancesButton.show();
   }
 }
  @Override
  protected View getListViewHeader(Bundle savedInstanceState) {
    View header =
        getLayoutInflater(savedInstanceState)
            .inflate(R.layout.fragment_select_program_header, mListView, false);
    mRegisterEventButton = (FloatingActionButton) header.findViewById(R.id.register_new_event);
    mQueryTrackedEntityInstancesButton =
        (FloatingActionButton) header.findViewById(R.id.query_trackedentityinstances_button);
    mUpcomingEventsButton = (FloatingActionButton) header.findViewById(R.id.upcoming_events_button);
    mRegisterEventButton.setOnClickListener(this);
    mQueryTrackedEntityInstancesButton.setOnClickListener(this);
    mUpcomingEventsButton.setOnClickListener(this);

    mRegisterEventButton.hide();
    mUpcomingEventsButton.hide();
    mQueryTrackedEntityInstancesButton.hide();
    return header;
  }