Fixes to speed alarm and poi alerts. Added flicker effect. Some new fields to text...
[jspeed] / src / speedalarmsettings.cpp
index 64e84c2..f56fbb3 100644 (file)
@@ -60,13 +60,13 @@ SpeedAlarmSettings::SpeedAlarmSettings(QWidget* parent): QDialog(parent)
     enabled_->setChecked(Settings::instance().value("alarm_enabled", false).toBool());
 
     ButtonBox* buttons = new ButtonBox;
-    buttons->addButton(tr("Save"), this, SLOT(saveSettings()), QDialogButtonBox::AcceptRole);
+    connect(buttons->addButton(tr("Save"), QDialogButtonBox::AcceptRole), SIGNAL(clicked(bool)), this, SLOT(saveSettings()));
 
     QHBoxLayout* layout = new QHBoxLayout;
     QVBoxLayout* left = new QVBoxLayout;
 
     left->addLayout(speedLayout);
-    left->addWidget(soundSelector_);
+    left->addLayout(soundSelector_);
     left->addWidget(enabled_);
     layout->addLayout(left, Qt::AlignLeft);
     layout->addWidget(buttons);
@@ -82,6 +82,7 @@ void SpeedAlarmSettings::loadData()
     speed_->setText(QString::number(static_cast<int>(speedValue)));
 
     QString selected = Settings::instance().value("alarm_sound", "").toString();
+    soundSelector_->load();
     soundSelector_->setValue(selected);
 }