diff options
author | deva <deva> | 2009-02-12 14:42:12 +0000 |
---|---|---|
committer | deva <deva> | 2009-02-12 14:42:12 +0000 |
commit | 9be2869c6ebad21621e10b3bd9e82dc811b75d2d (patch) | |
tree | 499aa5af9dfd80aae4c07437f2f55f21241e5891 /client/widgets/widget.cc | |
parent | 22e0b0ddd78f13b2648befe892d9ec6c5b1b1229 (diff) |
Added formatlanguage attribute to metawidget, and implemented lua parser for it.
Diffstat (limited to 'client/widgets/widget.cc')
-rw-r--r-- | client/widgets/widget.cc | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/client/widgets/widget.cc b/client/widgets/widget.cc index 0857d67..870fc4b 100644 --- a/client/widgets/widget.cc +++ b/client/widgets/widget.cc @@ -81,8 +81,11 @@ bool Widget::regexpValidator() bool Widget::luaValidator() { if(!hasluaprogram) return true; + + if(macrowindow->luaprograms.contains(luaprogram) == false) return false; + QString program = macrowindow->luaprograms.value(luaprogram); - return macrowindow->lua->run(luaprogram, getName(), getValue()); + return macrowindow->lua->runValidator(program, getName(), getValue()); } void Widget::setInitialValue(QString value) |