Detecting screen capturing in iOS 11

We were working on an iOS app which provide paid video content. So the possibility of getting the video being recorded using the iOS 11 screen capture feature was something that needs to be handled. Here is how I did it. NB: The code is in Objective-C as I was working on an old project. It is pretty simple and you can easily convert it to swift if you wish.

//Obj-C
@property(nonatomic, readonly, getter=isCaptured) BOOL captured;
// swift
var isCaptured: Bool { get }
Detecting screen capturing in iOS 11

If you enjoyed reading this post, please share and give some clapps so others can find it 👏👏👏👏👏 !!!!

iOS and tvOS developer, dreamer, photographer 🤨

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store