Retired Document
Important: This sample code may not represent best practices for current development. The project may use deprecated symbols and illustrate technologies and techniques that are no longer recommended.
GestaltTalk/GestaltTalkSelector.c
/* |
GestaltTalkSelector.c |
--------------------- |
This selector returns the address to GestaltTalk globals, |
which includes a pointer to the data buffer. |
*/ |
pascal OSErr GestaltTalkGestalt(long selector, long *response) |
{ |
asm { |
bsr.s @skipStorage ; skip over the data and push address |
dc.l 0x00 ; this is the gestaltTalk globals record |
dc.l 0x00 ; |
dc.l 0x00 |
dc.l 0x00 |
dc.l 0x00 |
@skipStorage: |
movea.l response,a0 |
move.l (sp)+,(a0) ; put the address of data into response |
} |
return 0; |
} |
Copyright © 2003 Apple Computer, Inc. All Rights Reserved. Terms of Use | Privacy Policy | Updated: 2003-01-14