Android 谷歌地图不是在wifi中的特定设备上加载,而是在3g网络中工作
我使用带有片段的google map v2,google maps加载良好,但在一些设备(如MiUi和华为)中,其未在wifi连接中加载地图,并显示未知的Handhshake错误,下面是代码片段Android 谷歌地图不是在wifi中的特定设备上加载,而是在3g网络中工作,android,google-maps,android-fragments,google-maps-android-api-2,handshake,Android,Google Maps,Android Fragments,Google Maps Android Api 2,Handshake,我使用带有片段的google map v2,google maps加载良好,但在一些设备(如MiUi和华为)中,其未在wifi连接中加载地图,并显示未知的Handhshake错误,下面是代码片段 private void initilizeMap() { if (googleMap == null) { googleMap = ((MapFragment) getActivity().getFragmentManager().findFragmentById(R.id.m
private void initilizeMap() {
if (googleMap == null) {
googleMap = ((MapFragment) getActivity().getFragmentManager().findFragmentById(R.id.map)).getMap();
buildGoogleApiClient();
setupLocationClient();
// check if map is created successfully or not
if (googleMap == null) {
Toast.makeText(getActivity(), "Sorry! unable to create maps", Toast.LENGTH_SHORT).show();
}
}
}
你有wifi权限吗?是的,我添加了所有必需的权限。