@Override
 public void onClick(View v) {
   // TODO Auto-generated method stub
   switch (v.getId()) {
     case R.id.get_black_list:
       getBlackList.setBackgroundDrawable(getResources().getDrawable(R.drawable.wifi_list_bg1));
       getWhiteList.setBackgroundDrawable(getResources().getDrawable(R.drawable.wifi_list_bg2));
       presenter.request(RequestParam.REQUEST_QUERY_ONE);
       break;
     case R.id.get_white_list:
       getBlackList.setBackgroundDrawable(getResources().getDrawable(R.drawable.wifi_list_bg2));
       getWhiteList.setBackgroundDrawable(getResources().getDrawable(R.drawable.wifi_list_bg1));
       presenter.request(RequestParam.REQUEST_QUERY_TWO);
       break;
     default:
       break;
   }
 }
  private void init() {
    // TODO Auto-generated method stub
    ((TextView) findViewById(R.id.activity_title)).setText("黑白名单");
    getBlackList = findViewById(R.id.get_black_list);
    getWhiteList = findViewById(R.id.get_white_list);
    presenter = new WifiWBPresenter(this);
    list = new ArrayList<WBModel>();
    context = this;

    pullToRefreshListView = (PullToRefreshListView) findViewById(R.id.wb_list);
    initRefreshListView();
    blackList = pullToRefreshListView.getRefreshableView();

    presenter.request(RequestParam.REQUEST_QUERY_ONE);

    adapter = new BlackAdapter();
    blackList.setAdapter(adapter);
  }