summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Kolesa <d.kolesa@osg.samsung.com>2015-05-28 15:41:30 +0100
committerDaniel Kolesa <d.kolesa@osg.samsung.com>2015-05-28 15:41:30 +0100
commit59ecddb55e7d2feb4550f5a39e26947ab3613e4c (patch)
treefb9b1d678952e1c0b1f4e25f44c568b8d9b8efa8
parent15814ccccbd30a28ae64ef661efbd5ca0418aaf2 (diff)
elua: generate separate key/value numbers for getters/setters
-rw-r--r--src/scripts/elua/modules/lualian.lua24
1 files changed, 14 insertions, 10 deletions
diff --git a/src/scripts/elua/modules/lualian.lua b/src/scripts/elua/modules/lualian.lua
index 9ef3b7b2ee..3689939898 100644
--- a/src/scripts/elua/modules/lualian.lua
+++ b/src/scripts/elua/modules/lualian.lua
@@ -332,18 +332,22 @@ local Property = Method:clone {
332 generate_prop = function(self, props) 332 generate_prop = function(self, props)
333 local proto = self:gen_proto() 333 local proto = self:gen_proto()
334 local prop = props[proto.name] 334 local prop = props[proto.name]
335 if prop then 335 local hasprop = true
336 if self.isget then 336 if not prop then
337 prop[3] = "true" 337 prop = { 0, 0, 0, 0, "false", "false" }
338 else 338 props[proto.name] = prop
339 prop[4] = "true" 339 hasprop = false
340 end 340 end
341 return false 341 if self.isget then
342 prop[1] = proto.nkeys
343 prop[3] = math.max(proto.nvals, 1)
344 prop[5] = "true"
342 else 345 else
343 props[proto.name] = { proto.nkeys, math.max(proto.nvals, 1), 346 prop[2] = proto.nkeys
344 tostring(self.isget), tostring(not self.isget) } 347 prop[4] = math.max(proto.nvals, 1)
345 return true 348 prop[6] = "true"
346 end 349 end
350 return not hasprop
347 end 351 end
348} 352}
349 353