diff options
| author | Tomasz Sterna <tomek@xiaoka.com> | 2014-08-01 12:58:36 +0200 |
|---|---|---|
| committer | Tomasz Sterna <tomek@xiaoka.com> | 2014-08-02 00:55:18 +0200 |
| commit | 0fa2ca1ee1dec8d7355115426a762f9fe808f2f6 (patch) | |
| tree | 663d80a1617fa856f4f0f5fb56f1200294ba9e0c /daemon | |
| parent | 006d08310e5fafa8b66520318598122603e32d8c (diff) | |
Implemented option to disable phone call forwarding to watch. closes #13
Diffstat (limited to 'daemon')
| -rw-r--r-- | daemon/manager.cpp | 5 | ||||
| -rw-r--r-- | daemon/settings.h | 3 |
2 files changed, 8 insertions, 0 deletions
diff --git a/daemon/manager.cpp b/daemon/manager.cpp index bd9fc4a..b47c170 100644 --- a/daemon/manager.cpp +++ b/daemon/manager.cpp @@ -120,6 +120,11 @@ void Manager::onActiveVoiceCallChanged() { logger()->debug() << "Manager::onActiveVoiceCallChanged()"; + if (!settings->property("incomingCallNotification").toBool()) { + logger()->debug() << "Ignoring ActiveVoiceCallChanged because of setting!"; + return; + } + VoiceCallHandler* handler = voice->activeVoiceCall(); if (handler) { connect(handler, SIGNAL(statusChanged()), SLOT(onActiveVoiceCallStatusChanged())); diff --git a/daemon/settings.h b/daemon/settings.h index 1f2e2e5..03423e4 100644 --- a/daemon/settings.h +++ b/daemon/settings.h @@ -8,6 +8,7 @@ class Settings : public MDConfGroup Q_OBJECT Q_PROPERTY(bool silentWhenConnected MEMBER silentWhenConnected NOTIFY silentWhenConnectedChanged) + Q_PROPERTY(bool incomingCallNotification MEMBER incomingCallNotification NOTIFY incomingCallNotificationChanged) Q_PROPERTY(bool notificationsCommhistoryd MEMBER notificationsCommhistoryd NOTIFY notificationsCommhistorydChanged) Q_PROPERTY(bool notificationsMissedCall MEMBER notificationsMissedCall NOTIFY notificationsMissedCallChanged) Q_PROPERTY(bool notificationsEmails MEMBER notificationsEmails NOTIFY notificationsEmailsChanged) @@ -17,6 +18,7 @@ class Settings : public MDConfGroup Q_PROPERTY(bool notificationsOther MEMBER notificationsOther NOTIFY notificationsOtherChanged) Q_PROPERTY(bool notificationsAll MEMBER notificationsAll NOTIFY notificationsAllChanged) bool silentWhenConnected; + bool incomingCallNotification; bool notificationsCommhistoryd; bool notificationsMissedCall; bool notificationsEmails; @@ -33,6 +35,7 @@ public: signals: void silentWhenConnectedChanged(bool); + void incomingCallNotificationChanged(bool); void notificationsCommhistorydChanged(bool); void notificationsMissedCallChanged(bool); void notificationsEmailsChanged(bool); |
