Carbon


SelectorFunctionProcPtr

Header: Gestalt.h Carbon status: Supported

Defines a pointer to a gestalt selector callback function. Your gestalt selector callback returns the information associated with your own selector code.

typedef OSErr(* SelectorFunctionProcPtr) (
    OSType selector, 
    SInt32 *response
);

You would declare your function like this if you were to name it MySelectorFunctionCallback:

OSErr MySelectorFunctionCallback (
    OSType selector, 
    SInt32 *response
);
Parameter descriptions
selector

The selector code that triggers the function.

response

On return, the information.

function result

A result code.

DISCUSSION

Your selector function places the requested information in the response parameter and returns a result code. If the information is not available, the selector function returns the appropriate error code, which the Gestalt function returns as its function result.

A selector function can call Gestalt or even other selector functions. It must reside in the system heap.


© 2000 Apple Computer, Inc. (Last Updated 6/30/2000)