diff --git a/lang/fr/fr.po b/lang/fr/fr.po index 67b6b2ad81751f1f4c80295af952263efe730a54..f54693bbc7997cbb294da2a69952492c91802803 100644 --- a/lang/fr/fr.po +++ b/lang/fr/fr.po @@ -892,7 +892,7 @@ msgstr "Fichier de configuration" #: ../sflphone-client-gnome/src/config/preferencesdialog.c:379 msgid "Store SIP credentials as MD5 hash" msgstr "" -"Stocker les informations d'authentification sour forme encryptée (MD5)" +"Stocker les informations d'authentification sous forme encryptée (MD5)" #: ../sflphone-client-gnome/src/config/preferencesdialog.c:423 msgid "Preferences" diff --git a/lang/it/it.po b/lang/it/it.po index 84a53d0b6618d0dffbdeb595869318047ef77618..88fc58458f6e365dd5d030203af3e1d5057ccf11 100644 --- a/lang/it/it.po +++ b/lang/it/it.po @@ -103,7 +103,7 @@ msgid "" "</b> SFL audio codecs have to be placed in <i>%s</i> or in the " "<b>.sflphone</b> directory in your home( <i>%s</i> )" msgstr "" -"<b>Errore: Non è stato trovato alcun codec audio.</b>\n" +"<b>Errore: Non è stato trovato alcun codec audio.</b>\n" "\n" "I codec audio SFL devono trovarsi in <i>%s</i> o nella sottocartella " "<b>.sflphone</b> della cartella home dell'utente (</i>%s</i>)" @@ -133,11 +133,11 @@ msgid "" "Pulseaudio is not running" msgstr "" "Notifica PulseAudio\n" -"PulseAudio non è in esecuzione" +"PulseAudio non è in esecuzione" #: ../sflphone-client-gnome/src/mainwindow.c:73 msgid "There is one call in progress." -msgstr "C'è una chiamata in corso." +msgstr "C'è una chiamata in corso." #: ../sflphone-client-gnome/src/mainwindow.c:77 msgid "There are calls in progress." @@ -176,7 +176,7 @@ msgstr "Chiudi la chiamata" msgid "" "A %s error forced the call with %s to fall under unencrypted mode.\n" "Exact reason: %s\n" -msgstr "Un errore %s ha provocato il passaggio della chiamata %s in modalit� non sicura.\n" +msgstr "Un errore %s ha provocato il passaggio della chiamata %s in modalità non sicura.\n" "Motivo esatto: %s\n" #: ../sflphone-client-gnome/src/mainwindow.c:414 @@ -188,7 +188,7 @@ msgstr "Negoziazione ZRTP fallita" msgid "" "%s wants to stop using secure communication. Confirm will resume " "conversation without SRTP.\n" -msgstr "%s vuole terminare l'uso della comunicazione sicura. Conferma ripristiner� " +msgstr "%s vuole terminare l'uso della comunicazione sicura. Conferma ripristinerà " "la converazione senza SRTP.\n" #: ../sflphone-client-gnome/src/mainwindow.c:428 @@ -281,7 +281,7 @@ msgstr "Segreteria telefonica" #: ../sflphone-client-gnome/src/uimanager.c:403 msgid "SFLphone is a VoIP client compatible with SIP and IAX2 protocols." -msgstr "SFLphone è un client VoIP compatibile con i protocolli SIP e IAX2." +msgstr "SFLphone è un client VoIP compatibile con i protocolli SIP e IAX2." #: ../sflphone-client-gnome/src/uimanager.c:406 msgid "About SFLphone" @@ -495,7 +495,7 @@ msgstr "" #: ../sflphone-client-gnome/src/config/accountlistconfigdialog.c:506 msgid "is " -msgstr "�" +msgstr "è" #: ../sflphone-client-gnome/src/config/accountlistconfigdialog.c:506 msgid "are " @@ -566,7 +566,7 @@ msgstr "Nome" #: ../sflphone-client-gnome/src/config/assistant.c:69 #, c-format msgid "This assistant is now finished." -msgstr "La procedura guidata � terminata." +msgstr "La procedura guidata è terminata." #: ../sflphone-client-gnome/src/config/assistant.c:71 msgid "" @@ -611,7 +611,7 @@ msgstr "" #: ../sflphone-client-gnome/src/config/assistant.c:237 msgid "This installation wizard will help you configure an account." -msgstr "Questa procedura di installazione permetter� di configurare un account." +msgstr "Questa procedura di installazione permetterà di configurare un account." #: ../sflphone-client-gnome/src/config/assistant.c:251 msgid "VoIP Protocols" @@ -666,7 +666,7 @@ msgstr "Indirizzo email opzionale" #: ../sflphone-client-gnome/src/config/assistant.c:365 msgid "This email address will be used to send your voicemail messages." msgstr "" -"L'indirizzo email sarà usato per l'invio dei messaggi della segreteria " +"L'indirizzo email sarà usato per l'invio dei messaggi della segreteria " "telefonica." #: ../sflphone-client-gnome/src/config/assistant.c:373 @@ -727,7 +727,7 @@ msgstr "Ingresso" #: ../sflphone-client-gnome/src/config/audioconf.c:752 msgid "_Voice Activity Detection" -msgstr "Rilevazione dell'attivit� _Voce" +msgstr "Rilevazione dell'attività _Voce" #: ../sflphone-client-gnome/src/config/audioconf.c:762 msgid "_Noise Reduction (Narrow-Band Companding)" @@ -824,7 +824,7 @@ msgid "" "sip URI such as <b>sip:remotepeer</b>. The settings you define here will " "also be used if no account can be matched to an incoming or outgoing call." msgstr "" -"Questo profilo � utilizzato quando vuoi raggiungere un nodo remoto semplicemente digitando un " +"Questo profilo è utilizzato quando vuoi raggiungere un nodo remoto semplicemente digitando un " "URI sip tipo <b>sip:remotepeer</b>. Le configurazione che definisci qui saranno " "usate anche se nessun account corrisponde ad una chiamata in ingresso o in uscita." @@ -920,14 +920,14 @@ msgid "" "dedicated\n" "port, different one from each other\n" msgstr "" -"Il trasporto TLS pu� essere utilizzato con UDP per le chiamate che\n" +"Il trasporto TLS può essere utilizzato con UDP per le chiamate che\n" "richiedono transazioni sip sicure (aka SIPS). Puoi configurare un trasporto\n" -"TLS diverso per ognia account. Tuttavia, ognuino di essi girer� su una " +"TLS diverso per ognia account. Tuttavia, ognuino di essi girerà su una " "porta dedicata, differente dalle altre\n" #: ../sflphone-client-gnome/src/config/tlsadvanceddialog.c:100 msgid "Certificate of Authority list" -msgstr "Lista delle Autorit� di certificazione" +msgstr "Lista delle Autorità di certificazione" #: ../sflphone-client-gnome/src/config/tlsadvanceddialog.c:104 msgid "Choose a CA list file (optional)" @@ -971,7 +971,7 @@ msgstr "Verifica certificati in ingresso, come server" #: ../sflphone-client-gnome/src/config/tlsadvanceddialog.c:242 msgid "Verify certificates from answer, as a client" -msgstr "Verifica certificati nella risposta, come client"" +msgstr "Verifica certificati nella risposta, come client" #: ../sflphone-client-gnome/src/config/tlsadvanceddialog.c:248 msgid "Require certificate for incoming tls connections" @@ -991,7 +991,7 @@ msgstr "Chiedi all'utente di confermare SAS" #: ../sflphone-client-gnome/src/config/zrtpadvanceddialog.c:80 msgid "_Warn if ZRTP not supported" -msgstr "Notifica se ZRTP non � supportato" +msgstr "Notifica se ZRTP non è supportato" #: ../sflphone-client-gnome/src/config/zrtpadvanceddialog.c:86 msgid "Display SAS once for hold events" @@ -1023,8 +1023,8 @@ msgstr "Cerca tra le chiamate effettuate" #~ msgid "(C) 2009 Savoir-faire Linux" #~ msgstr "(C) 2009 Savoir-faire Linux" -#~ msgid "Jérémy Quentin" -#~ msgstr "Jérémy Quentin" +#~ msgid "Jérémy Quentin" +#~ msgstr "Jérémy Quentin" #~ msgid "Address book" #~ msgstr "Rubrica" @@ -1057,7 +1057,7 @@ msgstr "Cerca tra le chiamate effettuate" #~ msgstr "Applica" #~ msgid "Down" -#~ msgstr "Gi�" +#~ msgstr "Giù" #~ msgid "Up" #~ msgstr "Su" @@ -1195,11 +1195,11 @@ msgstr "Cerca tra le chiamate effettuate" #~ "Pressing \"apply\" will restart the network layer. Otherwise, SFLPhone would " #~ "have to be restarted." #~ msgstr "" -#~ "Premendo il tasto \"Applica\" il modulo di rete verr� riavviato. In " +#~ "Premendo il tasto \"Applica\" il modulo di rete verrà riavviato. In " #~ "alternativa occorrerebbe riavviare SFLphone." #~ msgid "Creation of account has failed for the reason" -#~ msgstr "La creazione dell'account è fallita per il seguente motivo" +#~ msgstr "La creazione dell'account è fallita per il seguente motivo" #~ msgid "Account creation wizard" #~ msgstr "Procedura guidata creazione account" diff --git a/sflphone-client-gnome/po/it/it.po b/sflphone-client-gnome/po/it/it.po index 84a53d0b6618d0dffbdeb595869318047ef77618..88fc58458f6e365dd5d030203af3e1d5057ccf11 100644 --- a/sflphone-client-gnome/po/it/it.po +++ b/sflphone-client-gnome/po/it/it.po @@ -103,7 +103,7 @@ msgid "" "</b> SFL audio codecs have to be placed in <i>%s</i> or in the " "<b>.sflphone</b> directory in your home( <i>%s</i> )" msgstr "" -"<b>Errore: Non è stato trovato alcun codec audio.</b>\n" +"<b>Errore: Non è stato trovato alcun codec audio.</b>\n" "\n" "I codec audio SFL devono trovarsi in <i>%s</i> o nella sottocartella " "<b>.sflphone</b> della cartella home dell'utente (</i>%s</i>)" @@ -133,11 +133,11 @@ msgid "" "Pulseaudio is not running" msgstr "" "Notifica PulseAudio\n" -"PulseAudio non è in esecuzione" +"PulseAudio non è in esecuzione" #: ../sflphone-client-gnome/src/mainwindow.c:73 msgid "There is one call in progress." -msgstr "C'è una chiamata in corso." +msgstr "C'è una chiamata in corso." #: ../sflphone-client-gnome/src/mainwindow.c:77 msgid "There are calls in progress." @@ -176,7 +176,7 @@ msgstr "Chiudi la chiamata" msgid "" "A %s error forced the call with %s to fall under unencrypted mode.\n" "Exact reason: %s\n" -msgstr "Un errore %s ha provocato il passaggio della chiamata %s in modalit� non sicura.\n" +msgstr "Un errore %s ha provocato il passaggio della chiamata %s in modalità non sicura.\n" "Motivo esatto: %s\n" #: ../sflphone-client-gnome/src/mainwindow.c:414 @@ -188,7 +188,7 @@ msgstr "Negoziazione ZRTP fallita" msgid "" "%s wants to stop using secure communication. Confirm will resume " "conversation without SRTP.\n" -msgstr "%s vuole terminare l'uso della comunicazione sicura. Conferma ripristiner� " +msgstr "%s vuole terminare l'uso della comunicazione sicura. Conferma ripristinerà " "la converazione senza SRTP.\n" #: ../sflphone-client-gnome/src/mainwindow.c:428 @@ -281,7 +281,7 @@ msgstr "Segreteria telefonica" #: ../sflphone-client-gnome/src/uimanager.c:403 msgid "SFLphone is a VoIP client compatible with SIP and IAX2 protocols." -msgstr "SFLphone è un client VoIP compatibile con i protocolli SIP e IAX2." +msgstr "SFLphone è un client VoIP compatibile con i protocolli SIP e IAX2." #: ../sflphone-client-gnome/src/uimanager.c:406 msgid "About SFLphone" @@ -495,7 +495,7 @@ msgstr "" #: ../sflphone-client-gnome/src/config/accountlistconfigdialog.c:506 msgid "is " -msgstr "�" +msgstr "è" #: ../sflphone-client-gnome/src/config/accountlistconfigdialog.c:506 msgid "are " @@ -566,7 +566,7 @@ msgstr "Nome" #: ../sflphone-client-gnome/src/config/assistant.c:69 #, c-format msgid "This assistant is now finished." -msgstr "La procedura guidata � terminata." +msgstr "La procedura guidata è terminata." #: ../sflphone-client-gnome/src/config/assistant.c:71 msgid "" @@ -611,7 +611,7 @@ msgstr "" #: ../sflphone-client-gnome/src/config/assistant.c:237 msgid "This installation wizard will help you configure an account." -msgstr "Questa procedura di installazione permetter� di configurare un account." +msgstr "Questa procedura di installazione permetterà di configurare un account." #: ../sflphone-client-gnome/src/config/assistant.c:251 msgid "VoIP Protocols" @@ -666,7 +666,7 @@ msgstr "Indirizzo email opzionale" #: ../sflphone-client-gnome/src/config/assistant.c:365 msgid "This email address will be used to send your voicemail messages." msgstr "" -"L'indirizzo email sarà usato per l'invio dei messaggi della segreteria " +"L'indirizzo email sarà usato per l'invio dei messaggi della segreteria " "telefonica." #: ../sflphone-client-gnome/src/config/assistant.c:373 @@ -727,7 +727,7 @@ msgstr "Ingresso" #: ../sflphone-client-gnome/src/config/audioconf.c:752 msgid "_Voice Activity Detection" -msgstr "Rilevazione dell'attivit� _Voce" +msgstr "Rilevazione dell'attività _Voce" #: ../sflphone-client-gnome/src/config/audioconf.c:762 msgid "_Noise Reduction (Narrow-Band Companding)" @@ -824,7 +824,7 @@ msgid "" "sip URI such as <b>sip:remotepeer</b>. The settings you define here will " "also be used if no account can be matched to an incoming or outgoing call." msgstr "" -"Questo profilo � utilizzato quando vuoi raggiungere un nodo remoto semplicemente digitando un " +"Questo profilo è utilizzato quando vuoi raggiungere un nodo remoto semplicemente digitando un " "URI sip tipo <b>sip:remotepeer</b>. Le configurazione che definisci qui saranno " "usate anche se nessun account corrisponde ad una chiamata in ingresso o in uscita." @@ -920,14 +920,14 @@ msgid "" "dedicated\n" "port, different one from each other\n" msgstr "" -"Il trasporto TLS pu� essere utilizzato con UDP per le chiamate che\n" +"Il trasporto TLS può essere utilizzato con UDP per le chiamate che\n" "richiedono transazioni sip sicure (aka SIPS). Puoi configurare un trasporto\n" -"TLS diverso per ognia account. Tuttavia, ognuino di essi girer� su una " +"TLS diverso per ognia account. Tuttavia, ognuino di essi girerà su una " "porta dedicata, differente dalle altre\n" #: ../sflphone-client-gnome/src/config/tlsadvanceddialog.c:100 msgid "Certificate of Authority list" -msgstr "Lista delle Autorit� di certificazione" +msgstr "Lista delle Autorità di certificazione" #: ../sflphone-client-gnome/src/config/tlsadvanceddialog.c:104 msgid "Choose a CA list file (optional)" @@ -971,7 +971,7 @@ msgstr "Verifica certificati in ingresso, come server" #: ../sflphone-client-gnome/src/config/tlsadvanceddialog.c:242 msgid "Verify certificates from answer, as a client" -msgstr "Verifica certificati nella risposta, come client"" +msgstr "Verifica certificati nella risposta, come client" #: ../sflphone-client-gnome/src/config/tlsadvanceddialog.c:248 msgid "Require certificate for incoming tls connections" @@ -991,7 +991,7 @@ msgstr "Chiedi all'utente di confermare SAS" #: ../sflphone-client-gnome/src/config/zrtpadvanceddialog.c:80 msgid "_Warn if ZRTP not supported" -msgstr "Notifica se ZRTP non � supportato" +msgstr "Notifica se ZRTP non è supportato" #: ../sflphone-client-gnome/src/config/zrtpadvanceddialog.c:86 msgid "Display SAS once for hold events" @@ -1023,8 +1023,8 @@ msgstr "Cerca tra le chiamate effettuate" #~ msgid "(C) 2009 Savoir-faire Linux" #~ msgstr "(C) 2009 Savoir-faire Linux" -#~ msgid "Jérémy Quentin" -#~ msgstr "Jérémy Quentin" +#~ msgid "Jérémy Quentin" +#~ msgstr "Jérémy Quentin" #~ msgid "Address book" #~ msgstr "Rubrica" @@ -1057,7 +1057,7 @@ msgstr "Cerca tra le chiamate effettuate" #~ msgstr "Applica" #~ msgid "Down" -#~ msgstr "Gi�" +#~ msgstr "Giù" #~ msgid "Up" #~ msgstr "Su" @@ -1195,11 +1195,11 @@ msgstr "Cerca tra le chiamate effettuate" #~ "Pressing \"apply\" will restart the network layer. Otherwise, SFLPhone would " #~ "have to be restarted." #~ msgstr "" -#~ "Premendo il tasto \"Applica\" il modulo di rete verr� riavviato. In " +#~ "Premendo il tasto \"Applica\" il modulo di rete verrà riavviato. In " #~ "alternativa occorrerebbe riavviare SFLphone." #~ msgid "Creation of account has failed for the reason" -#~ msgstr "La creazione dell'account è fallita per il seguente motivo" +#~ msgstr "La creazione dell'account è fallita per il seguente motivo" #~ msgid "Account creation wizard" #~ msgstr "Procedura guidata creazione account" diff --git a/sflphone-client-gnome/src/mainwindow.c b/sflphone-client-gnome/src/mainwindow.c index 22e34cfb840926edaba1dc6fddc2e06d6a10ffea..2c655ccfbbe86bdd2489f9d6dcc0e57982109efb 100644 --- a/sflphone-client-gnome/src/mainwindow.c +++ b/sflphone-client-gnome/src/mainwindow.c @@ -146,13 +146,14 @@ create_main_window () gchar *path; GError *error = NULL; gboolean ret; + const char *window_title = "SFLphone VoIP Client"; focus_is_on_calltree = FALSE; focus_is_on_searchbar = FALSE; window = gtk_window_new (GTK_WINDOW_TOPLEVEL); gtk_container_set_border_width (GTK_CONTAINER (window), 0); - gtk_window_set_title (GTK_WINDOW (window), PACKAGE); + gtk_window_set_title (GTK_WINDOW (window), window_title); gtk_window_set_default_size (GTK_WINDOW (window), MAIN_WINDOW_WIDTH, MAIN_WINDOW_HEIGHT); gtk_window_set_default_icon_from_file (LOGO, NULL); @@ -198,7 +199,13 @@ create_main_window () gtk_box_pack_start (GTK_BOX (vbox), widget, FALSE /*expand*/, TRUE /*fill*/, 0 /*padding*/); widget = create_toolbar_actions (ui_manager); - gtk_toolbar_set_style (GTK_TOOLBAR (widget), GTK_TOOLBAR_BOTH); + // Do not override GNOME user settings + // gtk_toolbar_set_style (GTK_TOOLBAR (widget), GTK_TOOLBAR_BOTH); + gtk_box_pack_start (GTK_BOX (vbox), widget, FALSE /*expand*/, TRUE /*fill*/, 0 /*padding*/); + + widget = create_toolbar_windows (ui_manager); + // Do not override GNOME user settings + //gtk_toolbar_set_style (GTK_TOOLBAR (widget), GTK_TOOLBAR_ICONS); gtk_box_pack_start (GTK_BOX (vbox), widget, FALSE /*expand*/, TRUE /*fill*/, 0 /*padding*/); gtk_box_pack_start (GTK_BOX (vbox), current_calls->tree, TRUE /*expand*/, TRUE /*fill*/, 0 /*padding*/); @@ -211,10 +218,6 @@ create_main_window () gtk_box_pack_start(GTK_BOX(subvbox), GTK_WIDGET(embedded_error_notebook), FALSE, FALSE, 0); - widget = create_toolbar_windows (ui_manager); - gtk_toolbar_set_style (GTK_TOOLBAR (widget), GTK_TOOLBAR_ICONS); - gtk_box_pack_start (GTK_BOX (vbox), widget, FALSE /*expand*/, TRUE /*fill*/, 0 /*padding*/); - if(SHOW_VOLUME){ speaker_control = create_slider("speaker"); gtk_box_pack_end (GTK_BOX (subvbox), speaker_control, FALSE /*expand*/, TRUE /*fill*/, 0 /*padding*/); diff --git a/sflphone-client-gnome/src/mainwindow.h b/sflphone-client-gnome/src/mainwindow.h index aea6763bcff63ea1dd6ec2b776b3f4b30730173a..98806a527d27732ce5fb3a0b0952dd404b133cc5 100644 --- a/sflphone-client-gnome/src/mainwindow.h +++ b/sflphone-client-gnome/src/mainwindow.h @@ -24,7 +24,7 @@ #include <calltree.h> #include <uimanager.h> -#define MAIN_WINDOW_WIDTH 400 +#define MAIN_WINDOW_WIDTH 280 #define MAIN_WINDOW_HEIGHT 320 /** @file mainwindow.h diff --git a/sflphone-client-gnome/src/ui.xml b/sflphone-client-gnome/src/ui.xml index 7ca6067abd61bc9caf2eace3200ae0695c888d56..97b865b044f28839eac5dc461af13d6f7ba66156 100644 --- a/sflphone-client-gnome/src/ui.xml +++ b/sflphone-client-gnome/src/ui.xml @@ -47,18 +47,19 @@ <toolbar name="ToolbarActions"> <toolitem name="NewCallToolbar" action="NewCall"/> <toolitem name="PickUpToolbar" action="PickUp"/> - <toolitem action="HangUp"/> + <toolitem name="HangUpToolbar" action="HangUp"/> <toolitem name="OnHoldToolbar" action="OnHold"/> <toolitem name="OffHoldToolbar" action="OffHold"/> <toolitem name="TransferToolbar" action="Transfer"/> + <toolitem name="RecordToolbar" action="Record"/> <separator/> - <toolitem action="Voicemail"/> + <toolitem name="VoicemailToolbar" action="Voicemail"/> + <toolitem name="HistoryToolbar" action="History"/> + <toolitem name="AddressbookToolbar" action="Addressbook"/> </toolbar> <toolbar name="ToolbarWindows"> - <toolitem name="CallWindowToolbar" action="CallWindow"/> - <toolitem name="HistoryToolbar" action="History"/> - <toolitem name="AddressbookToolbar" action="Addressbook"/> + <!--toolitem name="CallWindowToolbar" action="CallWindow"/--> </toolbar> </ui> diff --git a/sflphone-client-gnome/src/uimanager.c b/sflphone-client-gnome/src/uimanager.c index e7d0c2c584675a58aadbd6c5c56ed92104d2da61..26effb27cdb41e166171e87e6c1c4415c03f19fa 100644 --- a/sflphone-client-gnome/src/uimanager.c +++ b/sflphone-client-gnome/src/uimanager.c @@ -38,6 +38,7 @@ GtkWidget * pickUpWidget; GtkAction * newCallAction; GtkWidget * newCallWidget; GtkAction * hangUpAction; +GtkWidget * hangUpWidget; GtkWidget * holdMenu; GtkWidget * holdToolbar; GtkWidget * offHoldToolbar; @@ -45,7 +46,9 @@ GtkWidget * transferToolbar; GtkAction * copyAction; GtkAction * pasteAction; GtkAction * recordAction; +GtkWidget * recordWidget; GtkAction * voicemailAction; +GtkWidget * voicemailToolbar; GtkWidget * editable_num; GtkDialog * edit_dialog; @@ -214,30 +217,53 @@ void update_actions() gtk_action_set_sensitive( GTK_ACTION (newCallAction), TRUE); gtk_action_set_sensitive (GTK_ACTION (pickUpAction), FALSE); gtk_action_set_sensitive (GTK_ACTION (hangUpAction), FALSE); + + g_object_ref (hangUpWidget); + g_object_ref (recordWidget); + g_object_ref (holdToolbar); + g_object_ref (offHoldToolbar); + g_object_ref (contactButton); + g_object_ref (transferToolbar); + g_object_ref (voicemailToolbar); + + if (is_inserted (GTK_WIDGET(hangUpWidget), GTK_WIDGET (toolbar))) + { + gtk_container_remove (GTK_CONTAINER (toolbar), GTK_WIDGET (hangUpWidget)); + } + + if (is_inserted (GTK_WIDGET(recordWidget), GTK_WIDGET (toolbar))) + { + gtk_container_remove (GTK_CONTAINER (toolbar), GTK_WIDGET (recordWidget)); + } + + if (is_inserted (GTK_WIDGET(transferToolbar), GTK_WIDGET (toolbar))) + { + gtk_container_remove (GTK_CONTAINER (toolbar), GTK_WIDGET (transferToolbar)); + } + + if (is_inserted (GTK_WIDGET(contactButton), GTK_WIDGET (toolbar))) + { + gtk_container_remove (GTK_CONTAINER (toolbar), GTK_WIDGET (contactButton)); + } + + if (is_inserted (GTK_WIDGET (voicemailToolbar), GTK_WIDGET (toolbar))) + { + gtk_container_remove (GTK_CONTAINER (toolbar), GTK_WIDGET (voicemailToolbar)); + } + gtk_widget_set_sensitive (GTK_WIDGET (holdMenu), FALSE); gtk_widget_set_sensitive (GTK_WIDGET (holdToolbar), FALSE); gtk_widget_set_sensitive (GTK_WIDGET (offHoldToolbar), FALSE); gtk_action_set_sensitive (GTK_ACTION (recordAction), FALSE); gtk_action_set_sensitive (GTK_ACTION (copyAction), FALSE); - gtk_action_set_sensitive (GTK_ACTION (voicemailAction), FALSE); - gtk_widget_set_sensitive (GTK_WIDGET (transferToolbar), FALSE); + //gtk_action_set_sensitive (GTK_ACTION (voicemailAction), FALSE); gtk_widget_set_sensitive( GTK_WIDGET(contactButton), FALSE); gtk_widget_set_tooltip_text (GTK_WIDGET (contactButton), _("No address book selected")); - g_object_ref (holdToolbar); - g_object_ref (offHoldToolbar); - - g_object_ref (contactButton); - if (is_inserted (GTK_WIDGET(contactButton), GTK_WIDGET (toolbarWindows))) - { - gtk_container_remove (GTK_CONTAINER (toolbarWindows), GTK_WIDGET (contactButton)); - } - if (is_inserted (GTK_WIDGET (holdToolbar), GTK_WIDGET (toolbar))) gtk_container_remove (GTK_CONTAINER (toolbar), GTK_WIDGET (holdToolbar)); if (is_inserted (GTK_WIDGET (offHoldToolbar), GTK_WIDGET (toolbar))) gtk_container_remove (GTK_CONTAINER (toolbar), GTK_WIDGET (offHoldToolbar)); - gtk_toolbar_insert (GTK_TOOLBAR (toolbar), GTK_TOOL_ITEM (holdToolbar), 3); if (is_inserted (GTK_WIDGET (newCallWidget), GTK_WIDGET (toolbar))) gtk_container_remove (GTK_CONTAINER (toolbar), GTK_WIDGET (newCallWidget)); @@ -246,8 +272,8 @@ void update_actions() gtk_toolbar_insert (GTK_TOOLBAR (toolbar), GTK_TOOL_ITEM (newCallWidget), 0); // If addressbook support has been enabled and all addressbooks are loaded, display the icon - if (addressbook_is_enabled () && addressbook_is_ready()) { - gtk_toolbar_insert (GTK_TOOLBAR (toolbarWindows), GTK_TOOL_ITEM (contactButton), 2); + if (addressbook_is_enabled () && addressbook_is_ready ()) { + gtk_toolbar_insert (GTK_TOOLBAR (toolbar), GTK_TOOL_ITEM (contactButton), -1); // Make the icon clickable only if at least one address book is active if (addressbook_is_active ()) { @@ -277,6 +303,7 @@ void update_actions() g_object_ref (newCallWidget); gtk_container_remove (GTK_CONTAINER (toolbar), GTK_WIDGET(newCallWidget)); gtk_toolbar_insert (GTK_TOOLBAR (toolbar), GTK_TOOL_ITEM (pickUpWidget), 0); + gtk_toolbar_insert (GTK_TOOLBAR (toolbar), GTK_TOOL_ITEM (hangUpWidget), 1); break; case CALL_STATE_HOLD: gtk_action_set_sensitive (GTK_ACTION (hangUpAction), TRUE); @@ -286,11 +313,13 @@ void update_actions() // Replace the hold button with the off-hold button //g_object_ref (holdToolbar); gtk_container_remove (GTK_CONTAINER (toolbar), GTK_WIDGET(holdToolbar)); - gtk_toolbar_insert (GTK_TOOLBAR(toolbar), GTK_TOOL_ITEM (offHoldToolbar), 3); + gtk_toolbar_insert (GTK_TOOLBAR (toolbar), GTK_TOOL_ITEM (hangUpWidget), 1); + gtk_toolbar_insert (GTK_TOOLBAR(toolbar), GTK_TOOL_ITEM (offHoldToolbar), 2); break; case CALL_STATE_RINGING: gtk_action_set_sensitive (GTK_ACTION (pickUpAction), TRUE); gtk_action_set_sensitive (GTK_ACTION (hangUpAction), TRUE); + gtk_toolbar_insert (GTK_TOOLBAR (toolbar), GTK_TOOL_ITEM (hangUpWidget), 1); break; case CALL_STATE_DIALING: gtk_action_set_sensitive (GTK_ACTION(pickUpAction), TRUE); @@ -299,16 +328,21 @@ void update_actions() g_object_ref (newCallWidget); gtk_container_remove (GTK_CONTAINER (toolbar), GTK_WIDGET (newCallWidget)); gtk_toolbar_insert (GTK_TOOLBAR (toolbar), GTK_TOOL_ITEM (pickUpWidget), 0); + if (active_calltree == current_calls) gtk_toolbar_insert (GTK_TOOLBAR (toolbar), GTK_TOOL_ITEM (hangUpWidget), 1); break; case CALL_STATE_CURRENT: case CALL_STATE_RECORD: gtk_action_set_sensitive (GTK_ACTION (hangUpAction), TRUE); + gtk_toolbar_insert (GTK_TOOLBAR (toolbar), GTK_TOOL_ITEM (hangUpWidget), 1); gtk_widget_set_sensitive (GTK_WIDGET (holdMenu), TRUE); gtk_widget_set_sensitive (GTK_WIDGET (holdToolbar), TRUE); //gtk_image_menu_item_set_image (GTK_IMAGE_MENU_ITEM (holdMenu), gtk_image_new_from_stock (GTK_STOCK_ONHOLD, GTK_ICON_SIZE_MENU)); gtk_widget_set_sensitive (GTK_WIDGET (transferToolbar), TRUE); //gtk_action_set_sensitive( GTK_ACTION(newCallMenu),TRUE); gtk_action_set_sensitive( GTK_ACTION (recordAction), TRUE); + gtk_toolbar_insert (GTK_TOOLBAR (toolbar), GTK_TOOL_ITEM (holdToolbar), 2); + gtk_toolbar_insert (GTK_TOOLBAR (toolbar), GTK_TOOL_ITEM (transferToolbar), 3); + gtk_toolbar_insert (GTK_TOOLBAR (toolbar), GTK_TOOL_ITEM (recordWidget), 4); gtk_signal_handler_block (GTK_OBJECT (transferToolbar), transfertButtonConnId); gtk_toggle_tool_button_set_active (GTK_TOGGLE_TOOL_BUTTON (transferToolbar), FALSE); gtk_signal_handler_unblock (transferToolbar, transfertButtonConnId); @@ -316,8 +350,11 @@ void update_actions() case CALL_STATE_BUSY: case CALL_STATE_FAILURE: gtk_action_set_sensitive( GTK_ACTION(hangUpAction), TRUE); + gtk_toolbar_insert (GTK_TOOLBAR (toolbar), GTK_TOOL_ITEM (hangUpWidget), 1); break; case CALL_STATE_TRANSFERT: + gtk_toolbar_insert (GTK_TOOLBAR (toolbar), GTK_TOOL_ITEM (hangUpWidget), 1); + gtk_toolbar_insert (GTK_TOOLBAR (toolbar), GTK_TOOL_ITEM (transferToolbar), 2); gtk_signal_handler_block (GTK_OBJECT (transferToolbar), transfertButtonConnId); gtk_toggle_tool_button_set_active (GTK_TOGGLE_TOOL_BUTTON (transferToolbar), TRUE); gtk_signal_handler_unblock (transferToolbar, transfertButtonConnId); @@ -334,6 +371,7 @@ void update_actions() else if(selectedConf) { + /* switch(selectedConf->_state) { case CONFERENCE_STATE_ACTIVE_ATACHED: @@ -351,6 +389,7 @@ void update_actions() default: break; } + */ } else @@ -359,7 +398,7 @@ void update_actions() { //gtk_widget_set_sensitive (GTK_WIDGET(callButton), TRUE); if (account_list_current_account_has_mailbox ()) - gtk_action_set_sensitive (GTK_ACTION (voicemailAction), TRUE); + gtk_toolbar_insert (GTK_TOOLBAR (toolbar), GTK_TOOL_ITEM (voicemailToolbar), -2); } else { @@ -731,6 +770,7 @@ static void clear_history (void) } } +/* static void calltree_switch_cb (GtkRadioAction *action, GtkRadioAction *current) { gint value = gtk_radio_action_get_current_value (current); @@ -750,30 +790,16 @@ static void calltree_switch_cb (GtkRadioAction *action, GtkRadioAction *current) break; } } +*/ + /** * Transfert the line */ static void call_transfer_cb () { - g_print ("call transfer cd !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!\n"); gboolean active = gtk_toggle_tool_button_get_active (GTK_TOGGLE_TOOL_BUTTON (transferToolbar)); - //g_print ("vsmb;dbfmd; bm: %i\n", active); active ? sflphone_set_transfert() : sflphone_unset_transfert() ; - /*callable_obj_t * selectedCall = calltab_get_selected_call(current_calls); - - - if(selectedCall) - { - if(selectedCall->_state == CALL_STATE_TRANSFERT) - { - sflphone_unset_transfert (); - } - else - { - sflphone_set_transfert (); - } - }*/ } static void call_mailbox_cb (void) @@ -798,6 +824,20 @@ static void call_mailbox_cb (void) calltree_display(current_calls); } +static void toggle_history_cb (GtkToggleAction *action, gpointer user_data) +{ + gboolean toggle; + toggle = gtk_toggle_action_get_active (action); + (toggle)? calltree_display (history) : calltree_display (current_calls); +} + +static void toggle_addressbook_cb (GtkToggleAction *action, gpointer user_data) +{ + gboolean toggle; + toggle = gtk_toggle_action_get_active (action); + (toggle)? calltree_display (contacts) : calltree_display (current_calls); +} + static const GtkActionEntry menu_entries[] = { // Call Menu @@ -836,17 +876,20 @@ static const GtkToggleActionEntry toggle_menu_entries[] = { { "Transfer", GTK_STOCK_TRANSFER, "_Transfer", "<control>T", "Transfer the call", NULL }, //G_CALLBACK (call_transfer_cb) }, { "Toolbar", NULL, "_Show toolbar", "<control>T", "Show the toolbar", NULL }, { "Dialpad", NULL, "_Dialpad", "<control>D", "Show the dialpad", G_CALLBACK (dialpad_bar_cb) }, - { "VolumeControls",NULL, "_Volume controls", "<control>V", "Show the volume controls", G_CALLBACK (volume_bar_cb) } + { "VolumeControls",NULL, "_Volume controls", "<control>V", "Show the volume controls", G_CALLBACK (volume_bar_cb) }, + { "History", "appointment-soon", "_History", NULL, "Calls history", G_CALLBACK (toggle_history_cb), FALSE}, + { "Addressbook", GTK_STOCK_ADDRESSBOOK, "_Address book", NULL, "Address book", G_CALLBACK (toggle_addressbook_cb), FALSE} }; +/* static const GtkRadioActionEntry radio_menu_entries[] = { {"CallWindow", GTK_STOCK_CALLS, "_Call window", NULL, "Calls list", CALLTREE_CALLS}, - {"History", "appointment-soon", "_History", NULL, "Calls history", CALLTREE_HISTORY}, - {"Addressbook", GTK_STOCK_ADDRESSBOOK, "_Address book", NULL, NULL, CALLTREE_CONTACTS} }; +*/ + gboolean uimanager_new (GtkUIManager **_ui_manager) { @@ -891,7 +934,7 @@ gboolean uimanager_new (GtkUIManager **_ui_manager) { gtk_action_group_set_translation_domain (action_group, "sflphone-client-gnome"); gtk_action_group_add_actions (action_group, menu_entries, G_N_ELEMENTS (menu_entries), window); gtk_action_group_add_toggle_actions (action_group, toggle_menu_entries, G_N_ELEMENTS (toggle_menu_entries), window); - gtk_action_group_add_radio_actions (action_group, radio_menu_entries, G_N_ELEMENTS (radio_menu_entries), CALLTREE_CALLS, G_CALLBACK (calltree_switch_cb), window); + //gtk_action_group_add_radio_actions (action_group, radio_menu_entries, G_N_ELEMENTS (radio_menu_entries), CALLTREE_CALLS, G_CALLBACK (calltree_switch_cb), window); gtk_ui_manager_insert_action_group (ui_manager, action_group, 0); *_ui_manager = ui_manager; @@ -1424,12 +1467,18 @@ GtkWidget* create_toolbar_actions (GtkUIManager *ui_manager) offHoldToolbar = gtk_ui_manager_get_widget (ui_manager, "/ToolbarActions/OffHoldToolbar"); transferToolbar = gtk_ui_manager_get_widget (ui_manager, "/ToolbarActions/TransferToolbar"); voicemailAction = gtk_ui_manager_get_action (ui_manager, "/ToolbarActions/Voicemail"); + voicemailToolbar = gtk_ui_manager_get_widget (ui_manager, "/ToolbarActions/VoicemailToolbar"); newCallWidget = gtk_ui_manager_get_widget (ui_manager, "/ToolbarActions/NewCallToolbar"); pickUpWidget = gtk_ui_manager_get_widget (ui_manager, "/ToolbarActions/PickUpToolbar"); + hangUpWidget = gtk_ui_manager_get_widget (ui_manager, "/ToolbarActions/HangUpToolbar"); + recordWidget = gtk_ui_manager_get_widget (ui_manager, "/ToolbarActions/RecordToolbar"); + historyButton = gtk_ui_manager_get_widget (ui_manager, "/ToolbarActions/HistoryToolbar"); + contactButton = gtk_ui_manager_get_widget (ui_manager, "/ToolbarActions/AddressbookToolbar"); + //currentCallsButton = gtk_ui_manager_get_widget (ui_manager, "/ToolbarActions/CallWindowToolbar"); // Set the handler ID for the transfer transfertButtonConnId = g_signal_connect (G_OBJECT (transferToolbar), "toggled", G_CALLBACK (call_transfer_cb), NULL); - // holdConnId = g_signal_connect (G_OBJECT (holdToolbar), "toggled", G_CALLBACK (call_hold), NULL); + active_calltree = current_calls; return toolbar; } @@ -1439,9 +1488,9 @@ GtkWidget* create_toolbar_windows (GtkUIManager *ui_manager) toolbarWindows = gtk_ui_manager_get_widget (ui_manager, "/ToolbarWindows"); active_calltree = current_calls; - historyButton = gtk_ui_manager_get_widget (ui_manager, "/ToolbarWindows/HistoryToolbar"); + /*historyButton = gtk_ui_manager_get_widget (ui_manager, "/ToolbarWindows/HistoryToolbar"); contactButton = gtk_ui_manager_get_widget (ui_manager, "/ToolbarWindows/AddressbookToolbar"); currentCallsButton = gtk_ui_manager_get_widget (ui_manager, "/ToolbarWindows/CallWindowToolbar"); - + */ return toolbarWindows; }