Replaced Popscren with a custom pop-up list for selecting public screen. Now it conta...
[tangerine.git] / compiler / include / workbench / workbench.h
blobb50b4523c70f19f4b4784cab25f70b465438d750
1 #ifndef WORKBENCH_WORKBENCH_H
2 #define WORKBENCH_WORKBENCH_H
4 /*
5 Copyright © 1995-2003, The AROS Development Team. All rights reserved.
6 $Id$
7 */
9 #ifndef EXEC_LISTS_H
10 # include <exec/lists.h>
11 #endif
13 #ifndef EXEC_NODES_H
14 # include <exec/nodes.h>
15 #endif
17 #ifndef EXEC_TASKS_H
18 # include <exec/tasks.h>
19 #endif
21 #ifndef EXEC_TYPES_H
22 # include <exec/types.h>
23 #endif
25 #ifndef DOS_BPTR_H
26 # include <dos/bptr.h>
27 #endif
29 #ifndef INTUITION_INTUITION_H
30 # include <intuition/intuition.h>
31 #endif
33 /*** Workbench library name *************************************************/
34 #define WORKBENCHNAME "workbench.library"
36 /*** Structures and associated definitions **********************************/
37 struct DrawerData
39 struct NewWindow dd_NewWindow;
40 LONG dd_CurrentX;
41 LONG dd_CurrentY;
42 ULONG dd_Flags;
43 UWORD dd_ViewModes;
46 #define DRAWERDATAFILESIZE (sizeof(struct DrawerData))
48 /* Definitions for dd_ViewModes */
49 #define DDVM_BYDEFAULT 0 /* Default (inherit parent's view mode) */
50 #define DDVM_BYICON 1 /* View as icons */
51 #define DDVM_BYNAME 2 /* View as text, sorted by name */
52 #define DDVM_BYDATE 3 /* View as text, sorted by date */
53 #define DDVM_BYSIZE 4 /* View as text, sorted by size */
54 #define DDVM_BYTYPE 5 /* View as text, sorted by type */
56 /* Definitions for dd_Flags */
57 #define DDFLAGS_SHOWDEFAULT 0 /* Default (show only icons) */
58 #define DDFLAGS_SHOWICONS 1 /* Show only icons */
59 #define DDFLAGS_SHOWALL 2 /* Show all files */
61 struct DiskObject
63 UWORD do_Magic;
64 UWORD do_Version;
65 struct Gadget do_Gadget;
66 UBYTE do_Type; /* see below */
67 STRPTR do_DefaultTool;
68 STRPTR *do_ToolTypes;
69 LONG do_CurrentX;
70 LONG do_CurrentY;
71 struct DrawerData *do_DrawerData;
72 STRPTR do_ToolWindow;
73 LONG do_StackSize;
76 #define WBDISK (1)
77 #define WBDRAWER (2)
78 #define WBTOOL (3)
79 #define WBPROJECT (4)
80 #define WBGARBAGE (5)
81 #define WBDEVICE (6)
82 #define WBKICK (7)
83 #define WBAPPICON (8)
85 #define WB_DISKVERSION (1)
86 #define WB_DISKREVISION (1)
87 #define WB_DISKREVISIONMASK (0xFF)
89 #define WB_DISKMAGIC (0xE310)
91 struct FreeList
93 WORD fl_NumFree;
94 struct List fl_MemList;
97 /* Icons */
98 #define GFLG_GADGBACKFILL 0x0001
99 #define NO_ICON_POSITION 0x80000000
101 struct AppMessage
103 struct Message am_Message;
104 UWORD am_Type; /* see below */
105 ULONG am_UserData;
106 ULONG am_ID;
107 LONG am_NumArgs;
108 struct WBArg * am_ArgList;
109 UWORD am_Version; /* see below */
110 UWORD am_Class;
111 WORD am_MouseX;
112 WORD am_MouseY;
113 ULONG am_Seconds;
114 ULONG am_Micros;
115 ULONG am_Reserved[8];
118 /* Definition for am_Version */
119 #define AM_VERSION 1
121 /* Definitions for am_Type */
122 #define AMTYPE_APPWINDOW 7
123 #define AMTYPE_APPICON 8
124 #define AMTYPE_APPMENUITEM 9
126 /* Definitions for am_Class */
127 #define AMCLASSICON_Open 0
128 #define AMCLASSICON_Copy 1
129 #define AMCLASSICON_Rename 2
130 #define AMCLASSICON_Information 3
131 #define AMCLASSICON_Snapshot 4
132 #define AMCLASSICON_UnSnapshot 5
133 #define AMCLASSICON_LeaveOut 6
134 #define AMCLASSICON_PutAway 7
135 #define AMCLASSICON_Delete 8
136 #define AMCLASSICON_FormatDisk 9
137 #define AMCLASSICON_EmptyTrash 10
138 #define AMCLASSICON_Selected 11
139 #define AMCLASSICON_Unselected 12
141 struct AppIconRenderMsg
143 struct RastPort *arm_RastPort;
144 struct DiskObject *arm_Icon;
145 STRPTR arm_Label;
146 struct TagItem *arm_Tags;
147 WORD arm_Left;
148 WORD arm_Top;
149 WORD arm_Width;
150 WORD arm_Height;
151 ULONG arm_State;
154 struct AppWindowDropZoneMsg
156 struct RastPort *adzm_RastPort;
157 struct IBox adzm_DropZoneBox;
158 ULONG adzm_ID;
159 ULONG adzm_UserData;
160 LONG adzm_Action; /* see below */
163 /* Definitions for adzm_Action */
164 #define ADZMACTION_Enter (0)
165 #define ADZMACTION_Leave (1)
167 struct IconSelectMsg
169 ULONG ism_Length;
170 BPTR ism_Drawer;
171 STRPTR ism_Name;
172 UWORD ism_Type;
173 BOOL ism_Selected;
174 struct TagItem *ism_Tags;
175 struct Window *ism_DrawerWindow;
176 struct Window *ism_ParentWindow;
177 WORD ism_Left;
178 WORD ism_Top;
179 WORD ism_Width;
180 WORD ism_Height;
183 /* Hook return values */
184 #define ISMACTION_Unselect (0)
185 #define ISMACTION_Select (1)
186 #define ISMACTION_Ignore (2)
187 #define ISMACTION_Stop (3)
189 /*** Private structures *****************************************************/
190 struct AppWindow;
191 struct AppWindowDropZone;
192 struct AppIcon;
193 struct AppMenuItem;
195 /*** Start of workbench.library tags ****************************************/
196 #define WBA_BASE (TAG_USER+0xA000)
198 /*** Tags for use with AddAppIconA() ****************************************/
199 /* The different menu items the AppIcon responds to (BOOL) */
200 #define WBAPPICONA_SupportsOpen (WBA_BASE+1)
201 #define WBAPPICONA_SupportsCopy (WBA_BASE+2)
202 #define WBAPPICONA_SupportsRename (WBA_BASE+3)
203 #define WBAPPICONA_SupportsInformation (WBA_BASE+4)
204 #define WBAPPICONA_SupportsSnapshot (WBA_BASE+5)
205 #define WBAPPICONA_SupportsUnSnapshot (WBA_BASE+6)
206 #define WBAPPICONA_SupportsLeaveOut (WBA_BASE+7)
207 #define WBAPPICONA_SupportsPutAway (WBA_BASE+8)
208 #define WBAPPICONA_SupportsDelete (WBA_BASE+9)
209 #define WBAPPICONA_SupportsFormatDisk (WBA_BASE+10)
210 #define WBAPPICONA_SupportsEmptyTrash (WBA_BASE+11)
212 /* Propagate the AppIcons position back to original DiskObject (BOOL) */
213 #define WBAPPICONA_PropagatePosition (WBA_BASE+12)
215 /* Call this hook when rendering this AppIcon (struct Hook *) */
216 #define WBAPPICONA_RenderHook (WBA_BASE+13)
218 /* Notify the AppIcon when it's select state changes (BOOL) */
219 #define WBAPPICONA_NotifySelectState (WBA_BASE+14)
221 /*** Tags for use with AddAppMenuItemA() ************************************/
222 /* Command key string for this AppMenu (STRPTR) */
223 #define WBAPPMENUA_CommandKeyString (WBA_BASE+15)
225 /*** Tags for use with OpenWorkbenchObjectA() *******************************/
226 #define WBOPENA_ArgLock (WBA_BASE+16)
227 #define WBOPENA_ArgName (WBA_BASE+17)
229 /*** Tags for use with WorkbenchControlA() **********************************/
230 #define WBCTRLA_IsOpen (WBA_BASE+18)
231 #define WBCTRLA_DuplicateSearchPath (WBA_BASE+19)
232 #define WBCTRLA_FreeSearchPath (WBA_BASE+20)
233 #define WBCTRLA_GetDefaultStackSize (WBA_BASE+21)
234 #define WBCTRLA_SetDefaultStackSize (WBA_BASE+22)
235 #define WBCTRLA_RedrawAppIcon (WBA_BASE+23)
236 #define WBCTRLA_GetProgramList (WBA_BASE+24)
237 #define WBCTRLA_FreeProgramList (WBA_BASE+25)
238 #define WBCTRLA_GetSelectedIconList (WBA_BASE+36)
239 #define WBCTRLA_FreeSelectedIconList (WBA_BASE+37)
240 #define WBCTRLA_GetOpenDrawerList (WBA_BASE+38)
241 #define WBCTRLA_FreeOpenDrawerList (WBA_BASE+39)
242 #define WBCTRLA_GetHiddenDeviceList (WBA_BASE+42)
243 #define WBCTRLA_FreeHiddenDeviceList (WBA_BASE+43)
244 #define WBCTRLA_AddHiddenDeviceName (WBA_BASE+44)
245 #define WBCTRLA_RemoveHiddenDeviceName (WBA_BASE+45)
246 #define WBCTRLA_GetTypeRestartTime (WBA_BASE+47)
247 #define WBCTRLA_SetTypeRestartTime (WBA_BASE+48)
249 /*** Tags for use with AddAppWindowDropZoneA() ******************************/
250 #define WBDZA_Left (WBA_BASE+26)
251 #define WBDZA_RelRight (WBA_BASE+27)
252 #define WBDZA_Top (WBA_BASE+28)
253 #define WBDZA_RelBottom (WBA_BASE+29)
254 #define WBDZA_Width (WBA_BASE+30)
255 #define WBDZA_RelWidth (WBA_BASE+31)
256 #define WBDZA_Height (WBA_BASE+32)
257 #define WBDZA_RelHeight (WBA_BASE+33)
258 #define WBDZA_Box (WBA_BASE+34)
259 #define WBDZA_Hook (WBA_BASE+35)
261 /*** Reserved tags **********************************************************/
262 #define WBA_Reserved1 (WBA_BASE+40)
263 #define WBA_Reserved2 (WBA_BASE+41)
264 #define WBA_Reserved3 (WBA_BASE+46)
265 #define WBA_Reserved4 (WBA_BASE+49)
266 #define WBA_Reserved5 (WBA_BASE+50)
267 #define WBA_Reserved6 (WBA_BASE+51)
268 #define WBA_Reserved7 (WBA_BASE+52)
269 #define WBA_Reserved8 (WBA_BASE+53)
270 #define WBA_Reserved9 (WBA_BASE+54)
271 #define WBA_Reserved10 (WBA_BASE+55)
272 #define WBA_Reserved11 (WBA_BASE+56)
273 #define WBA_Reserved12 (WBA_BASE+57)
274 #define WBA_Reserved13 (WBA_BASE+58)
275 #define WBA_Reserved14 (WBA_BASE+59)
276 #define WBA_Reserved15 (WBA_BASE+60)
277 #define WBA_Reserved16 (WBA_BASE+61)
278 #define WBA_Reserved17 (WBA_BASE+62)
279 #define WBA_Reserved18 (WBA_BASE+63)
280 #define WBA_Reserved19 (WBA_BASE+64)
282 /*** Last tag ***************************************************************/
284 #define WBA_LAST_TAG (WBA_BASE+64)
286 #endif /* WORKBENCH_WORKBENCH_H */