SetFromStack

This commit is contained in:
Glenn Maynard
2005-02-22 04:22:24 +00:00
parent f762300f49
commit 61064820b9
2 changed files with 14 additions and 0 deletions
+12
View File
@@ -32,6 +32,14 @@ void IPreference::PushValue( lua_State *L ) const
lua_pushnil( L );
}
void IPreference::SetFromStack( lua_State *L )
{
if( LOG )
LOG->Trace( "The preference value \"%s\" is of a type not supported by Lua", m_sName.c_str() );
lua_pop( L, 1 );
}
#define READFROM_AND_WRITETO( type ) \
void Preference<type>::FromString( const CString &s ) \
{ \
@@ -44,6 +52,10 @@ void IPreference::PushValue( lua_State *L ) const
void Preference<type>::PushValue( lua_State *L ) const \
{ \
LuaManager::PushStack( m_currentValue, L ); \
} \
void Preference<type>::SetFromStack( lua_State *L ) \
{ \
LuaManager::PopStack( m_currentValue, L ); \
}
READFROM_AND_WRITETO( int )