home *** CD-ROM | disk | FTP | other *** search
Text File | 1993-06-02 | 2.3 KB | 119 lines | [TEXT/KAHL] |
- /*
- File: LoaderPrivate.h
-
- Contains: Private header file for Loader component routines.
-
- Refer to develop Issue 15, "Managing Component Registration",
- for details on this code.
-
- Written by: Gary Woodcock
-
- Copyright: © 1993 by Apple Computer, Inc.
-
- Change History (most recent first):
-
- */
-
- //-----------------------------------------------------------------------
- // Includes
-
- #ifndef _LOADERPRIVATE_
- #define _LOADERPRIVATE_
-
- #include "CompileFlags.h"
-
- #include <Components.h>
-
- //-----------------------------------------------------------------------
- // Private constants
-
- #define kComponentLoadListResType 'thld'
-
- // Base resource ID
- enum
- {
- kLoaderBaseResID = 128
- };
-
- // Maximum number of instances that can be opened
- enum
- {
- kMaxLoaderInstances = 1
- };
-
- // Component and interface revision levels
- enum
- {
- loaderInterfaceRev = 0x00010001
- };
-
- enum
- {
- kRegisterLocally = 0,
- kRegisterGlobally = 1
- };
-
- //-----------------------------------------------------------------------
- // Private types
-
- typedef struct ComponentLoadSpec
- {
- ResType componentResType;
- short componentResID;
- }
- ComponentLoadSpec, *ComponentLoadSpecPtr, **ComponentLoadSpecHdl;
-
- typedef struct ComponentLoadList
- {
- short count;
- ComponentLoadSpec spec[1];
- }
- ComponentLoadList, *ComponentLoadListPtr, **ComponentLoadListHdl;
-
- typedef struct LoaderPrivateGlobals
- {
- Component self; // Component ID
- }
- LoaderPrivateGlobals, *LoaderPrivateGlobalsPtr, **LoaderPrivateGlobalsHdl;
-
- //-----------------------------------------------------------------------
- // Private prototypes
-
- #ifdef BUILD_LINKED
-
- // Only need this prototype if we're running linked (for debugging)
- pascal ComponentResult
- LoaderDispatcher (ComponentParameters *params, Handle storage);
-
- #endif BUILD_LINKED
-
- pascal ComponentResult
- _LoaderOpen (Handle storage, ComponentInstance self);
-
- pascal ComponentResult
- _LoaderClose (Handle storage, ComponentInstance self);
-
- pascal ComponentResult
- _LoaderCanDo (short selector);
-
- pascal ComponentResult
- _LoaderVersion (void);
-
- pascal ComponentResult
- _LoaderRegister (Handle storage);
-
- #ifdef THINK_C
- #ifdef BUILD_LINKED
-
- Component
- RegisterLoader (void);
-
- #endif BUILD_LINKED
- #endif THINK_C
-
- //-----------------------------------------------------------------------
-
- #endif _LOADERPRIVATE_
-
- //-----------------------------------------------------------------------
-