twostraws / CodeScanner

A SwiftUI view that is able to scan barcodes, QR codes, and more, and send back what was found.
MIT License
1.03k stars 295 forks source link

iPad Multitasking Support #101

Open bennokress opened 1 year ago

bennokress commented 1 year ago

In its current state the camera feed just freezes when using the Scanner on an iPad and activating one of the Multitasking Modes. With iPadOS 16 Apple introduced support for having the camera active in Multitasking scenarios and I think we should add that as an option.

I'll probably look into adding it in the coming days and open a PR if I have it in a working state.

bennokress commented 1 year ago

Sadly I'm not able to get this to work so far. If anyone has a way to improve this, I think it would improve the quality of this package though. For my personal use case I'm working around it for now by displaying a placeholder and a hint when the user enters a Multitasking Mode.

kelvinjou commented 1 year ago

@bennokress Do you have code that I could test out? I'm going to attempt to add multitasking support next week.

bennokress commented 1 year ago

@kelvinjou No, I discarded my attempts and it's too long ago for me to remember what I did, sorry.