Google maps not showing all of a sudden in Android

android, google-maps, java

Solution

Try these things if your code does not have these:

Try adding android:name="com.google.android.gms.maps.SupportMapFragment" to your fragment.xml.

Try using extend Fragment instead of extend SupportMapFragment.

onMapReady() is triggered by a call to getMapAsync() on your MapFragment be sure to have that.

Also check your manifest file if it lacks some permissions

<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="com.google.android.providers.gsf.permission.READ_GSERVICES" />
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />

<permission
android:name="your.package.name.permission.MAPS_RECEIVE"
android:protectionLevel="signature" />
<uses-permission android:name="your.package.name.permission.MAPS_RECEIVE"/>
<uses-feature
android:glEsVersion="0x00020000"
android:required="true"/>

Post your log cat so that the exact cause may be found out!!

Problem

I am currently developing an application in Android that uses Google maps. I have followed all the instructions like - Including the google play services dependency to my project - Downloading google play services in Android SDK - Creating an Android key from google developers console. - giving the necessary permissions The google maps were showing up normally as expected until suddenly a black screen starts appearing now. I get the following lines on logcat. W/ResourcesManager﹕ Asset path '/system/framework/com.android.media.remotedisplay.jar' does not exist or contains no resources. W/ResourcesManager﹕ Asset path '/system/framework/com.android.location.provider.jar' does not exist or contains no resources. I/Google Maps Android API﹕ Google Play services client version: 6587000 I/Google Maps Android API﹕ Google Play services package version: 6774436 This is the dependency I have in my build.gradle file compile 'com.google.android.gms:play-services:6.5.87' How do I resolve this issue? Is it due to some update to the google play service? If so I have checked the SDK and I have the latest Google play service installed. Kindly help anyone Here is the log cat ``` 02-19 13:53:01.212 14731-14749 D/OpenGLRenderer﹕ Render dirty regions requested: true 02-19 13:53:01.218 14731-14731 D/Atlas﹕ Validating map... 02-19 13:53:01.292 14731-14749 I/Adreno-EGL﹕ <qeglDrvAPI_eglInitialize:410>: QUALCOMM Build: 10/03/14, c40da3f, Ifda814c646 02-19 13:53:01.293 14731-14749 I/OpenGLRenderer﹕ Initialized EGL, version 1.4 02-19 13:53:01.311 14731-14749 D/OpenGLRenderer﹕ Enabling debug mode 0 02-19 13:53:04.472 14731-14731 I/x﹕ Making Creator dynamically 02-19 13:53:04.477 14731-14731 W/ResourcesManager﹕ Asset path '/system/framework/com.android.media.remotedisplay.jar' does not exist or contains no resources. 02-19 13:53:04.478 14731-14731 W/ResourcesManager﹕ Asset path '/system/framework/com.android.location.provider.jar' does not exist or contains no resources. 02-19 13:53:04.503 14731-14731 I/Google Maps Android API﹕ Google Play services client version: 6587000 02-19 13:53:04.515 14731-14731 I/Google Maps Android API﹕ Google Play services package version: 6774436 ```

Original source

Related problems