Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/android/231.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Android 谷歌地图不是在wifi中的特定设备上加载,而是在3g网络中工作_Android_Google Maps_Android Fragments_Google Maps Android Api 2_Handshake - Fatal编程技术网

Android 谷歌地图不是在wifi中的特定设备上加载,而是在3g网络中工作

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

我使用带有片段的google map v2,google maps加载良好,但在一些设备(如MiUi和华为)中,其未在wifi连接中加载地图,并显示未知的Handhshake错误,下面是代码片段

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权限吗?是的,我添加了所有必需的权限。