summaryrefslogtreecommitdiffstats
path: root/src/gui
diff options
context:
space:
mode:
authorFrédéric Brière <fbriere@fbriere.net>2018-08-17 21:35:23 -0400
committerFrédéric Brière <fbriere@fbriere.net>2019-06-30 22:16:19 -0400
commitf3d6f33a3ca173e2fc57f1d8679d25b0ac1c6a15 (patch)
tree60164e6202de0f742cad6638bb96b34c9ddc5505 /src/gui
parent05082ae12051821b1d969e6672d9e4e5afe1bc07 (diff)
downloadtwinkle-f3d6f33a3ca173e2fc57f1d8679d25b0ac1c6a15.tar
twinkle-f3d6f33a3ca173e2fc57f1d8679d25b0ac1c6a15.tar.gz
twinkle-f3d6f33a3ca173e2fc57f1d8679d25b0ac1c6a15.tar.lz
twinkle-f3d6f33a3ca173e2fc57f1d8679d25b0ac1c6a15.tar.xz
twinkle-f3d6f33a3ca173e2fc57f1d8679d25b0ac1c6a15.zip
Add configuration option to disable incoming call popup window
Closes #126
Diffstat (limited to 'src/gui')
-rw-r--r--src/gui/mphoneform.cpp3
-rw-r--r--src/gui/syssettingsform.cpp6
-rw-r--r--src/gui/syssettingsform.ui15
3 files changed, 22 insertions, 2 deletions
diff --git a/src/gui/mphoneform.cpp b/src/gui/mphoneform.cpp
index 6c447a8..d2a7b59 100644
--- a/src/gui/mphoneform.cpp
+++ b/src/gui/mphoneform.cpp
@@ -810,7 +810,8 @@ void MphoneForm::updateState()
name = cr.from_uri.encode_no_params_hdrs(false);
incomingCallPopup->setCallerName(QString::fromStdString(name));
- showIncomingCallPopup = true;
+ if (sys_config->get_gui_show_incoming_popup())
+ showIncomingCallPopup = true;
break;
}
diff --git a/src/gui/syssettingsform.cpp b/src/gui/syssettingsform.cpp
index 355df59..aa9bb7d 100644
--- a/src/gui/syssettingsform.cpp
+++ b/src/gui/syssettingsform.cpp
@@ -268,6 +268,9 @@ void SysSettingsForm::populate()
// Call history
histSizeSpinBox->setValue(sys_config->get_ch_max_size());
+ // Show popup on incoming call
+ incomingPopupCheckBox->setChecked(sys_config->get_gui_show_incoming_popup());
+
// Auto show on incoming call
autoShowCheckBox->setChecked(sys_config->get_gui_auto_show_incoming());
autoShowTimeoutSpinBox->setValue(sys_config->get_gui_auto_show_timeout());
@@ -377,6 +380,9 @@ void SysSettingsForm::validate()
sys_config->set_gui_hide_on_close(guiHideCheckBox->isChecked());
sys_config->set_gui_show_call_osd(osdCheckBox->isChecked());
+ // Show popup on incoming call
+ sys_config->set_gui_show_incoming_popup(incomingPopupCheckBox->isChecked());
+
// Auto show on incoming call
sys_config->set_gui_auto_show_incoming(autoShowCheckBox->isChecked());
sys_config->set_gui_auto_show_timeout(autoShowTimeoutSpinBox->value());
diff --git a/src/gui/syssettingsform.ui b/src/gui/syssettingsform.ui
index a792f81..d9e5262 100644
--- a/src/gui/syssettingsform.ui
+++ b/src/gui/syssettingsform.ui
@@ -890,6 +890,19 @@ If before answering a call, the microphone or speaker appears to be invalid, a w
</layout>
</item>
<item row="6" column="0">
+ <widget class="QCheckBox" name="incomingPopupCheckBox">
+ <property name="whatsThis">
+ <string>Display a popup window with "Answer" and "Reject" buttons on an incoming call.</string>
+ </property>
+ <property name="text">
+ <string>Show &amp;popup window on incoming call</string>
+ </property>
+ <property name="shortcut">
+ <string>Alt+P</string>
+ </property>
+ </widget>
+ </item>
+ <item row="7" column="0">
<layout class="QHBoxLayout">
<item>
<widget class="QCheckBox" name="autoShowCheckBox">
@@ -942,7 +955,7 @@ If before answering a call, the microphone or speaker appears to be invalid, a w
</item>
</layout>
</item>
- <item row="7" column="0">
+ <item row="8" column="0">
<layout class="QHBoxLayout">
<item>
<widget class="QLabel" name="browserTextLabel">