Repository navigation
Commit fec06c0
committed
Keep the iOS pick open when a swipe down is cancelled
presentationControllerWillDismiss finished the request right away, but UIKit calls it as soon as the user starts pulling the sheet down, even if they let it spring back. The pick completed as cancelled while the picker stayed open, and the files selected afterwards were dropped because the request had already been cleared.
Wait for the dismissal transition to end and only finish the request if it was not cancelled. A completed dismissal, including the fast swipe from vicajilau#2021 that may never reach presentationControllerDidDismiss, still finishes the request. Without a transition coordinator it finishes right away, as before.
Bumps file_picker_darwin to 2.1.4.
Fixes vicajilau#22431 parent 9f53465 commit fec06c0
3 files changed
Lines changed: 26 additions & 3 deletions
File tree
- packages/file_picker_darwin
- darwin/file_picker_darwin/Sources/file_picker_darwin
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
1 | 5 | | |
2 | 6 | | |
3 | 7 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
189 | 189 | | |
190 | 190 | | |
191 | 191 | | |
192 | | - | |
193 | | - | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
194 | 213 | | |
195 | 214 | | |
196 | 215 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| |||
0 commit comments