Commit 3ea6341
committed
fix(sample): dismiss bottom sheet before launching file picker on iOS
iOS cannot present a UIDocumentPickerViewController while a
ModalBottomSheet is still visible (stacked modals not supported).
Use a pendingPick flag + LaunchedEffect to launch the picker only
after the sheet is fully dismissed. Also revert the unnecessary
security-scoped resource access changes in VideoPlayerState.1 parent 41ad9ec commit 3ea6341
2 files changed
Lines changed: 27 additions & 29 deletions
File tree
- mediaplayer/src/iosMain/kotlin/io/github/kdroidfilter/composemediaplayer
- sample/composeApp/src/commonMain/kotlin/sample/app/player
Lines changed: 1 addition & 27 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
19 | | - | |
20 | | - | |
21 | 19 | | |
22 | 20 | | |
23 | 21 | | |
| |||
172 | 170 | | |
173 | 171 | | |
174 | 172 | | |
175 | | - | |
176 | | - | |
177 | 173 | | |
178 | 174 | | |
179 | 175 | | |
| |||
522 | 518 | | |
523 | 519 | | |
524 | 520 | | |
525 | | - | |
526 | | - | |
527 | | - | |
528 | 521 | | |
529 | 522 | | |
530 | 523 | | |
| |||
550 | 543 | | |
551 | 544 | | |
552 | 545 | | |
553 | | - | |
554 | | - | |
555 | 546 | | |
556 | | - | |
557 | | - | |
558 | | - | |
559 | | - | |
560 | | - | |
561 | | - | |
562 | | - | |
563 | | - | |
564 | 547 | | |
565 | 548 | | |
566 | 549 | | |
| |||
735 | 718 | | |
736 | 719 | | |
737 | 720 | | |
738 | | - | |
739 | | - | |
740 | | - | |
741 | | - | |
742 | | - | |
743 | | - | |
744 | | - | |
745 | | - | |
746 | | - | |
747 | | - | |
| 721 | + | |
748 | 722 | | |
749 | 723 | | |
750 | 724 | | |
| |||
Lines changed: 26 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
88 | 88 | | |
89 | 89 | | |
90 | 90 | | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
91 | 97 | | |
92 | 98 | | |
93 | 99 | | |
| |||
102 | 108 | | |
103 | 109 | | |
104 | 110 | | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
105 | 126 | | |
106 | 127 | | |
107 | 128 | | |
| |||
219 | 240 | | |
220 | 241 | | |
221 | 242 | | |
222 | | - | |
| 243 | + | |
223 | 244 | | |
224 | 245 | | |
225 | 246 | | |
| |||
252 | 273 | | |
253 | 274 | | |
254 | 275 | | |
255 | | - | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
256 | 280 | | |
257 | 281 | | |
258 | 282 | | |
| |||
0 commit comments