2019-04-10 23:20:57 +00:00
|
|
|
#include "types.rez"
|
|
|
|
|
|
|
|
#define winDiskBrowser 1001
|
|
|
|
|
|
|
|
#define searchLine 1002
|
|
|
|
#define searchButton 1003
|
|
|
|
#define findDisksForText 1004
|
|
|
|
#define forIIGSRadio 1005
|
|
|
|
#define forAnyAppleIIRadio 1006
|
|
|
|
#define disksList 1007
|
2019-04-16 19:35:07 +00:00
|
|
|
#define mountDiskButton 1008
|
2019-04-10 23:20:57 +00:00
|
|
|
|
|
|
|
resource rWindParam1 (winDiskBrowser) {
|
|
|
|
fTitle+fClose+fFlex+fMove+fVis, /* wFrameBits */
|
2019-04-18 18:27:30 +00:00
|
|
|
winDiskBrowser, /* wTitle */
|
2019-04-10 23:20:57 +00:00
|
|
|
0, /* wRefCon */
|
|
|
|
{0,0,0,0}, /* ZoomRect */
|
2019-04-18 18:27:30 +00:00
|
|
|
winDiskBrowser, /* wColor ID */
|
2019-04-10 23:20:57 +00:00
|
|
|
{0,0}, /* Origin */
|
|
|
|
{0,0}, /* data size */
|
|
|
|
{0,0}, /* max height-width */
|
|
|
|
{0,0}, /* scroll vertical, horizontal */
|
|
|
|
{0,0}, /* page vertical, horizontal */
|
|
|
|
0, /* wInfoRefCon */
|
|
|
|
0, /* wInfoHeight */
|
|
|
|
{27,5,198,425}, /* wPosition */
|
|
|
|
infront, /* wPlane */
|
|
|
|
winDiskBrowser, /* wStorage */
|
2019-04-18 18:27:30 +00:00
|
|
|
$0A09 /* wInVerb */
|
|
|
|
};
|
|
|
|
|
|
|
|
resource rPString(winDiskBrowser) { " Archive.org Disk Browser " };
|
|
|
|
|
|
|
|
resource rWindColor (winDiskBrowser) {
|
|
|
|
0x0000, /* frameColor */
|
|
|
|
0x0F00, /* titleColor */
|
|
|
|
0x020F, /* tbarColor */
|
|
|
|
0xF0F0, /* growColor */
|
|
|
|
0x00F0 /* infoColor */
|
2019-04-10 23:20:57 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
resource rControlList (winDiskBrowser) {{
|
2019-04-11 19:40:12 +00:00
|
|
|
mountDiskButton,
|
|
|
|
disksList,
|
|
|
|
findDisksForText,
|
|
|
|
forIIGSRadio,
|
|
|
|
forAnyAppleIIRadio,
|
|
|
|
searchLine,
|
|
|
|
searchButton
|
2019-04-10 23:20:57 +00:00
|
|
|
}};
|
|
|
|
|
|
|
|
resource rControlTemplate (searchLine) {
|
|
|
|
searchLine,
|
|
|
|
{8, 10, 26, 300},
|
|
|
|
editLineControl {{
|
|
|
|
0,
|
|
|
|
$7000+RefIsResource,
|
|
|
|
0,
|
|
|
|
255, /* max size */
|
|
|
|
searchLine /* text ref */
|
|
|
|
}};
|
|
|
|
};
|
|
|
|
|
|
|
|
resource rPString (searchLine) { "" };
|
|
|
|
|
|
|
|
|
2019-04-17 03:58:46 +00:00
|
|
|
resource rControlTemplate (searchButton) {
|
|
|
|
searchButton,
|
2019-04-17 21:55:36 +00:00
|
|
|
{10, 309, 24, 410},
|
2019-04-17 03:58:46 +00:00
|
|
|
SimpleButtonControl {{
|
|
|
|
0,
|
2019-04-17 21:55:36 +00:00
|
|
|
$3000+RefIsResource,
|
2019-04-17 03:58:46 +00:00
|
|
|
0,
|
|
|
|
searchButton,
|
|
|
|
0, /* color table ref */
|
2019-04-17 21:55:36 +00:00
|
|
|
{"\$0D","\$0D",0,0} /* key equivalent = Return */
|
2019-04-17 03:58:46 +00:00
|
|
|
}};
|
|
|
|
};
|
|
|
|
|
2019-04-10 23:20:57 +00:00
|
|
|
resource rPString(searchButton) { "Find Disks" };
|
|
|
|
|
|
|
|
|
|
|
|
resource rControlTemplate (findDisksForText) {
|
|
|
|
findDisksForText, /* control ID */
|
|
|
|
{30, 9, 42, 118}, /* control rect */
|
|
|
|
statTextControl {{
|
|
|
|
fBlastText, /* flags */
|
|
|
|
$1000+RefIsResource, /* moreFlags */
|
|
|
|
0, /* refCon */
|
|
|
|
findDisksForText /* title ref */
|
|
|
|
}};
|
|
|
|
};
|
|
|
|
|
|
|
|
resource rTextForLETextBox2 (findDisksForText) {
|
|
|
|
"Find disks for:"
|
|
|
|
};
|
|
|
|
|
|
|
|
resource rControlTemplate (forIIGSRadio) {
|
|
|
|
forIIGSRadio,
|
|
|
|
{30,120,0,0},
|
|
|
|
RadioControl {{
|
|
|
|
$0002,
|
|
|
|
$1002,
|
|
|
|
0,
|
|
|
|
forIIGSRadio, /* Title ref */
|
|
|
|
1 /* initial value */
|
|
|
|
}};
|
|
|
|
};
|
|
|
|
resource rPString (forIIgsRadio) {"Apple IIGS"};
|
|
|
|
|
|
|
|
resource rControlTemplate (forAnyAppleIIRadio) {
|
|
|
|
forAnyAppleIIRadio,
|
|
|
|
{30,235,0,0},
|
|
|
|
RadioControl {{
|
|
|
|
$0002,
|
|
|
|
$1002,
|
|
|
|
0,
|
|
|
|
forAnyAppleIIRadio, /* Title ref */
|
|
|
|
0 /* initial value */
|
|
|
|
}};
|
|
|
|
};
|
|
|
|
resource rPString (forAnyAppleIIRadio) {"Any Apple II"};
|
|
|
|
|
|
|
|
resource rControlTemplate (disksList) {
|
|
|
|
disksList, /* control ID */
|
2019-04-19 03:58:57 +00:00
|
|
|
{45, 10, 147, 386}, /* control rect */
|
2019-04-10 23:20:57 +00:00
|
|
|
ListControl {{
|
2019-04-19 03:58:57 +00:00
|
|
|
$0000, /* flags */
|
2019-04-11 23:28:05 +00:00
|
|
|
$1400, /* more flags */
|
2019-04-10 23:20:57 +00:00
|
|
|
0, /* refcon */
|
|
|
|
0, /* list size */
|
|
|
|
10, /* List View */
|
2019-04-19 03:58:57 +00:00
|
|
|
$0003, /* List Type */
|
2019-04-10 23:20:57 +00:00
|
|
|
0, /* List Start */
|
|
|
|
10, /* ListMemHeight */
|
2019-04-18 01:11:49 +00:00
|
|
|
13, /* List Mem Size */
|
2019-04-10 23:20:57 +00:00
|
|
|
0, /* List Ref */
|
|
|
|
0 /* Color Ref */
|
|
|
|
}};
|
|
|
|
};
|
|
|
|
|
|
|
|
resource rControlTemplate (mountDiskButton) {
|
|
|
|
mountDiskButton,
|
2019-04-17 21:55:36 +00:00
|
|
|
{152, 305, 166, 410},
|
2019-04-10 23:20:57 +00:00
|
|
|
SimpleButtonControl {{
|
2019-04-11 05:50:38 +00:00
|
|
|
0,
|
|
|
|
$1000+RefIsResource,
|
2019-04-10 23:20:57 +00:00
|
|
|
0,
|
|
|
|
mountDiskButton,
|
|
|
|
0, /* color table ref */
|
2019-04-17 03:58:46 +00:00
|
|
|
{"\$0D","\$0D",0,0} /* key equivalent */
|
|
|
|
}};
|
|
|
|
};
|
|
|
|
|
2019-04-10 23:20:57 +00:00
|
|
|
resource rPString(mountDiskButton) { "Mount Disk" };
|
2019-04-15 00:24:07 +00:00
|
|
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
* Error messages
|
|
|
|
*/
|
|
|
|
|
|
|
|
#define searchErrorAlert 3000
|
2019-04-18 01:11:49 +00:00
|
|
|
#define mountErrorAlert 3001
|
2019-04-15 00:24:07 +00:00
|
|
|
|
|
|
|
resource rAlertString (searchErrorAlert) {
|
2019-04-19 05:49:46 +00:00
|
|
|
"72/"
|
|
|
|
"There was an error when searching for disks.\n"
|
|
|
|
"\n"
|
|
|
|
"*0"
|
2019-04-15 00:24:07 +00:00
|
|
|
"/^#0\$00"
|
|
|
|
};
|
2019-04-18 01:11:49 +00:00
|
|
|
|
|
|
|
resource rAlertString (mountErrorAlert) {
|
2019-04-19 05:49:46 +00:00
|
|
|
"72/"
|
|
|
|
"There was an error when trying to mount a disk.\n"
|
|
|
|
"\n"
|
|
|
|
"*0"
|
2019-04-18 01:11:49 +00:00
|
|
|
"/^#0\$00"
|
|
|
|
};
|
|
|
|
|