You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
62 lines
1.7 KiB
C++
62 lines
1.7 KiB
C++
/*
|
|
* NotifyWidget.h
|
|
*
|
|
* Created on: May 14, 2021
|
|
* Author: emanoil
|
|
*
|
|
* kdbusnotification Copyright (C) 2009 kdbusnotification development team
|
|
*
|
|
* This program is free software; you can redistribute it and/or modify
|
|
* it under the terms of the GNU General Public License version 2
|
|
* as published by the Free Software Foundation.
|
|
*
|
|
* This program is distributed in the hope that it will be useful,
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
* GNU General Public License for more details.
|
|
*
|
|
* You should have received a copy of the GNU General Public License
|
|
* along with this program; if not, write to the Free Software
|
|
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
*/
|
|
#ifndef SRC_DAEMON_NOTIFYWIDGET_H_
|
|
#define SRC_DAEMON_NOTIFYWIDGET_H_
|
|
|
|
#include <tqlabel.h>
|
|
#include <tqdbusvariant.h>
|
|
|
|
class NotificationsService;
|
|
|
|
class NotifyWidget: public TQLabel
|
|
{
|
|
TQ_OBJECT
|
|
|
|
public:
|
|
NotifyWidget(TQWidget *parent=0, const char *name=0, NotificationsService *ns=0, TQ_INT32 id=0 );
|
|
virtual ~NotifyWidget();
|
|
|
|
void setAutoMask(bool b);
|
|
|
|
void setIcon(const TQString& icon);
|
|
void setActions(const TQStringList& actions);
|
|
void setHints(const TQMap< TQString, TQT_DBusVariant >& hints);
|
|
void setTimeout(TQ_INT32 t);
|
|
|
|
protected:
|
|
void mousePressEvent( TQMouseEvent *);
|
|
|
|
private slots:
|
|
void timeout();
|
|
|
|
private:
|
|
NotificationsService *notificationService;
|
|
TQString mName;
|
|
TQ_INT32 mId;
|
|
TQString mIcon;
|
|
TQStringList mActions;
|
|
TQMap< TQString, TQT_DBusVariant > mHints;
|
|
|
|
};
|
|
|
|
#endif /* SRC_DAEMON_NOTIFYWIDGET_H_ */
|