private void OnPushTapped(object sender, RoutedEventArgs e)
        {
            LocationIcon10m locationPin = sender as LocationIcon10m;
            if (locationPin != null)
            {
                var x = MapLayer.GetPosition(locationPin);
                double lat = x.Latitude;
               // _vm.GetSpotByLatitude(lat);
                foreach (Place p in _vm.Places)
                {
                    if (p.Latitude == x.Latitude || p.Longitude == x.Longitude)
                    {
                        //txtTappedPlace.Text = p.PlaceId.ToString();
                        ActiveUserAndSpot uas = new ActiveUserAndSpot();
                        uas.Place = p;
                        uas.User = _vm.ActiveUser;
                        Frame.Navigate(typeof(DetailSpotPage), uas);

                    }
                }
            }
        }
Example #2
0
 private void topspotMap_Tap_1(object sender, System.Windows.Input.GestureEventArgs e)
 {
     ActiveUserAndSpot uas = new ActiveUserAndSpot();
     uas.Place = _vm.Places[1];
     uas.User = _vm.ActiveUser;
     u.Email = "*****@*****.**";
     NavigationService.Navigate(new Uri("/DetailSpotPage.xaml?user="******"&spotId=" + uas.Place.PlaceId, UriKind.Relative));        
 }
        private void OnPushTapped(object sender, EventArgs e)
        {
              Image img = sender as Image;
              Place tappedPlace = (Place)img.Tag;

              foreach (Place p in _vm.Places)
              {
                  if (p.Latitude == tappedPlace.Latitude || p.Longitude == tappedPlace.Longitude)
                  {
                      //txtTappedPlace.Text = p.PlaceId.ToString();
                      ActiveUserAndSpot uas = new ActiveUserAndSpot();
                      uas.Place = p;
                      uas.User = _vm.ActiveUser;

                      //user.Email = "*****@*****.**";

                      NavigationService.Navigate(new Uri("/DetailSpotPage.xaml?user="******"&spotId=" + uas.Place.PlaceId, UriKind.Relative));            
                  }
              }
        }
Example #4
0
        private void Spot3_Tapped(object sender, TappedRoutedEventArgs e)
        {
            if (_vm.ActiveUser == null)
            {

            }
            else
            {
                ActiveUserAndSpot uas = new ActiveUserAndSpot();
                uas.Place = _vm.Places[2];
                uas.User = _vm.ActiveUser;
                Frame.Navigate(typeof(DetailSpotPage), uas);
            }
        }
 private void grvSpots_ItemClick(object sender, ItemClickEventArgs e)
 {
     ActiveUserAndSpot uas = new ActiveUserAndSpot();
     uas.Place = (Place)e.ClickedItem;
     uas.User = _vm.ActiveUser;
     Frame.Navigate(typeof(DetailSpotPage), uas);
 }