Commit 77ebaa0
committed
MTP: Show loading progress when opening folders
- `list_directory_with_progress()` on `MtpConnectionManager` uses mtp-rs's
new `list_objects_stream()` to get the handle count upfront, then fetches
metadata per handle with progress callbacks every 20 items
- `MtpVolume` overrides the `Volume` trait's `list_directory_with_progress()`
to wire this through
- Extracted `convert_object_infos()` and `finalize_listing()` to share
post-processing between the two listing code paths
- No frontend changes needed — the existing streaming listing pipeline
already displays "Loaded N files..." when progress callbacks fire1 parent 17efe8b commit 77ebaa0
3 files changed
Lines changed: 330 additions & 22 deletions
File tree
- apps/desktop/src-tauri/src
- file_system/volume
- indexing
- mtp/connection
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
112 | 112 | | |
113 | 113 | | |
114 | 114 | | |
115 | | - | |
116 | | - | |
117 | 115 | | |
118 | 116 | | |
119 | 117 | | |
| |||
139 | 137 | | |
140 | 138 | | |
141 | 139 | | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
142 | 182 | | |
143 | 183 | | |
144 | 184 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
828 | 828 | | |
829 | 829 | | |
830 | 830 | | |
831 | | - | |
832 | | - | |
| 831 | + | |
| 832 | + | |
| 833 | + | |
| 834 | + | |
| 835 | + | |
| 836 | + | |
| 837 | + | |
| 838 | + | |
833 | 839 | | |
834 | 840 | | |
835 | 841 | | |
| |||
899 | 905 | | |
900 | 906 | | |
901 | 907 | | |
902 | | - | |
903 | | - | |
| 908 | + | |
| 909 | + | |
| 910 | + | |
| 911 | + | |
| 912 | + | |
| 913 | + | |
| 914 | + | |
| 915 | + | |
904 | 916 | | |
905 | 917 | | |
906 | 918 | | |
| |||
0 commit comments