J'ai un bouton pour choisir l'image de l'album photo. Après avoir choisi l'image, j'ai besoin de montrer le bouton navigationBar et partager. Mais navigationBar ne s'affiche pas après la sélection de l'image. J'ai utilisé `[self.navigationController.navigationBar setHidden: NO] ;. Mais la barre de navigation ne s'affiche pas.NavigationBar ne s'affiche pas après la sélection de l'image de l'album
code:
-(void)showAlbum:(id)sender{
imagePicker=[[UIImagePickerController alloc]init];
imagePicker.delegate = self;
imagePicker.allowsEditing =NO;
imagePicker.sourceType = UIImagePickerControllerSourceTypePhotoLibrary;
[self presentModalViewController:imagePicker animated:YES];
}
-(void)imagePickerControllerDidCancel:(UIImagePickerController *)picker{
//release picker
[picker dismissModalViewControllerAnimated:YES];
}
-(void)imagePickerController:(UIImagePickerController *)picker didFinishPickingMediaWithInfo:(NSDictionary *)info{
//set image
[self.navigationController.navigationBar setHidden:NO];
newImage = [[UIImageView alloc] initWithImage:[info objectForKey:UIImagePickerControllerOriginalImage]];
[newImage setFrame:CGRectMake(0, 0, 320, 568)];
[self.view addSubview:newImage];
[picker dismissModalViewControllerAnimated:YES];
}