Handle key input in vgui (#198)

This commit is contained in:
Roman Chistokhodov 2021-10-27 21:20:03 +03:00 committed by GitHub
parent ba2cab60df
commit 504e8b19d5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -380,7 +380,11 @@ Return 1 to allow engine to process the key, otherwise, act on it as needed
============ ============
*/ */
int DLLEXPORT HUD_Key_Event( int down, int keynum, const char *pszCurrentBinding ) int DLLEXPORT HUD_Key_Event( int down, int keynum, const char *pszCurrentBinding )
{ {
#if USE_VGUI
if (gViewPort)
return gViewPort->KeyInput(down, keynum, pszCurrentBinding);
#endif
return 1; return 1;
} }