MCPcopy Create free account
hub / github.com/BZFlag-Dev/bzflag / GetKeyModifiers

Method GetKeyModifiers

src/lua/LuaCallOuts.cpp:1647–1658  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1645
1646
1647int LuaCallOuts::GetKeyModifiers(lua_State* L) {
1648 BzfDisplay* dpy = getDisplay();
1649 if (dpy == NULL) {
1650 return luaL_pushnil(L);
1651 }
1652 bool alt, ctrl, shift;
1653 dpy->getModState(shift, ctrl, alt);
1654 lua_pushboolean(L, alt);
1655 lua_pushboolean(L, ctrl);
1656 lua_pushboolean(L, shift);
1657 return 3;
1658}
1659
1660
1661//============================================================================//

Callers

nothing calls this directly

Calls 4

luaL_pushnilFunction · 0.85
getDisplayFunction · 0.50
lua_pushbooleanFunction · 0.50
getModStateMethod · 0.45

Tested by

no test coverage detected