Eliminados los mensajes de consola generados al cargar ficheros de menu
This commit is contained in:
@@ -108,7 +108,7 @@ bool Menu::load(std::string file_path)
|
|||||||
if (file.good())
|
if (file.good())
|
||||||
{
|
{
|
||||||
// Procesa el fichero linea a linea
|
// Procesa el fichero linea a linea
|
||||||
std::cout << "Reading file " << filename.c_str() << std::endl;
|
//std::cout << "Reading file " << filename.c_str() << std::endl;
|
||||||
while (std::getline(file, line))
|
while (std::getline(file, line))
|
||||||
{
|
{
|
||||||
if (line == "[item]")
|
if (line == "[item]")
|
||||||
@@ -132,7 +132,7 @@ bool Menu::load(std::string file_path)
|
|||||||
// Procesa las dos subcadenas
|
// Procesa las dos subcadenas
|
||||||
if (!setItem(&item, line.substr(0, pos), line.substr(pos + 1, line.length())))
|
if (!setItem(&item, line.substr(0, pos), line.substr(pos + 1, line.length())))
|
||||||
{
|
{
|
||||||
std::cout << "Warning: file " << filename.c_str() << "\n, unknown parameter \"" << line.substr(0, pos).c_str() << "\"" << std::endl;
|
//std::cout << "Warning: file " << filename.c_str() << "\n, unknown parameter \"" << line.substr(0, pos).c_str() << "\"" << std::endl;
|
||||||
success = false;
|
success = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -149,7 +149,7 @@ bool Menu::load(std::string file_path)
|
|||||||
// Procesa las dos subcadenas
|
// Procesa las dos subcadenas
|
||||||
if (!setVars(line.substr(0, pos), line.substr(pos + 1, line.length())))
|
if (!setVars(line.substr(0, pos), line.substr(pos + 1, line.length())))
|
||||||
{
|
{
|
||||||
std::cout << "Warning: file " << filename.c_str() << "\n, unknown parameter \"" << line.substr(0, pos).c_str() << "\"" << std::endl;
|
//std::cout << "Warning: file " << filename.c_str() << "\n, unknown parameter \"" << line.substr(0, pos).c_str() << "\"" << std::endl;
|
||||||
success = false;
|
success = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -163,13 +163,13 @@ bool Menu::load(std::string file_path)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Cierra el fichero
|
// Cierra el fichero
|
||||||
std::cout << "Closing file " << filename.c_str() << std::endl;
|
//std::cout << "Closing file " << filename.c_str() << std::endl;
|
||||||
file.close();
|
file.close();
|
||||||
}
|
}
|
||||||
// El fichero no se puede abrir
|
// El fichero no se puede abrir
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
std::cout << "Warning: Unable to open " << filename.c_str() << " file" << std::endl;
|
//std::cout << "Warning: Unable to open " << filename.c_str() << " file" << std::endl;
|
||||||
success = false;
|
success = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user