Closed wdoyle2 closed 6 months ago
@wdoyle2 hi, What version are you using, and can I see your code? And if you want a completely prevent screenshot like Android, it's going to be hard, I know the best for iOS is make a black screen as user do screenshot
@0xlethe hi, We use verison 1.9.1, we use it this way in app.tsx. We also use the same useeffect in ApplicationNavigator. black screen will be enough for us but some users take screenshots normally
We also trigger expo-screen-capture with usePreventScreenCapture as an additional measure
@mstfmedeni hi, It looks like a conflict with expo-screen-capture to me. in expo-screen-capture, add subview for sharedApplication.keyWindow.subviews.firstObject, also react-native-capture-protection use add sublayer in sharedApplication.keyWindow.sublayers.firstObject
For now, it seems like a good idea to use one.
However, i'll be modifying the library to include this in the near future.
thank you I will test in detail
We use useCaptureProtection and preventScreenshot to prevent screenshoting on iOS and Android. On Android this works perfectly fine as well as the events when a screenshot is triggered.
However on iOS we have noticed that the screenshot prevent does not engage correctly and block the image. The notification to say the screenshot was taken is correctly flagged however the screenshot is still intact.
Is this something we are getting wrong? Can you make any suggestions on how we can ensure that screenshots never get taken on iOS?