Mark Jones
Mark Jones

Reputation: 41

What is the equivilent to a ContentObserver in iOS?

I use a ContentObserver in my android application to receive a notification whenever a photo is taken. Obviously iOS doesn't use the intent system, so is there an equivalent or alternative way to do this? I would prefer not to write a full camera application if possible.

Upvotes: 4

Views: 309

Answers (3)

devunwired
devunwired

Reputation: 63303

This is not quite possible. Even the latest Google+ application on iOS, with its Instant Upload feature does not get notified when photos are taken, it simply checks the asset library while the application is running, and then as long as possible while running in the background before getting timed out by the OS.

The following is from the Google+ help on the matter:

Note: Photos and videos will upload while the Google+ application is open and for a brief period of time afterwards.

HTH

Upvotes: 3

Felix
Felix

Reputation: 35394

Take a look at UIImagePickerController. It is really easy to let the user select or take a photo on iOS.

There is no equivalent to ContentObserver in iOS.

Upvotes: 0

fzwo
fzwo

Reputation: 9902

You cannot run in the background and get notified when a picture is taken and saved to the Camera Roll by another app on iOS.

That said, you don't really need to write a whole camera app to be able to let the user take pictures from within your app, or to access Camera Roll from within your running app.

Upvotes: 0

Related Questions