X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=blobdiff_plain;f=src%2Fqtui%2Fdesktopnotificationbackend.cpp;h=a703f6af2d70a5f341762d82808e2e0de4f408b2;hp=d2cf9ed8ab0d4a9effacfe0edd05b80f9c1437b2;hb=f824db0e31b54969e0b7fa0b5405b1e9173d482c;hpb=c80ab2e825ff9125c1c7e8e829487a4b1c118579 diff --git a/src/qtui/desktopnotificationbackend.cpp b/src/qtui/desktopnotificationbackend.cpp index d2cf9ed8..a703f6af 100644 --- a/src/qtui/desktopnotificationbackend.cpp +++ b/src/qtui/desktopnotificationbackend.cpp @@ -1,5 +1,5 @@ /*************************************************************************** -* Copyright (C) 2005-08 by the Quassel Project * +* Copyright (C) 2005-09 by the Quassel Project * * devel@quassel-irc.org * * * * This program is free software; you can redistribute it and/or modify * @@ -26,9 +26,9 @@ #include "clientsettings.h" #include "networkmodel.h" -DesktopNotificationBackend::DesktopNotificationBackend(QObject *parent) : AbstractNotificationBackend(parent) { - _configWidget = new ConfigWidget(); - +DesktopNotificationBackend::DesktopNotificationBackend(QObject *parent) + : AbstractNotificationBackend(parent) +{ _dbusInterface = new org::freedesktop::Notifications( "org.freedesktop.Notifications", "/org/freedesktop/Notifications", @@ -59,10 +59,6 @@ DesktopNotificationBackend::DesktopNotificationBackend(QObject *parent) : Abstra notificationSettings.notify("DesktopNotification/QueueNotifications", this, SLOT(queueNotificationsChanged(const QVariant &))); } -DesktopNotificationBackend::~DesktopNotificationBackend() { - delete _configWidget; -} - void DesktopNotificationBackend::enabledChanged(const QVariant &v) { _enabled = v.toBool(); } @@ -152,10 +148,11 @@ void DesktopNotificationBackend::desktopNotificationClosed(uint id, uint reason) void DesktopNotificationBackend::desktopNotificationInvoked(uint id, const QString & action) { Q_UNUSED(id); Q_UNUSED(action); + emit activated(); } -SettingsPage *DesktopNotificationBackend::configWidget() const { - return _configWidget; +SettingsPage *DesktopNotificationBackend::createConfigWidget() const { + return new ConfigWidget(); } /***************************************************************************/