mirror of
https://github.com/sheumann/NetDisk.git
synced 2024-12-22 10:30:42 +00:00
304 lines
8.1 KiB
Plaintext
304 lines
8.1 KiB
Plaintext
#include "types.rez"
|
|
|
|
resource rVersion (1) {
|
|
{ 1,0,0,beta,1 },
|
|
verUS,
|
|
"NetDisk",
|
|
"By Stephen Heumann"
|
|
};
|
|
|
|
resource rComment (1) {
|
|
"The NetDisk control panel allows you to mount disk images "
|
|
"hosted on HTTP servers.\n"
|
|
"\n"
|
|
"Copyright 2018 Stephen Heumann\n"
|
|
"\n"
|
|
"This program contains material from the ORCA/C Run-Time Libraries, "
|
|
"copyright 1987-1996 by Byte Works, Inc. Used with permission."
|
|
};
|
|
|
|
resource rCDEVFlags (1) {
|
|
wantMachine+wantHit+wantClose+wantEdit+wantCreate,
|
|
1, /* enabled */
|
|
1, /* version */
|
|
1, /* min ROM version */
|
|
0, /* reserved */
|
|
{0, 0, 55, 320}, /* rectangle */
|
|
"NetDisk", /* name */
|
|
"Stephen Heumann", /* author */
|
|
"v1.0b1" /* version string */
|
|
};
|
|
|
|
read rCDevCode (0x1,convert,locked) "cdev.obj";
|
|
|
|
resource rIcon (1) {
|
|
0x8000, /* color icon */
|
|
20, /* dimensions */
|
|
28,
|
|
$"FFFFF000000000000000000FFFFF"
|
|
$"FFFFF0F0FFFFFFFFFFFF0F0FFFFF"
|
|
$"FFFFF0F0F33333F333FF0F0FFFFF"
|
|
$"FFFFF0F0FFFFFFFFFFFF0F0FFFFF"
|
|
$"FFFFF0F0F333F333333F0F0FFFFF"
|
|
$"FFFFF0F0FFFFFFFFFFFF0F0FFFFF"
|
|
$"FFFFF0F0FFFFFFFFFFFF0F0FFFFF"
|
|
$"FFFFF0F00000000000000F0FFFFF"
|
|
$"FFFFF0FFFFFFFFFFFFFFFF0FFFFF"
|
|
$"FFFFF0FFFFCCCCCCCCFFFF0FFFFF"
|
|
$"FFFFF0FFFFCCFCCCCCFFFF0FFFFF"
|
|
$"FFFFFF0FFFCCFCCCCCFFFF0FFFFF"
|
|
$"FFFFFFF0000000000000000FFFFF"
|
|
$"FFFFFFFFFFFFF0F0FFFFFFFFFFFF"
|
|
$"FFFFFFFFFFFF00000FFFFFFFFFFF"
|
|
$"FFFFFFFFFFFF0FFF0FFFFFFFFFFF"
|
|
$"FFFFFFFFFFFF00000FFFFFFFFFFF"
|
|
$"F0F00000000000F0000000000F0F"
|
|
$"FFFFFFFFFFFFFF0FFFFFFFFFFFFF"
|
|
$"F0F00000000000F0000000000F0F",
|
|
|
|
$"00000FFFFFFFFFFFFFFFFFF00000"
|
|
$"00000FFFFFFFFFFFFFFFFFF00000"
|
|
$"00000FFFFFFFFFFFFFFFFFF00000"
|
|
$"00000FFFFFFFFFFFFFFFFFF00000"
|
|
$"00000FFFFFFFFFFFFFFFFFF00000"
|
|
$"00000FFFFFFFFFFFFFFFFFF00000"
|
|
$"00000FFFFFFFFFFFFFFFFFF00000"
|
|
$"00000FFFFFFFFFFFFFFFFFF00000"
|
|
$"00000FFFFFFFFFFFFFFFFFF00000"
|
|
$"00000FFFFFFFFFFFFFFFFFF00000"
|
|
$"00000FFFFFFFFFFFFFFFFFF00000"
|
|
$"000000FFFFFFFFFFFFFFFFF00000"
|
|
$"0000000FFFFFFFFFFFFFFFF00000"
|
|
$"0000000000000FFF000000000000"
|
|
$"000000000000FFFFF00000000000"
|
|
$"000000000000FFFFF00000000000"
|
|
$"000000000000FFFFF00000000000"
|
|
$"0F0FFFFFFFFFFFFFFFFFFFFFF0F0"
|
|
$"0F0FFFFFFFFFFFFFFFFFFFFFF0F0"
|
|
$"0F0FFFFFFFFFFF0FFFFFFFFFF0F0"
|
|
|
|
};
|
|
|
|
#define cdevWindow 1000
|
|
#define helpWindow 2000
|
|
|
|
#define imageURLTxt 2
|
|
#define urlLine 3
|
|
#define mountBtn 1
|
|
//#define optionsPopUp 6
|
|
//#define trianglePic 7
|
|
#define useCacheChk 8
|
|
|
|
#define helpTxt 5
|
|
|
|
|
|
/*
|
|
* Controls in the control panel window (for 640 mode or 320 mode)
|
|
*/
|
|
resource rControlList (640) {
|
|
{
|
|
cdevWindow+imageURLTxt,
|
|
cdevWindow+urlLine,
|
|
cdevWindow+useCacheChk,
|
|
cdevWindow+mountBtn,
|
|
//cdevWindow+trianglePic,
|
|
//cdevWindow+optionsPopUp
|
|
};
|
|
};
|
|
|
|
resource rControlList (320) {
|
|
{
|
|
cdevWindow+imageURLTxt,
|
|
cdevWindow+urlLine,
|
|
cdevWindow+useCacheChk,
|
|
cdevWindow+mountBtn,
|
|
//cdevWindow+trianglePic+320,
|
|
//cdevWindow+optionsPopUp+320
|
|
};
|
|
};
|
|
|
|
resource rControlTemplate (cdevWindow+imageURLTxt) {
|
|
imageURLTxt, /* control ID */
|
|
{4, 10, 15, 270}, /* control rect */
|
|
statTextControl {{
|
|
fBlastText, /* flags */
|
|
$1000+RefIsResource, /* moreFlags */
|
|
0, /* refCon */
|
|
cdevWindow+imageURLTxt /* title ref */
|
|
}};
|
|
};
|
|
|
|
resource rTextForLETextBox2 (cdevWindow+imageURLTxt) {
|
|
"Disk Image URL:"
|
|
};
|
|
|
|
resource rControlTemplate (cdevWindow+urlLine) {
|
|
urlLine,
|
|
{15, 10, 28, 310},
|
|
editLineControl {{
|
|
0,
|
|
$7000+RefIsResource,
|
|
0,
|
|
255, /* max size */
|
|
cdevWindow+urlLine /* text ref */
|
|
}};
|
|
};
|
|
|
|
resource rPString (cdevWindow+urlLine) { "http://" };
|
|
|
|
resource rControlTemplate (cdevWindow+mountBtn) {
|
|
mountBtn,
|
|
{35, 156, 0, 0},
|
|
SimpleButtonControl {{
|
|
DefaultButton,
|
|
$3000+RefIsResource,
|
|
0,
|
|
cdevWindow+mountBtn,
|
|
0, /* color table ref */
|
|
{"\$0D","\$0D",0,0} /* key equivalent = Return */
|
|
}};
|
|
};
|
|
|
|
resource rPString(cdevWindow+mountBtn) { "Mount Disk Image" };
|
|
|
|
resource rControlTemplate (cdevWindow+useCacheChk) {
|
|
useCacheChk,
|
|
{37,10,0,0},
|
|
CheckControl {{
|
|
$0000,
|
|
$1002,
|
|
0,
|
|
cdevWindow+useCacheChk, /* Title ref */
|
|
1 /* initial value */
|
|
}};
|
|
};
|
|
resource rPString (cdevWindow+useCacheChk) {"Use Disk Cache"};
|
|
|
|
#if 0
|
|
/* Options menu pop-up -- separate versions for 640 mode and 320 mode */
|
|
resource rControlTemplate (cdevWindow+optionsPopUp) {
|
|
optionsPopUp,
|
|
{5, 282, 13, 310 },
|
|
PopUpControl {{
|
|
fDontDrawTitle+fDontDrawResult,
|
|
fCtlProcNotPtr+RefIsResource/*+fDrawPopDownIcon*/,
|
|
0,
|
|
0,
|
|
optionsMenu, /* menu ref */
|
|
optionsItem, /* initial value */
|
|
0
|
|
}};
|
|
};
|
|
|
|
resource rControlTemplate (cdevWindow+optionsPopUp+ 320) {
|
|
optionsPopUp,
|
|
{5, 296, 13, 310 },
|
|
PopUpControl {{
|
|
fDontDrawTitle+fDontDrawResult,
|
|
fCtlProcNotPtr+RefIsResource/*+fDrawPopDownIcon*/,
|
|
0,
|
|
0,
|
|
optionsMenu, /* menu ref */
|
|
optionsItem, /* initial value */
|
|
0
|
|
}};
|
|
};
|
|
|
|
/* Triangle to draw on options pop-up */
|
|
resource rControlTemplate (cdevWindow+trianglePic) {
|
|
trianglePic,
|
|
{7, 286, 11, 302},
|
|
PictureControl {{
|
|
CtlInactive,
|
|
fCtlProcNotPtr+RefIsResource,
|
|
0,
|
|
trianglePic /* picture reference */
|
|
}};
|
|
};
|
|
|
|
resource rControlTemplate (cdevWindow+trianglePic+320) {
|
|
trianglePic,
|
|
{7, 298, 0, 0},
|
|
PictureControl {{
|
|
CtlInactive,
|
|
fCtlProcNotPtr+RefIsResource,
|
|
0,
|
|
trianglePic /* picture reference */
|
|
}};
|
|
};
|
|
|
|
data rPicture (trianglePic) {
|
|
$"8000 0000 0000 0400 1000 1182 0100 0A00"
|
|
$"01C0 01C0 FF3F FF3F 9000 8000 0000 0400"
|
|
$"0000 0000 0400 1000 0000 0000 0400 1000"
|
|
$"0000 0000 0400 1000 0000 0000 0000 F000"
|
|
$"000F FF00 00FF FFF0 0FFF"
|
|
};
|
|
|
|
resource rMenu (optionsMenu) {
|
|
optionsMenu, /* menu ID */
|
|
refIsResource*menuTitleRefShift + refIsResource*itemRefShift,
|
|
optionsMenu, /* menu title ref (not drawn) */
|
|
{
|
|
//items go here
|
|
};
|
|
};
|
|
resource rPString(optionsMenu,noCrossBank) { "" };
|
|
#endif
|
|
|
|
/*
|
|
* Controls in the help window
|
|
*/
|
|
resource rControlList (2) {
|
|
{
|
|
helpWindow+helpTxt
|
|
};
|
|
};
|
|
|
|
resource rControlTemplate (helpWindow+helpTxt) {
|
|
helpTxt,
|
|
{38, 5, 138, 280},
|
|
statTextControl {{
|
|
0, /* flags */
|
|
$1000+RefIsResource, /* moreFlags */
|
|
0, /* refCon */
|
|
helpWindow+helpTxt /* title ref */
|
|
}};
|
|
};
|
|
|
|
resource rTextForLETextBox2 (helpWindow+helpTxt) {
|
|
"The NetDisk control panel allows you to mount disk images "
|
|
"hosted on HTTP servers.\n"
|
|
};
|
|
|
|
|
|
/*
|
|
* Error messages
|
|
*/
|
|
|
|
#define netDiskMissingError 3000
|
|
#define mountURLError 3001
|
|
#define unsupportedProtocolAlert 3002
|
|
|
|
resource rAlertString (netDiskMissingError) {
|
|
"62/"
|
|
"To use this control panel, you must have NetDiskInit installed "
|
|
"in the System:System.Setup folder on the boot disk."
|
|
"/^#0\$00"
|
|
};
|
|
|
|
resource rAlertString (mountURLError) {
|
|
"32:"
|
|
"MountURL error *0."
|
|
":^#0\$00"
|
|
};
|
|
|
|
resource rAlertString (unsupportedProtocolAlert) {
|
|
"64:"
|
|
"NetDisk does not support the *0 protocol. Do you want to try "
|
|
"connecting using unencrypted HTTP instead? (The server may "
|
|
"or may not support this.)"
|
|
":#3:^#2\$00"
|
|
};
|
|
|