• 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: Contextual Menu Setting
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Contextual Menu Setting


  • Subject: Re: Contextual Menu Setting
  • From: email@hidden
  • Date: Fri, 1 Nov 2002 10:49:47 +0100

On vendredi, novembre 1, 2002, at 12:57 AM, Lucas M. Haley wrote:

Heya all --

I'm trying to set a menu to be the contextual menu for a table. In IB I've set up the menu and targets, and in the document's awakeFromNib I call:

[attributesTable setMenu:attributesMenu];

which seems to work well. I get a strange error when the app runs, and I control-click on the table:

*** malloc[700]: Deallocation of a pointer not malloced: 0x1c1e45c; This could be a double free(), or free() called with the middle of an allocated block; Try setting environment variable MallocHelp to see tools to help debug

am I missing something? Forget to do something?

Without the source code, it's a bit difficult to know how attributesMenu is obtained.

If you're not doing any specific modification of your attributesMenu before calling setMenu, it could be easier to just set the Menu to be the one of the TableView using Interface Builder. Create a link from the NSTableView to the NSMenu and connect the menu outlet.
_______________________________________________
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.
  • Prev by Date: How to make an NSTextField the First Responder?
  • Next by Date: Re: Looking for performance-oneway asynch call
  • Previous by thread: Re: How to make an NSTextField the First Responder?
  • Next by thread: Re: Looking for performance-oneway asynch call
  • Index(es):
    • Date
    • Thread