从页面导航时,Ui imageview选取器图像消失

时间:2012-04-19 02:12:29

标签: ios ios5 uiimageview

我有一个Ui图像视图,可以选择要在我的应用程序中显示的照片表单cameraroll,当我从页面移开时它会消失。当页面被导航离开时,有什么方法可以抓住它?

xcode 4.3谢谢

- (void)imagePickerController:(UIImagePickerController *)picker didFinishPickingMediaWithInfo:(NSDictionary *)info {
[picker dismissModalViewControllerAnimated:YES];
imageView.image = [info objectForKey:@"UIImagePickerControllerOriginalImage"];




- (IBAction)getPhoto:(id)sender {



UIImagePickerController * picker = [[UIImagePickerController alloc] init];
picker.delegate = self;

if((UIButton *) sender == choosePhotoBtn) {
    picker.sourceType = UIImagePickerControllerSourceTypeSavedPhotosAlbum;
}

[self presentModalViewController:picker animated:YES];

0 个答案:

没有答案