aboutsummaryrefslogtreecommitdiffstats
path: root/src
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 /src
parentecore_imf/wayland: support input language mode in wayland text input (diff)
downloadefl-59ecddb55e7d2feb4550f5a39e26947ab3613e4c.tar.gz
elua: generate separate key/value numbers for getters/setters
Diffstat (limited to 'src')
-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 {
generate_prop = function(self, props)
local proto = self:gen_proto()
local prop = props[proto.name]
- if prop then
- if self.isget then
- prop[3] = "true"
- else
- prop[4] = "true"
- end
- return false
+ local hasprop = true
+ if not prop then
+ prop = { 0, 0, 0, 0, "false", "false" }
+ props[proto.name] = prop
+ hasprop = false
+ end
+ if self.isget then
+ prop[1] = proto.nkeys
+ prop[3] = math.max(proto.nvals, 1)
+ prop[5] = "true"
else
- props[proto.name] = { proto.nkeys, math.max(proto.nvals, 1),
- tostring(self.isget), tostring(not self.isget) }
- return true
+ prop[2] = proto.nkeys
+ prop[4] = math.max(proto.nvals, 1)
+ prop[6] = "true"
end
+ return not hasprop
end
}