From ae6948ded397324c5c5194e0d91d2f27c8f96c55 Mon Sep 17 00:00:00 2001 From: Guillaume BIENKOWSKI Date: Thu, 9 Jan 2014 09:36:33 +0100 Subject: [PATCH] Moved belle sip object includes into private.h --- coreapi/contact_providers_priv.h | 2 +- coreapi/contactprovider.c | 3 +-- coreapi/linphonecore.h | 15 -------------- coreapi/private.h | 34 ++++++++++++++++++++++---------- gtk/main.c | 2 +- 5 files changed, 27 insertions(+), 29 deletions(-) diff --git a/coreapi/contact_providers_priv.h b/coreapi/contact_providers_priv.h index 41b7bd327..b3d667df6 100644 --- a/coreapi/contact_providers_priv.h +++ b/coreapi/contact_providers_priv.h @@ -17,7 +17,7 @@ #ifndef CONTACT_PROVIDERS_PRIV_H #define CONTACT_PROVIDERS_PRIV_H -#include +#include "private.h" #include "linphonecore.h" /* Base for contact search and contact provider */ diff --git a/coreapi/contactprovider.c b/coreapi/contactprovider.c index cd40887b1..2ee037c78 100644 --- a/coreapi/contactprovider.c +++ b/coreapi/contactprovider.c @@ -59,7 +59,7 @@ int linphone_contact_search_compare(const void* a, const void* b) { return !(ra->id == rb->id); // return 0 if id is equal, 1 otherwise } -LinphoneContactSearch*linphone_ldap_contact_search_ref(void* obj) +LinphoneContactSearch*linphone_contact_search_ref(void* obj) { return LINPHONE_CONTACT_SEARCH(belle_sip_object_ref(obj)); } @@ -136,4 +136,3 @@ BELLE_SIP_INSTANCIATE_CUSTOM_VPTR_BEGIN(LinphoneContactProvider) NULL, /* begin_search -> pure virtual */ NULL /* cancel_search -> pure virtual */ BELLE_SIP_INSTANCIATE_CUSTOM_VPTR_END - diff --git a/coreapi/linphonecore.h b/coreapi/linphonecore.h index 14d4ff057..b6532e2f2 100644 --- a/coreapi/linphonecore.h +++ b/coreapi/linphonecore.h @@ -33,9 +33,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #include "lpconfig.h" -#include -#include - #define LINPHONE_IPADDR_SIZE 64 #define LINPHONE_HOSTNAME_SIZE 128 @@ -2235,18 +2232,6 @@ LINPHONE_PUBLIC int linphone_core_get_video_dscp(const LinphoneCore *lc); LINPHONE_PUBLIC const char *linphone_core_get_video_display_filter(LinphoneCore *lc); LINPHONE_PUBLIC void linphone_core_set_video_display_filter(LinphoneCore *lc, const char *filtername); - -/** Belle Sip-based objects need unique ids - */ - -BELLE_SIP_DECLARE_TYPES_BEGIN(linphone,10000) -BELLE_SIP_TYPE_ID(LinphoneContactSearch), -BELLE_SIP_TYPE_ID(LinphoneContactProvider), -BELLE_SIP_TYPE_ID(LinphoneLDAPContactProvider), -BELLE_SIP_TYPE_ID(LinphoneLDAPContactSearch) -BELLE_SIP_DECLARE_TYPES_END - - /** Contact Providers */ diff --git a/coreapi/private.h b/coreapi/private.h index 3ce58499f..297535c34 100644 --- a/coreapi/private.h +++ b/coreapi/private.h @@ -34,6 +34,9 @@ extern "C" { #include "sal/sal.h" #include "sipsetup.h" +#include +#include + #ifdef HAVE_CONFIG_H #include "config.h" #endif @@ -201,22 +204,22 @@ struct _LinphoneCall LinphoneCall *referer; /*when this call is the result of a transfer, referer is set to the original call that caused the transfer*/ LinphoneCall *transfer_target;/*if this call received a transfer request, then transfer_target points to the new call created to the refer target */ int localdesc_changed; - + bool_t refer_pending; bool_t media_pending; bool_t audio_muted; bool_t camera_enabled; - + bool_t all_muted; /*this flag is set during early medias*/ bool_t playing_ringbacktone; bool_t owns_call_log; bool_t ringing_beep; /* whether this call is ringing through an already existent current call*/ - + bool_t videostream_encrypted; bool_t audiostream_encrypted; bool_t auth_token_verified; bool_t defer_update; - + bool_t was_automatically_paused; bool_t ping_replied; bool_t record_active; @@ -381,9 +384,9 @@ LinphoneProxyConfig * is_a_linphone_proxy_config(void *user_pointer); static const int linphone_proxy_config_magic=0x7979; -/*chat*/ +/*chat*/ void linphone_chat_message_destroy(LinphoneChatMessage* msg); -/**/ +/**/ struct _LinphoneProxyConfig { @@ -447,7 +450,7 @@ struct _LinphoneChatRoom{ }; - + struct _LinphoneFriend{ LinphoneAddress *uri; SalOp *insub; @@ -499,7 +502,7 @@ typedef struct rtp_config int nortp_timeout; int disable_upnp; bool_t rtp_no_xmit_on_audio_mute; - /* stop rtp xmit when audio muted */ + /* stop rtp xmit when audio muted */ bool_t audio_adaptive_jitt_comp_enabled; bool_t video_adaptive_jitt_comp_enabled; bool_t pad; @@ -645,12 +648,12 @@ struct _LinphoneCore bool_t apply_nat_settings; bool_t initial_subscribes_sent; bool_t bl_refresh; - + bool_t preview_finished; bool_t auto_net_state_mon; bool_t network_reachable; bool_t use_preview_window; - + time_t network_last_check; bool_t network_last_status; @@ -829,6 +832,17 @@ void linphone_free_xml_text_content(const char *text); xmlXPathObjectPtr linphone_get_xml_xpath_object_for_node_list(xmlparsing_context_t *xml_ctx, const char *xpath_expression); +/** Belle Sip-based objects need unique ids + */ + +BELLE_SIP_DECLARE_TYPES_BEGIN(linphone,10000) +BELLE_SIP_TYPE_ID(LinphoneContactSearch), +BELLE_SIP_TYPE_ID(LinphoneContactProvider), +BELLE_SIP_TYPE_ID(LinphoneLDAPContactProvider), +BELLE_SIP_TYPE_ID(LinphoneLDAPContactSearch) +BELLE_SIP_DECLARE_TYPES_END + + #ifdef __cplusplus } #endif diff --git a/gtk/main.c b/gtk/main.c index e47af7f3a..a7de9323b 100644 --- a/gtk/main.c +++ b/gtk/main.c @@ -847,7 +847,7 @@ static gboolean launch_contact_provider_search(void *userdata) ); if(search) - belle_sip_object_ref(search); + linphone_contact_search_ref(search); } return FALSE; }