diff options
author | Remko Tronçon <git@el-tramo.be> | 2010-10-04 19:48:09 (GMT) |
---|---|---|
committer | Remko Tronçon <git@el-tramo.be> | 2010-10-04 19:48:09 (GMT) |
commit | bb31d6f3a20e8989e182fa78b1bf2edaa2156dea (patch) | |
tree | 35be6fa1ea67e12985e2b852b9a04977b6f0a00a /SwifTools/Notifier/Notifier.cpp | |
parent | 537afef23b0f5da31c0cd38597a13773d79f77d4 (diff) | |
download | swift-contrib-bb31d6f3a20e8989e182fa78b1bf2edaa2156dea.zip swift-contrib-bb31d6f3a20e8989e182fa78b1bf2edaa2156dea.tar.bz2 |
Disable the notifier when going to DND.
Resolves: #572
Diffstat (limited to 'SwifTools/Notifier/Notifier.cpp')
-rw-r--r-- | SwifTools/Notifier/Notifier.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/SwifTools/Notifier/Notifier.cpp b/SwifTools/Notifier/Notifier.cpp index 7a7ed13..ec6a12f 100644 --- a/SwifTools/Notifier/Notifier.cpp +++ b/SwifTools/Notifier/Notifier.cpp @@ -8,9 +8,18 @@ namespace Swift { +Notifier::Notifier() : enabled(true) { +} + Notifier::~Notifier() { } +void Notifier::showMessage(Type type, const String& subject, const String& description, const boost::filesystem::path& picture, boost::function<void()> callback) { + if (enabled) { + doShowMessage(type, subject, description, picture, callback); + } +} + String Notifier::typeToString(Type type) { switch (type) { case ContactAvailable: return "Contact Becomes Available"; |