我已经实现了异步图像视图,以便在自定义单元格视图中加载图像,但图像在单元格上显示为很小。所以我需要在点击图像视图时显示该图像的放大形式。我怎样才能做到这一点?在iPhone中单击图像视图时放大显示图像
这是我的代码:
if (cell == nil) {
UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier];
//create new cell
cell = [[[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:CellIdentifier] autorelease];
//common settings
cell.selectionStyle = UITableViewCellSelectionStyleNone;
cell.accessoryType = UITableViewCellAccessoryDetailDisclosureButton;
cell.layer.cornerRadius = 10;
cell.layer.masksToBounds = YES;
cell.imageView.contentMode = UIViewContentModeScaleAspectFit;
cell.imageView.frame = CGRectMake(10.0f, 10.0f, 60.0f, 44.0f);
cell.imageView.backgroundColor = [UIColor colorWithRed:73 green:73 blue:73 alpha:1];
cell.imageView.image = [UIImage imageNamed:@"Placeholder.png"];
imgBtn=[cell imageView];
objectAtIndex:indexPath.row]objectForKey:@"Name"];
cell.imageView.imageURL = [NSURL URLWithString:[[detailsList objectAtIndex:indexPath.row]objectForKey:@"image_url"]];
}
我想触摸到细胞内的图像视图放大图像。有任何想法吗?提前致谢。
现在工作吗? – 2012-07-10 09:45:16
@Simha.hb s bose .. :) – 2012-07-10 09:51:19