aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/src/GuiLua
diff options
context:
space:
mode:
authorDavid Walter Seikel2014-05-08 09:05:01 +1000
committerDavid Walter Seikel2014-05-08 09:05:01 +1000
commitb4e8ab19c4f232c68ba511534880d22ef35a04b0 (patch)
treea0ed2d296e20e3ec18187a7e2ad9c75b320982c9 /src/GuiLua
parentSetup all the Lua paths in a central place. (diff)
downloadSledjHamr-b4e8ab19c4f232c68ba511534880d22ef35a04b0.zip
SledjHamr-b4e8ab19c4f232c68ba511534880d22ef35a04b0.tar.gz
SledjHamr-b4e8ab19c4f232c68ba511534880d22ef35a04b0.tar.bz2
SledjHamr-b4e8ab19c4f232c68ba511534880d22ef35a04b0.tar.xz
A new function to load GuiLua skang modules.
Diffstat (limited to 'src/GuiLua')
-rw-r--r--src/GuiLua/GuiLua.c8
-rw-r--r--src/GuiLua/GuiLua.h1
2 files changed, 9 insertions, 0 deletions
diff --git a/src/GuiLua/GuiLua.c b/src/GuiLua/GuiLua.c
index dbd3f95..55037e0 100644
--- a/src/GuiLua/GuiLua.c
+++ b/src/GuiLua/GuiLua.c
@@ -433,6 +433,14 @@ GuiLua *GuiLuaDo(int argc, char **argv, winFang *parent)
433 return result; 433 return result;
434} 434}
435 435
436void GuiLuaLoad(char *module, winFang *parent)
437{
438 char *args[] = {"GuiLUa", "-l", ""};
439
440 args[2] = module;
441 GuiLuaDo(3, args, parent);
442}
443
436void GuiLuaDel(GuiLua *gl) 444void GuiLuaDel(GuiLua *gl)
437{ 445{
438 if (gl) 446 if (gl)
diff --git a/src/GuiLua/GuiLua.h b/src/GuiLua/GuiLua.h
index 75c0b38..b123fe7 100644
--- a/src/GuiLua/GuiLua.h
+++ b/src/GuiLua/GuiLua.h
@@ -30,6 +30,7 @@ typedef struct _GuiLua
30extern const char *glName; 30extern const char *glName;
31 31
32GuiLua *GuiLuaDo(int argc, char **argv, winFang *parent); 32GuiLua *GuiLuaDo(int argc, char **argv, winFang *parent);
33void GuiLuaLoad(char *module, winFang *parent);
33void GuiLuaDel(GuiLua *gl); 34void GuiLuaDel(GuiLua *gl);
34 35
35#endif 36#endif