Beispiel #1
0
        public GoogleMap()
        {
            InitializeComponent();
            BindingContext = googleMapViewModel = new GoogleMapViewModel();
            var location = Geolocation.GetLastKnownLocationAsync();

            map.MoveToRegion(MapSpan.FromCenterAndRadius(new Position(location.Result.Latitude, location.Result.Longitude),
                                                         Distance.FromMeters(1000)));
        }
Beispiel #2
0
        public override ActionResult Index(GoogleMapBlock currentBlock)
        {
            var viewmodel = new GoogleMapViewModel
            {
                Latitude  = currentBlock.Latitude,
                Longitude = currentBlock.Longitude
            };

            return(PartialView(viewmodel));
        }
        public ActionResult GoogleMap(Position center)
        {
            GoogleMapUco uco = new GoogleMapUco();

            GoogleMapDto dto = uco.GetViewModel(center);

            GoogleMapViewModel vm = ConvertToViewModel(dto);

            return(View("GoogleMap", vm));
        }
Beispiel #4
0
 public ActionResult GoogleMap(GoogleMapViewModel model)
 {
     return(View(model));
 }