Ugly bugfix
This commit is contained in:
@@ -134,9 +134,12 @@ namespace NavCityBreda.Views
|
||||
|
||||
if (App.RouteManager.CurrentRoute == null) return;
|
||||
|
||||
GeofenceMonitor.Current.Geofences.Clear();
|
||||
Map.MapElements.Clear();
|
||||
await Task.Delay(TimeSpan.FromMilliseconds(100));
|
||||
while (Map.MapElements.Any() || GeofenceMonitor.Current.Geofences.Any())
|
||||
{
|
||||
Map.MapElements.Clear();
|
||||
await Task.Delay(TimeSpan.FromMilliseconds(100));
|
||||
GeofenceMonitor.Current.Geofences.Clear();
|
||||
}
|
||||
Map.MapElements.Add(CurrentPosition);
|
||||
Map.MapElements.Add(CurrentNavigationLine);
|
||||
|
||||
@@ -158,10 +161,12 @@ namespace NavCityBreda.Views
|
||||
private async void RemoveRoute()
|
||||
{
|
||||
Track(false);
|
||||
await Task.Delay(TimeSpan.FromMilliseconds(100));
|
||||
Map.MapElements.Clear();
|
||||
await Task.Delay(TimeSpan.FromMilliseconds(100));
|
||||
GeofenceMonitor.Current.Geofences.Clear();
|
||||
while (Map.MapElements.Any() || GeofenceMonitor.Current.Geofences.Any())
|
||||
{
|
||||
Map.MapElements.Clear();
|
||||
await Task.Delay(TimeSpan.FromMilliseconds(100));
|
||||
GeofenceMonitor.Current.Geofences.Clear();
|
||||
}
|
||||
await Task.Delay(TimeSpan.FromMilliseconds(100));
|
||||
DrawCurrenPosition(App.Geo.Position.Coordinate.Point);
|
||||
}
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
using NavCityBreda.Model.Object;
|
||||
using NavCityBreda.ViewModels;
|
||||
using System;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using Windows.UI;
|
||||
using Windows.UI.Xaml;
|
||||
@@ -49,7 +50,11 @@ namespace NavCityBreda.Views
|
||||
|
||||
private async void DrawRoute()
|
||||
{
|
||||
Map.MapElements.Clear();
|
||||
while (Map.MapElements.Any())
|
||||
{
|
||||
Map.MapElements.Clear();
|
||||
await Task.Delay(TimeSpan.FromMilliseconds(100));
|
||||
}
|
||||
|
||||
Zoom();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user