• 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
Passing C Style Function Callbacks in Cocoa
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Passing C Style Function Callbacks in Cocoa


  • Subject: Passing C Style Function Callbacks in Cocoa
  • From: Vince Ackerman <email@hidden>
  • Date: Fri, 5 Mar 2004 07:37:11 -0800

I'm a Object C newbie and hope someone here can help. I need to pass a
function call-back to a C- style function from one of my objects. I
have declared the call-back function before the @implementation MyObj.
The problem I'm having is accessing my object from within the call-back
function, which doesn't seem to know about my object. I want the
callback to send a setter message to my object. I'd rather be able to
pass a call-back that was a method of my object instead. Is there a way
to pass a Obj C style message as a function* in place of the C-style
function???

Thanks in advance

Vince Ackerman
_______________________________________________
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.


  • Follow-Ups:
    • Re: Passing C Style Function Callbacks in Cocoa
      • From: Hiro Fujimoto <email@hidden>
    • Re: Passing C Style Function Callbacks in Cocoa
      • From: Allan Odgaard <email@hidden>
    • Re: Passing C Style Function Callbacks in Cocoa
      • From: Vince Ackerman <email@hidden>
  • Prev by Date: Re: Capture "Space" key event
  • Next by Date: Re: Capture "Space" key event
  • Previous by thread: Re: drag and drop: NSView vs. NSImageView
  • Next by thread: Re: Passing C Style Function Callbacks in Cocoa
  • Index(es):
    • Date
    • Thread