#include "client.h"
#include "clientsettings.h"
+#include "iconloader.h"
#include "mainwin.h"
#include "networkmodel.h"
#include "qtui.h"
_server = QIndicate::Server::defaultInstance();
_server->setType("message.irc");
- _server->setDesktopFile(XSTR(DESKTOP_FILE));
- connect(_server, SIGNAL(serverDisplay()), QtUi::mainWindow(), SLOT(forceActivated()));
+ QString desktopFile = QString("%1/%2.desktop")
+ .arg(XSTR(XDG_APPS_INSTALL_DIR))
+ .arg(QCoreApplication::applicationFilePath().section('/', -1));
+ _server->setDesktopFile(desktopFile);
+ connect(_server, SIGNAL(serverDisplay()), SLOT(activateMainWidget()));
if (_enabled) {
_server->show();
qDeleteAll(_indicatorHash);
}
+void IndicatorNotificationBackend::activateMainWidget() {
+ GraphicalUi::activateMainWidget();
+}
+
void IndicatorNotificationBackend::notify(const Notification ¬ification) {
if(!_enabled) {
return;
: SettingsPage("Internal", "IndicatorNotification", parent)
{
ui.setupUi(this);
+ // FIXME find proper icon (this one is used by the plasmoid as well)
+ ui.enabled->setIcon(SmallIcon("mail-message-new"));
connect(ui.enabled, SIGNAL(toggled(bool)), SLOT(widgetChanged()));
}