0

I don't know if it's correct or not to show a waiting dialog/indicator while saving a photo taken with the camera. In iPad 4 the saving process is very fast, but maybe on other devices this process could take more time.

Start a new thread to save the image and show the dialog/indicator, is it worth?

I think that it isn't worth it, but I would like to know more expert opinions.

Some example code to illustrate my question:

[indicator startAnimating];
[NSThread detachNewThreadSelector:@selector(saveImage) toTarget:self withObject:nil];

and...

- (void)saveImage {
    library = [[ALAssetsLibrary alloc] init];
    [library saveImage:myPhoto toAlbum:@"MyAlbum" withCompletionBlock:^(NSError *error) {
        if (error==nil) {
           [indicator stopAnimating];
        }
    }
}

I'm using this category for saving images into custom album: https://github.com/Kjuly/ALAssetsLibrary-CustomPhotoAlbum

Xithias
  • 991
  • 1
  • 14
  • 32

1 Answers1

1

The general iOS paradigm is that the user should not be aware of any 'saving' operations that are going on - hence the preference for doing such things on a background thread.

So, with that under consideration, your current approach seems perfectly acceptable and within the iOS UI guidelines.

David Haynes
  • 933
  • 5
  • 14
  • Then I shouldn't throw a new thread, just save the image without showing the indicator. The saving process is already in a background thread, isn't it? – Xithias Mar 20 '13 at 11:54