parent
88ccb9907e
commit
3ab8aed89c
|
@ -95,7 +95,7 @@ QSystemTrayIcon *TrayIcon::trayIcon()
|
|||
|
||||
void TrayIcon::slotTestNotification()
|
||||
{
|
||||
SnoreCore::instance().displayExapleNotification();
|
||||
SnoreCore::instance().displayExampleNotification();
|
||||
}
|
||||
|
||||
void TrayIcon::slotSettings()
|
||||
|
|
|
@ -73,8 +73,8 @@ void SettingsDialog::initTabs()
|
|||
ui->errorLabel->setVisible(false);
|
||||
ui->errorLineEdit->setVisible(false);
|
||||
|
||||
connect(&SnoreCore::instance(), &SnoreCore::prmaryNotificationBackendChanged, this, &SettingsDialog::loadPrimaryBackendBox);
|
||||
connect(&SnoreCore::instance(), &SnoreCore::prmaryNotificationBackendError, [this](const QString & error) {
|
||||
connect(&SnoreCore::instance(), &SnoreCore::primaryNotificationBackendChanged, this, &SettingsDialog::loadPrimaryBackendBox);
|
||||
connect(&SnoreCore::instance(), &SnoreCore::primaryNotificationBackendError, [this](const QString & error) {
|
||||
ui->errorLabel->setVisible(true);
|
||||
ui->errorLineEdit->setVisible(true);
|
||||
ui->errorLineEdit->setText(error);
|
||||
|
@ -83,7 +83,7 @@ void SettingsDialog::initTabs()
|
|||
|
||||
void SettingsDialog::on_pushButton_clicked()
|
||||
{
|
||||
SnoreCore::instance().displayExapleNotification();
|
||||
SnoreCore::instance().displayExampleNotification();
|
||||
}
|
||||
|
||||
void SettingsDialog::load()
|
||||
|
|
|
@ -253,7 +253,7 @@ Notification SnoreCore::getActiveNotificationByID(uint id) const
|
|||
return d->m_activeNotifications.value(id);
|
||||
}
|
||||
|
||||
void SnoreCore::displayExapleNotification()
|
||||
void SnoreCore::displayExampleNotification()
|
||||
{
|
||||
Application app = SnoreCorePrivate::instance()->defaultApplication();
|
||||
QString text = QLatin1String("<i>") + tr("This is %1").arg(app.name()) + QLatin1String("</i><br>"
|
||||
|
|
|
@ -80,7 +80,7 @@ public:
|
|||
/**
|
||||
* Displays a example notification.
|
||||
*/
|
||||
void displayExapleNotification();
|
||||
void displayExampleNotification();
|
||||
|
||||
/**
|
||||
* Register an application.
|
||||
|
@ -159,23 +159,23 @@ Q_SIGNALS:
|
|||
* @todo maybe introduce a special action state for this case
|
||||
* @see Action
|
||||
*/
|
||||
void actionInvoked(Snore::Notification);
|
||||
void actionInvoked(const Snore::Notification ¬ification);
|
||||
|
||||
/**
|
||||
* This signal is emitted when a Notification is closed.
|
||||
* @see Notification::CloseReasons
|
||||
*/
|
||||
void notificationClosed(Snore::Notification);
|
||||
void notificationClosed(const Snore::Notification ¬ification);
|
||||
|
||||
/**
|
||||
* This signal is emited in case the Primary backend encountered an error.
|
||||
*/
|
||||
void prmaryNotificationBackendError(const QString &error);
|
||||
void primaryNotificationBackendError(const QString &error);
|
||||
|
||||
/**
|
||||
* This signal is emited in case the Primary backend changed.
|
||||
*/
|
||||
void prmaryNotificationBackendChanged(const QString &erro);
|
||||
void primaryNotificationBackendChanged(const QString &error);
|
||||
|
||||
private:
|
||||
SnoreCore(QObject *parent);
|
||||
|
|
|
@ -93,7 +93,7 @@ bool SnoreCorePrivate::setBackendIfAvailible(const QString &backend)
|
|||
if (!b->isReady()) {
|
||||
snoreDebug(SNORE_DEBUG) << "Backend not ready:" << b->errorString();
|
||||
|
||||
emit q->prmaryNotificationBackendError(b->errorString());
|
||||
emit q->primaryNotificationBackendError(b->errorString());
|
||||
return false;
|
||||
}
|
||||
if (m_notificationBackend) {
|
||||
|
@ -106,7 +106,7 @@ bool SnoreCorePrivate::setBackendIfAvailible(const QString &backend)
|
|||
connect(b, &SnoreBackend::error, [this, b](const QString &) {
|
||||
slotInitPrimaryNotificationBackend();
|
||||
});
|
||||
emit q->prmaryNotificationBackendChanged(b->name());
|
||||
emit q->primaryNotificationBackendChanged(b->name());
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
|
|
Loading…
Reference in New Issue