Added more error logging to Qt GUI.
This commit is contained in:
parent
7ccfd43a98
commit
7acaf7f2bd
|
@ -509,11 +509,12 @@ void consoleWin_t::showErrorMsgWindow()
|
||||||
QMessageBox msgBox(this);
|
QMessageBox msgBox(this);
|
||||||
|
|
||||||
fceuWrapperLock();
|
fceuWrapperLock();
|
||||||
|
msgBox.resize( this->size() );
|
||||||
msgBox.setIcon( QMessageBox::Critical );
|
msgBox.setIcon( QMessageBox::Critical );
|
||||||
msgBox.setText( tr(errorMsg.c_str()) );
|
msgBox.setText( tr(errorMsg.c_str()) );
|
||||||
errorMsg.clear();
|
errorMsg.clear();
|
||||||
fceuWrapperUnLock();
|
fceuWrapperUnLock();
|
||||||
msgBox.show();
|
//msgBox.show();
|
||||||
msgBox.exec();
|
msgBox.exec();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -200,7 +200,7 @@ LuaControlDialog_t::~LuaControlDialog_t(void)
|
||||||
{
|
{
|
||||||
std::list<LuaControlDialog_t *>::iterator it;
|
std::list<LuaControlDialog_t *>::iterator it;
|
||||||
|
|
||||||
printf("Destroy Lua Control Window\n");
|
//printf("Destroy Lua Control Window\n");
|
||||||
|
|
||||||
periodicTimer->stop();
|
periodicTimer->stop();
|
||||||
|
|
||||||
|
@ -217,7 +217,7 @@ LuaControlDialog_t::~LuaControlDialog_t(void)
|
||||||
//----------------------------------------------------
|
//----------------------------------------------------
|
||||||
void LuaControlDialog_t::closeEvent(QCloseEvent *event)
|
void LuaControlDialog_t::closeEvent(QCloseEvent *event)
|
||||||
{
|
{
|
||||||
printf("Lua Control Close Window Event\n");
|
//printf("Lua Control Close Window Event\n");
|
||||||
done(0);
|
done(0);
|
||||||
deleteLater();
|
deleteLater();
|
||||||
event->accept();
|
event->accept();
|
||||||
|
@ -415,7 +415,9 @@ void LuaControlDialog_t::startLuaScript(void)
|
||||||
fceuWrapperLock();
|
fceuWrapperLock();
|
||||||
if (0 == FCEU_LoadLuaCode(scriptPath->text().toStdString().c_str(), scriptArgs->text().toStdString().c_str()))
|
if (0 == FCEU_LoadLuaCode(scriptPath->text().toStdString().c_str(), scriptArgs->text().toStdString().c_str()))
|
||||||
{
|
{
|
||||||
printf("Error: Could not open the selected lua script: '%s'\n", scriptPath->text().toStdString().c_str());
|
char error_msg[2048];
|
||||||
|
sprintf( error_msg, "Error: Could not open the selected lua script: '%s'\n", scriptPath->text().toStdString().c_str());
|
||||||
|
FCEUD_PrintError(error_msg);
|
||||||
}
|
}
|
||||||
fceuWrapperUnLock();
|
fceuWrapperUnLock();
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in New Issue