diff --git a/engine/client/cl_gameui.c b/engine/client/cl_gameui.c index b39ee040..03647c8e 100644 --- a/engine/client/cl_gameui.c +++ b/engine/client/cl_gameui.c @@ -1324,10 +1324,21 @@ static int pfnIsCvarReadOnly( const char *name ) return FBitSet( cv->flags, FCVAR_READ_ONLY ) ? 1 : 0; } +static int GAME_EXPORT pfnUtfProcessChar( int in ) +{ + // compatibility export, deprecated, do not use + + if( !cls.accept_utf8 ) // incoming character is not a UTF-8 sequence + return in; + + // otherwise, decode it and convert to selected codepage + return Con_UtfProcessCharForce( in ); +} + static ui_extendedfuncs_t gExtendedfuncs = { pfnEnableTextInput, - Con_UtfProcessChar, + pfnUtfProcessChar, Con_UtfMoveLeft, Con_UtfMoveRight, pfnGetRenderers, diff --git a/engine/client/client.h b/engine/client/client.h index 75c03d04..f4ad674b 100644 --- a/engine/client/client.h +++ b/engine/client/client.h @@ -1106,7 +1106,6 @@ void Con_DrawDebug( void ); void Con_RunConsole( void ); void Con_DrawConsole( void ); void Con_DrawVersion( void ); -int Con_UtfProcessChar( int in ); int Con_UtfProcessCharForce( int in ); int Con_UtfMoveLeft( char *str, int pos ); int Con_UtfMoveRight( char *str, int pos, int length ); diff --git a/engine/client/console.c b/engine/client/console.c index c3a25684..519a8345 100644 --- a/engine/client/console.c +++ b/engine/client/console.c @@ -632,15 +632,6 @@ int Con_UtfProcessCharForce( int in ) return '?'; // not implemented yet } -int GAME_EXPORT Con_UtfProcessChar( int in ) -{ - if( !cls.accept_utf8 ) // incoming character is not a UTF-8 sequence - return in; - - // otherwise, decode it and convert to selected codepage - return Con_UtfProcessCharForce( in ); -} - /* ================= Con_UtfMoveLeft