- Moved all settings to settings class. Singleton in settings class.
- New socketClosed function on OlaThread to handle olad closing - Added some doc
This commit is contained in:
parent
fc1eda5ae9
commit
1b7664edaf
11 changed files with 278 additions and 152 deletions
|
|
@ -65,10 +65,6 @@ libreMediaServerAudio::libreMediaServerAudio(QStringList args, QWidget *parent)
|
|||
aw = new AudioWidget(this);
|
||||
setCentralWidget(aw);
|
||||
|
||||
// Inicia la lectur de datos DMX
|
||||
ola->blockSignals(true);
|
||||
ola->start(QThread::TimeCriticalPriority );
|
||||
|
||||
// Inicia el widget Master.
|
||||
amw = new AudioMasterWidget(this);
|
||||
QDockWidget *topWidget = new QDockWidget(tr("Master"), this);
|
||||
|
|
@ -82,17 +78,17 @@ libreMediaServerAudio::libreMediaServerAudio(QStringList args, QWidget *parent)
|
|||
connect(ui.actionChange_Media_Path, SIGNAL(triggered()), this, SLOT(ChangeMediaPath()));
|
||||
connect(ui.actionLaunch_OLA_Setup, SIGNAL(triggered()), this, SLOT(olasetup()));
|
||||
|
||||
Settings *set = new Settings();
|
||||
|
||||
connect(set, SIGNAL( layersNumber(int)),
|
||||
ola, SLOT( setLayersNumber(int)));
|
||||
connect(set, SIGNAL( DMXConf(dmxSetting ) ),
|
||||
ola, SLOT( setDMXConf(dmxSetting) ) );
|
||||
connect(Settings::getInstance(), SIGNAL( registerUniverse(int) ),
|
||||
ola, SLOT( registerUniverse(int) ) );
|
||||
ola->registerUniverse(); // register now all the universes
|
||||
ola->blockSignals(true);
|
||||
connect(ola, SIGNAL (layerReceived()),
|
||||
amw, SLOT(updateWatchDMX()));
|
||||
|
||||
// Lee la configuración por defecto
|
||||
set->readDefaultFile();
|
||||
// Inicia la mediaLibrary
|
||||
MediaLibrary::getInstance()->initMediaLibrary();
|
||||
// Inicia la lectura de datos DMX
|
||||
ola->start(QThread::TimeCriticalPriority );
|
||||
ola->blockSignals(false);
|
||||
connect(ola, SIGNAL( dmxOutput(int, int, int) ),
|
||||
this, SLOT( dmxInput(int, int, int) ) );
|
||||
|
|
@ -151,7 +147,7 @@ void libreMediaServerAudio::ChangeMediaPath()
|
|||
return;
|
||||
fileNames = dialog.selectedFiles();
|
||||
QString file = fileNames.at(0);
|
||||
MediaLibrary::getInstance()->setPath(file);
|
||||
Settings::getInstance()->setPathMedia(file);
|
||||
QString desc = tr("Media Path Changed to: %1").arg(m_pathmedia);
|
||||
qDebug(desc.toLatin1().constData());
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue