Code example for ViewFlipper

Methods: getCurrentView, showPrevious

0
 
	} 
	 
	@Override 
	public void onBackPressed(){ 
		if(vf.getCurrentView().getId() == vflistview){
			btnLogoutClicked(iv);
			//showToast("whatup"); 
			 
		} 
		else if(vf.getCurrentView().getId() == vfloginview){
			super.onBackPressed(); 
			//showToast("whatup"); 
		} 
		else{ 
			//showToast(vf.getId() + ""); 
			//Log.v("viewstuff", vf.getCurrentView().getId()+ ""); 
			 
			vf.showPrevious();
		} 
	} 
 
	@Override 
	public boolean onCreateOptionsMenu(Menu menu) {