not quite so much needs to be delayed to the init() function
[personal-kdebase.git] / workspace / plasma / applets / systemtray / ui / notificationwidget.h
blobec65dad89ff6b3b7284abe6ecbd9347ba7fb88d2
1 /***************************************************************************
2 * notificationwidget.h *
3 * *
4 * Copyright (C) 2008 Dmitry Suzdalev <dimsuz@gmail.com> *
5 * Copyright (C) 2008 Rob Scheepmaker <r.scheepmaker@student.utwente.nl> *
6 * Copyright (C) 2008 Jason Stubbs <jasonbstubbs@gmail.com> *
7 * *
8 * This program is free software; you can redistribute it and/or modify *
9 * it under the terms of the GNU Library General Public License as *
10 * published by the Free Software Foundation; either version 2 of the *
11 * License, or (at your option) any later version. *
12 * *
13 * This program is distributed in the hope that it will be useful, *
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
16 * GNU Library General Public License for more details. *
17 * *
18 * You should have received a copy of the GNU Library General Public *
19 * License along with this library; if not, write to the *
20 * Free Software Foundation, Inc., *
21 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA . *
22 ***************************************************************************/
24 #ifndef NOTIFICATIONITEM_H
25 #define NOTIFICATIONITEM_H
27 #include <QGraphicsWidget>
29 #include "../core/notification.h"
31 namespace Plasma
33 class ExtenderItem;
36 class NotificationWidgetPrivate;
38 /**
39 * A graphics item, representing notification message.
41 class NotificationWidget : public QGraphicsWidget
43 Q_OBJECT
45 public:
46 NotificationWidget(SystemTray::Notification *notification, Plasma::ExtenderItem *parent);
47 ~NotificationWidget();
49 protected:
50 void resizeEvent(QGraphicsSceneResizeEvent *event);
52 private:
53 NotificationWidgetPrivate* const d;
55 Q_PRIVATE_SLOT(d, void updateNotification())
56 Q_PRIVATE_SLOT(d, void destroy())
59 #endif // NOTIFICATIONWIDGET_H