Added a DMX watchdog. Changed the play methos, now play reset to 0 and stop not.
This commit is contained in:
parent
a6909f8c16
commit
69ffe79742
13 changed files with 276 additions and 154 deletions
53
src/main.cpp
53
src/main.cpp
|
@ -79,29 +79,54 @@ void MessageHandler(QtMsgType type, const QMessageLogContext &context, const QSt
|
|||
QString txt;
|
||||
switch (type) {
|
||||
case QtDebugMsg:
|
||||
txt.append("Debug: ");
|
||||
txt.append("Debug from File: ");
|
||||
txt.append(context.file);
|
||||
txt.append(context.line);
|
||||
txt.append(" Line: ");
|
||||
txt.append(QString::number(context.line));
|
||||
txt.append(" Function: ");
|
||||
txt.append(context.function);
|
||||
txt.append(" Message: ");
|
||||
txt.append(msg);
|
||||
// libreMediaServerAudio::textEdit->append(msg);, context.file, context.line, context.function);
|
||||
libreMediaServerAudio::textEdit->append(txt);
|
||||
break;
|
||||
case QtWarningMsg:
|
||||
// txt.append("Warning: ");
|
||||
// txt.append(msg);
|
||||
libreMediaServerAudio::textEdit->append(msg);
|
||||
txt.append("Warning from File: ");
|
||||
txt.append(context.file);
|
||||
txt.append(" Line: ");
|
||||
txt.append(QString::number(context.line));
|
||||
txt.append(" Function: ");
|
||||
txt.append(context.function);
|
||||
txt.append(" Message: ");
|
||||
txt.append(msg);
|
||||
// libreMediaServerAudio::textEdit->append(msg);, context.file, context.line, context.function);
|
||||
libreMediaServerAudio::textEdit->append(txt);
|
||||
abort();
|
||||
break;
|
||||
case QtCriticalMsg:
|
||||
// txt.append("Critical: ");
|
||||
// txt.append(msg);
|
||||
libreMediaServerAudio::textEdit->append(msg);
|
||||
// txt.append("Critical from File: ");
|
||||
txt.append(context.file);
|
||||
txt.append(" Line: ");
|
||||
txt.append(QString::number(context.line));
|
||||
txt.append(" Function: ");
|
||||
txt.append(context.function);
|
||||
txt.append(" Message ");
|
||||
txt.append(msg);
|
||||
// libreMediaServerAudio::textEdit->append(msg);, context.file, context.line, context.function);
|
||||
libreMediaServerAudio::textEdit->append(txt);
|
||||
abort();
|
||||
break;
|
||||
case QtFatalMsg:
|
||||
// txt.append("Fatal: ");
|
||||
// txt.append(msg);
|
||||
libreMediaServerAudio::textEdit->append(msg);
|
||||
// ts << txt << endl;
|
||||
// txt.append("Fatal from File: ");
|
||||
txt.append(context.file);
|
||||
txt.append(" Line: ");
|
||||
txt.append(QString::number(context.line));
|
||||
txt.append(" Function: ");
|
||||
txt.append(context.function);
|
||||
txt.append(" Message: ");
|
||||
txt.append(msg);
|
||||
// libreMediaServerAudio::textEdit->append(msg);, context.file, context.line, context.function);
|
||||
libreMediaServerAudio::textEdit->append(txt);// ts << txt << endl;
|
||||
abort();
|
||||
}
|
||||
// outFile.write(txt.toLatin1().constData(), txt.size());
|
||||
|
@ -120,9 +145,9 @@ int main(int argc, char *argv[])
|
|||
{
|
||||
qInstallMessageHandler(MessageHandler);
|
||||
}*/
|
||||
|
||||
QApplication app(argc, argv);
|
||||
qInstallMessageHandler(MessageHandler);
|
||||
QApplication app(argc, argv);
|
||||
|
||||
QStringList args = app.arguments();
|
||||
// parse the command line
|
||||
if (args.size() > 1)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue