图片添加点击事件

resizedImageView.userInteractionEnabled = YES;

    UITapGestureRecognizer *singleTap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(photoTapped)];
    [resizedImageView addGestureRecognizer:singleTap];//点击图片事件
    NSLog(@"haha");
    [self.view addSubview:resizedImageView];//加载图片

posted on   yucaijiang  阅读(719)  评论(0编辑  收藏  举报

努力加载评论中...

导航

点击右上角即可分享
微信分享提示