git_ui: Avoid blocking main thread during stage/unstage (#47806)

With a large number of files in the git status, pressing stage/unstage
could cause a noticeable freeze. The async performance profiler showed
that the task spawned inside `change_all_files_stage` blocked the main
thread for 300ms+, resulting in a clear and visible UI stall. The main
cause was the need to traverse all entries to determine what to stage or
unstage, which becomes expensive for large change sets.

Same repro as: #47800

Release Notes:

- Improved latency of stage/unstage operations
0c9b8fdba8Marco Mihai Condrache committed on 3/18/2026, 6:11:43 AM· committed by GitHubparente6939ad
1 file changedLine totals unavailable