1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-08-01 16:39:30 +02:00

Nyquist: Handle nyx_list return value

Required to avoid error on running Macoro Scripting commands
from Nyquist.
This commit is contained in:
SteveDaulton 2020-02-15 15:28:01 +00:00
parent cda8f2fcd6
commit 63c7f6b722
3 changed files with 29 additions and 16 deletions

View File

@ -804,6 +804,8 @@ nyx_rval nyx_get_type(LVAL expr)
label track */
if (nyx_is_labels(expr)) {
nyx_result_type = nyx_labels;
} else {
nyx_result_type = nyx_list;
}
}
break;

View File

@ -24,7 +24,8 @@ extern "C"
nyx_int,
nyx_double,
nyx_string,
nyx_labels
nyx_labels,
nyx_list
} nyx_rval;
void nyx_init();

View File

@ -1412,6 +1412,16 @@ bool NyquistEffect::ProcessOne()
return false;
}
if (rval == nyx_list) {
wxLogMessage("Nyquist returned nyx_list");
if (GetType() == EffectTypeTool) {
mProjectChanged = true;
} else {
Effect::MessageBox(XO("Nyquist returned a list.") );
}
return true;
}
if (rval == nyx_string) {
// Assume the string has already been translated within the Lisp runtime
// if necessary, by gettext or ngettext defined below, before it is