aboutsummaryrefslogtreecommitdiff
path: root/src/LuaRuntime.hpp
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/LuaRuntime.hpp12
1 files changed, 9 insertions, 3 deletions
diff --git a/src/LuaRuntime.hpp b/src/LuaRuntime.hpp
index 74b7810..2b834aa 100644
--- a/src/LuaRuntime.hpp
+++ b/src/LuaRuntime.hpp
@@ -10,10 +10,16 @@
#include "utils.hpp"
#include "widgets/WebViewStack.hpp"
+#ifndef PROJECT_LUA_PATH
+#define PROJECT_LUA_PATH ""
+#endif
+
#define preserve_top(STATE, BODY) \
- const int __top = lua_gettop(STATE); \
- BODY; \
- lua_settop(STATE, __top);
+ { \
+ const int __top = lua_gettop(STATE); \
+ BODY; \
+ lua_settop(STATE, __top); \
+ };
class LuaRuntime : public QObject {
Q_OBJECT