Merge pull request #3 from Ragora/bugfix-tsneo-editors

* BugFix: Corrections for editors.
This commit is contained in:
Jeff Hutchinson 2021-09-03 20:06:31 -04:00 committed by GitHub
commit 57de7fd379
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 3 deletions

View file

@ -23,6 +23,7 @@
#ifndef _CODEBLOCK_H_
#define _CODEBLOCK_H_
#include <vector>
#include <unordered_map>
struct CompilerLocalVariableToRegisterMappingTable

View file

@ -318,7 +318,8 @@ void GuiInspectorField::setData( const char* data, bool callbacks )
{
char buffer[ 2048 ];
expandEscape( buffer, newValue );
newValue = (const char*)Con::evaluatef( "%%f = \"%s\"; return ( %s );", oldValue.c_str(), buffer );
newValue = (const char*)Con::evaluatef( "$f = \"%s\"; return ( %s );", oldValue.c_str(), buffer );
Con::evaluatef("$f=0;");
}
else if( type == TypeS32Vector
|| type == TypeF32Vector
@ -353,9 +354,10 @@ void GuiInspectorField::setData( const char* data, bool callbacks )
char buffer[ 2048 ];
expandEscape( buffer, newComponentExpr );
const char* newComponentVal = Con::evaluatef( "%%f = \"%s\"; %%v = \"%s\"; return ( %s );",
const char* newComponentVal = Con::evaluatef( "$f = \"%s\"; $v = \"%s\"; return ( %s );",
oldComponentVal, oldValue.c_str(), buffer );
Con::evaluatef("$f=0;$v=0;");
if( !isFirst )
strNew.append( ' ' );
strNew.append( newComponentVal );