Commit d21c6bfe authored by Ronan Abhamon's avatar Ronan Abhamon

fix(ui/views/App/Main/MainWindow): display correctly auto answer status

parent f514b2d6
......@@ -32,12 +32,12 @@ using namespace std;
const string SettingsModel::UI_SECTION("ui");
SettingsModel::SettingsModel (QObject *parent) : QObject(parent) {
// TODO: Uncomment when `getConfig` will be available.
// m_config = CoreManager::getInstance()->getCore()->getConfig();
m_config = CoreManager::getInstance()->getCore()->getConfig();
}
// -----------------------------------------------------------------------------
bool SettingsModel::getAutoAnswerStatus () const {
return true; // TODO: See above.
return !!m_config->getInt(UI_SECTION, "auto_answer", 0);
}
......@@ -46,6 +46,8 @@ void SettingsModel::setAutoAnswerStatus (bool status) {
emit autoAnswerStatusChanged(status);
}
// -----------------------------------------------------------------------------
QString SettingsModel::getFileTransferUrl () const {
return ::Utils::linphoneStringToQString(
CoreManager::getInstance()->getCore()->getFileTransferServer()
......
......@@ -183,6 +183,7 @@ Controls1.ApplicationWindow {
color: MainWindowStyle.autoAnswerStatus.text.color
font.pointSize: MainWindowStyle.autoAnswerStatus.text.fontSize
text: qsTr('autoAnswerStatus')
visible: SettingsModel.autoAnswerStatus
width: parent.width
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment