private void Layer_MarkerSelected(object sender, MarkerSelectedEventArgs e) { PopulationMarker marker = (PopulationMarker)e.P0; if (marker != null) { if (currentToast != null) { currentToast.Cancel(); } currentToast = Toast.MakeText(sampleContext, marker.Name + "\n" + marker.Population, ToastLength.Short); currentToast.Show(); } }
private void MapsGettingStarted_MarkerSelected(object sender, MarkerSelectedEventArgs e) { if (e.MapMarker != null) { Toast.IsVisible = true; CustomMarker custommarker = (CustomMarker)e.MapMarker; countryLabel.Text = custommarker.Label; populationLabel.Text = custommarker.Population.ToString(); Device.StartTimer(new TimeSpan(0, 0, 3), () => { Toast.IsVisible = false; return(false); }); } }
public override void OnMarkerSelected(SFMap map, MarkerSelectedEventArgs markerSelectedEventArgs) { PopulationMarker Populationmarker = (PopulationMarker)markerSelectedEventArgs.SelectedMarker; mar.displayToastWithMessage((NSString)(Populationmarker.Name + "\n"), (NSString)Populationmarker.Population); }
private void Layer_MarkerSelected(object sender, MarkerSelectedEventArgs e) { e.CustomView = this.Resources["selectedMarker"] as DataTemplate; }