You can loop through subviews of an existing view. This works especially well if you use the “tag” property on your views.
|
1 2 3 4 5 6 |
for (UIImageView *anImage in [self.view subviews]) { if (anImage.tag == 1) { // do something } } |
Tagged with: Animage • Loop Through • Self View • Tag Property
Filed under: Box 2d • Cocoa • Cocos2d • iPad • iPhone • Objective C
Like this post? Subscribe to my RSS feed and get loads more!




Leave a Reply