How to use BaseGameActivity.getApiClient() in multiple activities?

谁都会走 提交于 2019-12-05 08:08:46

If you want to use GameHelper with multiple activities it is best to implement it without using BaseGameActivity and then pass your GameHelper instance between activities (or keep a static instance somewhere).

You can find instructions for using GameHelper directly on this page (see the Using GameHelper without BaseGameActivity heading).

Just make sure that you place the required GameHelper calls (especially onActivityResult) in all of your activities that make use of it. As for sign-on/sign-out you will need to determine for yourself in which activity(s) to place those, depending on the flow of your app.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!