'Is Picture in Picture possible on IOS Simulator?
Solution 1:[1]
Currently (Q2 2022) it seems that Picture-in-Picture is omitted from simulated iPhones, even when the model of iPhone in question supports PIP on real hardware.
However, as Robin pointed out, PIP is available on simulated iPads such as the iPad Pro (9.7-inch).
Solution 2:[2]
Please paste your actual code here, instead of uploading it as an image. It is much easier for us to provide some help.
To help you with your question.
You are currently building and overwriting requestBody each time it loops inside the for loop. To avoid that, only the addFormDataPart() method should be inside the for loop.
If you would like you can also use forEachIndexed() to replace the for loop.
val requestBody = MultipartBody.Builder()
.setType(MultipartBody.FORM)
galleryListArray.forEachIndexed { index, image ->
requestBody.addFormDataPart("attachment[${index}]", image.toString())
}
requestBody.build()
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Alan H. |
| Solution 2 |

