From 3b1f6a695fe72b2c47e209e9c890d6e1f7fc601e Mon Sep 17 00:00:00 2001 From: Eric House Date: Thu, 8 Nov 2012 06:38:35 -0800 Subject: [PATCH] don't show "can't do GCM" Toast on Kindle Fire --- .../src/org/eehouse/android/xw4/GCMIntentService.java | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/xwords4/android/XWords4/src/org/eehouse/android/xw4/GCMIntentService.java b/xwords4/android/XWords4/src/org/eehouse/android/xw4/GCMIntentService.java index 682b90c67..e9eb0e995 100644 --- a/xwords4/android/XWords4/src/org/eehouse/android/xw4/GCMIntentService.java +++ b/xwords4/android/XWords4/src/org/eehouse/android/xw4/GCMIntentService.java @@ -73,27 +73,22 @@ public class GCMIntentService extends GCMBaseIntentService { public static void init( Application app ) { - DbgUtils.logf( "GCMIntentService.init()" ); - int sdkVersion = Integer.valueOf(android.os.Build.VERSION.SDK); + int sdkVersion = Integer.valueOf( android.os.Build.VERSION.SDK ); if ( 8 <= sdkVersion ) { try { GCMRegistrar.checkDevice( app ); - GCMRegistrar.checkManifest( app ); + // GCMRegistrar.checkManifest( app ); final String regId = GCMRegistrar.getRegistrationId( app ); if (regId.equals("")) { - DbgUtils.logf( "registering..." ); GCMRegistrar.register( app, GCMConsts.SENDER_ID ); - } else { - DbgUtils.logf( "Already registered: id=\"%s\"", regId ); } String curID = XWPrefs.getGCMDevID( app ); if ( ! curID.equals( regId ) ) { - DbgUtils.logf( "saved bad id: %s", curID ); XWPrefs.setGCMDevID( app, regId ); } } catch ( UnsupportedOperationException uoe ) { - DbgUtils.showf( app, "Device can't do GCM; am I on an emulator?" ); + DbgUtils.logf( "Device can't do GCM." ); } } }