开发者

Adding object to an NSMutableSet automatically when it's initiated... (iphone)

I have this problem adding an object to NSSet...

The NSM开发者_Go百科utableSet *set "belongs" to main ViewController. I want to add an object (Wall) to this NSMutableSet automatically if I add it to view in interface builder... Wall is a subclass of UIImageView...

Thanks :)


found a way how to do it :)

for(UIView *v in self.view.subviews) { if([v isKindOfClass:[Wall class]]) [obstacleSet addObject:v]; }

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜