Mailing Lists: Apple Mailing Lists
Image of Mac OS face in stamp
Re: Shared Window Controllers
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Shared Window Controllers



On 9/28/02 3:33 PM, "King Chung Huang" <email@hidden> wrote:

> I don't understand how this will only cause one instance of the controller
> to be instantiated and shared by anyone who calls it. Wouldn't
> *sharedToolPaletteController get set to nil every time the function is
> called? Or does the "static" label cause it to do something different?

Variables declared static within a function stay in existence for the life
of the program, rather than being created and destroyed with each function
call. I suggest picking up a copy of K&R's "The C Programming Language" for
basics like this.

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

References: 
 >Shared Window Controllers (From: King Chung Huang <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2011 Apple Inc. All rights reserved.