我在设置一个小程序时遇到了问题。 其实质是从相机拍摄照片并将其存放在桌子上(类似于年表)。 AppDelegate.m 这是图像选择器:
- (void) imagePickerController: (UIImagePickerController*) picker
didFinishPickingMediaWithInfo: (NSDictionary*) info
{
// do something useful with results
UITabBarController *tabs = self.tabBarController;
tabs.selectedIndex = 1;
ResultsViewController *results = [tabs.viewControllers objectAtIndex: 1];
UIImage *image = [info objectForKey: UIImagePickerControllerOriginalImage];
results.resultImage.image = image;
id <NSFastEnumeration> syms =
[info objectForKey: ZBarReaderControllerResults];
for(ZBarSymbol *sym in syms) {
results.resultText.text = sym.data;
break;
}
}
@end
我应该做什么/在哪里实施/获得结果?
并且ResultViewController.m为空
#import "ResultsViewController.h"
@implementation ResultsViewController
@synthesize resultImage, resultText;
- (BOOL) shouldAutorotateToInterfaceOrientation: (UIInterfaceOrientation) orient
{
return(YES);
}
@end
在这里试图更明确的是project