tasks not mapa latino how google gms exist example error does custom android google-maps xamarin xamarin.android mvvmcross

android - not - MarkerClick funciona pero InfoWindowClick no abre ViewModel



xamarin forms maps xaml (0)

La siguiente implementación de MarkerClick funciona perfectamente bien. Pude abrir otra vista a través de ShowViewModel

View.cs

mMap.MarkerClick += MMap_MarkerClick; private void MMap_MarkerClick(object sender, GoogleMap.MarkerClickEventArgs e) { ViewModel.MapInfoSelected(e.Marker.Title); }

ViewModel.cs

public void MapInfoSelected(string name) { ShowViewModel<StudentViewModel>(new { studentName = name}); }

InfoWindowClick no se InfoWindowClick para abrir otra Vista.

View.cs

mMap.InfoWindowClick += MMap_InfoWindowClick; private void MMap_InfoWindowClick(object sender, GoogleMap.InfoWindowClickEventArgs e) { ViewModel.MapInfoSelected(e.Marker.Title); }

ViewModel.cs

public void MapInfoSelected(string name) { // it hits here, but does not hit `StudentViewModel` Init() method, the app is frozen and do nothing ShowViewModel<StudentViewModel>(new { studentName = name}); }

Incluso probé SetOnInfoWindowClickListener siguiente manera, tampoco abre la Vista.

mMap.SetOnInfoWindowClickListener(this); public void OnInfoWindowClick(Marker marker) { ViewModel.MapInfoSelected(marker.Title); }

ACTUALIZAR:

Incluso golpea el método OnPause() , pero aún no llama al StudentViewModel Init () de InfoWindowClick si uso el evento InfoWindowClick

public override void OnPause() { base.OnPause(); mMap.InfoWindowClick -= MMap_InfoWindowClick; }