don't append excess slash to g_qeglobals.m_userGamePath

This commit is contained in:
Garux
2019-09-07 20:55:55 +03:00
parent a834981d53
commit 05d7db4e3e
3 changed files with 3 additions and 3 deletions

View File

@@ -593,7 +593,7 @@ const char* misc_model_dialog( GtkWidget* parent ){
if ( !file_readable( buffer.c_str() ) ) {
// just go to fsmain
buffer.clear();
buffer << g_qeglobals.m_userGamePath.c_str() << "/";
buffer << g_qeglobals.m_userGamePath.c_str();
}
const char *filename = file_dialog( parent, TRUE, "Choose Model", buffer.c_str(), ModelLoader::Name() );

View File

@@ -330,7 +330,7 @@ const char* browse_sound( GtkWidget* parent ){
if ( !file_readable( buffer.c_str() ) ) {
// just go to fsmain
buffer.clear();
buffer << g_qeglobals.m_userGamePath.c_str() << "/";
buffer << g_qeglobals.m_userGamePath.c_str();
}
const char* filename = file_dialog( parent, TRUE, "Open Wav File", buffer.c_str(), "sound" );

View File

@@ -1336,7 +1336,7 @@ const char* BackgroundImage::background_image_dialog(){
if ( !file_readable( buffer.c_str() ) ) {
// just go to fsmain
buffer.clear();
buffer << g_qeglobals.m_userGamePath.c_str() << "/";
buffer << g_qeglobals.m_userGamePath.c_str();
}
const char *filename = file_dialog( GTK_WIDGET( MainFrame_getWindow() ), TRUE, "Background Image", buffer.c_str(), NULL );