mirror of
https://github.com/SolraBizna/MacLua5.3.git
synced 2026-05-15 22:01:04 -06:00
1 line
No EOL
2.3 KiB
R
1 line
No EOL
2.3 KiB
R
#include "Types.r"
|
|
#include "BalloonTypes.r"
|
|
#include "Cmdo.r"
|
|
|
|
resource 'hfdr' (-5696, purgeable) {
|
|
HelpMgrVersion,
|
|
hmDefaultOptions,
|
|
0, // Default balloon definition function
|
|
0, // Default variation code
|
|
{
|
|
HMSTRResItem
|
|
{
|
|
128 // Resource ID of help string ('STR ') to display
|
|
}
|
|
}
|
|
};
|
|
|
|
resource 'STR ' (128, purgeable) {
|
|
"This is an MPW tool. It requires the Macintosh Programmer's Workshop to run.\n\n"
|
|
"This tool allows you to run Lua scripts, and interact with a Lua prompt, from within MPW."
|
|
};
|
|
|
|
resource 'cmdo' (128) {
|
|
{
|
|
330, // height of dialog
|
|
"Allows you to execute Lua code from within MPW.", // help text
|
|
{
|
|
// #1
|
|
Or { { 4, 5 } }, CheckOption {
|
|
NotSet,
|
|
{200, 20, 215, 270},
|
|
"Become interactive on completion",
|
|
"-i",
|
|
"Enter interactive mode after all other code finishes executing.",
|
|
},
|
|
// #2
|
|
notDependent {}, CheckOption {
|
|
NotSet,
|
|
{200, 270, 215, 460},
|
|
"Ignore environment",
|
|
"-E",
|
|
"Causes Lua to ignore environment variables such as LUA_PATH.",
|
|
},
|
|
// #3
|
|
notDependent {}, MultiRegularEntry {
|
|
"Libraries to load:",
|
|
{25, 20, 40, 230},
|
|
{45, 20, 80, 230},
|
|
{ "" },
|
|
"-l",
|
|
"You may specify one or more Lua modules to load. "
|
|
"It will be as if you did 'modulename = require \"modulename\"' for each library. "
|
|
"This is usually not required when running a script."
|
|
},
|
|
// #4
|
|
notDependent {}, MultiRegularEntry {
|
|
"Additional code to run:",
|
|
{25, 250, 40, 460},
|
|
{45, 250, 80, 460},
|
|
{ "" },
|
|
"-e",
|
|
"You may specify one or more lines of Lua code to run. "
|
|
"Each line will be processed as a separate chunk."
|
|
},
|
|
// #5
|
|
notDependent { }, Files {
|
|
InputFile,
|
|
OptionalFile {
|
|
{90, 20, 105, 460},
|
|
{110, 20, 130, 460},
|
|
"Script to execute:",
|
|
"",
|
|
"--",
|
|
"",
|
|
"Select a script to execute.",
|
|
dim,
|
|
"Interactive mode",
|
|
"Select a script to executeÉ",
|
|
"",
|
|
},
|
|
Additional {
|
|
"",
|
|
".lua",
|
|
"Lua scripts only",
|
|
"All files",
|
|
{text},
|
|
},
|
|
},
|
|
// #6
|
|
Or { { 5 } }, MultiRegularEntry {
|
|
"Additional arguments for script:",
|
|
{135, 20, 150, 460},
|
|
{155, 20, 190, 460},
|
|
{ "" },
|
|
"",
|
|
"Arguments to pass in the script's \"arg\" table, one per line."
|
|
},
|
|
}
|
|
}
|
|
}; |