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