Skip to content

fix: move blocking shortcut-delete and app-list scans off the UI thread, gate log refresh#935

Merged
laurentiu021 merged 2 commits into
mainfrom
fix/p2-ui-thread-offload
Jun 18, 2026
Merged

fix: move blocking shortcut-delete and app-list scans off the UI thread, gate log refresh#935
laurentiu021 merged 2 commits into
mainfrom
fix/p2-ui-thread-offload

Conversation

@laurentiu021

Copy link
Copy Markdown
Owner

Three UI-responsiveness fixes (P2).

Changes

  • ShortcutCleanerViewModel.DeleteSelectedasync DeleteSelectedAsync; the synchronous SHFileOperation batch delete now runs via Task.Run, so deleting many shortcuts doesn't freeze the window.
  • AppAlertsViewModel.RefreshInstalledAppsasync RefreshInstalledAppsAsync; the full HKLM uninstall-tree enumeration now runs via Task.Run(...).ConfigureAwait(true), off the UI thread.
  • LogsViewModel.Refresh — gated with [RelayCommand(CanExecute = nameof(NotBusy))] + PropertyChanged observer on IsBusy; a second refresh started while one is running could let the cancelled run's queued UI batches pollute the new Entries list. The button is now disabled while scanning.

Tests

  • LogsViewModelTests.RefreshCommand_DisabledWhileBusy asserts the gate (allowed idle → blocked busy → allowed again).
  • The two Task.Run offloads are behavior-preserving (same work, off-thread); covered by existing VM tests.

Notes

  • The ContextMenu ApplyPreset and Ping Stop-blocks-UI findings are deferred — they touch shared NetworkSharedState/RestartExplorer flows and warrant separate, carefully-verified PRs.

Build: main + tests 0 warnings / 0 errors. Version 1.20.42. (Stacks on #930/#933; will rebase before merge.)

@laurentiu021 laurentiu021 force-pushed the fix/p2-ui-thread-offload branch from 83fd342 to 8b2f6d9 Compare June 18, 2026 00:30
@laurentiu021 laurentiu021 force-pushed the fix/p2-ui-thread-offload branch from b4cdc37 to 7ab19a3 Compare June 18, 2026 00:38
@laurentiu021 laurentiu021 merged commit a8bc04a into main Jun 18, 2026
4 checks passed
@laurentiu021 laurentiu021 deleted the fix/p2-ui-thread-offload branch June 18, 2026 00:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant