Exemplo n.º 1
0
 private void DeclareGlobals()
 {
     if (!LocationSettings.TryGetLocationFromSettings(out location))
     {
         RefreshLocation();
     }
     RefreshSettings();
 }
Exemplo n.º 2
0
 private void RefreshLocation()
 {
     if (!(LocationSettings.TryGetLocationFromSettings(out location) || LocationSettings.TryGetLocationFromDevice(out location)))
     {
         location = LocationSettings.GetLocationFromZip();
     }
     location.Latitude  = double.Parse(Shared.InputBox("Latitude", "Latitude", location.Latitude.ToString()));
     location.Longitude = double.Parse(Shared.InputBox("Longitude", "Longitude", location.Longitude.ToString()));
     LocationSettings.SaveLocationToConfig(location);
 }
Exemplo n.º 3
0
 public static System.Device.Location.GeoCoordinate GetLocationFromZip()
 {
     return(LocationSettings.GetLatLong(int.Parse(LocationSettings.TryGetZip())));
 }