Commit b5feb843 authored by Julien Bonjean's avatar Julien Bonjean

Fixed GTK client remaining compilation warnings

parent 3f8e4078
......@@ -6,7 +6,7 @@
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 3 of the License, or
* (at your option) any later version.
*
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
......@@ -54,7 +54,7 @@ void prefill_sip(void) ;
void set_account_type( GtkWidget* widget , gpointer data UNUSED ) {
if( gtk_toggle_button_get_active( GTK_TOGGLE_BUTTON( widget )) ){
account_type = _SIP;
}else{
}else{
account_type = _IAX ;
}
}
......@@ -105,7 +105,7 @@ static void sip_apply_callback( void ) {
dbus_add_account( current );
account_list_set_current_id( current->accountID );
sprintf(message, MESSAGE_SUMMARY,
sprintf(message, MESSAGE_SUMMARY,
gtk_entry_get_text (GTK_ENTRY(wiz->sip_alias)),
gtk_entry_get_text (GTK_ENTRY(wiz->sip_server)),
gtk_entry_get_text (GTK_ENTRY(wiz->sip_username)),
......@@ -130,7 +130,7 @@ static void iax_apply_callback( void ) {
g_hash_table_insert(current->properties, g_strdup(ACCOUNT_PASSWORD), g_strdup((gchar *)gtk_entry_get_text(GTK_ENTRY(wiz->iax_password))));
dbus_add_account( current );
account_list_set_current_id( current->accountID );
sprintf(message, MESSAGE_SUMMARY,
sprintf(message, MESSAGE_SUMMARY,
gtk_entry_get_text (GTK_ENTRY(wiz->iax_alias)),
gtk_entry_get_text (GTK_ENTRY(wiz->iax_server)),
gtk_entry_get_text (GTK_ENTRY(wiz->iax_username)),
......@@ -169,7 +169,7 @@ void build_wizard( void ) {
build_summary();
g_signal_connect(G_OBJECT(wiz->assistant), "close" , G_CALLBACK(close_callback), NULL);
g_signal_connect(G_OBJECT(wiz->assistant), "cancel" , G_CALLBACK(cancel_callback), NULL);
gtk_widget_show_all(wiz->assistant);
......@@ -202,9 +202,9 @@ GtkWidget* build_select_account() {
gtk_box_pack_start( GTK_BOX(wiz->protocols) , sip , TRUE, TRUE, 0);
iax = gtk_radio_button_new_with_label_from_widget(GTK_RADIO_BUTTON(sip), "IAX2 (InterAsterix Exchange)");
gtk_box_pack_start( GTK_BOX(wiz->protocols) , iax , TRUE, TRUE, 0);
g_signal_connect(G_OBJECT( sip ) , "clicked" , G_CALLBACK( set_account_type ) , NULL );
gtk_assistant_set_page_complete(GTK_ASSISTANT(wiz->assistant), wiz->protocols, TRUE);
return wiz->protocols;
}
......@@ -221,7 +221,7 @@ GtkWidget* build_sfl_or_account() {
cus = gtk_radio_button_new_with_label_from_widget(GTK_RADIO_BUTTON(sfl), _("Register an existing SIP or IAX2 account"));
gtk_box_pack_start( GTK_BOX(wiz->sflphone_org) , cus , TRUE, TRUE, 0);
g_signal_connect(G_OBJECT( sfl ) , "clicked" , G_CALLBACK( set_sflphone_org ) , NULL );
return wiz->sflphone_org;
}
......@@ -231,13 +231,13 @@ GtkWidget* build_sip_account_configuration( void ) {
GtkWidget* label;
GtkWidget* image;
wiz->sip_account = create_vbox( GTK_ASSISTANT_PAGE_CONTENT , _("SIP account configuration") , _("Please fill the following information:"));
wiz->sip_account = create_vbox( GTK_ASSISTANT_PAGE_CONTENT , _("SIP account configuration") , _("Please fill the following information:"));
// table
table = gtk_table_new ( 4, 2 , FALSE/* homogeneous */);
gtk_table_set_row_spacings( GTK_TABLE(table), 10);
gtk_table_set_col_spacings( GTK_TABLE(table), 10);
gtk_box_pack_start( GTK_BOX(wiz->sip_account) , table , TRUE, TRUE, 0);
// alias field
label = gtk_label_new_with_mnemonic (_("_Alias"));
gtk_table_attach ( GTK_TABLE( table ), label, 0, 1, 0, 1, GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
......@@ -245,7 +245,7 @@ GtkWidget* build_sip_account_configuration( void ) {
wiz->sip_alias = gtk_entry_new();
gtk_label_set_mnemonic_widget (GTK_LABEL (label), wiz->sip_alias);
gtk_table_attach ( GTK_TABLE( table ), wiz->sip_alias, 1, 2, 0, 1, GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
// server field
label = gtk_label_new_with_mnemonic (_("_Host name"));
gtk_table_attach ( GTK_TABLE( table ), label, 0, 1, 1, 2, GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
......@@ -253,7 +253,7 @@ GtkWidget* build_sip_account_configuration( void ) {
wiz->sip_server = gtk_entry_new();
gtk_label_set_mnemonic_widget (GTK_LABEL (label), wiz->sip_server);
gtk_table_attach ( GTK_TABLE( table ), wiz->sip_server, 1, 2, 1, 2, GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
// username field
label = gtk_label_new_with_mnemonic (_("_User name"));
gtk_table_attach ( GTK_TABLE( table ), label, 0, 1, 2, 3, GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
......@@ -264,11 +264,11 @@ GtkWidget* build_sip_account_configuration( void ) {
#else
wiz->sip_username = sexy_icon_entry_new();
image = gtk_image_new_from_file( ICONS_DIR "/stock_person.svg" );
sexy_icon_entry_set_icon( SEXY_ICON_ENTRY(wiz->sip_username), SEXY_ICON_ENTRY_PRIMARY , GTK_IMAGE(image) );
sexy_icon_entry_set_icon( SEXY_ICON_ENTRY(wiz->sip_username), SEXY_ICON_ENTRY_PRIMARY , GTK_IMAGE(image) );
#endif
gtk_label_set_mnemonic_widget (GTK_LABEL (label), wiz->sip_username);
gtk_table_attach ( GTK_TABLE( table ), wiz->sip_username, 1, 2, 2, 3, GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
// password field
label = gtk_label_new_with_mnemonic (_("_Password"));
gtk_table_attach ( GTK_TABLE( table ), label, 0, 1, 3, 4, GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
......@@ -279,12 +279,12 @@ GtkWidget* build_sip_account_configuration( void ) {
#else
wiz->sip_password = sexy_icon_entry_new();
image = gtk_image_new_from_stock( GTK_STOCK_DIALOG_AUTHENTICATION , GTK_ICON_SIZE_SMALL_TOOLBAR );
sexy_icon_entry_set_icon( SEXY_ICON_ENTRY(wiz->sip_password), SEXY_ICON_ENTRY_PRIMARY , GTK_IMAGE(image) );
sexy_icon_entry_set_icon( SEXY_ICON_ENTRY(wiz->sip_password), SEXY_ICON_ENTRY_PRIMARY , GTK_IMAGE(image) );
#endif
gtk_label_set_mnemonic_widget (GTK_LABEL (label), wiz->sip_password);
gtk_entry_set_visibility(GTK_ENTRY(wiz->sip_password), FALSE);
gtk_table_attach ( GTK_TABLE( table ), wiz->sip_password, 1, 2, 3, 4, GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
//gtk_assistant_set_page_complete(GTK_ASSISTANT(wiz->assistant), wiz->sip_account, TRUE);
return wiz->sip_account;
}
......@@ -293,13 +293,13 @@ GtkWidget* build_email_configuration( void ) {
GtkWidget* label;
GtkWidget* table;
wiz->email = create_vbox( GTK_ASSISTANT_PAGE_CONTENT , _("Optional Email Address ") , _("This email address will be use to send your voicemail messages"));
wiz->email = create_vbox( GTK_ASSISTANT_PAGE_CONTENT , _("Optional Email Address ") , _("This email address will be use to send your voicemail messages"));
table = gtk_table_new ( 4, 2 , FALSE/* homogeneous */);
gtk_table_set_row_spacings( GTK_TABLE(table), 10);
gtk_table_set_col_spacings( GTK_TABLE(table), 10);
gtk_box_pack_start( GTK_BOX(wiz->email) , table , TRUE, TRUE, 0);
// email field
label = gtk_label_new_with_mnemonic (_("_Email"));
gtk_table_attach ( GTK_TABLE( table ), label, 0, 1, 0, 1, GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
......@@ -310,19 +310,19 @@ GtkWidget* build_email_configuration( void ) {
return wiz->email;
}
GtkWidget* build_iax_account_configuration( void ) {
GtkWidget* label;
GtkWidget* table;
GtkWidget* image;
wiz->iax_account = create_vbox( GTK_ASSISTANT_PAGE_CONFIRM , _("IAX2 account configuration") , _("Please fill the following information:"));
wiz->iax_account = create_vbox( GTK_ASSISTANT_PAGE_CONFIRM , _("IAX2 account configuration") , _("Please fill the following information:"));
table = gtk_table_new ( 4, 2 , FALSE/* homogeneous */);
gtk_table_set_row_spacings( GTK_TABLE(table), 10);
gtk_table_set_col_spacings( GTK_TABLE(table), 10);
gtk_box_pack_start( GTK_BOX(wiz->iax_account) , table , TRUE, TRUE, 0);
// alias field
label = gtk_label_new_with_mnemonic (_("_Alias"));
gtk_table_attach ( GTK_TABLE( table ), label, 0, 1, 0, 1, GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
......@@ -330,7 +330,7 @@ GtkWidget* build_iax_account_configuration( void ) {
wiz->iax_alias = gtk_entry_new();
gtk_label_set_mnemonic_widget (GTK_LABEL (label), wiz->iax_alias);
gtk_table_attach ( GTK_TABLE( table ), wiz->iax_alias, 1, 2, 0, 1, GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
// server field
label = gtk_label_new_with_mnemonic (_("_Host name"));
gtk_table_attach ( GTK_TABLE( table ), label, 0, 1, 1, 2, GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
......@@ -338,7 +338,7 @@ GtkWidget* build_iax_account_configuration( void ) {
wiz->iax_server = gtk_entry_new();
gtk_label_set_mnemonic_widget (GTK_LABEL (label), wiz->iax_server);
gtk_table_attach ( GTK_TABLE( table ), wiz->iax_server, 1, 2, 1, 2, GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
// username field
label = gtk_label_new_with_mnemonic (_("_User name"));
gtk_table_attach ( GTK_TABLE( table ), label, 0, 1, 2, 3, GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
......@@ -349,11 +349,11 @@ GtkWidget* build_iax_account_configuration( void ) {
#else
wiz->iax_username = sexy_icon_entry_new();
image = gtk_image_new_from_file( ICONS_DIR "/stock_person.svg" );
sexy_icon_entry_set_icon( SEXY_ICON_ENTRY(wiz->iax_username), SEXY_ICON_ENTRY_PRIMARY , GTK_IMAGE(image) );
sexy_icon_entry_set_icon( SEXY_ICON_ENTRY(wiz->iax_username), SEXY_ICON_ENTRY_PRIMARY , GTK_IMAGE(image) );
#endif
gtk_label_set_mnemonic_widget (GTK_LABEL (label), wiz->iax_username);
gtk_table_attach ( GTK_TABLE( table ), wiz->iax_username, 1, 2, 2, 3, GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
// password field
label = gtk_label_new_with_mnemonic (_("_Password"));
gtk_table_attach ( GTK_TABLE( table ), label, 0, 1, 3, 4, GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
......@@ -364,15 +364,15 @@ GtkWidget* build_iax_account_configuration( void ) {
#else
wiz->iax_password = sexy_icon_entry_new();
image = gtk_image_new_from_stock( GTK_STOCK_DIALOG_AUTHENTICATION , GTK_ICON_SIZE_SMALL_TOOLBAR );
sexy_icon_entry_set_icon( SEXY_ICON_ENTRY(wiz->iax_password), SEXY_ICON_ENTRY_PRIMARY , GTK_IMAGE(image) );
sexy_icon_entry_set_icon( SEXY_ICON_ENTRY(wiz->iax_password), SEXY_ICON_ENTRY_PRIMARY , GTK_IMAGE(image) );
#endif
gtk_label_set_mnemonic_widget (GTK_LABEL (label), wiz->iax_password);
gtk_entry_set_visibility(GTK_ENTRY(wiz->iax_password), FALSE);
gtk_table_attach ( GTK_TABLE( table ), wiz->iax_password, 1, 2, 3, 4, GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
current -> state = ACCOUNT_STATE_UNREGISTERED;
g_signal_connect( G_OBJECT( wiz->assistant ) , "apply" , G_CALLBACK( iax_apply_callback ), NULL);
return wiz->iax_account;
......@@ -381,22 +381,22 @@ GtkWidget* build_iax_account_configuration( void ) {
GtkWidget* build_nat_settings( void ) {
GtkWidget* label;
GtkWidget* table;
wiz->nat = create_vbox( GTK_ASSISTANT_PAGE_CONFIRM , _("Network Address Translation") , _("You should probably enable this if you are behind a firewall."));
wiz->nat = create_vbox( GTK_ASSISTANT_PAGE_CONFIRM , _("Network Address Translation") , _("You should probably enable this if you are behind a firewall."));
// table
table = gtk_table_new ( 2, 2 , FALSE/* homogeneous */);
gtk_table_set_row_spacings( GTK_TABLE(table), 10);
gtk_table_set_col_spacings( GTK_TABLE(table), 10);
gtk_box_pack_start( GTK_BOX(wiz->nat), table , TRUE, TRUE, 0);
// enable
wiz->enable = gtk_check_button_new_with_mnemonic(_("E_nable STUN"));
gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(wiz->enable), FALSE);
gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(wiz->enable), FALSE);
gtk_table_attach ( GTK_TABLE( table ), wiz->enable, 0, 1, 0, 1, GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
gtk_widget_set_sensitive( GTK_WIDGET( wiz->enable ) , TRUE );
g_signal_connect( G_OBJECT( GTK_TOGGLE_BUTTON(wiz->enable)) , "toggled" , G_CALLBACK( enable_stun ), NULL);
// server address
label = gtk_label_new_with_mnemonic (_("_STUN server"));
gtk_table_attach ( GTK_TABLE( table ), label, 0, 1, 1, 2, GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
......@@ -405,9 +405,9 @@ GtkWidget* build_nat_settings( void ) {
gtk_label_set_mnemonic_widget (GTK_LABEL (label), wiz->addr);
gtk_table_attach ( GTK_TABLE( table ), wiz->addr, 1, 2, 1, 2, GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
gtk_widget_set_sensitive( GTK_WIDGET( wiz->addr ), gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(wiz->enable)));
g_signal_connect( G_OBJECT( wiz->assistant ) , "apply" , G_CALLBACK( sip_apply_callback ), NULL);
return wiz->nat;
}
......@@ -421,20 +421,20 @@ GtkWidget* build_summary() {
gtk_label_set_line_wrap(GTK_LABEL(wiz->label_summary), TRUE);
//gtk_widget_set_size_request(GTK_WIDGET(wiz->label_summary), 380, -1);
gtk_box_pack_start(GTK_BOX(wiz->summary), wiz->label_summary, FALSE, TRUE, 0);
return wiz->summary;
}
GtkWidget* build_registration_error() {
GtkWidget *label;
wiz->reg_failed = create_vbox( GTK_ASSISTANT_PAGE_SUMMARY , "Account Registration" , "Registration error");
label = gtk_label_new(" Please correct the information.") ;
gtk_misc_set_alignment(GTK_MISC(label), 0, 0);
gtk_label_set_line_wrap(GTK_LABEL(label), TRUE);
gtk_widget_set_size_request(GTK_WIDGET(label), 380, -1);
gtk_box_pack_start(GTK_BOX(wiz->reg_failed), label, FALSE, TRUE, 0);
return wiz->reg_failed;
}
......@@ -475,7 +475,7 @@ typedef enum {
PAGE_SUMMARY
} assistant_state;
static gint forward_page_func( gint current_page , gpointer data) {
static gint forward_page_func( gint current_page , gpointer data UNUSED) {
gint next_page = 0;
switch( current_page ){
......@@ -486,32 +486,32 @@ static gint forward_page_func( gint current_page , gpointer data) {
if (use_sflphone_org) {
next_page = PAGE_EMAIL;
} else
next_page = PAGE_TYPE;
next_page = PAGE_TYPE;
break;
case PAGE_TYPE:
if( account_type == _SIP ) {
set_sip_infos_sentivite(TRUE);
next_page = PAGE_SIP;
next_page = PAGE_SIP;
} else
next_page = PAGE_IAX;
next_page = PAGE_IAX;
break;
case PAGE_SIP:
next_page = PAGE_STUN;
case PAGE_SIP:
next_page = PAGE_STUN;
break;
case PAGE_EMAIL:
next_page = PAGE_STUN;
case PAGE_EMAIL:
next_page = PAGE_STUN;
break;
case PAGE_STUN:
next_page = PAGE_SUMMARY;
next_page = PAGE_SUMMARY;
break;
case PAGE_IAX:
next_page = PAGE_SUMMARY;
next_page = PAGE_SUMMARY;
break;
case PAGE_SUMMARY:
next_page = PAGE_SUMMARY;
next_page = PAGE_SUMMARY;
break;
default:
next_page = -1;
next_page = -1;
}
return next_page;
}
......@@ -524,7 +524,7 @@ static GtkWidget* create_vbox(GtkAssistantPageType type, const gchar *title, con
vbox = gtk_vbox_new(FALSE, 6);
gtk_container_set_border_width(GTK_CONTAINER(vbox), 24);
gtk_assistant_append_page(GTK_ASSISTANT(wiz->assistant), vbox);
gtk_assistant_set_page_type(GTK_ASSISTANT(wiz->assistant), vbox, type);
str = g_strdup_printf(" %s", title);
......@@ -533,7 +533,7 @@ static GtkWidget* create_vbox(GtkAssistantPageType type, const gchar *title, con
g_free(str);
gtk_assistant_set_page_complete(GTK_ASSISTANT(wiz->assistant), vbox, TRUE);
wiz->logo = gdk_pixbuf_new_from_file(ICONS_DIR "/sflphone.png", NULL);
gtk_assistant_set_page_header_image(GTK_ASSISTANT(wiz->assistant),vbox, wiz->logo);
g_object_unref(wiz->logo);
......@@ -549,4 +549,4 @@ static GtkWidget* create_vbox(GtkAssistantPageType type, const gchar *title, con
return vbox;
}
#endif // GTK_CHECK_VERSION
#endif // GTK_CHECK_VERSION
......@@ -286,7 +286,7 @@ main_window_volume_controls( gboolean *state ){
}
void
main_window_searchbar( gboolean *state ){
main_window_searchbar( gboolean *state UNUSED){
if( !SHOW_SEARCHBAR )
{
// filterEntry = create_filter_entry();
......
#include <glib-object.h>
#include <marshaller.h>
#ifdef G_ENABLE_DEBUG
......@@ -50,10 +50,10 @@
/* VOID:STRING,STRING,STRING (marshaller.list:1) */
void
g_cclosure_user_marshal_VOID__STRING_STRING_STRING (GClosure *closure,
GValue *return_value,
GValue *return_value UNUSED,
guint n_param_values,
const GValue *param_values,
gpointer invocation_hint,
gpointer invocation_hint UNUSED,
gpointer marshal_data)
{
typedef void (*GMarshalFunc_VOID__STRING_STRING_STRING) (gpointer data1,
......@@ -89,10 +89,10 @@ g_cclosure_user_marshal_VOID__STRING_STRING_STRING (GClosure *closure,
/* VOID:STRING,STRING (marshaller.list:2) */
void
g_cclosure_user_marshal_VOID__STRING_STRING (GClosure *closure,
GValue *return_value,
GValue *return_value UNUSED,
guint n_param_values,
const GValue *param_values,
gpointer invocation_hint,
gpointer invocation_hint UNUSED,
gpointer marshal_data)
{
typedef void (*GMarshalFunc_VOID__STRING_STRING) (gpointer data1,
......@@ -128,10 +128,10 @@ g_cclosure_user_marshal_VOID__STRING_STRING (GClosure *closure,
/* VOID:STRING,INT (marshaller.list:4) */
void
g_cclosure_user_marshal_VOID__STRING_INT (GClosure *closure,
GValue *return_value,
GValue *return_value UNUSED,
guint n_param_values,
const GValue *param_values,
gpointer invocation_hint,
gpointer invocation_hint UNUSED,
gpointer marshal_data)
{
typedef void (*GMarshalFunc_VOID__STRING_INT) (gpointer data1,
......@@ -165,10 +165,10 @@ g_cclosure_user_marshal_VOID__STRING_INT (GClosure *closure,
/* VOID:STRING,DOUBLE (marshaller.list:5) */
void
g_cclosure_user_marshal_VOID__STRING_DOUBLE (GClosure *closure,
GValue *return_value,
GValue *return_value UNUSED,
guint n_param_values,
const GValue *param_values,
gpointer invocation_hint,
gpointer invocation_hint UNUSED,
gpointer marshal_data)
{
typedef void (*GMarshalFunc_VOID__STRING_DOUBLE) (gpointer data1,
......
......@@ -2,7 +2,8 @@
#ifndef __g_cclosure_user_marshal_MARSHAL_H__
#define __g_cclosure_user_marshal_MARSHAL_H__
#include <glib-object.h>
#include <glib-object.h>
#include <sflphone_const.h>
G_BEGIN_DECLS
......
......@@ -711,7 +711,7 @@ create_menus ( )
/* ----------------------------------------------------------------- */
static void edit_number_cb (GtkWidget *widget, gpointer user_data) {
static void edit_number_cb (GtkWidget *widget UNUSED, gpointer user_data) {
show_edit_number ((call_t*)user_data);
}
......@@ -1038,7 +1038,7 @@ void add_registered_accounts_to_menu (GtkWidget *menu) {
}
static void ok_cb (GtkWidget *widget, gpointer userdata) {
static void ok_cb (GtkWidget *widget UNUSED, gpointer userdata) {
gchar *new_number, *from;
call_t *modified_call, *original;
......@@ -1046,8 +1046,8 @@ static void ok_cb (GtkWidget *widget, gpointer userdata) {
// Change the number of the selected call before calling
new_number = (gchar*) gtk_entry_get_text (GTK_ENTRY (editable_num));
original = (call_t*)userdata;
// Edit the from field with the updated phone number value
// Edit the from field with the updated phone number value
from = g_strconcat("\"", call_get_name (original), "\" <", new_number, ">",NULL);
// Create the new call
......@@ -1072,14 +1072,14 @@ void show_edit_number (call_t *call) {
GtkWidget *ok, *hbox, *image;
GdkPixbuf *pixbuf;
edit_dialog = GTK_DIALOG (gtk_dialog_new());
// Set window properties
gtk_window_set_default_size(GTK_WINDOW(edit_dialog), 300, 20);
gtk_window_set_title(GTK_WINDOW(edit_dialog), _("Edit phone"));
gtk_window_set_resizable (GTK_WINDOW (edit_dialog), FALSE);
g_signal_connect (G_OBJECT (edit_dialog), "delete-event", G_CALLBACK (on_delete), NULL);
hbox = gtk_hbox_new (FALSE, 0);
......@@ -1090,13 +1090,13 @@ void show_edit_number (call_t *call) {
#if GTK_CHECK_VERSION(2,12,0)
gtk_widget_set_tooltip_text(GTK_WIDGET(editable_num), _("Edit the phone number before making a call"));
#endif
if (call)
if (call)
gtk_entry_set_text(GTK_ENTRY(editable_num), g_strdup (call_get_number (call)));
else
g_print ("This a bug, the call should be defined. menus.c line 1051\n");
gtk_box_pack_start(GTK_BOX (hbox), editable_num, TRUE, TRUE, 0);
// Set a custom image for the button
pixbuf = gdk_pixbuf_new_from_file_at_scale (ICONS_DIR "/outgoing.svg", 32, 32, TRUE, NULL);
image = gtk_image_new_from_pixbuf (pixbuf);
......
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