refs #485, further removed global setup traits from classes with read only

Use global setup from sGui/sApp
This commit is contained in:
Klaus Basan
2016-03-01 01:49:59 +01:00
committed by Mathew Sutcliffe
parent 30b5e5dade
commit aa96731143
20 changed files with 22 additions and 48 deletions

View File

@@ -63,9 +63,6 @@ private slots:
//! Menu clicked
void ps_onMenuClicked();
//! Setup has been changed
void ps_setupChanged();
private:
void init();
void initLogDisplay();
@@ -79,7 +76,6 @@ private:
QScopedPointer<Ui::CSwiftData> ui;
BlackGui::CManagedStatusBar m_statusBar;
BlackMisc::CData<BlackCore::Data::GlobalSetup> m_setup {this, &CSwiftData::ps_setupChanged}; //!< setup cache
BlackMisc::CData<BlackCore::Data::UpdateInfo> m_updateInfo { this }; //!< download / version data
};

View File

@@ -105,7 +105,7 @@ void CSwiftData::ps_onMenuClicked()
}
else if (sender == this->ui->menu_JsonBootstrapTemplate)
{
QString json(m_setup.get().toJsonString());
QString json(sApp->getGlobalSetup().toJsonString());
this->ui->comp_MainInfoArea->getLogComponent()->appendPlainTextToConsole(json);
this->displayConsole();
}
@@ -123,7 +123,7 @@ void CSwiftData::ps_onMenuClicked()
}
else if (sender == this->ui->menu_InternalsSetup)
{
QString setup(this->m_setup.get().convertToQString("\n", true));
QString setup(sApp->getGlobalSetup().convertToQString("\n", true));
this->ui->comp_MainInfoArea->getLogComponent()->appendPlainTextToConsole(setup);
this->displayConsole();
}
@@ -135,11 +135,6 @@ void CSwiftData::ps_onMenuClicked()
}
}
void CSwiftData::ps_setupChanged()
{
CLogMessage(this).debug() << "Setup changed";
}
void CSwiftData::initDynamicMenus()
{
Q_ASSERT_X(this->ui->menu_InfoAreas, Q_FUNC_INFO, "missing info areas");