4

问题很简单,我需要一个 UIImage 符合 NSCopying 协议,但我完全不知道从哪里开始实现这一点。

你有什么指针可以帮助我吗?

提前致谢

4

1 回答 1

10
- (id) copyWithZone: (NSZone *) zone
{
    return [[UIImage allocWithZone: zone] initWithCGImage: self.CGImage];
}
于 2010-01-17T14:13:34.043 回答