mirror of
https://github.com/opentx/opentx.git
synced 2025-07-16 04:45:17 +03:00
[Horus] Options in widgets can now have a min and a max defined
This commit is contained in:
parent
3940716b5d
commit
5822cfded1
9 changed files with 50 additions and 36 deletions
|
@ -807,6 +807,16 @@ ZoneOption * createOptionsArray(int reference)
|
|||
luaL_checktype(L, -1, LUA_TNUMBER); // value is number
|
||||
option->deflt.signedValue = lua_tointeger(L, -1);
|
||||
break;
|
||||
case 3:
|
||||
luaL_checktype(L, -2, LUA_TNUMBER); // key is number
|
||||
luaL_checktype(L, -1, LUA_TNUMBER); // value is number
|
||||
option->min.signedValue = lua_tointeger(L, -1);
|
||||
break;
|
||||
case 4:
|
||||
luaL_checktype(L, -2, LUA_TNUMBER); // key is number
|
||||
luaL_checktype(L, -1, LUA_TNUMBER); // value is number
|
||||
option->max.signedValue = lua_tointeger(L, -1);
|
||||
break;
|
||||
}
|
||||
}
|
||||
option++;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue