Google Play服务需要更新,但Play商店无需更新

时间:2014-07-02 08:48:07

标签: java android google-maps google-play-services

我开发了一款使用GoogleMap的应用。我刚刚更新了Eclipse中的Android插件(带有Android L库),并重新导入了GooglePlayService库等。

所以,我在Nexus 7(4.4.2)上重新编译并且在我的手机上工作得很好(4.4.2中的Sony Xperia Z),GenyMotion仿真器(4.4.2)。但它不适用于两款三星Galaxy S4(4.4.2)和4.4.2中的另一款三星平板电脑。事实上,我用这种方式检查了GooglePlay服务的版本:

resultCode = GooglePlayServicesUtil.isGooglePlayServicesAvailable(this.getActivity());
        // resultCode = ConnectionResult.SERVICE_VERSION_UPDATE_REQUIRED;
        if (resultCode != ConnectionResult.SUCCESS) {
            if (GooglePlayServicesUtil.isUserRecoverableError(resultCode)) {
                GooglePlayServicesUtil.getErrorDialog(resultCode, this.getActivity(), 1).show();
                rootView = inflater.inflate(R.layout.fragment_googleplayerror, container, false);
                return rootView;
            } else {
                Log.i(Tag, "This device is not supported.");
                getActivity().finish();
            }
        }

        else {
            rootView = inflater.inflate(R.layout.activity_tracking, container, false);
        }

因此,在应用无法运行的设备中,Android检测到GPS(GooglePlayService)不是最新的,并重定向到GooglePlayStore,但在Play商店中只有两个按钮:卸载和打开。我还读到导入GooglePlayServiceForFroyo可以解析pb。但是,为什么它在某些设备上工作,但在其他设备上没有,即使它们是在同一个Android版本上?

1 个答案:

答案 0 :(得分:1)

你能试试看问题是否已经解决了吗? Google Play Services 5.0的推出刚刚完成推出(1小时前),如本博文中所述:http://android-developers.blogspot.com/2014/07/google-play-services-5.html

可能是您在部署完成之前使用了5.0 SDK,但由于您的设备未收到更新,因此无法运行。

相关问题