mirror of
https://github.com/martinrotter/rssguard.git
synced 2025-01-10 23:23:52 +01:00
SEttings works...
This commit is contained in:
parent
470f53fe1f
commit
36555ee943
@ -104,6 +104,14 @@ FormSettings::FormSettings(QWidget *parent) : QDialog(parent), m_ui(new Ui::Form
|
||||
this, SLOT(onMysqlPasswordChanged(QString)));
|
||||
connect(m_ui->m_btnMysqlTestSetup, SIGNAL(clicked()),
|
||||
this, SLOT(mysqlTestConnection()));
|
||||
connect(m_ui->m_spinMysqlPort, SIGNAL(editingFinished()),
|
||||
this, SLOT(onMysqlDataStorageEdited()));
|
||||
connect(m_ui->m_txtMysqlHostname->lineEdit(), SIGNAL(textEdited(QString)),
|
||||
this, SLOT(onMysqlDataStorageEdited()));
|
||||
connect(m_ui->m_txtMysqlPassword->lineEdit(), SIGNAL(textEdited(QString)),
|
||||
this, SLOT(onMysqlDataStorageEdited()));
|
||||
connect(m_ui->m_txtMysqlUsername->lineEdit(), SIGNAL(textEdited(QString)),
|
||||
this, SLOT(onMysqlDataStorageEdited()));
|
||||
|
||||
// Load all settings.
|
||||
loadGeneral();
|
||||
@ -491,7 +499,8 @@ void FormSettings::saveDataStorage() {
|
||||
|
||||
Settings::instance()->setValue(APP_CFG_DB, "database_driver", selected_db_driver);
|
||||
|
||||
if (original_db_driver != selected_db_driver) {
|
||||
if (original_db_driver != selected_db_driver ||
|
||||
m_initialSettings.m_mysqlDataStorageChanged) {
|
||||
m_changedDataTexts.append(tr("data storage backend changed"));
|
||||
}
|
||||
}
|
||||
@ -539,6 +548,10 @@ void FormSettings::onMysqlPasswordChanged(const QString &new_password) {
|
||||
}
|
||||
}
|
||||
|
||||
void FormSettings::onMysqlDataStorageEdited() {
|
||||
m_initialSettings.m_mysqlDataStorageChanged = true;
|
||||
}
|
||||
|
||||
void FormSettings::loadGeneral() {
|
||||
// Load auto-start status.
|
||||
SystemFactory::AutoStartStatus autostart_status = SystemFactory::instance()->getAutoStartStatus();
|
||||
|
@ -15,10 +15,12 @@ struct TemporarySettings {
|
||||
|
||||
public:
|
||||
TemporarySettings()
|
||||
: m_webBrowserProgress(QColor()) {
|
||||
: m_webBrowserProgress(QColor()),
|
||||
m_mysqlDataStorageChanged(false) {
|
||||
}
|
||||
|
||||
QColor m_webBrowserProgress;
|
||||
bool m_mysqlDataStorageChanged;
|
||||
};
|
||||
|
||||
class FormSettings : public QDialog {
|
||||
@ -58,6 +60,7 @@ class FormSettings : public QDialog {
|
||||
void onMysqlHostnameChanged(const QString &new_hostname);
|
||||
void onMysqlUsernameChanged(const QString &new_username);
|
||||
void onMysqlPasswordChanged(const QString &new_password);
|
||||
void onMysqlDataStorageEdited();
|
||||
|
||||
void loadLanguage();
|
||||
void saveLanguage();
|
||||
|
Loading…
Reference in New Issue
Block a user