Quassel IRC  Pre-Release
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros
LegacySystemTray Class Reference

#include </tmp/quassel/src/qtui/legacysystemtray.h>

Inheritance diagram for LegacySystemTray:
Collaboration diagram for LegacySystemTray:

Public Slots

virtual void setState (State state)
virtual void setVisible (bool visible=true)
virtual void showMessage (const QString &title, const QString &message, MessageIcon icon=Information, int msTimeout=10000, uint notificationId=0)
virtual void closeMessage (uint notificationId)
virtual void setToolTip (const QString &title, const QString &subtitle)

Signals

void activated (SystemTray::ActivationReason)
void iconChanged (const QIcon &icon)
void animationEnabledChanged (bool)
void toolTipChanged (const QString &title, const QString &subtitle)
void messageClicked (uint notificationId)
void messageClosed (uint notificationId)

Public Member Functions

 LegacySystemTray (QWidget *parent)
virtual ~LegacySystemTray ()
virtual void init ()
virtual bool isVisible () const
virtual bool isSystemTrayAvailable () const
virtual QIcon stateIcon () const

Protected Slots

virtual void activate (SystemTray::ActivationReason=Trigger)

Protected Member Functions

virtual void setMode (Mode mode)
bool shouldBeVisible () const
QIcon stateIcon (State state) const
QString toolTipTitle () const
QString toolTipSubTitle () const
QMenu * trayMenu () const
bool animationEnabled () const

Private Slots

void on_blinkTimeout ()
void on_activated (QSystemTrayIcon::ActivationReason)
void on_messageClicked ()
void syncLegacyIcon ()

Private Attributes

QTimer _blinkTimer
bool _blinkState
uint _lastMessageId
QSystemTrayIcon * _trayIcon

Detailed Description

Definition at line 37 of file legacysystemtray.h.

Constructor & Destructor Documentation

virtual ~LegacySystemTray ( )
inlinevirtual

Definition at line 43 of file legacysystemtray.h.

Member Function Documentation

void init ( )
virtual
bool isVisible ( ) const
virtual

Reimplemented from SystemTray.

Definition at line 96 of file legacysystemtray.cpp.

References _trayIcon, SystemTray::Legacy, and SystemTray::mode().

bool isSystemTrayAvailable ( ) const
inlinevirtual

Reimplemented from SystemTray.

Definition at line 83 of file legacysystemtray.h.

References SystemTray::Legacy, and SystemTray::mode().

QIcon stateIcon ( ) const
virtual

Reimplemented from SystemTray.

Definition at line 145 of file legacysystemtray.cpp.

References _blinkState, SystemTray::Legacy, SystemTray::mode(), and SystemTray::state().

Referenced by on_blinkTimeout(), setState(), and syncLegacyIcon().

void setState ( State  state)
virtualslot
void setVisible ( bool  visible = true)
virtualslot
void showMessage ( const QString &  title,
const QString &  message,
SystemTray::MessageIcon  icon = Information,
int  msTimeout = 10000,
uint  notificationId = 0 
)
virtualslot

Definition at line 172 of file legacysystemtray.cpp.

References _lastMessageId, and _trayIcon.

Referenced by closeMessage().

void closeMessage ( uint  notificationId)
virtualslot

Definition at line 181 of file legacysystemtray.cpp.

References SystemTray::NoIcon, and showMessage().

void setMode ( Mode  mode)
protectedvirtual
void on_blinkTimeout ( )
privateslot

Definition at line 153 of file legacysystemtray.cpp.

References _blinkState, _trayIcon, and stateIcon().

Referenced by LegacySystemTray().

void on_activated ( QSystemTrayIcon::ActivationReason  reason)
privateslot

Definition at line 160 of file legacysystemtray.cpp.

References SystemTray::activate().

Referenced by LegacySystemTray().

void on_messageClicked ( )
privateslot

Definition at line 166 of file legacysystemtray.cpp.

References _lastMessageId, and SystemTray::messageClicked().

Referenced by LegacySystemTray().

void syncLegacyIcon ( )
privateslot
void setToolTip ( const QString &  title,
const QString &  subtitle 
)
virtualslotinherited
void activated ( SystemTray::ActivationReason  )
signalinherited
void iconChanged ( const QIcon &  icon)
signalinherited
void animationEnabledChanged ( bool  )
signalinherited
void toolTipChanged ( const QString &  title,
const QString &  subtitle 
)
signalinherited
void messageClicked ( uint  notificationId)
signalinherited
void messageClosed ( uint  notificationId)
signalinherited
void activate ( SystemTray::ActivationReason  reason = Trigger)
protectedvirtualslotinherited

Definition at line 185 of file systemtray.cpp.

References SystemTray::activated().

Referenced by on_activated().

bool shouldBeVisible ( ) const
inlineprotectedinherited

Definition at line 134 of file systemtray.h.

References SystemTray::_shouldBeVisible.

Referenced by setMode(), and setVisible().

QIcon stateIcon ( State  state) const
protectedinherited
QString toolTipTitle ( ) const
inlineprotectedinherited

Definition at line 136 of file systemtray.h.

References SystemTray::_toolTipTitle.

Referenced by syncLegacyIcon().

QString toolTipSubTitle ( ) const
inlineprotectedinherited

Definition at line 137 of file systemtray.h.

References SystemTray::_toolTipSubTitle.

Referenced by syncLegacyIcon().

QMenu * trayMenu ( ) const
inlineprotectedinherited

Definition at line 135 of file systemtray.h.

References SystemTray::_trayMenu.

Referenced by init().

bool animationEnabled ( ) const
inlineprotectedinherited

Definition at line 138 of file systemtray.h.

References SystemTray::_animationEnabled.

Referenced by setState().

Member Data Documentation

QTimer _blinkTimer
private

Definition at line 69 of file legacysystemtray.h.

Referenced by LegacySystemTray(), setMode(), and setState().

bool _blinkState
private

Definition at line 70 of file legacysystemtray.h.

Referenced by on_blinkTimeout(), setState(), and stateIcon().

uint _lastMessageId
private

Definition at line 71 of file legacysystemtray.h.

Referenced by on_messageClicked(), and showMessage().

QSystemTrayIcon* _trayIcon
private

The documentation for this class was generated from the following files: