use CopiedString.empty()
This commit is contained in:
parent
1f2e1616a8
commit
649fcd4067
|
|
@ -125,7 +125,7 @@ public:
|
|||
void evaluate( StringBuffer& output ) const override {
|
||||
StringBuffer buffer;
|
||||
m_test->evaluate( buffer );
|
||||
if ( !string_empty( buffer.c_str() ) ) {
|
||||
if ( !buffer.empty() ) {
|
||||
m_result->evaluate( output );
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -253,7 +253,7 @@ void environment_init( int argc, char* argv[] ){
|
|||
{
|
||||
char real[PATH_MAX];
|
||||
app_filepath = getexename( real );
|
||||
ASSERT_MESSAGE( !string_empty( app_filepath.c_str() ), "failed to deduce app path" );
|
||||
ASSERT_MESSAGE( !app_filepath.empty(), "failed to deduce app path" );
|
||||
// NOTE: we build app path with a trailing '/'
|
||||
// it's a general convention in Radiant to have the slash at the end of directories
|
||||
app_path = PathFilenameless( real );
|
||||
|
|
|
|||
|
|
@ -492,7 +492,7 @@ struct ModelResource : public Resource
|
|||
return true;
|
||||
}
|
||||
bool isModified() const {
|
||||
return ( ( !string_empty( m_path.c_str() ) // had or has an absolute path
|
||||
return ( ( !m_path.empty() // had or has an absolute path
|
||||
&& m_modified != modified() ) // AND disk timestamp changed
|
||||
|| !path_equal( rootPath( m_originalName.c_str() ), m_path.c_str() ) ); // OR absolute vfs-root changed
|
||||
}
|
||||
|
|
|
|||
|
|
@ -333,7 +333,7 @@ typedef std::pair<LoadImageCallback, CopiedString> TextureKey;
|
|||
|
||||
void qtexture_realise( qtexture_t& texture, const TextureKey& key ){
|
||||
texture.texture_number = 0;
|
||||
if ( !string_empty( key.second.c_str() ) ) {
|
||||
if ( !key.second.empty() ) {
|
||||
if( !key.first.m_skybox ){
|
||||
Image* image = key.first.loadImage( key.second.c_str() );
|
||||
if ( image != 0 ) {
|
||||
|
|
|
|||
|
|
@ -827,13 +827,13 @@ public:
|
|||
m_stack.push_back( MenuPair( menu, "" ) );
|
||||
}
|
||||
~EntityClassMenuInserter(){
|
||||
if ( !string_empty( m_previous.c_str() ) ) {
|
||||
if ( !m_previous.empty() ) {
|
||||
addItem( m_previous.c_str(), "" );
|
||||
}
|
||||
}
|
||||
void visit( EntityClass* e ){
|
||||
ASSERT_MESSAGE( !string_empty( e->name() ), "entity-class has no name" );
|
||||
if ( !string_empty( m_previous.c_str() ) ) {
|
||||
if ( !m_previous.empty() ) {
|
||||
addItem( m_previous.c_str(), e->name() );
|
||||
}
|
||||
m_previous = e->name();
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user