add map support for gps denied

This commit is contained in:
Alex Bezdieniezhnykh
2025-03-17 09:08:43 +02:00
parent 33070b90bf
commit 099f9cf52b
15 changed files with 783 additions and 21 deletions
+24
View File
@@ -43,6 +43,7 @@ public partial class Annotator
private ObservableCollection<DetectionClass> AnnotationClasses { get; set; } = new();
private bool _suspendLayout;
private bool _gpsPanelVisible = false;
public readonly CancellationTokenSource MainCancellationSource = new();
public CancellationTokenSource DetectionCancellationSource = new();
@@ -105,6 +106,7 @@ public partial class Annotator
};
Editor.GetTimeFunc = () => TimeSpan.FromMilliseconds(_mediaPlayer.Time);
MapMatcherComponent.Init(_appConfig);
}
private void OnLoaded(object sender, RoutedEventArgs e)
@@ -587,6 +589,28 @@ public partial class Annotator
});
}
private void SwitchGpsPanel(object sender, RoutedEventArgs e)
{
_gpsPanelVisible = !_gpsPanelVisible;
if (_gpsPanelVisible)
{
GpsSplitterRow.Height = new GridLength(4);
GpsSplitter.Visibility = Visibility.Visible;
GpsSectionRow.Height = new GridLength(1, GridUnitType.Star);
MapMatcherComponent.Visibility = Visibility.Visible;
}
else
{
GpsSplitterRow.Height = new GridLength(0);
GpsSplitter.Visibility = Visibility.Collapsed;
GpsSectionRow.Height = new GridLength(0);
MapMatcherComponent.Visibility = Visibility.Collapsed;
}
}
private void SoundDetections(object sender, RoutedEventArgs e)
{
throw new NotImplementedException();