mirror of https://github.com/KLayout/klayout.git
Avoid an assertion in macro editor when no script support is compiled in
This commit is contained in:
parent
d47cbeb231
commit
a759492f1e
|
|
@ -328,6 +328,10 @@ MacroController::drop_url (const std::string &path_or_url)
|
||||||
void
|
void
|
||||||
MacroController::show_editor (const std::string &cat, bool force_add)
|
MacroController::show_editor (const std::string &cat, bool force_add)
|
||||||
{
|
{
|
||||||
|
if (macro_categories ().empty ()) {
|
||||||
|
throw tl::Exception (tl::to_string (QObject::tr ("Application has not been compiled with scripting support - no macro IDE available")));
|
||||||
|
}
|
||||||
|
|
||||||
if (mp_macro_editor) {
|
if (mp_macro_editor) {
|
||||||
mp_macro_editor->show (cat, force_add);
|
mp_macro_editor->show (cat, force_add);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue