Android_maps_conflict_avoidance.com.google.googlenav.map.BaseTileRequest.readResponseData

androidandroid-mapviewmapactivity

I have a app with two MapActivity, each one have its MapView, with the same API key.

It work OK in Android 3.x and 4.x devices, but error in 2.3.x when switch activity.

Can anybody help?

Here is the error:

08-26 21:00:03.160: W/System.err(1858): IOException processing: 26
08-26 21:00:03.160: W/System.err(1858): java.io.IOException: Server returned: 3
08-26 21:00:03.160: W/System.err(1858): at android_maps_conflict_avoidance.com.google.googlenav.map.BaseTileRequest.readResponseData(BaseTileRequest.java:115)
08-26 21:00:03.160: W/System.err(1858): at android_maps_conflict_avoidance.com.google.googlenav.map.MapService$MapTileRequest.readResponseData(MapService.java:1473)
08-26 21:00:03.160: W/System.err(1858): at android_maps_conflict_avoidance.com.google.googlenav.datarequest.DataRequestDispatcher.processDataRequest(DataRequestDispatcher.java:1117)
08-26 21:00:03.160: W/System.err(1858): at android_maps_conflict_avoidance.com.google.googlenav.datarequest.DataRequestDispatcher.serviceRequests(DataRequestDispatcher.java:994)
08-26 21:00:03.160: W/System.err(1858): at android_maps_conflict_avoidance.com.google.googlenav.datarequest.DataRequestDispatcher$DispatcherServer.run(DataRequestDispatcher.java:1702)

Best Answer

Answer :

Use map in nested Framelayout when you are using map with fixed dimension.

      <FrameLayout
            android:id="@+id/mapview_bg"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:background="@color/silver" 
            >

            <com.google.android.maps.MapView
                android:id="@+id/deal_mapview"
                android:layout_width="146dp"
                android:layout_height="106dp"
                android:apiKey="@string/google_map_api_key"
                android:clickable="true" />
       </FrameLayout>

Enjoy :)

Related Topic