Skip to content

Commit 7250925

Browse files
BornToBeRootclaude
andcommitted
Fix: Scroll to the selected application in the application list
The application list only scrolled to the selected application on startup and after clearing the search. An application opened from somewhere else (dashboard, another application, run command) could stay out of view. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
1 parent 7eac71c commit 7250925

3 files changed

Lines changed: 13 additions & 0 deletions

File tree

‎Source/NETworkManager/MainWindow.xaml‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -533,6 +533,7 @@
533533
Style="{StaticResource FadeOutScrollViewer}">
534534
<ListView x:Name="ListViewApplication" ItemsSource="{Binding Applications}"
535535
SelectedItem="{Binding SelectedApplication, Mode=TwoWay}"
536+
SelectionChanged="ListViewApplication_OnSelectionChanged"
536537
SelectionMode="Single"
537538
BorderThickness="0"
538539
dd:DragDrop.IsDragSource="True"

‎Source/NETworkManager/MainWindow.xaml.cs‎

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1031,6 +1031,17 @@ private void ClearSearchOnApplicationListMinimize()
10311031
ListViewApplication.ScrollIntoView(SelectedApplication);
10321032
}
10331033

1034+
/// <summary>
1035+
/// Scrolls the selected application into view, also if it was selected from somewhere else (e.g. the dashboard,
1036+
/// another application or the run command).
1037+
/// </summary>
1038+
private void ListViewApplication_OnSelectionChanged(object sender,
1039+
System.Windows.Controls.SelectionChangedEventArgs e)
1040+
{
1041+
if (ListViewApplication.SelectedItem != null)
1042+
ListViewApplication.ScrollIntoView(ListViewApplication.SelectedItem);
1043+
}
1044+
10341045
private async void NavigationManager_ApplicationRequested(object sender, ApplicationRequest request)
10351046
{
10361047
// Clear the search, otherwise the application may be filtered out

‎Website/docs/changelog/next-release.md‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,7 @@ Release date: **xx.xx.2026**
116116

117117
- Fixed changes to lists in the settings (e.g. query histories, port profiles, custom commands) not being saved if no other setting was changed in the same session. This happened since the settings are stored as JSON. [#3607](https://github.com/BornToBeRoot/NETworkManager/pull/3607)
118118
- Fixed the profile search (profile list in the tools, **Profiles** settings and import result) filtering the profiles while still typing. The profiles are now filtered once after the user stopped typing, instead of every 750 ms after the first key press. [#3638](https://github.com/BornToBeRoot/NETworkManager/pull/3638)
119+
- Fixed the application list not scrolling to the selected application if it was opened from somewhere else (e.g. from the **Dashboard**, another application or the run command).
119120

120121
**Firewall**
121122

0 commit comments

Comments
 (0)