AIR Android GCM ANE无法使用操作脚本3获取注册Id

AIR Android GCM ANE无法使用操作脚本3获取注册Id,android,actionscript-3,air,google-cloud-messaging,Android,Actionscript 3,Air,Google Cloud Messaging,我在游戏中使用推送通知,因为它支持图标、声音和振动,使通知有意义 这是我的密码: var gcm:Gcm = new Gcm(senderId); gcm.addEventListener(GcmEvent.REGISTERED, onRegistered); gcm.vibrate = true; gcm.showNotificationWhenAppRunning = true; gcm.register(); trace(gcm.getRegistrationId); //get a b

我在游戏中使用推送通知,因为它支持图标、声音和振动,使通知有意义

这是我的密码:

var gcm:Gcm = new Gcm(senderId); 
gcm.addEventListener(GcmEvent.REGISTERED, onRegistered);
gcm.vibrate = true;
gcm.showNotificationWhenAppRunning = true;
gcm.register();
trace(gcm.getRegistrationId); //get a blank String ""
trace(gcm.check()); // get false
如果我在我的设备android 4.3上运行它,我成功地获得gcm.getRegistrationId,并在gcm.check中获得true; 然而,如果我在其他设备android 4.0/4.1上运行它,我会得到空白字符串和false

有人能帮忙吗?

试试看

       trace(_ex.getRegistrationId);