Leku icon indicating copy to clipboard operation
Leku copied to clipboard

when i click on map its not showing complete address

Open usmanokara opened this issue 4 years ago • 3 comments

Describe the bug

To Reproduce Steps to reproduce the behavior:

Expected behavior

Info Required

  • Which version of the library do you actually use?

  • Do you have the localization permission granted?

  • Are you sending parameters to the activity through the bundle?

  • Android monitor shows any log related to the library when the error is shown?

  • Any other thing that could help me to reproduce the error?

Screenshots

Smartphone:

  • Device: [e.g. Samsung S8]

Additional context

usmanokara avatar Jul 17 '20 06:07 usmanokara

I'm using version 7.2.0 because I need to support android v19 and above. When I click on the map it shows the current lat and lng coordinates in the display box.

What is required to display addresses after a map click is performed?

DJPretorius avatar Jul 13 '21 12:07 DJPretorius

I suspected it had something to do with the API key because the reverse geocoding didn't work. Then I came across this website, which I think should be made more noticeable in the readme of this repo. The part that solved the issue was the meta tag in the AndroidManifest I didn't have this set.

<meta-data
            android:name="com.google.android.geo.API_KEY"
            android:value="@string/google_maps_api" />

DJPretorius avatar Jul 14 '21 09:07 DJPretorius

Map addresses are provided by Google so it's possible that the map is not providing the desired address to display. Anyway, it should help to add the search zone like to allow more precise results:

.withSearchZone("es_ES")
.withSearchZone(SearchZoneRect(LatLng(26.525467, -18.910366), LatLng(43.906271, 5.394197)))

ferranpons avatar Jul 19 '21 11:07 ferranpons