another exception handler
This commit is contained in:
parent
1f0c10a5e3
commit
4902d49fcd
1 changed files with 7 additions and 2 deletions
|
@ -8,6 +8,7 @@ using Android.Gms.Games;
|
|||
using Android.OS;
|
||||
using Android.Views;
|
||||
using Android.Widget;
|
||||
using GameAnalyticsSDK;
|
||||
using Microsoft.Xna.Framework;
|
||||
using MLEM.Extensions;
|
||||
using MLEM.Misc;
|
||||
|
@ -78,8 +79,12 @@ namespace Android {
|
|||
protected override void OnActivityResult(int requestCode, Result result, Intent data) {
|
||||
base.OnActivityResult(requestCode, result, data);
|
||||
// Connect again after logging in to Google Play game services, but only if we haven't tried yet
|
||||
try {
|
||||
if (requestCode == AndroidPlatform.GooglePlayLoginRequest && (int) result != GamesActivityResultCodes.ResultSignInFailed)
|
||||
this.platform.GoogleApi.Connect();
|
||||
} catch (Exception e) {
|
||||
GameAnalytics.NewErrorEvent(GAErrorSeverity.Error, "OnActivityResult " + e);
|
||||
}
|
||||
}
|
||||
|
||||
public override void OnWindowFocusChanged(bool hasFocus) {
|
||||
|
|
Loading…
Reference in a new issue