我一直在搞这个天。我是新的xcode ..但只是不知道为什么我一直得到这个错误。我已经尝试过,并试图......我希望有人能帮助我。感谢您的时间'ImageEditorViewController'没有明显的@interface声明选择器'initWithImageAndSaveName:saveName:'
- (void)longPressAction:(UILongPressGestureRecognizer *)gestureRecognizer
{
CGPoint touchLocation = [gestureRecognizer locationInView:self.webView];
NSString *javascript = [NSString stringWithFormat:@"document.elementFromPoint(%f, %f).src", touchLocation.x, touchLocation.y];
NSString *imageUrl = [self.webView stringByEvaluatingJavaScriptFromString:javascript];
NSData *imageData = [NSData dataWithContentsOfURL:[NSURL URLWithString:imageUrl]];
UIImage *image = [UIImage imageWithData:imageData];
// Show the editor
ImageEditorViewController *editView = [[ImageEditorViewController alloc] initWithImageAndSaveName:image saveName:[imageUrl lastPathComponent]];
[self.navigationController pushViewController:editView animated:YES];
}
你在哪里申报和实施这些方法?做cmd-shift-f来搜索整个项目。 – 2013-03-22 05:39:13