unit Intuition_2;

INTERFACE
uses Exec, Graphics, Input, Intuition, Keymap, Timer, Utility;


type
	ppRemember = ^pRemember;


var
	IntuitionBase: pIntuitionBase;


const
	LABELIMAGE = $2000;
	MENUHELP = $1000000;
	WBENCHWINDOW = $2000000;
	SMART_REFRESH = 0;
	BOTTOMBORDER = $80;
	ACTIVEWINDOW = $40000;
	WINDOWACTIVE = $2000;
	IDCMPUPDATE = $800000;
	STRINGCENTER = $200;
	BORDERSNIFF = $8000;
	NEWPREFS = $4000;
	LABELSTRING = $1000;
	GADGET0002 = 2;
	STRINGEXTEND = $2000;
	RIGHTBORDER = $10;
	GADGIMMEDIATE = 2;
	BOOLGADGET = 1;
	DISKREMOVED = $10000;
	GADGIMAGE = 4;
	REFRESHBITS = $C0;
	SUPER_BITMAP = $80;
	WINDOWSIZING = 1;
	RMBTRAP = $10000;
	GRELHEIGHT = $40;
	CLOSEWINDOW_ = $200;
	GADGETDOWN = $20;
	LONGINT_ = $800;
	GADGDISABLED = $100;
	SUPFRONT = $50;
	ENDGADGET = 4;
	WINDOWDEPTH = 4;
	LEFTBORDER = $20;
	WINDOWCLOSE = 8;
	WUPFRONT = $40;
	HASZOOM = $20000000;
	PROPGADGET = 3;
	SIZEBBOTTOM = $20;
	LABELITEXT = 0;
	GADGETTYPE = $FC00;
	MOUSEBUTTONS = 8;
	GADGHCOMP = 0;
	NEWSIZE = 2;
	GADGHNONE = 3;
	STRINGRIGHT = $400;
	VANILLAKEY = $200000;
	NW_EXTENDED = $40000;
	LABELMASK = $3000;
	WBENCHMESSAGE = $20000;
	BOOLEXTEND = $2000;
	BORDERLESS = $800;
	WINDOWDRAG = 2;
	FOLLOWMOUSE = 8;
	SCRGADGET = $4000;
	REQGADGET = $1000;
	REPORTMOUSE_ = $200;
	VISITOR = $8000000;
	SDRAGGING = $30;
	SIZEBRIGHT = $10;
	INACTIVEWINDOW = $80000;
	NOCAREREFRESH = $20000;
	ZOOMED = $10000000;
	GRELBOTTOM = 8;
	WDRAGGING = $20;
	GADGHIGHBITS = 3;
	SDOWNBACK = $70;
	STRINGLEFT = 0;
	RAWKEY = $400;
	ACTIVEGADGET = $4000;
	SIZING = $10;
	REQSET = $80;
	WDOWNBACK = $60;
	DELTAMOVE = $100000;
	INTUITICKS = $400000;
	SIMPLE_REFRESH = $40;
	CLOSE_ = $80;
	STRGADGET = 4;
	MENUVERIFY = $2000;
	GZZGADGET = $2000;
	GRELRIGHT = $10;
	ALTKEYMAP = $1000;
	GADGHBOX = 1;
	LONELYMESSAGE = $80000000;
	GRELWIDTH = $20;
	SYSGADGET = $8000;
	SIZEVERIFY = 1;
	BACKDROP = $100;
	SELECTED = $80;
	TOPBORDER = $40;
	REQCLEAR = $1000;
	CHANGEWINDOW = $2000000;
	GTYPEMASK = 7;
	GADGETUP = $40;
	ACTIVATE = $1000;
	MENUSTATE = $8000;
	RELVERIFY = 1;
	TOGGLESELECT = $100;
	REFRESHWINDOW = 4;
	WINDOWREFRESH = $1000000;
	CUSTOMGADGET = 5;
	REQVERIFY = $800;
	GADGHIMAGE = 2;
	DISKINSERTED = $8000;
	MOUSEMOVE = $10;
	GIMMEZEROZERO = $400;
	INREQUEST = $4000;
	MENUPICK = $100;
	OTHER_REFRESH = $C0;
	WINDOWTICKED = $4000000;


procedure OpenIntuition;
procedure Intuition_ (iEvent: pInputEvent);
function AddGadget
		(window: pWindow;
		gadget: pGadget;
		position: word): word;

function ClearDMRequest (window: pWindow): boolean;
procedure ClearMenuStrip (window: pWindow);
procedure ClearPointer (window: pWindow);
function CloseScreen (screen: pScreen): boolean;
procedure CloseWindow (window: pWindow);
function CloseWorkBench: boolean;
procedure CurrentTime
		(seconds: plong;
		micros: plong);

function DisplayAlert
		(alertNumber: long;
		string_: pbyte;
		height: integer): boolean;

procedure DisplayBeep (screen: pScreen);
function DoubleClick
		(sSeconds: long;
		sMicros: long;
		cSeconds: long;
		cMicros: long): boolean;

procedure DrawBorder
		(rp: pRastPort;
		border: pBorder;
		leftOffset: integer;
		topOffset: integer);

procedure DrawImage
		(rp: pRastPort;
		image: pImage;
		leftOffset: integer;
		topOffset: integer);

procedure EndRequest
		(requester: pRequester;
		window: pWindow);

function GetDefPrefs
		(preferences: pPreferences;
		size: integer): pPreferences;

function GetPrefs
		(preferences: pPreferences;
		size: integer): pPreferences;

procedure InitRequester (requester: pRequester);
function ItemAddress
		(menuStrip: pMenu;
		menuNumber: word): pMenuItem;

function ModifyIDCMP
		(window: pWindow;
		flags: long): boolean;

procedure ModifyProp
		(gadget: pGadget;
		window: pWindow;
		requester: pRequester;
		flags: word;
		horizPot: word;
		vertPot: word;
		horizBody: word;
		vertBody: word);

procedure MoveScreen
		(screen: pScreen;
		dx: integer;
		dy: integer);

procedure MoveWindow
		(window: pWindow;
		dx: integer;
		dy: integer);

procedure OffGadget
		(gadget: pGadget;
		window: pWindow;
		requester: pRequester);

procedure OffMenu
		(window: pWindow;
		menuNumber: word);

procedure OnGadget
		(gadget: pGadget;
		window: pWindow;
		requester: pRequester);

procedure OnMenu
		(window: pWindow;
		menuNumber: word);

function OpenScreen (newScreen: pNewScreen): pScreen;
function OpenWindow (newWindow: pNewWindow): pWindow;
function OpenWorkBench: boolean;
procedure PrintIText
		(rp: pRastPort;
		iText: pIntuiText;
		left: integer;
		top: integer);

procedure RefreshGadgets
		(gadgets: pGadget;
		window: pWindow;
		requester: pRequester);

function RemoveGadget
		(window: pWindow;
		gadget: pGadget): word;

procedure ReportMouse
		(flag: boolean;
		window: pWindow);

function Request
		(requester: pRequester;
		window: pWindow): boolean;

procedure ScreenToBack (screen: pScreen);
procedure ScreenToFront (screen: pScreen);
function SetDMRequest
		(window: pWindow;
		requester: pRequester): boolean;

function SetMenuStrip
		(window: pWindow;
		menu: pMenu): boolean;

procedure SetPointer
		(window: pWindow;
		pointer: pword;
		height: integer;
		width: integer;
		xOffset: integer;
		yOffset: integer);

procedure SetWindowTitles
		(window: pWindow;
		windowTitle: STRPTR;
		screenTitle: STRPTR);

procedure ShowTitle
		(screen: pScreen;
		showIt: boolean);

procedure SizeWindow
		(window: pWindow;
		dx: integer;
		dy: integer);

function ViewAddress: pView;
function ViewPortAddress (window: pWindow): pViewPort;
procedure WindowToBack (window: pWindow);
procedure WindowToFront (window: pWindow);
function WindowLimits
		(window: pWindow;
		widthMin: integer;
		heightMin: integer;
		widthMax: word;
		heightMax: word): boolean;

function SetPrefs
		(preferences: pPreferences;
		size: longint;
		inform: boolean): pPreferences;

function IntuiTextLength (iText: pIntuiText): longint;
function WBenchToBack: boolean;
function WBenchToFront: boolean;
function AutoRequest
		(window: pWindow;
		body: pIntuiText;
		posText: pIntuiText;
		negText: pIntuiText;
		pFlag: long;
		nFlag: long;
		width: integer;
		height: integer): boolean;

procedure BeginRefresh (window: pWindow);
function BuildSysRequest
		(window: pWindow;
		body: pIntuiText;
		posText: pIntuiText;
		negText: pIntuiText;
		flags: long;
		width: integer;
		height: integer): pWindow;

procedure EndRefresh
		(window: pWindow;
		complete: boolean);

procedure FreeSysRequest (window: pWindow);
procedure MakeScreen (screen: pScreen);
procedure RemakeDisplay;
procedure RethinkDisplay;
function AllocRemember
		(rememberKey: ppRemember;
		size: long;
		flags: long): pointer;

procedure AlohaWorkbench (wbport: longint);
procedure FreeRemember
		(rememberKey: ppRemember;
		reallyForget: boolean);

function LockIBase (dontknow: long): long;
procedure UnlockIBase (ibLock: long);
function GetScreenData
		(buffer: pointer;
		size: word;
		type_: word;
		screen: pScreen): boolean;

procedure RefreshGList
		(gadgets: pGadget;
		window: pWindow;
		requester: pRequester;
		numGad: integer);

function AddGList
		(window: pWindow;
		gadget: pGadget;
		position: word;
		numGad: integer;
		requester: pRequester): word;

function RemoveGList
		(remPtr: pWindow;
		gadget: pGadget;
		numGad: integer): word;

function ActivateWindow (window: pWindow): longint;
procedure RefreshWindowFrame (window: pWindow);
function ActivateGadget
		(gadgets: pGadget;
		window: pWindow;
		requester: pRequester): boolean;

procedure NewModifyProp
		(gadget: pGadget;
		window: pWindow;
		requester: pRequester;
		flags: word;
		horizPot: word;
		vertPot: word;
		horizBody: word;
		vertBody: word;
		numGad: integer);

function QueryOverscan
		(displayID: long;
		rect: pRectangle;
		oScanType: integer): longint;

procedure MoveWindowInFrontOf
		(window: pWindow;
		behindWindow: pWindow);

procedure ChangeWindowBox
		(window: pWindow;
		left: integer;
		top: integer;
		width: integer;
		height: integer);

function SetEditHook (hook: pHook): pHook;
function SetMouseQueue
		(window: pWindow;
		queueLength: word): longint;

procedure ZipWindow (window: pWindow);
function LockPubScreen (name: STRPTR): pScreen;
procedure UnlockPubScreen
		(name: STRPTR;
		screen: pScreen);

function LockPubScreenList: pList;
procedure UnlockPubScreenList;
function NextPubScreen
		(screen: pScreen;
		namebuf: pbyte): STRPTR;

procedure SetDefaultPubScreen (name: STRPTR);
function SetPubScreenModes (modes: word): word;
function PubScreenStatus
		(screen: pScreen;
		statusFlags: word): word;

function ObtainGIRPort (gInfo: pGadgetInfo): pRastPort;
procedure ReleaseGIRPort (rp: pRastPort);
procedure GetDefaultPubScreen (nameBuffer: pbyte);
function EasyRequestArgs
		(window: pWindow;
		easyStruct: pEasyStruct;
		idcmpPtr: plong;
		args: pointer): longint;

function BuildEasyRequestArgs
		(window: pWindow;
		easyStruct: pEasyStruct;
		idcmp: long;
		args: pointer): pWindow;

function SysReqHandler
		(window: pWindow;
		idcmpPtr: plong;
		waitInput: boolean): longint;

function OpenWindowTagList
		(newWindow: pNewWindow;
		tagList: pTagItem): pWindow;

function OpenScreenTagList
		(newScreen: pNewScreen;
		tagList: pTagItem): pScreen;

procedure DrawImageState
		(rp: pRastPort;
		image: pImage;
		leftOffset: integer;
		topOffset: integer;
		state: long;
		drawInfo: pDrawInfo);

function PointInImage
		(point: Point;
		image: pImage): boolean;

procedure EraseImage
		(rp: pRastPort;
		image: pImage;
		leftOffset: integer;
		topOffset: integer);

function NewObjectA
		(classPtr: pIClass;
		classID: STRPTR;
		tagList: pTagItem): pointer;

procedure DisposeObject (object: pointer);
function SetAttrsA
		(object: pointer;
		tagList: pTagItem): long;

function GetAttr
		(attrID: long;
		object: pointer;
		storagePtr: plong): long;

function SetGadgetAttrsA
		(gadget: pGadget;
		window: pWindow;
		requester: pRequester;
		tagList: pTagItem): long;

function NextObject (objectPtrPtr: pointer): pointer;
function MakeClass
		(classID: STRPTR;
		superClassID: STRPTR;
		superClassPtr: pIClass;
		instanceSize: word;
		flags: long): pIClass;

procedure AddClass (classPtr: pIClass);
function GetScreenDrawInfo (screen: pScreen): pDrawInfo;
procedure FreeScreenDrawInfo
		(screen: pScreen;
		drawInfo: pDrawInfo);

function ResetMenuStrip
		(window: pWindow;
		menu: pMenu): boolean;

procedure RemoveClass (classPtr: pIClass);
function FreeClass (classPtr: pIClass): boolean;


function MENUNUM (n: word): integer;
function ITEMNUM (n: word): integer;
function SUBNUM (n: word): integer;
function SHIFTMENU (n: integer): word;
function SHIFTITEM (n: integer): word;
function SHIFTSUB (n: integer): word;
function FULLMENUNUM (menu, item, sub: integer): word;

function SHAKNUM (n: byte): integer;
function SPARNUM (n: byte): integer;
function SRBNUM (n: byte): integer;
function SSBNUM (n: byte): integer;
function SWBNUM (n: byte): integer;

function CUSTOM_HOOK (gadget: pGadget): pHook;
function GADGET_BOX (g: pGadget): pIBox;
function IM_BGPEN (im: pImage): byte;
function IM_BOX (im: pImage): pIBox; inline $2E9F;
function IM_FGPEN (im: pImage): byte;

function BASEOBJECT (o: p_Object): pointer;
function INST_DATA (cl: pIClass; o: pointer): pointer;
function _OBJ(o: pointer): p_Object; inline $2E9F;
function _OBJECT (o: pointer): p_Object;
function OCLASS (o: pointer): pIClass;
function SIZEOF_INSTANCE (cl: pIClass): longint;


IMPLEMENTATION
function INST_DATA;
begin
	INST_DATA := pointer(longint(o) + cl^.cl_InstOffset)
end;

function SIZEOF_INSTANCE;
begin
	SIZEOF_INSTANCE := cl^.cl_InstOffset + cl^.cl_InstSize + sizeof(t_Object)
end;

function BASEOBJECT;
begin
	BASEOBJECT := pointer(longint(o) + sizeof(t_Object))
end;

function _OBJECT;
begin
	_OBJECT := p_Object(longint(o) - sizeof(t_Object))
end;

function OCLASS;
var
	obj: p_Object;
begin
	obj := p_Object(longint(o) - sizeof(t_Object));
	OCLASS := obj^.o_Class
end;

function ITEMNUM;
begin
	ITEMNUM := (n shr 5) and $3F
end;

function MENUNUM;
begin
	MENUNUM := n and $1f
end;

function SUBNUM;
begin
	SUBNUM := (n shr 11) and $1f
end;

function SHIFTITEM;
begin
	SHIFTITEM := (n and $3f) shl 5
end;

function SHIFTMENU;
begin
	SHIFTMENU := n and $1f
end;

function SHIFTSUB;
begin
	SHIFTSUB := (n and $1f) shl 11
end;

function FULLMENUNUM;
begin
	FULLMENUNUM := ((sub and $1f) shl 11) or
					((item and $3f) shl 5) or
					  (menu and $1f)
end;

function SPARNUM;
begin
	SPARNUM := n shr 4
end;

function SHAKNUM;
begin
	SHAKNUM := n and $f
end;

function SRBNUM;
begin
	SRBNUM := $8 - (n shr 4)
end;

function SSBNUM;
begin
	SSBNUM := $1 + (n shr 4)
end;

function SWBNUM;
begin
	SWBNUM := $8 - (n and $f)
end;

function IM_BGPEN;
begin
	IM_BGPEN := im^.PlaneOnOff
end;

function IM_FGPEN;
begin
	IM_FGPEN := im^.PlanePick
end;

function GADGET_BOX;
begin
	GADGET_BOX := pIBox(@g^.LeftEdge)
end;

function CUSTOM_HOOK;
begin
	CUSTOM_HOOK := pHook(gadget^.MutualExclude)
end;

procedure OpenIntuition; xassembler;
asm
	move.l	a6,-(sp)
	move.l	IntuitionBase,a6
	jsr		-$1E(a6)
	move.l	(sp)+,a6
end;

procedure Intuition_; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$24(a6)
	move.l	(sp)+,a6
end;

function AddGadget; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.w	(a6)+,d0
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$2A(a6)
	move.w	d0,$12(sp)
	move.l	(sp)+,a6
end;

function ClearDMRequest; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$30(a6)
	tst.l	d0
	sne		d0
	neg.b	d0
	move.b	d0,$C(sp)
	move.l	(sp)+,a6
end;

procedure ClearMenuStrip; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$36(a6)
	move.l	(sp)+,a6
end;

procedure ClearPointer; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$3C(a6)
	move.l	(sp)+,a6
end;

function CloseScreen; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$42(a6)
	tst.l	d0
	sne		d0
	neg.b	d0
	move.b	d0,$C(sp)
	move.l	(sp)+,a6
end;

procedure CloseWindow; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$48(a6)
	move.l	(sp)+,a6
end;

function CloseWorkBench; xassembler;
asm
	move.l	a6,-(sp)
	move.l	IntuitionBase,a6
	jsr		-$4E(a6)
	tst.l	d0
	sne		d0
	neg.b	d0
	move.b	d0,8(sp)
	move.l	(sp)+,a6
end;

procedure CurrentTime; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$54(a6)
	move.l	(sp)+,a6
end;

function DisplayAlert; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.w	(a6)+,d1
	move.l	(a6)+,a0
	move.l	(a6)+,d0
	move.l	IntuitionBase,a6
	jsr		-$5A(a6)
	tst.l	d0
	sne		d0
	neg.b	d0
	move.b	d0,$12(sp)
	move.l	(sp)+,a6
end;

procedure DisplayBeep; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$60(a6)
	move.l	(sp)+,a6
end;

function DoubleClick; xassembler;
asm
	movem.l	d3/a6,-(sp)
	lea		$C(sp),a6
	move.l	(a6)+,d3
	move.l	(a6)+,d2
	move.l	(a6)+,d1
	move.l	(a6)+,d0
	move.l	IntuitionBase,a6
	jsr		-$66(a6)
	tst.l	d0
	sne		d0
	neg.b	d0
	move.b	d0,$1C(sp)
	movem.l	(sp)+,d3/a6
end;

procedure DrawBorder; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.w	(a6)+,d1
	move.w	(a6)+,d0
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$6C(a6)
	move.l	(sp)+,a6
end;

procedure DrawImage; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.w	(a6)+,d1
	move.w	(a6)+,d0
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$72(a6)
	move.l	(sp)+,a6
end;

procedure EndRequest; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$78(a6)
	move.l	(sp)+,a6
end;

function GetDefPrefs; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.w	(a6)+,d0
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$7E(a6)
	move.l	d0,$E(sp)
	move.l	(sp)+,a6
end;

function GetPrefs; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.w	(a6)+,d0
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$84(a6)
	move.l	d0,$E(sp)
	move.l	(sp)+,a6
end;

procedure InitRequester; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$8A(a6)
	move.l	(sp)+,a6
end;

function ItemAddress; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.w	(a6)+,d0
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$90(a6)
	move.l	d0,$E(sp)
	move.l	(sp)+,a6
end;

function ModifyIDCMP; xassembler;
asm
	move.l	a6,-(sp)
	movem.l	8(sp),d0/a0
	move.l	IntuitionBase,a6
	jsr		-$96(a6)
	tst.l	d0
	sne		d0
	neg.b	d0
	move.b	d0,$10(sp)
	move.l	(sp)+,a6
end;

procedure ModifyProp; xassembler;
asm
	movem.l	d3-d4/a2/a6,-(sp)
	lea		$14(sp),a6
	move.w	(a6)+,d4
	move.w	(a6)+,d3
	move.w	(a6)+,d2
	move.w	(a6)+,d1
	move.w	(a6)+,d0
	move.l	(a6)+,a2
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$9C(a6)
	movem.l	(sp)+,d3-d4/a2/a6
end;

procedure MoveScreen; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.w	(a6)+,d1
	move.w	(a6)+,d0
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$A2(a6)
	move.l	(sp)+,a6
end;

procedure MoveWindow; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.w	(a6)+,d1
	move.w	(a6)+,d0
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$A8(a6)
	move.l	(sp)+,a6
end;

procedure OffGadget; xassembler;
asm
	movem.l	a2/a6,-(sp)
	lea		$C(sp),a6
	move.l	(a6)+,a2
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$AE(a6)
	movem.l	(sp)+,a2/a6
end;

procedure OffMenu; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.w	(a6)+,d0
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$B4(a6)
	move.l	(sp)+,a6
end;

procedure OnGadget; xassembler;
asm
	movem.l	a2/a6,-(sp)
	lea		$C(sp),a6
	move.l	(a6)+,a2
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$BA(a6)
	movem.l	(sp)+,a2/a6
end;

procedure OnMenu; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.w	(a6)+,d0
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$C0(a6)
	move.l	(sp)+,a6
end;

function OpenScreen; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$C6(a6)
	move.l	d0,$C(sp)
	move.l	(sp)+,a6
end;

function OpenWindow; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$CC(a6)
	move.l	d0,$C(sp)
	move.l	(sp)+,a6
end;

function OpenWorkBench; xassembler;
asm
	move.l	a6,-(sp)
	move.l	IntuitionBase,a6
	jsr		-$D2(a6)
	tst.l	d0
	sne		d0
	neg.b	d0
	move.b	d0,8(sp)
	move.l	(sp)+,a6
end;

procedure PrintIText; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.w	(a6)+,d1
	move.w	(a6)+,d0
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$D8(a6)
	move.l	(sp)+,a6
end;

procedure RefreshGadgets; xassembler;
asm
	movem.l	a2/a6,-(sp)
	lea		$C(sp),a6
	move.l	(a6)+,a2
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$DE(a6)
	movem.l	(sp)+,a2/a6
end;

function RemoveGadget; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$E4(a6)
	move.w	d0,$10(sp)
	move.l	(sp)+,a6
end;

procedure ReportMouse; xassembler;
asm
	move.l	a6,-(sp)
	moveq	#0,d0
	lea		8(sp),a6
	move.l	(a6)+,a0
	move.b	(a6)+,d0
	move.l	IntuitionBase,a6
	jsr		-$EA(a6)
	move.l	(sp)+,a6
end;

function Request; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$F0(a6)
	tst.l	d0
	sne		d0
	neg.b	d0
	move.b	d0,$10(sp)
	move.l	(sp)+,a6
end;

procedure ScreenToBack; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$F6(a6)
	move.l	(sp)+,a6
end;

procedure ScreenToFront; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$FC(a6)
	move.l	(sp)+,a6
end;

function SetDMRequest; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$102(a6)
	tst.l	d0
	sne		d0
	neg.b	d0
	move.b	d0,$10(sp)
	move.l	(sp)+,a6
end;

function SetMenuStrip; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$108(a6)
	tst.l	d0
	sne		d0
	neg.b	d0
	move.b	d0,$10(sp)
	move.l	(sp)+,a6
end;

procedure SetPointer; xassembler;
asm
	movem.l	d3/a6,-(sp)
	lea		$C(sp),a6
	move.w	(a6)+,d3
	move.w	(a6)+,d2
	move.w	(a6)+,d1
	move.w	(a6)+,d0
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$10E(a6)
	movem.l	(sp)+,d3/a6
end;

procedure SetWindowTitles; xassembler;
asm
	movem.l	a2/a6,-(sp)
	lea		$C(sp),a6
	move.l	(a6)+,a2
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$114(a6)
	movem.l	(sp)+,a2/a6
end;

procedure ShowTitle; xassembler;
asm
	move.l	a6,-(sp)
	moveq	#0,d0
	move.b	8(sp),d0
	move.l	$A(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$11A(a6)
	move.l	(sp)+,a6
end;

procedure SizeWindow; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.w	(a6)+,d1
	move.w	(a6)+,d0
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$120(a6)
	move.l	(sp)+,a6
end;

function ViewAddress; xassembler;
asm
	move.l	a6,-(sp)
	move.l	IntuitionBase,a6
	jsr		-$126(a6)
	move.l	d0,8(sp)
	move.l	(sp)+,a6
end;

function ViewPortAddress; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$12C(a6)
	move.l	d0,$C(sp)
	move.l	(sp)+,a6
end;

procedure WindowToBack; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$132(a6)
	move.l	(sp)+,a6
end;

procedure WindowToFront; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$138(a6)
	move.l	(sp)+,a6
end;

function WindowLimits; xassembler;
asm
	movem.l	d3/a6,-(sp)
	lea		$C(sp),a6
	move.w	(a6)+,d3
	move.w	(a6)+,d2
	move.w	(a6)+,d1
	move.w	(a6)+,d0
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$13E(a6)
	tst.l	d0
	sne		d0
	neg.b	d0
	move.b	d0,$18(sp)
	movem.l	(sp)+,d3/a6
end;

function SetPrefs; xassembler;
asm
	move.l	a6,-(sp)
	moveq	#0,d1
	move.b	8(sp),d1
	movem.l	$A(sp),d0/a0
	move.l	IntuitionBase,a6
	jsr		-$144(a6)
	move.l	d0,$12(sp)
	move.l	(sp)+,a6
end;

function IntuiTextLength; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$14A(a6)
	move.l	d0,$C(sp)
	move.l	(sp)+,a6
end;

function WBenchToBack; xassembler;
asm
	move.l	a6,-(sp)
	move.l	IntuitionBase,a6
	jsr		-$150(a6)
	tst.l	d0
	sne		d0
	neg.b	d0
	move.b	d0,8(sp)
	move.l	(sp)+,a6
end;

function WBenchToFront; xassembler;
asm
	move.l	a6,-(sp)
	move.l	IntuitionBase,a6
	jsr		-$156(a6)
	tst.l	d0
	sne		d0
	neg.b	d0
	move.b	d0,8(sp)
	move.l	(sp)+,a6
end;

function AutoRequest; xassembler;
asm
	movem.l	d3/a2-a3/a6,-(sp)
	lea		$14(sp),a6
	move.w	(a6)+,d3
	move.w	(a6)+,d2
	move.l	(a6)+,d1
	move.l	(a6)+,d0
	move.l	(a6)+,a3
	move.l	(a6)+,a2
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$15C(a6)
	tst.l	d0
	sne		d0
	neg.b	d0
	move.b	d0,$30(sp)
	movem.l	(sp)+,d3/a2-a3/a6
end;

procedure BeginRefresh; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$162(a6)
	move.l	(sp)+,a6
end;

function BuildSysRequest; xassembler;
asm
	movem.l	a2-a3/a6,-(sp)
	lea		$10(sp),a6
	move.w	(a6)+,d2
	move.w	(a6)+,d1
	move.l	(a6)+,d0
	move.l	(a6)+,a3
	move.l	(a6)+,a2
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$168(a6)
	move.l	d0,$28(sp)
	movem.l	(sp)+,a2-a3/a6
end;

procedure EndRefresh; xassembler;
asm
	move.l	a6,-(sp)
	moveq	#0,d0
	move.b	8(sp),d0
	move.l	$A(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$16E(a6)
	move.l	(sp)+,a6
end;

procedure FreeSysRequest; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$174(a6)
	move.l	(sp)+,a6
end;

procedure MakeScreen; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$17A(a6)
	move.l	(sp)+,a6
end;

procedure RemakeDisplay; xassembler;
asm
	move.l	a6,-(sp)
	move.l	IntuitionBase,a6
	jsr		-$180(a6)
	move.l	(sp)+,a6
end;

procedure RethinkDisplay; xassembler;
asm
	move.l	a6,-(sp)
	move.l	IntuitionBase,a6
	jsr		-$186(a6)
	move.l	(sp)+,a6
end;

function AllocRemember; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.l	(a6)+,d1
	move.l	(a6)+,d0
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$18C(a6)
	move.l	d0,$14(sp)
	move.l	(sp)+,a6
end;

procedure AlohaWorkbench; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$192(a6)
	move.l	(sp)+,a6
end;

procedure FreeRemember; xassembler;
asm
	move.l	a6,-(sp)
	moveq	#0,d0
	move.b	8(sp),d0
	move.l	$A(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$198(a6)
	move.l	(sp)+,a6
end;

function LockIBase; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),d0
	move.l	IntuitionBase,a6
	jsr		-$19E(a6)
	move.l	d0,$C(sp)
	move.l	(sp)+,a6
end;

procedure UnlockIBase; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$1A4(a6)
	move.l	(sp)+,a6
end;

function GetScreenData; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.l	(a6)+,a1
	move.w	(a6)+,d1
	move.w	(a6)+,d0
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$1AA(a6)
	tst.l	d0
	sne		d0
	neg.b	d0
	move.b	d0,$14(sp)
	move.l	(sp)+,a6
end;

procedure RefreshGList; xassembler;
asm
	movem.l	a2/a6,-(sp)
	lea		$C(sp),a6
	move.w	(a6)+,d0
	move.l	(a6)+,a2
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$1B0(a6)
	movem.l	(sp)+,a2/a6
end;

function AddGList; xassembler;
asm
	movem.l	a2/a6,-(sp)
	lea		$C(sp),a6
	move.l	(a6)+,a2
	move.w	(a6)+,d1
	move.w	(a6)+,d0
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$1B6(a6)
	move.w	d0,$1C(sp)
	movem.l	(sp)+,a2/a6
end;

function RemoveGList; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.w	(a6)+,d0
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$1BC(a6)
	move.w	d0,$12(sp)
	move.l	(sp)+,a6
end;

function ActivateWindow; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$1C2(a6)
	move.l	d0,$C(sp)
	move.l	(sp)+,a6
end;

procedure RefreshWindowFrame; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$1C8(a6)
	move.l	(sp)+,a6
end;

function ActivateGadget; xassembler;
asm
	movem.l	a2/a6,-(sp)
	lea		$C(sp),a6
	move.l	(a6)+,a2
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$1CE(a6)
	tst.l	d0
	sne		d0
	neg.b	d0
	move.b	d0,$18(sp)
	movem.l	(sp)+,a2/a6
end;

procedure NewModifyProp; xassembler;
asm
	movem.l	d3-d5/a2/a6,-(sp)
	lea		$18(sp),a6
	move.w	(a6)+,d5
	move.w	(a6)+,d4
	move.w	(a6)+,d3
	move.w	(a6)+,d2
	move.w	(a6)+,d1
	move.w	(a6)+,d0
	move.l	(a6)+,a2
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$1D4(a6)
	movem.l	(sp)+,d3-d5/a2/a6
end;

function QueryOverscan; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.w	(a6)+,d0
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$1DA(a6)
	move.l	d0,$12(sp)
	move.l	(sp)+,a6
end;

procedure MoveWindowInFrontOf; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$1E0(a6)
	move.l	(sp)+,a6
end;

procedure ChangeWindowBox; xassembler;
asm
	movem.l	d3/a6,-(sp)
	lea		$C(sp),a6
	move.w	(a6)+,d3
	move.w	(a6)+,d2
	move.w	(a6)+,d1
	move.w	(a6)+,d0
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$1E6(a6)
	movem.l	(sp)+,d3/a6
end;

function SetEditHook; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$1EC(a6)
	move.l	d0,$C(sp)
	move.l	(sp)+,a6
end;

function SetMouseQueue; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.w	(a6)+,d0
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$1F2(a6)
	move.l	d0,$E(sp)
	move.l	(sp)+,a6
end;

procedure ZipWindow; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$1F8(a6)
	move.l	(sp)+,a6
end;

function LockPubScreen; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$1FE(a6)
	move.l	d0,$C(sp)
	move.l	(sp)+,a6
end;

procedure UnlockPubScreen; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$204(a6)
	move.l	(sp)+,a6
end;

function LockPubScreenList; xassembler;
asm
	move.l	a6,-(sp)
	move.l	IntuitionBase,a6
	jsr		-$20A(a6)
	move.l	d0,8(sp)
	move.l	(sp)+,a6
end;

procedure UnlockPubScreenList; xassembler;
asm
	move.l	a6,-(sp)
	move.l	IntuitionBase,a6
	jsr		-$210(a6)
	move.l	(sp)+,a6
end;

function NextPubScreen; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$216(a6)
	move.l	d0,$10(sp)
	move.l	(sp)+,a6
end;

procedure SetDefaultPubScreen; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$21C(a6)
	move.l	(sp)+,a6
end;

function SetPubScreenModes; xassembler;
asm
	move.l	a6,-(sp)
	move.w	8(sp),d0
	move.l	IntuitionBase,a6
	jsr		-$222(a6)
	move.w	d0,$A(sp)
	move.l	(sp)+,a6
end;

function PubScreenStatus; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.w	(a6)+,d0
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$228(a6)
	move.w	d0,$E(sp)
	move.l	(sp)+,a6
end;

function ObtainGIRPort; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$22E(a6)
	move.l	d0,$C(sp)
	move.l	(sp)+,a6
end;

procedure ReleaseGIRPort; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$234(a6)
	move.l	(sp)+,a6
end;

procedure GetDefaultPubScreen; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$246(a6)
	move.l	(sp)+,a6
end;

function EasyRequestArgs; xassembler;
asm
	movem.l	a2-a3/a6,-(sp)
	lea		$10(sp),a6
	move.l	(a6)+,a3
	move.l	(a6)+,a2
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$24C(a6)
	move.l	d0,$20(sp)
	movem.l	(sp)+,a2-a3/a6
end;

function BuildEasyRequestArgs; xassembler;
asm
	movem.l	a3/a6,-(sp)
	lea		$C(sp),a6
	move.l	(a6)+,a3
	move.l	(a6)+,d0
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$252(a6)
	move.l	d0,$1C(sp)
	movem.l	(sp)+,a3/a6
end;

function SysReqHandler; xassembler;
asm
	move.l	a6,-(sp)
	moveq	#0,d0
	lea		8(sp),a6
	move.b	(a6)+,d0
	addq.l	#1,a6
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$258(a6)
	move.l	d0,$12(sp)
	move.l	(sp)+,a6
end;

function OpenWindowTagList; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$25E(a6)
	move.l	d0,$10(sp)
	move.l	(sp)+,a6
end;

function OpenScreenTagList; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$264(a6)
	move.l	d0,$10(sp)
	move.l	(sp)+,a6
end;

procedure DrawImageState; xassembler;
asm
	movem.l	a2/a6,-(sp)
	lea		$C(sp),a6
	move.l	(a6)+,a2
	move.l	(a6)+,d2
	move.w	(a6)+,d1
	move.w	(a6)+,d0
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$26A(a6)
	movem.l	(sp)+,a2/a6
end;

function PointInImage; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.l	(a6)+,a0
	move.l	(a6)+,d0
	move.l	IntuitionBase,a6
	jsr		-$270(a6)
	tst.l	d0
	sne		d0
	neg.b	d0
	move.b	d0,$10(sp)
	move.l	(sp)+,a6
end;

procedure EraseImage; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.w	(a6)+,d1
	move.w	(a6)+,d0
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$276(a6)
	move.l	(sp)+,a6
end;

function NewObjectA; xassembler;
asm
	movem.l	a2/a6,-(sp)
	lea		$C(sp),a6
	move.l	(a6)+,a2
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$27C(a6)
	move.l	d0,$18(sp)
	movem.l	(sp)+,a2/a6
end;

procedure DisposeObject; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$282(a6)
	move.l	(sp)+,a6
end;

function SetAttrsA; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$288(a6)
	move.l	d0,$10(sp)
	move.l	(sp)+,a6
end;

function GetAttr; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	(a6)+,d0
	move.l	IntuitionBase,a6
	jsr		-$28E(a6)
	move.l	d0,$14(sp)
	move.l	(sp)+,a6
end;

function SetGadgetAttrsA; xassembler;
asm
	movem.l	a2-a3/a6,-(sp)
	lea		$10(sp),a6
	move.l	(a6)+,a3
	move.l	(a6)+,a2
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$294(a6)
	move.l	d0,$20(sp)
	movem.l	(sp)+,a2-a3/a6
end;

function NextObject; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$29A(a6)
	move.l	d0,$C(sp)
	move.l	(sp)+,a6
end;

function MakeClass; xassembler;
asm
	movem.l	a2/a6,-(sp)
	lea		$C(sp),a6
	move.l	(a6)+,d1
	move.w	(a6)+,d0
	move.l	(a6)+,a2
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$2A6(a6)
	move.l	d0,$1E(sp)
	movem.l	(sp)+,a2/a6
end;

procedure AddClass; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$2AC(a6)
	move.l	(sp)+,a6
end;

function GetScreenDrawInfo; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$2B2(a6)
	move.l	d0,$C(sp)
	move.l	(sp)+,a6
end;

procedure FreeScreenDrawInfo; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$2B8(a6)
	move.l	(sp)+,a6
end;

function ResetMenuStrip; xassembler;
asm
	move.l	a6,-(sp)
	lea		8(sp),a6
	move.l	(a6)+,a1
	move.l	(a6)+,a0
	move.l	IntuitionBase,a6
	jsr		-$2BE(a6)
	tst.l	d0
	sne		d0
	neg.b	d0
	move.b	d0,$10(sp)
	move.l	(sp)+,a6
end;

procedure RemoveClass; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$2C4(a6)
	move.l	(sp)+,a6
end;

function FreeClass; xassembler;
asm
	move.l	a6,-(sp)
	move.l	8(sp),a0
	move.l	IntuitionBase,a6
	jsr		-$2CA(a6)
	tst.l	d0
	sne		d0
	neg.b	d0
	move.b	d0,$C(sp)
	move.l	(sp)+,a6
end;

end.
