aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/ClientHamr
diff options
context:
space:
mode:
authorDavid Walter Seikel2014-03-26 14:03:31 +1000
committerDavid Walter Seikel2014-03-26 14:03:31 +1000
commit33ac9ac2eb876d1663d1b6fce7221d96888a85f7 (patch)
tree34266e0c38047e1f5338c4a1c03676ae56ab8feb /ClientHamr
parentTest and fix setting nil on a Thing with a default. (diff)
downloadSledjHamr-33ac9ac2eb876d1663d1b6fce7221d96888a85f7.zip
SledjHamr-33ac9ac2eb876d1663d1b6fce7221d96888a85f7.tar.gz
SledjHamr-33ac9ac2eb876d1663d1b6fce7221d96888a85f7.tar.bz2
SledjHamr-33ac9ac2eb876d1663d1b6fce7221d96888a85f7.tar.xz
White space redistribution.
Diffstat (limited to 'ClientHamr')
-rw-r--r--ClientHamr/GuiLua/skang.lua57
1 files changed, 30 insertions, 27 deletions
diff --git a/ClientHamr/GuiLua/skang.lua b/ClientHamr/GuiLua/skang.lua
index c0c63dc..e24523f 100644
--- a/ClientHamr/GuiLua/skang.lua
+++ b/ClientHamr/GuiLua/skang.lua
@@ -22,33 +22,33 @@ just pass the file name to skang.load() in this library. B-)
22 22
23The old skang argument types are - 23The old skang argument types are -
24 24
25 {"name", "java.lang.String"}, 25{"name", "java.lang.String"},
26 {"action", "java.lang.String"}, 26{"action", "java.lang.String"},
27 {"type", "java.lang.String"}, 27{"type", "java.lang.String"},
28 {"data", "java.lang.String"}, 28{"data", "java.lang.String"},
29 {"URL", "java.lang.String"}, 29{"URL", "java.lang.String"},
30 {"file", "java.lang.String"}, 30{"file", "java.lang.String"},
31 {"method", "java.lang.String"}, 31{"method", "java.lang.String"},
32 {"lx", "java.lang.String"}, 32{"lx", "java.lang.String"},
33 {"ly", "java.lang.String"}, 33{"ly", "java.lang.String"},
34 {"lw", "java.lang.String"}, 34{"lw", "java.lang.String"},
35 {"lh", "java.lang.String"}, 35{"lh", "java.lang.String"},
36 {"normal", "java.lang.String"}, 36{"normal", "java.lang.String"},
37 {"ghost", "java.lang.String"}, 37{"ghost", "java.lang.String"},
38 {"active", "java.lang.String"}, 38{"active", "java.lang.String"},
39 {"toggle", "java.lang.String"}, 39{"toggle", "java.lang.String"},
40 {"boolean","java.lang.Boolean"}, 40{"boolean","java.lang.Boolean"},
41 {"number", "java.lang.Integer"}, 41{"number", "java.lang.Integer"},
42 {"int", "java.lang.Integer"}, 42{"int", "java.lang.Integer"},
43 {"x", "java.lang.Integer"}, 43{"x", "java.lang.Integer"},
44 {"y", "java.lang.Integer"}, 44{"y", "java.lang.Integer"},
45 {"w", "java.lang.Integer"}, 45{"w", "java.lang.Integer"},
46 {"h", "java.lang.Integer"}, 46{"h", "java.lang.Integer"},
47 {"r", "java.lang.Integer"}, 47{"r", "java.lang.Integer"},
48 {"g", "java.lang.Integer"}, 48{"g", "java.lang.Integer"},
49 {"b", "java.lang.Integer"}, 49{"b", "java.lang.Integer"},
50 {"alpha", "java.lang.Integer"}, 50{"alpha", "java.lang.Integer"},
51 {"acl", "net.matrix_rad.security.ACL"}, 51{"acl", "net.matrix_rad.security.ACL"},
52]] 52]]
53 53
54 54
@@ -149,6 +149,7 @@ Thing =
149 149
150 hasCrashed = 0, -- How many times this Thing has crashed. 150 hasCrashed = 0, -- How many times this Thing has crashed.
151 151
152
152 __index = function (table, key) 153 __index = function (table, key)
153 -- This only works for keys that don't exist. By definition a value of nil means it doesn't exist. 154 -- This only works for keys that don't exist. By definition a value of nil means it doesn't exist.
154 local thing = things[key] 155 local thing = things[key]
@@ -170,6 +171,7 @@ Thing =
170 return nil 171 return nil
171 end, 172 end,
172 173
174
173 __newindex = function (table, key, value) 175 __newindex = function (table, key, value)
174 local thing = things[key] 176 local thing = things[key]
175 177
@@ -193,6 +195,7 @@ Thing =
193 end 195 end
194 end, 196 end,
195 197
198
196 -- TODO - Seemed like a good idea at the time, but do we really need it? 199 -- TODO - Seemed like a good idea at the time, but do we really need it?
197-- __call = function (func, ...) 200-- __call = function (func, ...)
198-- return func.func(...) 201-- return func.func(...)