r84813 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r84812‎ | r84813 | r84814 >
Date:19:15, 26 March 2011
Author:hartman
Status:deferred
Tags:
Comment:
But only store the image if the source is the Camera of course.
Modified paths:
  • /trunk/tools/WikiSnaps/Classes/SourcePickerViewController.m (modified) (history)

Diff [purge]

Index: trunk/tools/WikiSnaps/Classes/SourcePickerViewController.m
@@ -217,8 +217,12 @@
218218 UIImage *image = [info valueForKey:UIImagePickerControllerOriginalImage];
219219
220220 image = [image correctOrientation:image];
221 - UIImageWriteToSavedPhotosAlbum( image, nil, nil, nil );
222 -
 221+
 222+ // Store the image on the Camera Roll
 223+ if( picker.sourceType == UIImagePickerControllerSourceTypeCamera ) {
 224+ UIImageWriteToSavedPhotosAlbum( image, nil, nil, nil );
 225+ }
 226+
223227 // Prepare upload
224228 CommonsUpload *ourUpload = [[CommonsUpload alloc] init];
225229 ourUpload.imageData = UIImageJPEGRepresentation(image, 0.85f);

Status & tagging log