mirror of
https://foundry.openuru.org/gitblit/r/CWE-ou-minkata.git
synced 2025-07-17 18:59:09 +00:00
Convert plUoid's object name to a plString
This commit is contained in:
@ -587,11 +587,11 @@ hsBool pfGUIControlMod::MsgReceive( plMessage *msg )
|
||||
|
||||
if( rend )
|
||||
{
|
||||
plProfile_BeginLap(GUITime, this->GetKey()->GetUoid().GetObjectName());
|
||||
plProfile_BeginLap(GUITime, this->GetKey()->GetUoid().GetObjectName().c_str());
|
||||
// Only need it once
|
||||
if( ISetUpDynTextMap( rend->Pipeline() ) )
|
||||
plgDispatch::Dispatch()->UnRegisterForExactType( plRenderMsg::Index(), GetKey() );
|
||||
plProfile_EndLap(GUITime, this->GetKey()->GetUoid().GetObjectName());
|
||||
plProfile_EndLap(GUITime, this->GetKey()->GetUoid().GetObjectName().c_str());
|
||||
return true;
|
||||
}
|
||||
|
||||
|
@ -122,22 +122,20 @@ pfGUICtrlGenerator &pfGUICtrlGenerator::Instance( void )
|
||||
|
||||
//// IGetNextKeyName /////////////////////////////////////////////////////////
|
||||
|
||||
void pfGUICtrlGenerator::IGetNextKeyName( char *name, const char *prefix )
|
||||
plString pfGUICtrlGenerator::IGetNextKeyName( const char *prefix )
|
||||
{
|
||||
static UInt32 keyCount = 0;
|
||||
|
||||
|
||||
sprintf( name, "%s%d", prefix, keyCount++ );
|
||||
return plString::Format( "%s%d", prefix, keyCount++ );
|
||||
}
|
||||
|
||||
//// IAddKey /////////////////////////////////////////////////////////////////
|
||||
|
||||
plKey pfGUICtrlGenerator::IAddKey( hsKeyedObject *ko, const char *prefix )
|
||||
{
|
||||
char keyName[ 128 ];
|
||||
plString keyName;
|
||||
|
||||
|
||||
IGetNextKeyName( keyName, prefix );
|
||||
keyName = IGetNextKeyName( prefix );
|
||||
return hsgResMgr::ResMgr()->NewKey( keyName, ko, plLocation::kGlobalFixedLoc );
|
||||
}
|
||||
|
||||
|
@ -85,7 +85,7 @@ class pfGUICtrlGenerator
|
||||
|
||||
|
||||
plKey IAddKey( hsKeyedObject *ko, const char *prefix );
|
||||
void IGetNextKeyName( char *name, const char *prefix );
|
||||
plString IGetNextKeyName( const char *prefix );
|
||||
|
||||
hsGMaterial *ICreateSolidMaterial( hsColorRGBA &color );
|
||||
|
||||
|
@ -221,8 +221,7 @@ pfGUIListPicture::pfGUIListPicture( plKey mipKey, hsBool respectAlpha ) : pfGUIL
|
||||
{
|
||||
// Gotta make and grab an uncompressed one
|
||||
plMipmap *uncompBuffer = hsCodecManager::Instance().CreateUncompressedMipmap( mip, hsCodecManager::k32BitDepth );
|
||||
char str[ 512 ];
|
||||
sprintf( str, "%s_uncomp", mip->GetKeyName() );
|
||||
plString str = plString::Format( "%s_uncomp", mip->GetKeyName() );
|
||||
fMipmapKey = hsgResMgr::ResMgr()->NewKey( str, uncompBuffer, fMipmapKey->GetUoid().GetLocation() );
|
||||
fMipmapKey->RefObject();
|
||||
}
|
||||
|
@ -97,8 +97,7 @@ class pfPopUpKeyGenerator
|
||||
|
||||
plKey CreateKey( hsKeyedObject *ko )
|
||||
{
|
||||
char name[ 256 ];
|
||||
sprintf( name, "%s-%d", fPrefix, fKeyCount++ );
|
||||
plString name = plString::Format( "%s-%d", fPrefix, fKeyCount++ );
|
||||
|
||||
return hsgResMgr::ResMgr()->NewKey( name, ko, fLoc );
|
||||
}
|
||||
|
Reference in New Issue
Block a user