home *** CD-ROM | disk | FTP | other *** search
Text File | 1996-08-28 | 7.0 KB | 233 lines | [TEXT/MPS ] |
- /*
- File: DocStub.r
-
- Contains: Resources for the document stub application
-
- Owned by: Nick Pilch
-
- Copyright: © 1993 - 1996 by Apple Computer, Inc., all rights reserved.
-
- Change History (most recent first):
-
- <2> 02.07.1996 NP 1364583: AppleScript targeting screwed up.
- <12> 9/29/95 eeh 1287262: use ShellDef.h
- <11> 8/12/95 TÇ 1276809 Optimization: lower stack size to
- 64K and default heap size to 384K
- <10> 8/11/95 jpa Rename doc-stub fragment "DocStub"
- [1276412]
- <9> 6/30/95 TÇ Changed default default document heap size
- to 768K.
- <8> 6/8/95 RR #1257260 Collapse base classes. #1214898
- StdTypes.r -> ODTypes.r
- <7> 5/25/95 jpa No more CODE 7. [1241078]
- <6> 3/16/95 TÇ #1228587 Can't run OD on w/8MB RAM (not
- finished!)
- <5> 1/6/95 jpa Get code rsrcs from new libs [1196515]
- <4> 10/20/94 NP 1159233: read statement seems to be working
- now. Removed full path name.
- <3> 10/10/94 TÇ #1191470 Need both 68K and PPC document
- stub application
- <2> 10/7/94 TÇ #1191470 Need both 68K and PPC document
- stub application
- <1> 10/7/94 TÇ first checked in
- */
-
- #ifndef _SHELLDEF_
- #include "ShellDef.h"
- #endif
-
- #ifndef SOM_Module_OpenDoc_StdDefs_defined
- #include "StdDefs.r"
- #endif // _STDDEFS_
-
-
- //====================================================================================
- // Code Resources for document launching
- //====================================================================================
-
- include "DocStubCode68k" ;
-
- // I don't get it. Rez is not finding the below file unless we give it a full path name
- // even though it found it above in the include statement without a full path. Hmmm...
- // NP-seems to be working now. Maybe the latest tools fixed it. 10/20/94 (rez V3.4d1)
-
- read kMainCFMType (kMainCFMPPCID) "DocStubCodePPC";
- read kMainCFMType (kSOMMemCFM68KID) "SOMMem68k";
- read kMainCFMType (kSOMMemCFMPPCID) "SOMMemPPC";
-
- //====================================================================================
- // Other (nonexecutable) document resources
- //====================================================================================
-
- #define SystemSevenOrBetter 1 // we want the extended types
- #define SystemSevenOrLater 1 // Types.r uses this variable
-
- #ifndef __TYPES_R__
- #include "Types.r"
- #endif
-
- #ifndef __SYSTYPES_R__
- #include "SysTypes.r"
- #endif
-
- #ifndef __AEWIDEUSERTERMTYPES__
- #include "AEUserTermTypes.r"
- #endif
-
- #ifndef __CODEFRAGMENTTYPES__
- #include "CodeFragmentTypes.r"
- #define __CODEFRAGMENTTYPES__
- // The .r file itself does not define the symbol -- naughty!
- #endif
-
-
- //-------------------------------------------------------------------------------------
- // SIZE Resource
- // Size -1 resource for all OpenDoc documents
- //-------------------------------------------------------------------------------------
-
- RESOURCE 'SIZE' (-1) {
- reserved,
- acceptSuspendResumeEvents,
- reserved,
- canBackground,
- doesActivateOnFGSwitch,
- backgroundAndForeground,
- dontGetFrontClicks,
- acceptChildDiedEvents, // necessary in case "New" command fails to launch doc
- is32BitCompatible,
- isHighLevelEventAware,
- localAndRemoteHLEvents,
- isStationeryAware,
- dontUseTextEditServices,
- reserved,
- reserved,
- reserved,
- kDocStubDefaultSize,
- kDocStubMinHeapSize
- };
-
- //-------------------------------------------------------------------------------------
- // scsz resource for AppleScript
- //
- // There is also on of these in ODAete.r. Why?????????
- //-------------------------------------------------------------------------------------
-
- resource 'scsz' (kscszID) { // <eeh> was 129, but that didn't seem to work
- readExtensionTerms, // was dontReadExtensionTerms; why?
- dontFindAppBySignature,
- alwaysSendSubject,
- reserved,
- reserved,
- reserved,
- reserved,
- reserved,
- reserved,
- reserved,
- reserved,
- reserved,
- reserved,
- reserved,
- reserved,
- reserved,
- 8,
- 8,
- 8,
- 368640,
- 368640,
- 368640
- };
-
-
- //-------------------------------------------------------------------------------------
- // Code-fragment resource (cfrg)
- //-------------------------------------------------------------------------------------
-
- resource 'cfrg' (kcfrgID) {
- {
- /* [1] Main document PPC code */
- kPowerPC,
- kFullLib,
- kNoVersionNum,
- kNoVersionNum,
- kDocStubStackSize,
- kNoAppSubFolder,
- kIsApp,
- kOnDiskSegmented,
- kMainCFMType,
- kMainCFMPPCID,
- "DocumentStub",
-
- /* [2] Main document 68k code */
- kMotorola,
- kFullLib,
- kNoVersionNum,
- kNoVersionNum,
- kDocStubStackSize,
- kNoAppSubFolder,
- kIsApp,
- kOnDiskSegmented,
- kMainCFMType,
- kMainCFM68KID,
- "DocumentStub",
-
- /* [3] SOMCustomMemoryMgr PPC lib */
- kPowerPC,
- kFullLib,
- 0, /*Erik sez use 1, but that doesn't work*/
- kNoVersionNum,
- 4096, /* was kDefaultStackSize */
- kNoAppSubFolder,
- kIsLib,
- kOnDiskSegmented,
- kMainCFMType,
- kSOMMemCFMPPCID,
- "SOMCustomMemoryMgr",
-
- /* [4] SOMCustomMemoryMgr 68k lib */
- kMotorola,
- kFullLib,
- 0, /*Erik sez use 1, but that doesn't work*/
- kNoVersionNum,
- 4096, /* was kDefaultStackSize */
- kNoAppSubFolder,
- kIsLib,
- kOnDiskSegmented,
- kMainCFMType,
- kSOMMemCFM68KID,
- "SOMCustomMemoryMgr"
- }
- };
-
-
- //====================================================================================
- // Finally convert all the resources into 'DSTB' resources:
- //====================================================================================
-
- // Document Stub Data Document Stub App
- // kDocStubRsrcType kDocStubRsrcID0 kcfrgRsrcType kcfrgID
- // kDocStubRsrcType kDocStubRsrcID1 kMainCFMType kMainCFMPPCID
- // kDocStubRsrcType kDocStubRsrcID2 kscszRsrcType kscszID
- // kDocStubRsrcType kDocStubRsrcID3 kMainCFMType kMainCFM68KID
- // kDocStubRsrcType kDocStubRsrcID4 kMainCFMType kMainCFM68KID1
- // kDocStubRsrcType kDocStubRsrcID5 kCODERsrcType kCODEID0
- // kDocStubRsrcType kDocStubRsrcID6 kCODERsrcType kCODEID1
- // kDocStubRsrcType kDocStubRsrcID7 kCODERsrcType kCODEID6
- // kDocStubRsrcType kDocStubRsrcID8 kMainCFMType kSOMMemCFM68KID
- // kDocStubRsrcType kDocStubRsrcID9 kMainCFMType kSOMMemCFMPPCID
- // kSIZERsrcType kDocStubSIZEID kSIZERsrcType kSIZEID
-
- Change kSIZERsrcType (kSIZEID) to kSIZERsrcType (kDocStubSIZEID);
- Change kcfrgRsrcType (kcfrgID) to kDocStubRSRCType (kDocStubRsrcID0);
- Change kMainCFMType (kMainCFMPPCID) to kDocStubRSRCType (kDocStubRsrcID1);
- Change kscszRsrcType (kscszID) to kDocStubRSRCType (kDocStubRsrcID2);
- Change kMainCFMType (kMainCFM68KID) to kDocStubRSRCType (kDocStubRsrcID3);
- Change kMainCFMType (kMainCFM68KID1) to kDocStubRSRCType (kDocStubRsrcID4);
- Change kCODERsrcType (kCODEID0) to kDocStubRSRCType (kDocStubRsrcID5);
- Change kCODERsrcType (kCODEID1) to kDocStubRSRCType (kDocStubRsrcID6);
- Change kCODERsrcType (kCODEID6) to kDocStubRSRCType (kDocStubRsrcID7);
- // Change kCODERsrcType (kCODEID7) to kDocStubRSRCType (kDocStubRsrcID8);
- // In CFM68K a3 there is no longer a CODE 7 generated for DocStub68K.
- Change kMainCFMType (kSOMMemCFM68KID) to kDocStubRSRCType (kDocStubRsrcID8);
- Change kMainCFMType (kSOMMemCFMPPCID) to kDocStubRSRCType (kDocStubRsrcID9);
-