From: sfan5 Date: Fri, 28 Oct 2016 13:50:23 +0000 (+0200) Subject: Add missing keyname_to_keycode function (needed on Android) X-Git-Tag: 0.4.15~149 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=6d7b95d76355334ccb57638d35b123fb49456cf6;p=oweals%2Fminetest.git Add missing keyname_to_keycode function (needed on Android) When rewriting keycode.cpp I overlooked this function, fixes #4683 completely --- diff --git a/src/keycode.cpp b/src/keycode.cpp index 48d010cf4..2e211ad59 100644 --- a/src/keycode.cpp +++ b/src/keycode.cpp @@ -385,3 +385,8 @@ void clearKeyCache() { g_key_setting_cache.clear(); } + +irr::EKEY_CODE keyname_to_keycode(const char *name) +{ + return lookup_keyname(name).Key; +}