1

In my app, I have to show the photos captured in a grid view and let user choose the one that they want to mess with. I am querying MediaStore.Images.Thumbnails to get the list of thumbnails to display. The app works fine --well most of the time. However, when the user puts the app in the background and takes photo and launches the app again, it does not display the new photo. The reason is that I am not reloading the thumbnails onResume of my activity. I do not want to refresh every time onResume because, most of the time it is unnecessary query to file system. My question is, is there a broadcast message or notification that I can register to get notified when a photo is taken from the camera even when my app is in background?

BTW: With still a lot of gingerbread phones around, the requirement is that it should work on 2.3.3 onwards.

user2995358
  • 977
  • 11
  • 27
  • 1
    Did you check this? http://stackoverflow.com/questions/3015448/where-is-android-camera-new-picture-defined – fasteque Nov 15 '13 at 08:48
  • No. It did not work. My activity is not getting called when a picture is taken even when I've the intent-filter as: – user2995358 Nov 15 '13 at 21:28
  • Hello ,did you figure out how to fix it? Using the NEW_PICTURE code works for me for ICS but I don't know if it works on Gingerbread. Let me know if you find a solution for it – Snake Dec 21 '13 at 19:01
  • No. I just added a refresh button, so it is refreshed only on demand. Also, I added a call to refresh the list onResume call of the activity. Don't like the solution, but it works. – user2995358 Dec 31 '13 at 22:11

0 Answers0