#include "PopDir.h"

/* Image-Ed Image generation */

/* Start of Image data */
USHORT chip popgadImageData[]={
	/* Plane 0 */
	0x0000, 0x0000, 0x7fff, 0xffe0, 0x7bf7, 0xbfe0, 0x7bae, 0xbbe0, 
	0x7bae, 0xbbe0, 0x7bee, 0xbfe0, 0x7bee, 0xbfe0, 0x7bee, 0xbfe0, 
	0x7bf7, 0xbfe0, 0x7fff, 0xffe0, 0x7fff, 0xffe0, 0x7bef, 0xbfe0, 
	0x7bbb, 0xbbe0, 0x7bbb, 0xbbe0, 0x7bbb, 0xbfe0, 0x7bbb, 0xafe0, 
	0x7bbb, 0xb7e0, 0x7bef, 0xbbe0, 0x7fff, 0xffe0, 0x0000, 0x0000, 
	
	/* Plane 1 */
	0xffff, 0xfff0, 0xffff, 0xfff0, 0xfc38, 0xc3f0, 0xfdd7, 0x5df0, 
	0xfdd7, 0x5df0, 0xfc37, 0x43f0, 0xfdf7, 0x5ff0, 0xfdf7, 0x5ff0, 
	0xfdf8, 0xdff0, 0xffff, 0xfff0, 0xffff, 0xfff0, 0xfc30, 0x43f0, 
	0xfddd, 0xddf0, 0xfddd, 0xddf0, 0xfddd, 0xc3f0, 0xfddd, 0xd7f0, 
	0xfddd, 0xdbf0, 0xfc30, 0x5df0, 0xffff, 0xfff0, 0xffff, 0xfff0
	};
/* End of Image data */

struct Image popgadImage={
	0,0,	 /* LeftEdge, TopEdge */
	28,20,2,	 /* Width, Height, Depth */
	popgadImageData,	 /* ImageData */
	0x3,0x0,	 /* PlanePick, PlaneOnOff */
	NULL	 /* NextImage */
};

/* Image-Ed Image generation */

/* Start of Image data */
USHORT chip popgad2ImageData[]={
	/* Plane 0 */
	0x0000, 0x0000, 0x7fff, 0xffe0, 0x7fe7, 0xffe0, 0x7fcf, 0xffe0, 
	0x7f9f, 0xffe0, 0x7f9f, 0xffe0, 0x7f9f, 0xffe0, 0x7f9f, 0xffe0, 
	0x7f9f, 0xffe0, 0x7fcf, 0xffe0, 0x7fcf, 0xffe0, 0x7fcf, 0xffe0, 
	0x7fe7, 0xffe0, 0x7fe7, 0xffe0, 0x7fff, 0xffe0, 0x7fe7, 0xffe0, 
	0x7fe7, 0xffe0, 0x7fe7, 0xffe0, 0x7fff, 0xffe0, 0x0000, 0x0000, 
	
	/* Plane 1 */
	0xffff, 0xfff0, 0xffff, 0xfff0, 0xfff8, 0xfff0, 0xfff0, 0x7ff0, 
	0xffe0, 0x3ff0, 0xffe0, 0x3ff0, 0xffe0, 0x3ff0, 0xffe0, 0x3ff0, 
	0xffe0, 0x3ff0, 0xfff0, 0x7ff0, 0xfff0, 0x7ff0, 0xfff0, 0x7ff0, 
	0xfff8, 0xfff0, 0xfff8, 0xfff0, 0xffff, 0xfff0, 0xfff8, 0xfff0, 
	0xfff8, 0xfff0, 0xfff8, 0xfff0, 0xffff, 0xfff0, 0xffff, 0xfff0
	};
/* End of Image data */

struct Image popgad2Image={
	0,0,	 /* LeftEdge, TopEdge */
	28,20,20,	 /* Width, Height, Depth */
	popgad2ImageData,	 /* ImageData */
	0x3,0x0,	 /* PlanePick, PlaneOnOff */
	NULL	 /* NextImage */
};

/* End of Image-Ed Image generation */

struct Gadget popgad={
	NULL,0,0,28,20,GADGHIMAGE|GADGIMAGE,GADGIMMEDIATE,WDRAGGING,(APTR)&popgadImage,
	(APTR)&popgad2Image,NULL,NULL,NULL,NULL,NULL};

char dobuffer[400]="DF0:", undobuffer[400];
struct StringInfo StrGadInfo={
	dobuffer,undobuffer,0,80,0};
short StrGadBorXY[]={
	-2,-1,332,-1,332,10,-2,10,-2,-1};
struct Border StrGadBor={
	-1,-1,1,0,JAM1,5,StrGadBorXY,NULL};
struct Gadget StrGad={
	NULL,10,15,329,15,GADGHCOMP,RELVERIFY,STRGADGET,(APTR)&StrGadBor,NULL,
	NULL,NULL,(APTR)&StrGadInfo,DIR,NULL};

short BoxGadBorXY[]={
	0,0,40,0,40,20,0,20,0,0};
struct Border BoxGadBor={
	-1,-1,1,0,JAM1,5,BoxGadBorXY,NULL};

struct IntuiText cGadText={
	1,0,JAM1,12,6,NULL,"C:",NULL};
struct Gadget cGad={
	&StrGad,134,52,39,19,GADGHCOMP,RELVERIFY,BOOLGADGET,(APTR)&BoxGadBor,NULL,
	&cGadText,NULL,NULL,C,NULL};

struct IntuiText sysGadText={
	1,0,JAM1,4,6,NULL,"SYS:",NULL};
struct Gadget sysGad={
	&cGad,92,52,39,19,GADGHCOMP,RELVERIFY,BOOLGADGET,(APTR)&BoxGadBor,NULL,
	&sysGadText,NULL,NULL,SYS,NULL};

struct IntuiText radGadText={
	1,0,JAM1,4,6,NULL,"RAD:",NULL};
struct Gadget radGad={
	&sysGad,50,52,39,19,GADGHCOMP,RELVERIFY,BOOLGADGET,(APTR)&BoxGadBor,NULL,
	&radGadText,NULL,NULL,RAD,NULL};

struct IntuiText ramGadText={
	1,0,JAM1,4,6,NULL,"RAM:",NULL};
struct Gadget ramGad={
	&radGad,8,52,39,19,GADGHCOMP,RELVERIFY,BOOLGADGET,(APTR)&BoxGadBor,NULL,
	&ramGadText,NULL,NULL,RAM,NULL};

struct IntuiText vdkGadText={
	1,0,JAM1,4,6,NULL,"VDK:",NULL};
struct Gadget vdkGad={
	&ramGad,302,30,39,19,GADGHCOMP,RELVERIFY,BOOLGADGET,(APTR)&BoxGadBor,NULL,
	&vdkGadText,NULL,NULL,VDK,NULL};

struct IntuiText vd0GadText={
	1,0,JAM1,4,6,NULL,"VD0:",NULL};
struct Gadget vd0Gad={
	&vdkGad,260,30,39,19,GADGHCOMP,RELVERIFY,BOOLGADGET,(APTR)&BoxGadBor,NULL,
	&vd0GadText,NULL,NULL,VD0,NULL};

struct IntuiText dh1GadText={
	1,0,JAM1,4,6,NULL,"DH1:",NULL};
struct Gadget dh1Gad={
	&vd0Gad,218,30,39,19,GADGHCOMP,RELVERIFY,BOOLGADGET,(APTR)&BoxGadBor,NULL,
	&dh1GadText,NULL,NULL,DH1,NULL};

struct IntuiText dh0GadText={
	1,0,JAM1,4,6,NULL,"DH0:",NULL};
struct Gadget dh0Gad={
	&dh1Gad,176,30,39,19,GADGHCOMP,RELVERIFY,BOOLGADGET,(APTR)&BoxGadBor,NULL,
	&dh0GadText,NULL,NULL,DH0,NULL};

struct IntuiText df3GadText={
	1,0,JAM1,4,6,NULL,"DF3:",NULL};
struct Gadget df3Gad={
	&dh0Gad,134,30,39,19,GADGHCOMP,RELVERIFY,BOOLGADGET,(APTR)&BoxGadBor,NULL,
	&df3GadText,NULL,NULL,DF3,NULL};

struct IntuiText df2GadText={
	1,0,JAM1,4,6,NULL,"DF2:",NULL};
struct Gadget df2Gad={
	&df3Gad,92,30,39,19,GADGHCOMP,RELVERIFY,BOOLGADGET,(APTR)&BoxGadBor,NULL,
	&df2GadText,NULL,NULL,DF2,NULL};

struct IntuiText df1GadText={
	1,0,JAM1,4,6,NULL,"DF1:",NULL};
struct Gadget df1Gad={
	&df2Gad,50,30,39,19,GADGHCOMP,RELVERIFY,BOOLGADGET,(APTR)&BoxGadBor,NULL,
	&df1GadText,NULL,NULL,DF1,NULL};

struct IntuiText df0GadText={
	1,0,JAM1,4,6,NULL,"DF0:",NULL};
struct Gadget df0Gad={
	&df1Gad,8,30,39,19,GADGHCOMP,RELVERIFY,BOOLGADGET,(APTR)&BoxGadBor,NULL,
	&df0GadText,NULL,NULL,DF0,NULL};

short DirGadBorXY[]={
	0,0,82,0,82,20,0,20,0,0};
struct Border DirGadBor={
	-1,-1,1,0,JAM1,5,DirGadBorXY,NULL};

struct IntuiText ParentText={
	1,0,JAM1,17,6,NULL, "Parent",NULL};
struct Gadget ParentGad={
	&df0Gad,176,52,81,19,GADGHCOMP,RELVERIFY,BOOLGADGET,
	(APTR)&DirGadBor,NULL,&ParentText,NULL,NULL,PARENT,NULL};

struct IntuiText DirGadText={
	1,0,JAM1,29,6,NULL,"Dir",NULL};
struct Gadget DirGad={
	&ParentGad,260,52,81,19,GADGHCOMP,RELVERIFY,BOOLGADGET,(APTR)&DirGadBor,NULL,
	&DirGadText,NULL,NULL,DIR,NULL};

struct NewWindow small={
	31,11,30,20,3,0,GADGETDOWN,
	BORDERLESS|SMART_REFRESH|NOCAREREFRESH,
	&popgad,NULL,NULL,NULL,NULL,0,0,0,0,WBENCHSCREEN};
struct NewWindow med={
	30,11,349,75,-1,-1,GADGETUP|CLOSEWINDOW|INACTIVEWINDOW|MOUSEBUTTONS,
	WINDOWCLOSE|WINDOWDEPTH|WINDOWDRAG|ACTIVATE|RMBTRAP|SMART_REFRESH|NOCAREREFRESH,
	&DirGad,NULL,"PopDir v1.6 by Jonathan Potter",NULL,NULL,0,0,0,0,WBENCHSCREEN};
struct NewWindow big={
	0,0,640,200,-1,-1,CLOSEWINDOW|VANILLAKEY,
	WINDOWCLOSE|WINDOWDEPTH|WINDOWDRAG|ACTIVATE|RMBTRAP|SMART_REFRESH|NOCAREREFRESH,
	NULL,NULL,NULL,NULL,NULL,0,0,0,0,WBENCHSCREEN};

char ToPrint[80];
struct IntuiText Files={
	1,0,JAM2,0,0,NULL,ToPrint,NULL};

struct IntuitionBase *IntuitionBase;
struct GfxBase *GfxBase;
struct IntuiMessage *Msg;
struct Window *Window;
struct FileLock *lock, *oldlock;
struct FileInfoBlock *finfo;
char titlestring[]="PopDir v1.6 © Copyright 1988,1989 Jonathan Potter";
