From 837b94df2dc753fe032ced4c87e9f4b1cc8435dc Mon Sep 17 00:00:00 2001 From: Sandrine Avakian Date: Mon, 8 Aug 2016 11:17:27 +0200 Subject: [PATCH] Experimental feature lime Adding lime_experimental_feature in linphonerc [GtkUi] section. Setting it to 1 shows the options related to lime in the GUI. Setting it to 0 hides the options. Default:set to 0. Note: enabling lime in the [sip] section does work too, the GUI will just not show the option has been changed. --- gtk/propertybox.c | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/gtk/propertybox.c b/gtk/propertybox.c index c2510ffc8..2b1e12caa 100644 --- a/gtk/propertybox.c +++ b/gtk/propertybox.c @@ -1397,9 +1397,16 @@ static void linphone_gtk_show_media_encryption(GtkWidget *pb){ } gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(linphone_gtk_get_widget(pb,"media_encryption_mandatory_checkbox")), linphone_core_is_media_encryption_mandatory(lc)); - - gtk_combo_box_set_active(GTK_COMBO_BOX(linphone_gtk_get_widget(pb,"chat_lime_combo")), linphone_core_lime_enabled(lc)); - gtk_widget_set_sensitive(linphone_gtk_get_widget(pb,"chat_lime_combo"), linphone_core_lime_available(lc)); + + gtk_widget_set_visible (linphone_gtk_get_widget(pb,"chat_lime_label"), 0); + gtk_widget_set_visible (linphone_gtk_get_widget(pb,"chat_lime_combo"), 0); + + if (linphone_gtk_get_ui_config_int("lime_experimental_feature", 0)){ + gtk_widget_set_visible (linphone_gtk_get_widget(pb,"chat_lime_label"), 1); + gtk_widget_set_visible (linphone_gtk_get_widget(pb,"chat_lime_combo"), 1); + gtk_combo_box_set_active(GTK_COMBO_BOX(linphone_gtk_get_widget(pb,"chat_lime_combo")), linphone_core_lime_enabled(lc)); + gtk_widget_set_sensitive(linphone_gtk_get_widget(pb,"chat_lime_combo"), linphone_core_lime_available(lc)); + } g_object_unref(G_OBJECT(model)); }