Commit 6e8baecb authored by Julien Bonjean's avatar Julien Bonjean

Merge branch 'master' into jbonjean

Conflicts:
	sflphone-common/src/sip/sipvoiplink.cpp
parents 89a759c7 f54d4220
......@@ -7,7 +7,10 @@ GNOME_DOC=gnome-doc-utils.make
log4crc_DATA = log4crc
log4crcdir = $(datadir)/sflphone
EXTRA_DIST = $(log4crc_DATA) sflphone.desktop.in $(GNOME_DOC) m4
uidir=$(DESTDIR)$(datadir)/sflphone/ui
ui_DATA=src/ui.xml
EXTRA_DIST = $(log4crc_DATA) sflphone.desktop.in $(GNOME_DOC) m4 $(UI_DATA)
appsdir = $(datadir)/applications
apps_in_files = sflphone.desktop.in
apps_DATA = $(apps_in_files:.desktop.in=.desktop)
......
/* config.h.in. Generated from configure.ac by autoheader. */
/* Define to 1 if you have the <dlfcn.h> header file. */
#undef HAVE_DLFCN_H
/* Define to 1 if you have the <inttypes.h> header file. */
#undef HAVE_INTTYPES_H
/* Define to 1 if you have the <log4c.h> header file. */
#undef HAVE_LOG4C_H
/* Define to 1 if you have the <memory.h> header file. */
#undef HAVE_MEMORY_H
/* Define to 1 if you have the <stdint.h> header file. */
#undef HAVE_STDINT_H
/* Define to 1 if you have the <stdlib.h> header file. */
#undef HAVE_STDLIB_H
/* Define to 1 if you have the <strings.h> header file. */
#undef HAVE_STRINGS_H
/* Define to 1 if you have the <string.h> header file. */
#undef HAVE_STRING_H
/* Define to 1 if you have the <sys/stat.h> header file. */
#undef HAVE_SYS_STAT_H
/* Define to 1 if you have the <sys/types.h> header file. */
#undef HAVE_SYS_TYPES_H
/* Define to 1 if you have the <unistd.h> header file. */
#undef HAVE_UNISTD_H
/* Define to the sub-directory in which libtool stores uninstalled libraries.
*/
#undef LT_OBJDIR
/* Name of package */
#undef PACKAGE
/* Define to the address where bug reports for this package should be sent. */
#undef PACKAGE_BUGREPORT
/* Define to the full name of this package. */
#undef PACKAGE_NAME
/* Define to the full name and version of this package. */
#undef PACKAGE_STRING
/* Define to the one symbol short name of this package. */
#undef PACKAGE_TARNAME
/* Define to the version of this package. */
#undef PACKAGE_VERSION
/* Define to 1 if you have the ANSI C header files. */
#undef STDC_HEADERS
/* Version number of package */
#undef VERSION
......@@ -35,6 +35,10 @@ if ! $have_log4c; then
AC_MSG_ERROR(Please install the log4c library)
fi
dnl uninstalled gsr ui dir
AC_DEFINE_UNQUOTED(SFLPHONE_UIDIR_UNINSTALLED, "`pwd`/src/",
[path to uninstalled SFLphone UI dir])
dnl Check for GTK+ version
dnl If gtk+-2.0 >= 2.16, we don't need libsexy package anymore
PKG_CHECK_MODULES(GTK216, gtk+-2.0 >= 2.16, need_libsexy=false, need_libsexy=true)
......@@ -78,6 +82,7 @@ src/dbus/Makefile
src/contacts/Makefile
src/contacts/addressbook/Makefile
src/widget/Makefile
src/icons/Makefile
pixmaps/Makefile
sflphone.desktop
tests/Makefile
......
......@@ -181,7 +181,7 @@
</sect3>
<sect3 id="account_edit">
<title>Editing an configured account</title>
<title>Editing a configured account</title>
<para>To edit an existing account, perform the following steps:</para>
<orderedlist>
<listitem><para>Choose <menuchoice><guimenu>Edit</guimenu><guimenuitem>Manage accounts</guimenuitem></menuchoice>.</para></listitem>
......@@ -214,8 +214,59 @@
</sect2>
<sect2 id="account_advanced">
<title>SIP advanced features</title>
<para>The advanced security features are only available with SIP.</para>
<title>Advanced features</title>
<para>These features are only available with SIP.</para>
<para>Follow the indications to <link linkend='account_edit'>edit an account</link> and choose the <guimenu>Advanced</guimenu> tab.</para>
<!-- ==== Figure ==== -->
<figure id="account-advanced-fig">
<title>Advanced features configuration panel</title>
<screenshot>
<mediaobject>
<imageobject>
<imagedata fileref="figures/account_advanced.png" format="PNG"/>
</imageobject>
</mediaobject>
</screenshot>
</figure>
<!-- ==== End of Figure ==== -->
<sect3 id="accounts_registration">
<title>Registration</title>
<para>You may set the expires header for a contact.</para>
<para>It basically represents the duration your registration will remain active. If you don't register again within that time, calls will no longer be routed to you. it should be not used as a keepalive mechanism though. The default value is 600 seconds (ten minutes).</para>
<note>To register to some VoIP services, you will need to set this value at at least 1600 seconds (Example: French VoIP server freephonie.net).
</note>
</sect3>
<sect3 id="accounts_stun">
<title>Network</title>
<para>This section enables you to set advanced network parameters.</para>
<variablelist>
<varlistentry>
<term><guilabel>Local address</guilabel></term>
<listitem><para>it is initialized to your private/local IP address. Calls will be routed to this address by default.</para></listitem>
</varlistentry>
<varlistentry>
<term><guilabel>Local port</guilabel></term>
<listitem><para>It is initialized to the default SIP port, 5060.</para></listitem>
</varlistentry>
<varlistentry>
<term><guilabel>Set published address and port</guilabel></term>
<listitem>
<itemizedlist>
<listitem>Using STUN
<para>If enabled, the core will try to initialize an UDP transport on the mapped address/port number that the NAT (Network Address Translator) has allocated to <application>SFLphone</application>.</para></listitem>
<listitem>Same as local parameters
</listitem>
<listitem>Manually
</listitem>
</itemizedlist>
</listitem>
</varlistentry>
</variablelist>
</sect3>
</sect2>
<sect2 id="account_security">
<title>Security features</title>
<para>These features are only available with SIP.</para>
<sect3 id="accounts_zrtp">
<title>Secure RTP</title>
</sect3>
......
......@@ -22,5 +22,6 @@ DOC_FIGURES = figures/addressbook-button.png \
figures/configfile-settings.png \
figures/notif-example.png \
figures/systemtray-settings.png \
figures/voicemail-notif.png
figures/voicemail-notif.png \
figures/account_advanced.png
DOC_LINGUAS = fr de es it zh_TW zh_HK zh_CN ko pl pt_BR pt ru
......@@ -17,5 +17,6 @@ AM_CPPFLAGS = $(DEPS_CFLAGS) \
-DPREFIX=\""$(prefix)"\" \
-DSYSCONFDIR=\""$(sysconfdir)"\" \
-DDATADIR=\""$(datadir)"\" \
-DLIBDIR=\""$(libdir)"\"
-DLIBDIR=\""$(libdir)"\" \
-DSFLPHONE_UIDIR=\""$(datadir)/sflphone/ui"\"
......@@ -2,7 +2,43 @@ icondir = $(datadir)/pixmaps
icon_DATA = sflphone.svg
buttons_DATA = accept.svg current.svg transfert.svg hang_up.svg hold.svg unhold.svg refuse.svg call.svg ring.svg dial.svg mic.svg mic_25.svg mic_50.svg mic_75.svg speaker.svg speaker_25.svg speaker_50.svg speaker_75.svg fail.svg incoming.svg outgoing.svg missed.svg mailbox.svg busy.svg icon_accept.svg icon_hold.svg icon_unhold.svg icon_hangup.svg icon_call.svg icon_dialpad.svg icon_volume.svg icon_dialpad_off.svg icon_volume_off.svg history2.svg sflphone.svg sflphone_small.svg stock_person.svg icon_rec.svg rec_call.svg addressbook.svg contact_default.svg face-monkey.svg users.svg usersActive.svg home.svg wait-on.gif lock_certified.svg lock_confirmed.svg lock_error.svg lock_off.svg lock_unconfirmed.svg
buttons_DATA = current.svg \
transfert.svg \
hold.svg \
unhold.svg \
refuse.svg \
call.svg \
ring.svg \
dial.svg \
mic.svg \
mic_25.svg \
mic_50.svg \
mic_75.svg \
speaker.svg \
speaker_25.svg \
speaker_50.svg \
speaker_75.svg \
fail.svg \
incoming.svg \
outgoing.svg \
missed.svg \
busy.svg \
sflphone.svg \
sflphone_small.svg \
stock_person.svg \
icon_rec.svg \
rec_call.svg \
contact_default.svg \
face-monkey.svg \
users.svg \
usersActive.svg \
home.svg \
wait-on.gif \
lock_certified.svg \
lock_confirmed.svg \
lock_error.svg \
lock_off.svg \
lock_unconfirmed.svg
buttonsdir = $(datadir)/sflphone
EXTRA_DIST = $(buttons_DATA) $(icon_DATA)
......@@ -2,21 +2,21 @@ include ../globals.mak
bin_PROGRAMS = sflphone-client-gnome
SUBDIRS = config contacts dbus widget
SUBDIRS = config contacts dbus widget icons
NOFIFY_LIBS = -lnotify
LOG4C = -llog4c
SFLPHONEGTK_LIBS=./contacts/libcontacts.la ./config/libconfig.la ./dbus/libdbus.la ./widget/libwidget.la
SFLPHONEGTK_LIBS=./contacts/libcontacts.la ./config/libconfig.la ./dbus/libdbus.la ./widget/libwidget.la ./icons/libicons.la
sflphone_client_gnome_SOURCES = \
main.c \
errors.c \
uimanager.c \
sflnotify.c \
mainwindow.c \
dialpad.c \
menus.c \
toolbar.c \
callable_obj.c \
conference_obj.c \
actions.c \
......@@ -24,13 +24,11 @@ sflphone_client_gnome_SOURCES = \
sliders.c \
statusicon.c \
codeclist.c \
reqaccount.c
reqaccount.c
noinst_HEADERS = actions.h sflnotify.h mainwindow.h dialpad.h codeclist.h \
reqaccount.h errors.h sflphone_const.h \
menus.h accountlist.h sliders.h statusicon.h callable_obj.h conference_obj.h toolbar.h
reqaccount.h errors.h sflphone_const.h uimanager.h \
accountlist.h sliders.h statusicon.h callable_obj.h conference_obj.h
sflphone_client_gnome_LDADD = $(DEPS_LIBS) $(NOTIFY_LIBS) $(SFLPHONEGTK_LIBS) $(LIBSEXY_LIBS) $(LOG4C)
......
......@@ -22,8 +22,7 @@
#include <dbus/dbus.h>
#include <statusicon.h>
#include <contacts/searchbar.h>
#include <menus.h>
#include <toolbar.h>
#include "icons/icon_factory.h"
#include <gtk/gtk.h>
#include <string.h>
......@@ -125,7 +124,7 @@ sflphone_hold (callable_obj_t * c )
{
c->_state = CALL_STATE_HOLD;
calltree_update_call(current_calls, c, NULL);
update_menus();
update_actions();
}
void
......@@ -133,7 +132,7 @@ sflphone_ringing(callable_obj_t * c )
{
c->_state = CALL_STATE_RINGING;
calltree_update_call(current_calls, c, NULL);
update_menus();
update_actions();
}
void
......@@ -143,7 +142,7 @@ sflphone_hung_up( callable_obj_t * c)
calltree_remove_call(current_calls, c, NULL);
c->_state = CALL_STATE_DIALING;
call_remove_all_errors(c);
update_menus();
update_actions();
#if GTK_CHECK_VERSION(2,10,0)
status_tray_icon_blink( FALSE );
#endif
......@@ -259,7 +258,7 @@ sflphone_fill_account_list(gboolean toolbarInitialized)
// Prevent update being called when toolbar is not yet initialized
if(toolbarInitialized)
toolbar_update_buttons();
update_actions ();
}
gboolean sflphone_init()
......@@ -273,13 +272,16 @@ gboolean sflphone_init()
{
dbus_register(getpid(), "Gtk+ Client");
// Init icons factory
init_icon_factory ();
current_calls = calltab_init(FALSE, CURRENT_CALLS);
contacts = calltab_init(TRUE, CONTACTS);
history = calltab_init(TRUE, HISTORY);
account_list_init ();
codec_list_init();
conferencelist_init();
conferencelist_init();
// Fetch the configured accounts
sflphone_fill_account_list(FALSE);
......@@ -290,8 +292,8 @@ gboolean sflphone_init()
// Fetch the audio codecs
sflphone_fill_codec_list();
// Fetch the conference list
sflphone_fill_conference_list();
// Fetch the conference list
sflphone_fill_conference_list();
return TRUE;
}
......@@ -468,7 +470,7 @@ sflphone_fail( callable_obj_t * c )
{
c->_state = CALL_STATE_FAILURE;
calltree_update_call(current_calls, c, NULL);
update_menus();
update_actions();
}
void
......@@ -476,7 +478,7 @@ sflphone_busy( callable_obj_t * c )
{
c->_state = CALL_STATE_BUSY;
calltree_update_call(current_calls, c, NULL);
update_menus();
update_actions();
}
void
......@@ -486,7 +488,7 @@ sflphone_current( callable_obj_t * c )
set_timestamp (&c->_time_start);
c->_state = CALL_STATE_CURRENT;
calltree_update_call(current_calls, c, NULL);
update_menus();
update_actions();
}
void
......@@ -496,7 +498,7 @@ sflphone_record( callable_obj_t * c )
set_timestamp (&c->_time_start);
c->_state = CALL_STATE_RECORD;
calltree_update_call(current_calls, c, NULL);
update_menus();
update_actions();
}
void
......@@ -508,9 +510,9 @@ sflphone_set_transfert()
c->_state = CALL_STATE_TRANSFERT;
c->_trsft_to = g_strdup("");
calltree_update_call(current_calls, c, NULL);
update_menus();
update_actions();
}
toolbar_update_buttons();
update_actions();
}
void
......@@ -522,9 +524,9 @@ sflphone_unset_transfert()
c->_state = CALL_STATE_CURRENT;
c->_trsft_to = g_strdup("");
calltree_update_call(current_calls, c, NULL);
update_menus();
update_actions();
}
toolbar_update_buttons();
update_actions();
}
void
......@@ -540,7 +542,7 @@ sflphone_incoming_call (callable_obj_t * c)
calllist_add ( current_calls, c );
calllist_add( history, c );
calltree_add_call( current_calls, c, NULL);
update_menus();
update_actions();
calltree_display (current_calls);
}
......@@ -627,10 +629,15 @@ sflphone_new_call()
{
callable_obj_t *c;
callable_obj_t * current_selected_call;
gchar *peer_name, *peer_number;
DEBUG("sflphone_new_call");
sflphone_on_hold();
current_selected_call = calltab_get_selected_call(current_calls);
if ((current_selected_call != NULL) && (current_selected_call->_confID == NULL))
sflphone_on_hold();
// Play a tone when creating a new call
if( calllist_get_size(current_calls) == 0 )
......@@ -642,7 +649,7 @@ sflphone_new_call()
calllist_add (current_calls,c);
calltree_add_call (current_calls, c, NULL);
update_menus();
update_actions();
return c;
}
......@@ -777,7 +784,6 @@ sflphone_keypad( guint keyval, gchar * key)
* If there is no default account selected, place a call with the first
* registered account of the account list
* Else, check if it an IP call. if not, popup an error message
*
*/
static gboolean _is_direct_call(callable_obj_t * c) {
......@@ -907,12 +913,20 @@ sflphone_display_selected_codec (const gchar* codecName)
msg = g_markup_printf_escaped (_("IP call - %s"), codecName);
}
else {
msg = g_markup_printf_escaped("%s %s (%s) - %s %s" ,
if (strcmp(codecName, "") != 0) {
msg = g_markup_printf_escaped("%s %s (%s) - %s %s" ,
_("Using account"),
(gchar*)g_hash_table_lookup( acc->properties , ACCOUNT_ALIAS),
(gchar*)g_hash_table_lookup( acc->properties , ACCOUNT_TYPE),
_("Codec"),
codecName);
} else {
msg = g_markup_printf_escaped("%s %s (%s)" ,
_("Using account"),
(gchar*)g_hash_table_lookup( acc->properties , ACCOUNT_ALIAS),
(gchar*)g_hash_table_lookup( acc->properties , ACCOUNT_TYPE));
}
}
statusbar_push_message( msg , __MSG_ACCOUNT_DEFAULT);
g_free(msg);
......@@ -1046,7 +1060,7 @@ sflphone_rec_call()
}
}
calltree_update_call(current_calls, selectedCall, NULL);
update_menus();
update_actions();
// gchar* codname = sflphone_get_current_codec_name();
// DEBUG("sflphone_get_current_codec_name: %s",codname);
......@@ -1227,7 +1241,7 @@ sflphone_srtp_on( callable_obj_t * c)
c->_srtp_state = SRTP_STATE_SAS_UNCONFIRMED;
calltree_update_call(current_calls, c, NULL);
update_menus();
update_actions();
}
void
......@@ -1235,7 +1249,7 @@ sflphone_srtp_off( callable_obj_t * c )
{
c->_srtp_state = SRTP_STATE_UNLOCKED;
calltree_update_call(current_calls, c, NULL);
update_menus();
update_actions();
}
void
......@@ -1251,7 +1265,7 @@ sflphone_srtp_show_sas( callable_obj_t * c, const gchar* sas, const gboolean ver
c->_srtp_state = SRTP_STATE_SAS_UNCONFIRMED;
}
calltree_update_call(current_calls, c, NULL);
update_menus();
update_actions();
}
void
......@@ -1299,5 +1313,5 @@ sflphone_call_state_changed( callable_obj_t * c, const gchar * description, cons
}
calltree_update_call(current_calls, c, NULL);
update_menus();
update_actions();
}
......@@ -112,8 +112,9 @@ void create_new_call (callable_type_t type, call_state_t state, gchar* callID ,
call_id = generate_call_id ();
else
call_id = callID;
// Set the ID
// Set the IDs
obj->_callID = g_strdup (call_id);
obj->_confID = NULL;
*new_call = obj;
}
......
......@@ -95,6 +95,7 @@ typedef struct {
int _state_code; // The numeric state code as defined in SIP or IAX
gchar* _state_code_description; // A textual description of _state_code
gchar* _callID; // The call ID
gchar* _confID; // The conference ID (NULL if don't participate to a conference)
gchar* _accountID; // The account the call is made with
time_t _time_start; // The timestamp the call was initiating
time_t _time_stop; // The timestamp the call was over
......
......@@ -49,6 +49,7 @@ typedef struct {
gchar* _confID; // The call ID
gboolean _conference_secured; // the security state of the conference
gboolean _conf_srtp_enabled; // security required for this conference
gchar** participant; // participant list for this
} conference_obj_t;
......
......@@ -26,7 +26,6 @@
#include <accountconfigdialog.h>
#include <actions.h>
#include <config.h>
#include <toolbar.h>
#include <dbus/dbus.h>
#include <mainwindow.h>
#include <audioconf.h>
......
......@@ -19,7 +19,6 @@
#include <addressbook.h>
#include <searchbar.h>
#include <toolbar.h>
#include <string.h>
#include <addressbook-config.h>
......@@ -109,7 +108,7 @@ addressbook_config_books()
}
// Update buttons
toolbar_update_buttons();
update_actions ();
}
/**
......
......@@ -24,7 +24,6 @@
#include <glib/gprintf.h>
#include <calllist.h>
#include <conferencelist.h>
#include <toolbar.h>
#include <mainwindow.h>
#include <history.h>
......@@ -145,7 +144,7 @@ call_selected_cb(GtkTreeSelection *sel, void* data UNUSED )
// sflphone_fill_conference_list();
g_value_unset(&val);
toolbar_update_buttons();
update_actions();
}
......@@ -163,73 +162,84 @@ row_activated(GtkTreeView *tree_view UNUSED,
DEBUG("double click action");
if( active_calltree == current_calls )
if(calltab_get_selected_type(active_calltree) == A_CALL)
{
if(calltab_get_selected_type(current_calls) == A_CALL)
DEBUG("Selected a call\n");
selectedCall = calltab_get_selected_call(active_calltree);
if (selectedCall)