home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD2.iso / Programming / C / BK-SC1_2.DMS / in.adf / ASM-Incl.Lha / workbench / workbench.i < prev   
Encoding:
Text File  |  1992-09-24  |  4.5 KB  |  165 lines

  1.     IFND    WORKBENCH_WORKBENCH_I
  2. WORKBENCH_WORKBENCH_I    EQU    1
  3. **
  4. **    $VER: workbench.i 37.2 (01.02.91)
  5. **    Includes Release 39.108
  6. **
  7. **    workbench.library general definitions
  8. **
  9. **    (C) Copyright 1985-1992 Commodore-Amiga, Inc.
  10. **    All Rights Reserved
  11. **
  12.  
  13.     IFND    EXEC_TYPES_I
  14.     INCLUDE    "exec/types.i"
  15.     ENDC
  16.  
  17.     IFND    EXEC_NODES_I
  18.     INCLUDE    "exec/nodes.i"
  19.     ENDC
  20.  
  21.     IFND    EXEC_LISTS_I
  22.     INCLUDE    "exec/lists.i"
  23.     ENDC
  24.  
  25.     IFND    EXEC_TASKS_I
  26.     INCLUDE    "exec/tasks.i"
  27.     ENDC
  28.  
  29.     IFND    INTUITION_INTUITION_I
  30.     INCLUDE    "intuition/intuition.i"
  31.     ENDC
  32.  
  33.  
  34. ; the Workbench object types
  35. WBDISK        EQU    1
  36. WBDRAWER    EQU    2
  37. WBTOOL        EQU    3
  38. WBPROJECT    EQU    4
  39. WBGARBAGE    EQU    5
  40. WBDEVICE    EQU    6
  41. WBKICK        EQU    7
  42. WBAPPICON    EQU    8
  43.  
  44. ; the main workbench object structure
  45.  STRUCTURE DrawerData,0
  46.     STRUCT    dd_NewWindow,nw_SIZE    ; args to open window
  47.     LONG    dd_CurrentX        ; current x coordinate of origin
  48.     LONG    dd_CurrentY        ; current y coordinate of origin
  49.     LABEL    OldDrawerData_SIZEOF    ; pre V36 size
  50. ; the amount of OldDrawerData actually written to disk
  51. OLDDRAWERDATAFILESIZE    EQU (OldDrawerData_SIZEOF)
  52.     ULONG    dd_Flags        ; flags for drawer
  53.     UWORD    dd_ViewModes        ; view mode for drawer
  54.     LABEL    DrawerData_SIZEOF
  55. ; the amount of DrawerData actually written to disk
  56. DRAWERDATAFILESIZE    EQU (DrawerData_SIZEOF)
  57.  
  58.  
  59.  STRUCTURE DiskObject,0
  60.     UWORD    do_Magic        ; a magic num at the start of the file
  61.     UWORD    do_Version        ; a version number, so we can change it
  62.     STRUCT    do_Gadget,gg_SIZEOF    ; a copy of in core gadget
  63.     UBYTE    do_Type
  64.     UBYTE    do_PAD_BYTE        ; Pad it out to the next word boundry
  65.     APTR    do_DefaultTool
  66.     APTR    do_ToolTypes
  67.     LONG    do_CurrentX
  68.     LONG    do_CurrentY
  69.     APTR    do_DrawerData
  70.     APTR    do_ToolWindow        ; only applies to tools
  71.     LONG    do_StackSize        ; only applies to tools
  72.     LABEL    do_SIZEOF
  73.  
  74. WB_DISKMAGIC    EQU    $e310    ; a magic number, not easily impersonated
  75. WB_DISKVERSION    EQU    1    ; our current version number
  76. WB_DISKREVISION    EQU    1    ; out current revision number
  77. ; I only use the lower 8 bits of Gadget.UserData for the revision #
  78. WB_DISKREVISIONMASK    EQU    $ff
  79.  
  80.  STRUCTURE FreeList,0
  81.     WORD    fl_NumFree
  82.     STRUCT    fl_MemList,LH_SIZE
  83.     ; weird name to avoid conflicts with FileLocks
  84.     LABEL    FreeList_SIZEOF
  85.  
  86.  
  87.  
  88. * each message that comes into the WorkBenchPort must have a type field
  89. * in the preceeding short.  These are the defines for this type
  90. *
  91.  
  92. MTYPE_PSTD        EQU    1    ; a "standard Potion" message
  93. MTYPE_TOOLEXIT        EQU    2    ; exit message from our tools
  94. MTYPE_DISKCHANGE    EQU    3    ; dos telling us of a disk change
  95. MTYPE_TIMER        EQU    4    ; we got a timer tick
  96. MTYPE_CLOSEDOWN        EQU    5    ; <unimplemented>
  97. MTYPE_IOPROC        EQU    6    ; <unimplemented>
  98. MTYPE_APPWINDOW        EQU    7    ; msg from an app window
  99. MTYPE_APPICON        EQU    8    ; msg from an app icon
  100. MTYPE_APPMENUITEM    EQU    9    ; msg from an app menuitem
  101. MTYPE_COPYEXIT        EQU    10    ; exit message from copy process
  102. MTYPE_ICONPUT        EQU    11    ; msg from PutDiskObject in icon.library
  103.  
  104. * workbench does different complement modes for its gadgets.
  105. * It supports separate images, complement mode, and backfill mode.
  106. * The first two are identical to intuitions GADGIMAGE and GADGHCOMP.
  107. * backfill is similar to GADGHCOMP, but the region outside of the
  108. * image (which normally would be color three when complemented)
  109. * is flood-filled to color zero.
  110. *
  111. GADGBACKFILL        EQU    $0001
  112.  
  113. * if an icon does not really live anywhere, set its current position
  114. * to here
  115. *
  116. NO_ICON_POSITION    EQU    ($80000000)
  117.  
  118.  
  119. * workbench now is a library.  this is it's name
  120. WORKBENCH_NAME    MACRO
  121.         dc.b        'workbench.library',0
  122.         ds.w        0
  123.         ENDM
  124.  
  125. ; If you find am_Version >= AM_VERSION, you now this structure has
  126. ; at least the fields defined in this version of the include file
  127. AM_VERSION    EQU    1
  128.  
  129.  STRUCTURE AppMessage,0
  130.     STRUCT am_Message,MN_SIZE    ; standard message structure
  131.     UWORD am_Type            ; message type
  132.     ULONG am_UserData        ; application specific
  133.     ULONG am_ID            ; application definable ID
  134.     LONG am_NumArgs            ; # of elements in arglist
  135.     APTR am_ArgList            ; the arguements themselves
  136.     UWORD am_Version        ; will be AM_VERSION
  137.     UWORD am_Class            ; message class
  138.     WORD am_MouseX            ; mouse x position of event
  139.     WORD am_MouseY            ; mount y position of event
  140.     ULONG am_Seconds        ; current system clock time
  141.     ULONG am_Micros            ; current system clock time
  142.     STRUCT am_Reserved,8        ; avoid recompilation
  143.     LABEL AppMessage_SIZEOF
  144.  
  145.  
  146. *
  147. * The following structures are private.  These are just stub
  148. * structures for code compatibility...
  149. *
  150.  STRUCTURE AppWindow,0
  151.     STRUCT aw_PRIVATE,0
  152.     LABEL AppWindow_SIZEOF
  153.  
  154.  STRUCTURE AppIcon,0
  155.      STRUCT ai_PRIVATE,0
  156.     LABEL AppIcon_SIZEOF
  157.  
  158.  STRUCTURE AppMenuItem,0
  159.     STRUCT ami_PRIVATE,0
  160.     LABEL AppMenuItem_SIZEOF
  161.  
  162.  
  163.     ENDC    ; WORKBENCH_WORKBENCH_I
  164.  
  165.