In my Android app i have a Google plus login activity with the method
@Override
public void onConnected(Bundle connectionHint) {
String accountName = mPlusClient.getAccountName();
Toast.makeText(this, accountName + " is connected.", Toast.LENGTH_LONG).show();
...
Intent userDetailsCaptureIntent = new Intent(this,UserDetailsCaptureActivity.class);
startActivity(userDetailsCaptureIntent);
}
In this method after the user has been signed in, i start the UserDetailsCaptureActivity
where details about the user are collected and stored in a Google App Engine backend.The problem is after i enter the details and save them i don't want Activity to ever start again, but it starts because i keep calling it the onConnected()
method. How do i let the Activity with the onConnected method know that UserDetailsCaptureActivity
should only be called once? If this is confusing am willing to explain further.