Created
August 14, 2014 21:37
-
-
Save koalahamlet/4db8a946562c4daf9ba2 to your computer and use it in GitHub Desktop.
revoke android access G+
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private void revokeGplusAccess() { | |
if (mGoogleApiClient.isConnected()) { | |
Plus.AccountApi.clearDefaultAccount(mGoogleApiClient); | |
Plus.AccountApi.revokeAccessAndDisconnect(mGoogleApiClient) | |
.setResultCallback(new ResultCallback<Status>() { | |
@Override | |
public void onResult(Status arg0) { | |
Log.e(TAG, "User access revoked!"); | |
mGoogleApiClient.connect(); | |
updateUI(false); | |
} | |
}); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment