diff --git a/Source/Pages/Inflight/InflightPageViewModel.cs b/Source/Pages/Inflight/InflightPageViewModel.cs index df8c530..4f5ac34 100644 --- a/Source/Pages/Inflight/InflightPageViewModel.cs +++ b/Source/Pages/Inflight/InflightPageViewModel.cs @@ -6,6 +6,7 @@ using System.Threading.Tasks; using Avalonia.Threading; using DynamicData; +using DynamicData.Binding; using mqttMultimeter.Common; using mqttMultimeter.Controls; using mqttMultimeter.Pages.Inflight.Export; @@ -39,7 +40,12 @@ public InflightPageViewModel(MqttClientService mqttClientService, InflightPageIt var filter = this.WhenAnyValue(x => x.FilterText).Throttle(TimeSpan.FromMilliseconds(800)).Select(BuildFilter); - _itemsSource.Connect().Filter(filter).ObserveOn(RxApp.MainThreadScheduler).Bind(out _items).Subscribe(); + _itemsSource.Connect() + .Filter(filter) + .Sort(SortExpressionComparer.Ascending(t => t.Number)) + .ObserveOn(RxApp.MainThreadScheduler) + .Bind(out _items) + .Subscribe(); } public event Action? RepeatMessageRequested; diff --git a/Source/Pages/PacketInspector/PacketInspectorPageViewModel.cs b/Source/Pages/PacketInspector/PacketInspectorPageViewModel.cs index 928be07..3db8761 100644 --- a/Source/Pages/PacketInspector/PacketInspectorPageViewModel.cs +++ b/Source/Pages/PacketInspector/PacketInspectorPageViewModel.cs @@ -92,7 +92,7 @@ Task ProcessPacket(InspectMqttPacketEventArgs eventArgs) { return Task.CompletedTask; } - + Dispatcher.UIThread.Invoke(() => { var number = _number++; diff --git a/Source/mqttMultimeter.sln.DotSettings b/Source/mqttMultimeter.sln.DotSettings index 8e9d44f..6ddae50 100644 --- a/Source/mqttMultimeter.sln.DotSettings +++ b/Source/mqttMultimeter.sln.DotSettings @@ -235,6 +235,7 @@ </Entry> </TypePattern> </Patterns> + False True True True