Hi,

Many Google Applications allow you to switch between Google Accounts and 
show you the currently connected account.

For example Google Fit, Gmail, Google+, etc...


>From the perspective of the code I call .connect() on the Google Client and 
enter a loop of
- connection failed
- launch automatic resolution
- get activity result
- retry connect

until I finally connect.
This is documented in many places, here for example: 
https://developers.google.com/android/guides/api-client

On the UX side what happens is that the user is presented with multiple 
dialogs asking every time something different.

One of the dialog ask to chose an Account between the ones available on the 
phone (it probably automatically resolve without user interaction if 
there's only one account configured).

How do you query the Google Client to know which account is currently 
connected?

I found no documentation about it anywhere.

The closest thing I found is this:
https://developers.google.com/android/reference/com/google/android/gms/common/AccountPicker

but I do not create the picker, it's something completely handled by the 
Play Services in the procedure I described above.

Thank you,
Daniele

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Android Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to