I'm trying to detect if user take a screenshot in order to warn them this is a video with copyright. I've tried Darwin Notification, but it didn't work... NSMetadataQuery might be a solution, but we want the app to run on iOS4 as well. Can somebody help me? Thanks!:p
相关问题
- CALayer - backgroundColor flipped?
- Core Data lightweight migration crashes after App
- Core Data lightweight migration crashes after App
- How can I implement password recovery in an iPhone
- State preservation and restoration strategies with
相关文章
- 现在使用swift开发ios应用好还是swift?
- UITableView dragging distance with UIRefreshContro
- Could I create “Call” button in HTML 5 IPhone appl
- TCC __TCCAccessRequest_block_invoke
- Where does a host app handle NSExtensionContext#co
- xcode 4 garbage collection removed?
- Unable to process app at this time due to a genera
- Swift - hide pickerView after value selected
before ios 4.0 you can register for
PictureWasTakenNotification
.This notification is sent when screenshot is taken.No notifications will be sent before the screenshot was taken. But after that this has been discontinued and IMHO there is no other way round... :/It is not possible to detect a screenshot has (or will) be taken on iOS 5.
In iOS 4.0, there was a Darwin notification fired
PictureWasTakenNotification
, but not anymore.The documentation does not mention anything, and using
NSNotificationCenter
to subscribe to all notifications only shows silence after taking a screenshot.you can detect it with adding an observer to
UIApplicationUserDidTakeScreenshotNotification
.