Little Tips

In Cocoa Programming,the variable of NSView class,the subviews is a variable of NSArray,and it is readonly,so the way remove all the views in the iOS can not be used in Cocoa. html

So,how should we remove the view from superview?Okay,maybe you will like this way to do it: app

[[nsview subviews] makeObjectsPerformSelector:@selector(removeFromSuperview)]; this

相關文章
相關標籤/搜索