Ejemplo n.º 1
0
        public async void LocationUpdateService_LocationChanged(object sender, LocationChangeEventArgs e)
        {
            _map.UpdateActiveUserCords(e.Latitude, e.Longitude);

            CurrentUserLatitude  = e.Latitude;
            CurrentUserLongitude = e.Longitude;

            await _mapRepository.UpdateMap(_map);
        }
Ejemplo n.º 2
0
        void LocationService_LocationChanged(object sender, LocationChangeEventArgs e)
        {
            FSLog.Debug();

            var coords = e.Position.Coordinate;

            var location = new Geolocation(
                lat: coords.Latitude,
                lon: coords.Longitude,
                acc: coords.Accuracy,
                time: coords.Timestamp.UtcDateTime);

            Deployment.Current.Dispatcher.BeginInvoke(async() =>
            {
                var resp = await ServerAPIManager.Instance.ReportLocation(location);
                if (!resp.IsSuccessful)
                {
                    FSLog.Error("Failed to update location");
                }
            });
        }
Ejemplo n.º 3
0
 private async void LocationService_LocationChanged(object sender, LocationChangeEventArgs e)
 {
     await SendLocation(e.Position);
 }
Ejemplo n.º 4
0
 void PedClient_OnUbicacionCambio(object sender, LocationChangeEventArgs e)
 {
     RunOnUiThread(() => txvUbicacion.Text = string.Format("{0}, {1}", e.Latitude, e.Longitude));
 }
 public void OnLocationChanged(LocationChangeEventArgs locationChangeEventArgs)
 {
     LocationChanged?.Invoke(this, locationChangeEventArgs);
 }