开发者

Tip on memory managment, objective c

i've an application with many view of graphic data (many labels, some images ecc), all these data is static, created in Interface builder and not connected to code because i don't need开发者_如何学Python them.

I've seen that changing view the memory value increases, but the doesn't the system remove these type of objects itself?

thanks


No, it would be better if you connect them (IBOutlet) to your code and release them in your dealloc and viewDidUnload method.

  1. connect:

    @property (nonatomic, retain) IBOutlet UIUserInterfaceElementClass *anOutlet;
    
  2. release:

    [anOutlet release], anOutlet = nil;
    
0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜