diff --git a/src/app/script/dialog_class.cpp b/src/app/script/dialog_class.cpp index 4e9d68242..26cbb1d94 100644 --- a/src/app/script/dialog_class.cpp +++ b/src/app/script/dialog_class.cpp @@ -1016,7 +1016,10 @@ static void fill_keymessage_values(lua_State* L, const ui::KeyMessage* msg) // KeyMessage specifics lua_pushinteger(L, msg->repeat()); - lua_setfield(L, -2, "repeat"); + lua_setfield(L, -2, "repeat"); // Only for backward compatibility, remove this in a future + + lua_pushinteger(L, msg->repeat()); + lua_setfield(L, -2, "repeatCount"); // TODO improve this (create an Event metatable) lua_pushcfunction(L, [](lua_State*) -> int {