Code example for ActionBarActivity

Methods: finish, startActivity

0
		protected void onPostExecute(String result) {
			 
			if(isFreshInstall()){ 
				 
				Intent mIntent = new Intent(SplashScreen.this, LoginActivity.class);
				startActivity(mIntent);
				finish(); 
				return; 
			} 
			 
			/* 
			if(needsToChangePassword()){ 
				Intent i = new Intent(SplashScreen.this, ChangePasswordActivity.class); 
				startActivity(i); 
				finish(); 
				return; 
			} 
			*/ 
 
			if(isTokenAndDataExist()){ 
				Intent mIntent = new Intent(SplashScreen.this, MainActivity.class);
				startActivity(mIntent);
			}else{ 
				Intent mIntent = new Intent(SplashScreen.this, LoginActivity.class);
				startActivity(mIntent);
			} 
 
			// Close the SplashScreen and show the main screen 
			finish(); 
 
		} 
 
		@Override 
		protected void onPreExecute() {