diff options
author | Wladimir J. van der Laan <laanwj@gmail.com> | 2011-11-13 13:19:52 +0100 |
---|---|---|
committer | Wladimir J. van der Laan <laanwj@gmail.com> | 2011-11-13 14:12:44 +0100 |
commit | af836ad58808a1f6437a8b9a76b670c07c9a1212 (patch) | |
tree | dbc63d61b6404cbdb1f1bd45b58efe794621ab4a /src/qt/notificator.h | |
parent | 66112ed6e69d304eb9be5721f8d9b76375930c52 (diff) |
Improve documentation for UI classes
Diffstat (limited to 'src/qt/notificator.h')
-rw-r--r-- | src/qt/notificator.h | 35 |
1 files changed, 18 insertions, 17 deletions
diff --git a/src/qt/notificator.h b/src/qt/notificator.h index ed69ae5c61..2d83013a7f 100644 --- a/src/qt/notificator.h +++ b/src/qt/notificator.h @@ -11,33 +11,34 @@ class QDBusInterface; #endif QT_END_NAMESPACE -// Cross-platform desktop notification client +/** Cross-platform desktop notification client. */ class Notificator: public QObject { Q_OBJECT public: - // Create a new notificator - // Ownership of trayIcon is not transferred to this object + /** Create a new notificator. + @note Ownership of trayIcon is not transferred to this object. + */ Notificator(const QString &programName=QString(), QSystemTrayIcon *trayIcon=0, QWidget *parent=0); ~Notificator(); // Message class enum Class { - Information, - Warning, - Critical, + Information, /**< Informational message */ + Warning, /**< Notify user of potential problem */ + Critical /**< An error occured */ }; public slots: - /* Show notification message. - * - * cls: general message class - * title: title shown with message - * text: message content - * icon: optional icon to show with message - * millisTimeout: notification timeout in milliseconds (default 10 seconds) + /** Show notification message. + @param[in] cls general message class + @param[in] title title shown with message + @param[in] text message content + @param[in] icon optional icon to show with message + @param[in] millisTimeout notification timeout in milliseconds (defaults to 10 seconds) + @note Platform implementations are free to ignore any of the provided fields except for \a text. */ void notify(Class cls, const QString &title, const QString &text, const QIcon &icon = QIcon(), int millisTimeout = 10000); @@ -45,10 +46,10 @@ public slots: private: QWidget *parent; enum Mode { - None, - Freedesktop, // Use DBus org.freedesktop.Notifications - QSystemTray, // Use QSystemTray::showMessage - Growl // Use the Growl notification system (Mac only) + None, /**< Ignore informational notifications, and show a modal pop-up dialog for Critical notifications. */ + Freedesktop, /**< Use DBus org.freedesktop.Notifications */ + QSystemTray, /**< Use QSystemTray::showMessage */ + Growl /**< Use the Growl notification system (Mac only) */ }; QString programName; Mode mode; |