• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: setMenu: nil does not release a menu ?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: setMenu: nil does not release a menu ?


  • Subject: Re: setMenu: nil does not release a menu ?
  • From: Tobias Hermann <email@hidden>
  • Date: Thu, 22 May 2003 16:57:24 +0200

hi!

I made a mistake :-) setMenu: nil does AUTORELEASE the menu, so that is fine.

but this still happens:
ps: By the way. When creating such a menu in Interface builder, every menu Item added within IB increases the menu's retain count by one. Why is that?
When I programmatically add menu Items, the menu does NOT get retained.
Consider a NSMenu built in IB. It has 4 menu items. After awakeFromNib, the menu's retain count is 5. (4 uneseccary retains from the items).
The joke is: If you call removeItemAtIndex in order to remove the items, the menu does NOT get released...
Something is going wrong there... Or I really did understand something totally wrong :-(
_______________________________________________


regards

Tobi
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

References: 
 >setMenu: nil does not release a menu ? (From: Tobias Hermann <email@hidden>)

  • Prev by Date: setMenu: nil does not release a menu ?
  • Next by Date: Re: setMenu: nil does not release a menu ?
  • Previous by thread: setMenu: nil does not release a menu ?
  • Next by thread: Re: setMenu: nil does not release a menu ?
  • Index(es):
    • Date
    • Thread