private void BouncePinBtn_Tapped(object sender, TappedRoutedEventArgs e) { Image forImage = new Image(); forImage.Source = new BitmapImage(new Uri("ms-appx:///Assets/pin.png")); MapControl.SetLocation(forImage, MyMap.Center); MapItems.Items.Add(forImage); PushpinAnimations.Bounce(forImage, null, null); }
private async void Bounce4PinsBtn_Tapped(object sender, TappedRoutedEventArgs e) { for (var i = 0; i < path.Positions.Count; i++) { Image forImage = new Image(); forImage.Source = new BitmapImage(new Uri("ms-appx:///Assets/pin.png")); MapControl.SetLocation(forImage, new Geopoint(path.Positions[i])); MapItems.Items.Add(forImage); PushpinAnimations.Bounce(forImage, null, null); await Task.Delay(500); } }