我一周以来一直在讨论这个问题.一直在搜索有关此问题的类似主题,但仍然无法解决我的问题.
Prolem是当我试图在Polar m600磨损或磨损模拟器(Android V 7.1.1和API25)上运行我的程序时,他们给我这条消息"Google Play服务已过时.需要11011000但找到了10289574" .
我在android开发者网站上关注了"获取最后一个已知位置"部分.(网站链接https://developer.android.com/training/location/retrieve-current.html#play-services)
这是我正在使用的Mainactivity代码
public class MainActivity extends Activity {
private FusedLocationProviderClient mFusedLocationClient;
public Location mLastLocation;
private TextView mTextView;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
final WatchViewStub stub = (WatchViewStub) findViewById(R.id.watch_view_stub);
stub.setOnLayoutInflatedListener(new WatchViewStub.OnLayoutInflatedListener() {
@Override
public void onLayoutInflated(WatchViewStub stub) {
mTextView = (TextView) stub.findViewById(R.id.text);
}
});
mFusedLocationClient = LocationServices.getFusedLocationProviderClient(this);
if (ActivityCompat.checkSelfPermission(this, android.Manifest.permission.ACCESS_FINE_LOCATION)
!= PackageManager.PERMISSION_GRANTED && ActivityCompat.checkSelfPermission(this, android.Manifest.permission.ACCESS_COARSE_LOCATION)
!= PackageManager.PERMISSION_GRANTED) {
return;
}
mFusedLocationClient.getLastLocation()
.addOnSuccessListener(this, new OnSuccessListener<Location>() {
@Override
public void onSuccess(Location …
Run Code Online (Sandbox Code Playgroud) W / GooglePlayServicesUtil(8660):Google Play服务已过期。需要13400000但找到了13280022
我正在尝试在Nexus S和Pixel Phone模拟器上的google_maps_plugin存储库中运行示例应用程序,它们均在Android Pie上运行。
有问题,而不是颤抖的一面。我未能应用他们的解决方案。
到目前为止我做了什么
1)我的模拟器中没有此选项 /sf/answers/3171894771/
2)这是在flutter标签上,但是解决方案是一个依赖项修复 /sf/answers/3778754871/
3)我不清楚如何在过时的Gradle Google Play服务中将Google Play服务降级。需要10298000但找到10084470
4)尝试使用模拟器从此链接下载播放服务,但是由于我没有playstore应用,因此无法将我的帐户与其关联,https://play.google.com/store/apps/details? id = com.google.android.gms
此Google帐户尚未与设备关联。请先在设备上访问Play商店应用,然后再安装应用。