public void onClick(View v){
  if (v == mPopupView) {
    switchViews(true);
  }
}

public void onClick ( View v ) { if ( v == mPopupView ) { switchViews ( true ) ; } }
this is called when the popup window is pressed .
