3 long __OSlibversion
= 37;
16 { DIR_LEFT
,DIR_RIGHT
, },
17 { DIR_RIGHT
,DIR_LEFT
, },
19 { 100,80,60,40,20,1, },
21 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, },
22 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, },
36 struct Library
* AslBase
;
37 struct Library
* GadToolsBase
;
38 struct GfxBase
* GfxBase
;
39 struct Library
* IconBase
;
40 struct IntuitionBase
* IntuitionBase
;
44 AslBase
= OpenLibrary("asl.library",0);
45 GadToolsBase
= OpenLibrary("gadtools.library",0);
46 GfxBase
= (struct GfxBase
*)OpenLibrary("graphics.library",0);
47 IconBase
= OpenLibrary("icon.library",0);
48 IntuitionBase
= (struct IntuitionBase
*)OpenLibrary("intuition.library",0);
50 if (!AslBase
|| !GadToolsBase
|| !GfxBase
|| !IconBase
|| !IntuitionBase
)
58 if (AslBase
) CloseLibrary(AslBase
);
59 if (GadToolsBase
) CloseLibrary(GadToolsBase
);
60 if (GfxBase
) CloseLibrary((struct Library
*)GfxBase
);
61 if (IconBase
) CloseLibrary(IconBase
);
62 if (IntuitionBase
) CloseLibrary((struct Library
*)IntuitionBase
);
65 /* ------------------------------------------------------------------- */
66 /* for cback.o startup */
67 /* ------------------------------------------------------------------- */
70 char *__procname
= "*shuffle V1.1*";
72 long __BackGroundIO
= 0;
73 extern BPTR _Backstdout
;
75 /* ----------------------------------------------------------------- */
77 void LoadIcon(int argc
, char **argv
);
79 int main(int argc
, char **argv
)
82 if (TRUE
== openlibs())
87 if(!OpenProject0Window())
89 info
.writeicon
= TRUE
;
90 strcpy(info
.f_file
,"shuffle.config");
91 load_config("env:shuffle.config");
95 WaitPort(Project0Wnd
->UserPort
);
96 if(HandleProject0IDCMP() == FALSE
)end
= TRUE
;
98 CloseProject0Window();
107 void LoadIcon(int argc
,char **argv
)
113 struct WBStartup
*msg
= (struct WBStartup
*)argv
;
116 if(msg
->sm_NumArgs
> 1)
118 for(i
= 1; i
< msg
->sm_NumArgs
;i
++)
120 NameFromLock(msg
->sm_ArgList
[i
].wa_Lock
,fname
,256);
121 AddPart(fname
,msg
->sm_ArgList
[i
].wa_Name
,256);