Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is it possible to disable Google Play Services automatic sign in upon start up?

Tags:

android

I have incorporated the newer google play game services into my app, and I can see that upon start up of my app, there is an automatic sign in. I was wondering if this could be disabled as I would like to give that option to the user. I have searched the code provided by BaseGameUtils, but I cant see any sign in functions being called anywhere.

Any help would be appreciated!

Thanks :)

like image 978
opposite of you Avatar asked Mar 31 '14 00:03

opposite of you


People also ask

How to disable Google Play Services on Android?

To check if you can or can’t disable Google Play Services, navigate to S ettings > Apps > All apps > Google Play Services. If the Uninstall (Disable) option is grayed out, you are out of luck. If not, you can disable the app. But, there are some consequences to it.

What happens if I turn off Google Play?

People for whom you turn on Google Play can use it to download and purchase mobile content and apps in their accounts. Users who have Google Play turned off retain limited access to the service, as described in the next section.

How do I add Google Play to my account?

Sign in to your Google Admin console . Sign in using your administrator account (does not end in @gmail.com). From the Admin console Home page, go to Apps Additional Google services. Click Google Play . Tip: Scroll to see all services. Or at the left, choose a Filter to narrow the list. For example, filter by status or popularity.

How do I Turn Off sign in with Google?

On the “Security” page, scroll down to the “Signing in to Other Sites” section. Here, click the “Signing in with Google” option. On the next page, under the “Signing in with Google” section, turn off the “Google Account Sign-In Prompts” toggle. You’ll see an “Updated” message at the lower-left corner of your browser.


Video Answer


1 Answers

As per this issue, auto sign on is the recommended pattern as stated in their best practices video. As they point out in the FAQ (questions 4 and 5):

[4] Why is GameHelper/BaseGameActivity attempting to sign in on application startup?

The default behavior of BaseGameActivity and GameHelper is to show the user the sign-in flow (consent dialogs, etc) as soon as your application starts. Naturally, once the user signs in for the first time, they won't see the consent flow again, so it will be a seamless experience. It is important for the user to sign in as early as possible so your application can take advantage of the Google Play Games API right away (for example, saving the user's progress using Cloud Save, unlocking achievements, etc). If the user cancels the sign-in flow, BaseGameAcitivity/GameHelper will remember that cancellation. If the total number of cancellations reaches a predefined maximum (by default, 3), the user will no longer be prompted to sign in on application startup. If that happens, they can still sign in by clicking your application's Sign In button, if you provide one.

[5] I don't like the new "auto sign in" feature of GameHelper. How can I disable it?

To disable this feature and return to the old behavior, you can edit GameHelper.java and set the DEFAULT_MAX_SIGN_IN_ATTEMPTS constant to 0, or call GameHelper.setMaxAutoSignInAttempts(0) at runtime, before calling GameHelper.setup() (or, correspondingly, from your Activity's onCreate method).

like image 134
ianhanniballake Avatar answered Oct 04 '22 00:10

ianhanniballake