/// <summary> /// Updates the locatin, if the watcher is ready. /// </summary> /// <param name="sender">The sender of the event.</param> /// <param name="e">The event arguments.</param> private static void Watcher_StatusChanged(object sender, GeoPositionStatusChangedEventArgs e) { if (e.Status == GeoPositionStatus.Ready && !LocationQueryService.Watcher.Position.Location.IsUnknown) { LocationQueryService.SetLocation(); } }
/// <summary> /// Sets the location, if the position has changed. /// </summary> /// <param name="sender">The sender of the event.</param> /// <param name="e">The event arguments.</param> private static void Watcher_PositionChanged(object sender, GeoPositionChangedEventArgs <GeoCoordinate> e) { if (!LocationQueryService.Watcher.Position.Location.IsUnknown) { LocationQueryService.SetLocation(); } }