From bd0e6cb3c7e8f827e07cca4f3bd3c8bd05c75dbb Mon Sep 17 00:00:00 2001 From: keshavbhatt Date: Sun, 18 Apr 2021 13:16:28 +0530 Subject: added option to change notification type. - added ability to switch b/w native notification and customized notifications --- src/settingswidget.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'src/settingswidget.cpp') diff --git a/src/settingswidget.cpp b/src/settingswidget.cpp index 2b23845..dc8cda3 100644 --- a/src/settingswidget.cpp +++ b/src/settingswidget.cpp @@ -23,6 +23,7 @@ SettingsWidget::SettingsWidget(QWidget *parent, QString engineCachePath, QString ui->userAgentLineEdit->setText(settings.value("useragent",defaultUserAgentStr).toString()); ui->enableSpellCheck->setChecked(settings.value("sc_enabled",true).toBool()); ui->notificationTimeOutspinBox->setValue(settings.value("notificationTimeOut",9000).toInt()/1000); + ui->notificationCombo->setCurrentIndex(settings.value("notificationCombo",1).toInt()); this->setCurrentPasswordText("Current Password: " +QByteArray::fromBase64(settings.value("asdfg").toString().toUtf8())+""); @@ -306,3 +307,13 @@ void SettingsWidget::on_notificationTimeOutspinBox_valueChanged(int arg1) settings.setValue("notificationTimeOut",arg1*1000); emit notificationPopupTimeOutChanged(); } + +void SettingsWidget::on_notificationCombo_currentIndexChanged(int index) +{ + settings.setValue("notificationCombo",index); +} + +void SettingsWidget::on_tryNotification_clicked() +{ + emit notify("Test Notification"); +} -- cgit v1.2.3