How to get final position after dragging a map?

stesvisstesvis USMember ✭✭✭

I am using Xamarin.Forms.GoogleMaps and I need to handle the event when you drag the map to a new position.

Example: I drag the map, and when I stop I need to call an API that returns a list of restaurants in that position, within a range.

The problem is that there is no such event. The are two other events:

  • CameraMoveStarted (when you start dragging the map): I can't use this, obviously, because it doesn't give me the final position
  • CameraMoving (for as long as you drag the map): I can use this, but it would fire the call to the API a huge number of times, while I only need to do it once, on the final position

Is there any way to achieve this?

Thank you

Best Answer

  • stesvisstesvis US ✭✭✭
    Accepted Answer

    Nevermind, the event is called CameraIdled.

Answers

  • stesvisstesvis USMember ✭✭✭
    Accepted Answer

    Nevermind, the event is called CameraIdled.

Sign In or Register to comment.