21 #ifndef KSTATUSNOTIFIERITEM_H
22 #define KSTATUSNOTIFIERITEM_H
24 #include <QtCore/QObject>
25 #include <QtCore/QString>
26 #include <QtDBus/QDBusArgument>
27 #include <QtCore/QPoint>
36 class KStatusNotifierItemPrivate;
78 Q_PROPERTY(
ItemCategory category READ category WRITE setCategory )
79 Q_PROPERTY(
QString title READ title WRITE setTitle )
80 Q_PROPERTY(
ItemStatus status READ status WRITE setStatus )
81 Q_PROPERTY(
QString iconName READ iconName WRITE setIconByName )
82 Q_PROPERTY(
QString overlayIconName READ overlayIconName WRITE setOverlayIconByName )
83 Q_PROPERTY(
QString attentionIconName READ attentionIconName WRITE setAttentionIconByName )
84 Q_PROPERTY(
QString toolTipIconName READ toolTipIconName WRITE setToolTipIconByName )
85 Q_PROPERTY(
QString toolTipTitle READ toolTipTitle WRITE setToolTipTitle )
86 Q_PROPERTY(
QString toolTipSubTitle READ toolTipSubTitle WRITE setToolTipSubTitle )
88 friend class KStatusNotifierItemDBus;
89 friend class KStatusNotifierItemPrivate;
112 ApplicationStatus = 1,
170 void setCategory(
const ItemCategory category);
175 ItemCategory category()
const;
180 void setTitle(
const QString &title);
190 void setStatus(
const ItemStatus status);
195 ItemStatus status()
const;
217 void setIconByPixmap(
const QIcon &icon);
222 QIcon iconPixmap()
const;
234 QString overlayIconName()
const;
243 void setOverlayIconByPixmap(
const QIcon &icon);
248 QIcon overlayIconPixmap()
const;
266 QString attentionIconName()
const;
274 void setAttentionIconByPixmap(
const QIcon &icon);
279 QIcon attentionIconPixmap()
const;
291 QString attentionMovieName()
const;
309 void setToolTip(
const QIcon &icon,
const QString &title,
const QString &subTitle);
322 QString toolTipIconName()
const;
330 void setToolTipIconByPixmap(
const QIcon &icon);
335 QIcon toolTipIconPixmap()
const;
340 void setToolTipTitle(
const QString &title);
350 void setToolTipSubTitle(
const QString &subTitle);
355 QString toolTipSubTitle()
const;
364 void setContextMenu(
KMenu *menu);
369 KMenu *contextMenu()
const;
381 void setAssociatedWidget(
QWidget *parent);
386 QWidget *associatedWidget()
const;
396 void setStandardActionsEnabled(
bool enabled);
401 bool standardActionsEnabled()
const;
411 void showMessage(
const QString &title,
const QString &message,
const QString &icon,
int timeout = 10000);
432 void scrollRequested(
int delta, Qt::Orientation orientation);
443 void activateRequested(
bool active,
const QPoint &pos);
453 void secondaryActivateRequested(
const QPoint &pos);
456 bool eventFilter(
QObject *watched, QEvent *event);
459 KStatusNotifierItemPrivate *
const d;
461 Q_PRIVATE_SLOT(d,
void serviceChange(
const QString&
name,
464 Q_PRIVATE_SLOT(d,
void checkForRegisteredHosts())
465 Q_PRIVATE_SLOT(d,
void registerToDaemon())
466 Q_PRIVATE_SLOT(d,
void contextMenuAboutToShow())
467 Q_PRIVATE_SLOT(d,
void maybeQuit())
468 Q_PRIVATE_SLOT(d,
void minimizeRestore())
469 Q_PRIVATE_SLOT(d,
void hideMenu())
470 Q_PRIVATE_SLOT(d,
void legacyWheelEvent(
int))
471 Q_PRIVATE_SLOT(d,
void legacyActivated(
QSystemTrayIcon::ActivationReason))
A container for a set of QAction objects.
const char * name(StandardAction id)
This will return the internal name of a given standard action.
ItemCategory
Different kinds of applications announce their type to the systemtray, so can be drawn in a different...
ItemStatus
All the possible status this icon can have, depending on the importance of the events that happens in...
KDE Status notifier Item protocol implementation