本文介绍了如何从谷歌加帐户在谷歌加上整合的Android注销的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我下面的工作,但它不工作后,再迅速注销其登录在app
私人无效signOutFromGplus(){ 如果(mGoogleApiClient.isConnected()){ // clearCookies(); Plus.AccountApi
.clearDefaultAccount(mGoogleApiClient); .mGoogleApiClient.disconnect(); .mGoogleApiClient.connect();
}
}
解决方案
私人无效googlePlusLogout(){ 如果(mGoogleApiClient.isConnected()){
Plus.AccountApi.clearDefaultAccount(mGoogleApiClient);
mGoogleApiClient.disconnect();
mGoogleApiClient.connect();
}
}
尝试调用按钮点击此方法。
I did following work but it is not working after logout it quickly again login in app
private void signOutFromGplus() {
if (mGoogleApiClient.isConnected()) {
// clearCookies();
Plus.AccountApi
.clearDefaultAccount(mGoogleApiClient);
.mGoogleApiClient.disconnect();
.mGoogleApiClient.connect();
}
}
解决方案
private void googlePlusLogout() {
if (mGoogleApiClient.isConnected()) {
Plus.AccountApi.clearDefaultAccount(mGoogleApiClient);
mGoogleApiClient.disconnect();
mGoogleApiClient.connect();
}
}
Try to call this method on button click.
这篇关于如何从谷歌加帐户在谷歌加上整合的Android注销的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!