Commit 6f413c5d authored by Tijmen de Mes's avatar Tijmen de Mes

Enable sip message preferences

parent 7ee23ac7
......@@ -256,6 +256,9 @@ class PreferencesWindow(base_class, ui_class, metaclass=QSingleton):
self.prefix_button.activated[str].connect(self._SH_PrefixButtonActivated)
self.account_tls_name_editor.editingFinished.connect(self._SH_TLSPeerNameEditorEditingFinished)
self.message_cpim_enabled_button.clicked.connect(self._SH_EnableMessageCPIMButtonClicked)
self.message_iscomposing_enabled_button.clicked.connect(self._SH_EnableMessageIsComposingButtonClicked)
# Audio devices
self.audio_alert_device_button.activated[int].connect(self._SH_AudioAlertDeviceButtonActivated)
self.audio_input_device_button.activated[int].connect(self._SH_AudioInputDeviceButtonActivated)
......@@ -823,6 +826,10 @@ class PreferencesWindow(base_class, ui_class, metaclass=QSingleton):
self.account_auto_answer.setChecked(account.sip.auto_answer)
# SMS settings tab, also relevant for bonjour
self.message_cpim_enabled_button.setChecked(account.sms.use_cpim)
self.message_iscomposing_enabled_button.setChecked(account.sms.enable_iscomposing)
if account is not bonjour_account:
self.account_auto_answer.setText('Auto answer from allowed contacts')
# Server settings tab
......@@ -1410,6 +1417,16 @@ class PreferencesWindow(base_class, ui_class, metaclass=QSingleton):
settings.tls.verify_server = checked
settings.save()
def _SH_EnableMessageCPIMButtonClicked(self, checked):
account = self.selected_account
account.sms.use_cpim = checked
account.save()
def _SH_EnableMessageIsComposingButtonClicked(self, checked):
account = self.selected_account
account.sms.enable_iscomposing = checked
account.save()
# Audio devices signal handlers
def _SH_AudioAlertDeviceButtonActivated(self, index):
device = self.audio_alert_device_button.itemData(index)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment