supermario/base/SuperMarioProj.1994-02-09/Internal/Asm/DisplaysPriv.a
2019-06-29 23:17:50 +08:00

192 lines
6.6 KiB
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

;
; File: DisplaysPriv.a
;
; Contains: Private Assembly headers for Display Manager
;
; Written by: Ian Hendry
;
; Copyright: © 1993 by Apple Computer, Inc., all rights reserved.
;
; Change History (most recent first):
;
; <11> 11/5/93 IH Sync with Excelsior.
; <SM10> 10/10/93 IH Sync with Excelsior.
; <9> 9/10/93 IH Fix cursor bug in horror ROMs and SuperMario.
; <SM8> 08-17-93 jmp Changed the gestaltDMLatestVersion equate to match the one in
; the .h file.
; <7> 8/16/93 IH #1099391 <KON>: Sync w/Reality.
; <6> 8/4/93 IH #1101633,1098397,1101795,1101636,1102280 <KON>: Fix 1102280. Add
; calls for getting declROM info. Add Trap for animation.
; <5> 6/25/93 IH Add new fields to display globals
; <4> 6/1/93 IH Add private trap selector to get timing mode table.
; <3> 5/28/93 IH #1081805,1086363: Put selectors for DMChangedDesktopIconRgn and
; DMDeskClick into the private (negative) range.
; <2> 3/31/93 IH Clean out display manager globals
; <1> 3/25/93 IH first checked in
; <2> 3/17/93 IH Change Display Manager selectors to hide private routines.
; <1> 3/5/93 IH first checked in
;
;
IF &TYPE('__INCLUDINGDISPLAYPRIVATEEQU__') = 'UNDEFINED' THEN
__INCLUDINGDISPLAYPRIVATEEQU__ SET 1
IF &TYPE('__INCLUDINGSYSPRIVATEEQU__') = 'UNDEFINED' THEN
INCLUDE 'SysPrivateEqu.a'
ENDIF
IF &TYPE('__INCLUDINGTRAPS__') = 'UNDEFINED' THEN
INCLUDE 'Traps.a'
ENDIF
; Make sure this is keep up with DisplaysPriv.h
gestaltDMLatestVersion EQU 2
DMGlobalsRec RECORD 0
fDrawingPort ds.l 1 ;
fPortStorage ds.b portRec ;
fWorkingDeskRectRgn ds.l 1 ;
fWorkingDeskFullRgn ds.l 1 ;
fWorkingUpdateRgn ds.l 1 ;
fDeskIconRgn ds.l 1 ;
fDesktopCacheRgn ds.l 1 ;
fAnimationCacheRgn ds.l 1 ;
fAnimatePSN ds.l 2 ;
fAnimateA5 ds.l 1 ;
fSavedDMGlobals ds.l 1 ;
fNextAnimateTime ds.l 1 ;
fIconRgnInvalid ds.b 1 ;
fDeskDrawNest ds.b 1 ;
fDisplayEntrySize ds.w 1 ; Initialized to be sizeof(DisplayInfoRec)
fDisplayNextID ds.l 1 ; Unique id for displays
fDisplayCount ds.w 1 ; How many displays in display table
fDisplayTable ds.l 1 ; Table of information about displays (FUTURE: should I sort and binary search?)
fNotificationCount ds.w 1 ; How many ProcPtrs in notification table
fNotificationTable ds.l 1 ; Table of information about notification (FUTURE: should I sort and binary search?)
fRemovedDevices ds.l 1 ; DeviceList of devices that have been removed (we do not dispose incase device has been cached)
; ••• Warning •••
;
; The BlackBird/Yeager mirroring code currently accesses these globals directly. So, dont move them
; without updating that code as well.
;
; •••
;
fDevicesOverlap ds.b 1 ; If true, *some* gDevices are overlapped (partically or fully).
fDevicesMirrored ds.b 1 ; If true, all gDevices are fully overlapped, smallest gDevice determines rectangle for all devices.
fMirroringBlocked ds.b 1 ; If true, mirroring has been “artifically” blocked (several 3rd-parties asked for this).
fUnused1Byte4 ds.b 1
;
; Back to regulary scheduled globals
;
fQDA5World ds.l 1 ; Points to fQDGlobals this value can be stuffed in A5 for display components
fQDGlobals ds.l 1 ; Storage for Display Mgr A5 world.
fUnused1 ds.l 1 ;
fUnused2 ds.l 1 ;
fUnused3 ds.l 1 ;
fUnused4 ds.l 1 ;
dmRecSize equ * ; size for this version
ENDR
MACRO
__GetDMGlobalsPtrInA0
Move.l ExpandMem,A0
Move.l ExpandMemRec.emDisplayManagerGlobals(A0),A0
ENDM
;————————————————————————————————————————————————————————————————————————————————————————————————————
; Define the private selectors for the Display Manager
selectInstallDisplayManager EQU -1
selectInitDisplayManager EQU -2
selectKillDisplayManager EQU -3
selectSetDesktopIconRgn EQU -4
selectGetDesktopIconRgn EQU -5
selectKeepWindowOnscreen EQU -6
selectNotifyAllProcesses EQU -7
selectSetAnimateProcess EQU -8
selectChangedDesktopIconRgn EQU -9
selectDeskClick EQU -10
selectGetROMMultiModeTable EQU -11
selectGiveDeskTime EQU -12
selectGetBestDepthModeInfo EQU -13
selectPrivateBeginConfigureDisplays EQU -14
selectRemoveCurrentProcessProcs EQU -15
selectDMMoveCursor EQU -16 ; do not want to steal a quickdraw name (MoveCursor should be QD and DMMoveCursor is mine)
selectRegisterExtendedNotification EQU -17
selectSetDisplayID EQU -18
;————————————————————————————————————————————————————————————————————————————————————————————————————
; Define the parameter size passed for each call
paramWordsInstallDisplayManager EQU 0
paramWordsInitDisplayManager EQU 0
paramWordsKillDisplayManager EQU 0
paramWordsSetDesktopIconRgn EQU 2
paramWordsGetDesktopIconRgn EQU 2
paramWordsKeepWindowOnscreen EQU 4
paramWordsNotifyAllProcesses EQU 0
paramWordsSetAnimateProcess EQU 2
paramWordsChangedDesktopIconRgn EQU 0
paramWordsDeskClick EQU 2
paramWordsGetROMMultiModeTable EQU 2
paramWordsGiveDeskTime EQU 0
paramWordsGetBestDepthModeInfo EQU 9
paramWordsPrivateBeginConfigureDisplays EQU 3
paramWordsRemoveCurrentProcessProcs EQU 0
paramWordsDMMoveCursor EQU 4 ; do not want to steal a quickdraw name (MoveCursor should be QD and DMMoveCursor is mine)
paramWordsRegisterExtendedNotification EQU 7
paramWordsSetDisplayID EQU 4
;————————————————————————————————————————————————————————————————————————————————————————————————————
; Macros for Display Manager.
; See DisplaysPriv.h for more details
;
MACRO
_DMInstallDisplayManager
DoDispatch _DisplayDispatch,selectInstallDisplayManager,paramWordsInstallDisplayManager
ENDM
MACRO
_DMInitDisplayManager
DoDispatch _DisplayDispatch,selectInitDisplayManager,paramWordsInitDisplayManager
ENDM
MACRO
_DMRemoveCurrentProcessProcs
DoDispatch _DisplayDispatch,selectRemoveCurrentProcessProcs,paramWordsRemoveCurrentProcessProcs
ENDM
; Add more selectors
MACRO
_DMSetDisplayID
DoDispatch _DisplayDispatch,selectSetDisplayID,paramWordsSetDisplayID
ENDM
ENDIF ; ...already included