Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
J
jami-daemon
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
130
Issues
130
List
Boards
Labels
Service Desk
Milestones
Iterations
Requirements
Requirements
List
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Operations
Operations
Incidents
Analytics
Analytics
Insights
Issue
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
savoirfairelinux
jami-daemon
Commits
7d1a1332
Commit
7d1a1332
authored
Oct 05, 2011
by
Tristan Matthews
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* #7100: gnome: remove shadowed vars, fix "ATTACHED" typo in DBUS
parent
24db5cdc
Changes
41
Hide whitespace changes
Inline
Side-by-side
Showing
41 changed files
with
271 additions
and
281 deletions
+271
-281
daemon/src/conference.cpp
daemon/src/conference.cpp
+1
-1
daemon/src/dbus/callmanager-introspec.xml
daemon/src/dbus/callmanager-introspec.xml
+1
-1
gnome/configure.ac
gnome/configure.ac
+1
-1
gnome/src/accountlist.c
gnome/src/accountlist.c
+8
-8
gnome/src/actions.c
gnome/src/actions.c
+4
-3
gnome/src/actions.h
gnome/src/actions.h
+3
-4
gnome/src/callable_obj.c
gnome/src/callable_obj.c
+4
-4
gnome/src/codeclist.c
gnome/src/codeclist.c
+17
-17
gnome/src/codeclist.h
gnome/src/codeclist.h
+1
-1
gnome/src/conference_obj.c
gnome/src/conference_obj.c
+5
-4
gnome/src/conference_obj.h
gnome/src/conference_obj.h
+1
-3
gnome/src/config/accountconfigdialog.c
gnome/src/config/accountconfigdialog.c
+18
-18
gnome/src/config/accountlistconfigdialog.c
gnome/src/config/accountlistconfigdialog.c
+2
-1
gnome/src/config/addressbook-config.c
gnome/src/config/addressbook-config.c
+14
-20
gnome/src/config/assistant.c
gnome/src/config/assistant.c
+11
-13
gnome/src/config/audioconf.c
gnome/src/config/audioconf.c
+10
-10
gnome/src/config/hooks-config.c
gnome/src/config/hooks-config.c
+1
-0
gnome/src/config/preferencesdialog.c
gnome/src/config/preferencesdialog.c
+5
-7
gnome/src/config/shortcuts-config.c
gnome/src/config/shortcuts-config.c
+1
-0
gnome/src/contacts/addrbookfactory.c
gnome/src/contacts/addrbookfactory.c
+1
-1
gnome/src/contacts/calllist.c
gnome/src/contacts/calllist.c
+1
-0
gnome/src/contacts/calllist.h
gnome/src/contacts/calllist.h
+2
-2
gnome/src/contacts/calltab.c
gnome/src/contacts/calltab.c
+4
-3
gnome/src/contacts/calltree.c
gnome/src/contacts/calltree.c
+5
-4
gnome/src/contacts/searchbar.c
gnome/src/contacts/searchbar.c
+24
-28
gnome/src/dbus/callmanager-introspec.xml
gnome/src/dbus/callmanager-introspec.xml
+1
-1
gnome/src/dbus/configurationmanager-introspec.xml
gnome/src/dbus/configurationmanager-introspec.xml
+3
-3
gnome/src/dbus/dbus.c
gnome/src/dbus/dbus.c
+31
-32
gnome/src/dbus/dbus.h
gnome/src/dbus/dbus.h
+5
-6
gnome/src/icons/icon_factory.c
gnome/src/icons/icon_factory.c
+1
-2
gnome/src/imwindow.c
gnome/src/imwindow.c
+3
-3
gnome/src/mainwindow.c
gnome/src/mainwindow.c
+3
-0
gnome/src/reqaccount.c
gnome/src/reqaccount.c
+4
-5
gnome/src/sflnotify.c
gnome/src/sflnotify.c
+1
-0
gnome/src/sflphone_const.h
gnome/src/sflphone_const.h
+0
-2
gnome/src/shortcuts.c
gnome/src/shortcuts.c
+9
-7
gnome/src/sliders.c
gnome/src/sliders.c
+7
-6
gnome/src/statusicon.c
gnome/src/statusicon.c
+17
-18
gnome/src/uimanager.c
gnome/src/uimanager.c
+19
-21
gnome/src/widget/gtkscrollbook.c
gnome/src/widget/gtkscrollbook.c
+12
-12
gnome/src/widget/imwidget.c
gnome/src/widget/imwidget.c
+10
-9
No files found.
daemon/src/conference.cpp
View file @
7d1a1332
...
...
@@ -86,7 +86,7 @@ void Conference::bindParticipant (std::string participant_id)
std
::
string
Conference
::
getStateStr
()
{
switch
(
_confState
)
{
case
ACTIVE_ATTACHED
:
return
"ACTIVE_ATACHED"
;
case
ACTIVE_ATTACHED
:
return
"ACTIVE_AT
T
ACHED"
;
case
ACTIVE_DETACHED
:
return
"ACTIVE_DETACHED"
;
case
ACTIVE_ATTACHED_REC
:
return
"ACTIVE_ATTACHED_REC"
;
case
ACTIVE_DETACHED_REC
:
return
"ACTIVE_DETACHED_REC"
;
...
...
daemon/src/dbus/callmanager-introspec.xml
View file @
7d1a1332
...
...
@@ -289,7 +289,7 @@
A map containing the ID of the conferences
and their states:
<ul>
<li>
ACTIVE_ATACHED
</li>
<li>
ACTIVE_AT
T
ACHED
</li>
<li>
ACTIVE_DETACHED
</li>
<li>
HOLD
</li>
</ul>
...
...
gnome/configure.ac
View file @
7d1a1332
...
...
@@ -9,7 +9,7 @@ AC_CONFIG_MACRO_DIR([m4])
dnl Silent build by default. Use make V=1 to increase verbosity
m4_ifdef([AM_SILENT_RULES],[AM_SILENT_RULES([yes])])
CFLAGS="$CFLAGS -g -Wall -Wextra"
CFLAGS="$CFLAGS -g -Wall -Wextra
-Wshadow
"
AC_PROG_CC_C99
AM_PROG_CC_C_O dnl for per target flags, i.e. test_program_CFLAGS
...
...
gnome/src/accountlist.c
View file @
7d1a1332
...
...
@@ -198,20 +198,20 @@ void account_list_free ()
}
void
account_list_move_up
(
guint
index
)
account_list_move_up
(
guint
account_
index
)
{
if
(
index
!=
0
)
{
gpointer
acc
=
g_queue_pop_nth
(
accountQueue
,
index
);
g_queue_push_nth
(
accountQueue
,
acc
,
index
-
1
);
if
(
account_
index
!=
0
)
{
gpointer
acc
=
g_queue_pop_nth
(
accountQueue
,
account_
index
);
g_queue_push_nth
(
accountQueue
,
acc
,
account_index
-
1
);
}
}
void
account_list_move_down
(
guint
index
)
account_list_move_down
(
guint
account_
index
)
{
if
(
index
!=
accountQueue
->
length
)
{
gpointer
acc
=
g_queue_pop_nth
(
accountQueue
,
index
);
g_queue_push_nth
(
accountQueue
,
acc
,
index
+
1
);
if
(
account_
index
!=
accountQueue
->
length
)
{
gpointer
acc
=
g_queue_pop_nth
(
accountQueue
,
account_
index
);
g_queue_push_nth
(
accountQueue
,
acc
,
account_index
+
1
);
}
}
...
...
gnome/src/actions.c
View file @
7d1a1332
...
...
@@ -54,6 +54,7 @@
#include "actions.h"
#include "dbus/dbus.h"
#include "logger.h"
#include "contacts/searchbar.h"
#include "contacts/addrbookfactory.h"
#include "icons/icon_factory.h"
...
...
@@ -995,11 +996,11 @@ sflphone_rec_call()
DEBUG
(
"SFLphone: Set record for selected conf"
);
dbus_set_record
(
selectedConf
->
_confID
);
switch
(
selectedConf
->
_state
)
{
case
CONFERENCE_STATE_ACTIVE_ATACHED
:
case
CONFERENCE_STATE_ACTIVE_AT
T
ACHED
:
selectedConf
->
_state
=
CONFERENCE_STATE_ACTIVE_ATTACHED_RECORD
;
break
;
case
CONFERENCE_STATE_ACTIVE_ATTACHED_RECORD
:
selectedConf
->
_state
=
CONFERENCE_STATE_ACTIVE_ATACHED
;
selectedConf
->
_state
=
CONFERENCE_STATE_ACTIVE_AT
T
ACHED
;
break
;
case
CONFERENCE_STATE_ACTIVE_DETACHED
:
selectedConf
->
_state
=
CONFERENCE_STATE_ACTIVE_DETACHED_RECORD
;
...
...
@@ -1142,7 +1143,7 @@ void sflphone_fill_history (void)
conference_obj_t
*
conf
=
conferencelist_get
(
history
,
history_call
->
_confID
);
if
(
!
conf
)
{
// conference does not exist yet, create it
conf
=
create_new_conference
(
CONFERENCE_STATE_ACTIVE_ATACHED
,
history_call
->
_confID
);
conf
=
create_new_conference
(
CONFERENCE_STATE_ACTIVE_AT
T
ACHED
,
history_call
->
_confID
);
conferencelist_add
(
history
,
conf
);
}
...
...
gnome/src/actions.h
View file @
7d1a1332
...
...
@@ -39,6 +39,7 @@
#include "codeclist.h"
#include "sflphone_const.h"
#include "conference_obj.h"
#include "callable_obj.h"
/** @file actions.h
* @brief General functions that change the state of the application.
...
...
@@ -276,11 +277,9 @@ void sflphone_call_state_changed (callable_obj_t * c, const gchar * description,
void
sflphone_add_main_participant
(
const
conference_obj_t
*
c
);
void
sflphone_conference_off_hold
(
const
conference_obj_t
*
c
);
void
sflphone_conference_off_hold
(
const
conference_obj_t
*
c
);
void
sflphone_srtp_sdes_off
(
callable_obj_t
*
c
);
void
sflphone_srtp_sdes_off
(
callable_obj_t
*
c
);
void
sflphone_fill_conference_list
(
void
);
...
...
gnome/src/callable_obj.c
View file @
7d1a1332
...
...
@@ -28,13 +28,13 @@
* as that of the covered work.
*/
#include
<callable_obj.h>
#include
<codeclist.h>
#include
<sflphone_const.h>
#include
"callable_obj.h"
#include
"codeclist.h"
#include
"sflphone_const.h"
#include <time.h>
#include "contacts/calltree.h"
#include "dbus.h"
#include <unistd.h>
#include <assert.h>
gint
get_state_callstruct
(
gconstpointer
a
,
gconstpointer
b
)
...
...
gnome/src/codeclist.c
View file @
7d1a1332
...
...
@@ -28,8 +28,8 @@
* as that of the covered work.
*/
#include
<codeclist.h>
#include
"codeclist.h"
#include "logger.h"
#include <string.h>
#include <stdlib.h>
#include <unistd.h>
...
...
@@ -156,47 +156,47 @@ codec_t* codec_list_get_by_payload (gconstpointer payload, GQueue *q)
return
c
?
c
->
data
:
NULL
;
}
codec_t
*
codec_list_get_nth
(
guint
index
,
GQueue
*
q
)
codec_t
*
codec_list_get_nth
(
guint
codec_
index
,
GQueue
*
q
)
{
return
g_queue_peek_nth
(
q
,
index
);
return
g_queue_peek_nth
(
q
,
codec_
index
);
}
codec_t
*
capabilities_get_nth
(
guint
index
)
codec_t
*
capabilities_get_nth
(
guint
caps_
index
)
{
return
g_queue_peek_nth
(
codecsCapabilities
,
index
);
return
g_queue_peek_nth
(
codecsCapabilities
,
caps_
index
);
}
void
codec_set_prefered_order
(
guint
index
,
GQueue
*
q
)
void
codec_set_prefered_order
(
guint
codec_
index
,
GQueue
*
q
)
{
codec_t
*
prefered
=
codec_list_get_nth
(
index
,
q
);
g_queue_pop_nth
(
q
,
index
);
codec_t
*
prefered
=
codec_list_get_nth
(
codec_
index
,
q
);
g_queue_pop_nth
(
q
,
codec_
index
);
g_queue_push_head
(
q
,
prefered
);
}
void
codec_list_move_codec_up
(
guint
index
,
GQueue
**
q
)
void
codec_list_move_codec_up
(
guint
codec_
index
,
GQueue
**
q
)
{
DEBUG
(
"Codec list Size: %i
\n
"
,
codec_list_get_size
());
GQueue
*
tmp
=
*
q
;
if
(
index
!=
0
)
{
gpointer
codec
=
g_queue_pop_nth
(
tmp
,
index
);
g_queue_push_nth
(
tmp
,
codec
,
index
-
1
);
if
(
codec_
index
!=
0
)
{
gpointer
codec
=
g_queue_pop_nth
(
tmp
,
codec_
index
);
g_queue_push_nth
(
tmp
,
codec
,
codec_index
-
1
);
}
*
q
=
tmp
;
}
void
codec_list_move_codec_down
(
guint
index
,
GQueue
**
q
)
void
codec_list_move_codec_down
(
guint
codec_
index
,
GQueue
**
q
)
{
DEBUG
(
"Codec list Size: %i
\n
"
,
codec_list_get_size
());
GQueue
*
tmp
=
*
q
;
if
(
index
!=
g_queue_get_length
(
tmp
)
)
{
gpointer
codec
=
g_queue_pop_nth
(
tmp
,
index
);
g_queue_push_nth
(
tmp
,
codec
,
index
+
1
);
if
(
codec_
index
!=
g_queue_get_length
(
tmp
)
)
{
gpointer
codec
=
g_queue_pop_nth
(
tmp
,
codec_
index
);
g_queue_push_nth
(
tmp
,
codec
,
codec_index
+
1
);
}
*
q
=
tmp
;
...
...
gnome/src/codeclist.h
View file @
7d1a1332
...
...
@@ -32,7 +32,7 @@
#define __CODECLIST_H__
#include <gtk/gtk.h>
#include
<accountlist.h>
#include
"accountlist.h"
/** @file codeclist.h
* @brief A list to hold codecs.
*/
...
...
gnome/src/conference_obj.c
View file @
7d1a1332
...
...
@@ -31,8 +31,9 @@
#include <time.h>
#include "callable_obj.h"
#include "dbus.h"
#include "sflphone_const.h"
#include "logger.h"
#include "calltab.h"
#include "calllist.h"
...
...
@@ -90,8 +91,8 @@ conference_obj_t *create_new_conference_from_details (const gchar *conf_id, GHas
gchar
*
state_str
=
g_hash_table_lookup
(
details
,
"CONF_STATE"
);
if
(
g_strcasecmp
(
state_str
,
"ACTIVE_ATACHED"
)
==
0
)
new_conf
->
_state
=
CONFERENCE_STATE_ACTIVE_ATACHED
;
if
(
g_strcasecmp
(
state_str
,
"ACTIVE_AT
T
ACHED"
)
==
0
)
new_conf
->
_state
=
CONFERENCE_STATE_ACTIVE_AT
T
ACHED
;
else
if
(
g_strcasecmp
(
state_str
,
"ACTIVE_ATTACHED_REC"
)
==
0
)
new_conf
->
_state
=
CONFERENCE_STATE_ACTIVE_ATTACHED_RECORD
;
else
if
(
g_strcasecmp
(
state_str
,
"ACTIVE_DETACHED"
)
==
0
)
...
...
@@ -243,7 +244,7 @@ gchar *serialize_history_conference_entry(conference_obj_t *entry)
conference_obj_t
*
create_conference_history_entry_from_serialized
(
gchar
*
entry
)
{
history_state_t
history_state
=
MISSED
;
conference_state_t
state
=
CONFERENCE_STATE_ACTIVE_ATACHED
;
conference_state_t
state
=
CONFERENCE_STATE_ACTIVE_AT
T
ACHED
;
const
gchar
*
participant
=
NULL
;
const
gchar
*
name
=
NULL
;
const
gchar
*
time_start
=
NULL
;
...
...
gnome/src/conference_obj.h
View file @
7d1a1332
...
...
@@ -36,13 +36,11 @@
#include <stdlib.h>
#include <time.h>
/** @enum conference_state_t
* This enum have all the states a conference can take.
*/
typedef
enum
{
CONFERENCE_STATE_ACTIVE_ATACHED
=
0
,
CONFERENCE_STATE_ACTIVE_AT
T
ACHED
=
0
,
CONFERENCE_STATE_ACTIVE_DETACHED
,
CONFERENCE_STATE_ACTIVE_ATTACHED_RECORD
,
CONFERENCE_STATE_ACTIVE_DETACHED_RECORD
,
...
...
gnome/src/config/accountconfigdialog.c
View file @
7d1a1332
...
...
@@ -31,6 +31,15 @@
* as that of the covered work.
*/
#include <sys/socket.h>
#include <sys/ioctl.h>
#include <net/if.h>
#include <netinet/in.h>
#include <string.h>
#include <gtk/gtk.h>
#include "config.h"
#include "logger.h"
#include "actions.h"
#include "mainwindow.h"
#include "accountlist.h"
...
...
@@ -39,16 +48,7 @@
#include "zrtpadvanceddialog.h"
#include "tlsadvanceddialog.h"
#include "audioconf.h"
#include <sys/socket.h>
#include <sys/ioctl.h>
#include <net/if.h>
#include <netinet/in.h>
#include <string.h>
#include <dbus/dbus.h>
#include <config.h>
#include <gtk/gtk.h>
#include "dbus/dbus.h"
#include "utils.h"
/**
...
...
@@ -355,7 +355,7 @@ static GtkWidget* create_basic_tab(account_t *currentAccount)
return
frame
;
}
static
void
fill_treeview_with_credential
(
GtkListStore
*
credentialStore
,
account_t
*
account
)
static
void
fill_treeview_with_credential
(
account_t
*
account
)
{
GtkTreeIter
iter
;
gtk_list_store_clear
(
credentialStore
);
...
...
@@ -373,10 +373,10 @@ static void fill_treeview_with_credential(GtkListStore * credentialStore, accoun
GHashTable
*
element
=
g_ptr_array_index
(
account
->
credential_information
,
i
);
gtk_list_store_append
(
credentialStore
,
&
iter
);
gtk_list_store_set
(
credentialStore
,
&
iter
,
COLUMN_CREDENTIAL_REALM
,
g_hash_table_lookup
(
element
,
ACCOUNT_REALM
),
COLUMN_CREDENTIAL_USERNAME
,
g_hash_table_lookup
(
element
,
ACCOUNT_USERNAME
),
COLUMN_CREDENTIAL_PASSWORD
,
g_hash_table_lookup
(
element
,
ACCOUNT_PASSWORD
),
COLUMN_CREDENTIAL_DATA
,
element
,
-
1
);
COLUMN_CREDENTIAL_REALM
,
g_hash_table_lookup
(
element
,
ACCOUNT_REALM
),
COLUMN_CREDENTIAL_USERNAME
,
g_hash_table_lookup
(
element
,
ACCOUNT_USERNAME
),
COLUMN_CREDENTIAL_PASSWORD
,
g_hash_table_lookup
(
element
,
ACCOUNT_PASSWORD
),
COLUMN_CREDENTIAL_DATA
,
element
,
-
1
);
}
}
...
...
@@ -697,7 +697,7 @@ GtkWidget* create_credential_widget(account_t *a)
gtk_container_add
(
GTK_CONTAINER
(
scrolledWindowCredential
),
treeViewCredential
);
fill_treeview_with_credential
(
credentialStore
,
a
);
fill_treeview_with_credential
(
a
);
/* Credential Buttons */
GtkWidget
*
hbox
=
gtk_hbox_new
(
FALSE
,
10
);
...
...
@@ -1079,10 +1079,10 @@ GtkWidget* create_advanced_tab(account_t *a)
return
ret
;
}
void
ringtone_enabled
(
GtkWidget
*
widget
UNUSED
,
gpointer
fileChooser
,
const
gchar
*
accountID
UNUSED
)
void
ringtone_enabled
(
GtkWidget
*
widget
UNUSED
,
gpointer
data
,
const
gchar
*
accountID
UNUSED
)
{
/* toggle sensitivity */
gtk_widget_set_sensitive
(
fileChooser
,
!
gtk_widget_is_sensitive
(
fileChooser
));
gtk_widget_set_sensitive
(
data
,
!
gtk_widget_is_sensitive
(
data
));
}
...
...
gnome/src/config/accountlistconfigdialog.c
View file @
7d1a1332
...
...
@@ -36,10 +36,11 @@
#include "actions.h"
#include "mainwindow.h"
#include "utils.h"
#include "logger.h"
#include <string.h>
#include <libgnome/gnome-help.h>
#define CONTEXT_ID_REGISTRATION 0
static
const
int
CONTEXT_ID_REGISTRATION
=
0
;
static
GtkWidget
*
addButton
;
static
GtkWidget
*
editButton
;
...
...
gnome/src/config/addressbook-config.c
View file @
7d1a1332
...
...
@@ -29,15 +29,25 @@
*/
#include "addressbook-config.h"
#include "dbus.h"
#include "logger.h"
#include "searchbar.h"
#include "contacts/addrbookfactory.h"
#include <string.h>
#include <stdlib.h>
AddressBook_Config
*
addressbook_config
;
GtkWidget
*
book_tree_view
;
static
AddressBook_Config
*
addressbook_config
;
static
GtkWidget
*
book_tree_view
;
GtkWidget
*
photo
,
*
cards_label
,
*
scale_label
,
*
scrolled_label
,
*
scrolled_window
,
*
scale_button
,
*
business
,
*
mobile
,
*
home
;
static
GtkWidget
*
photo
;
static
GtkWidget
*
cards_label
;
static
GtkWidget
*
scale_label
;
static
GtkWidget
*
scrolled_label
;
static
GtkWidget
*
scrolled_window
;
static
GtkWidget
*
scale_button
;
static
GtkWidget
*
business
;
static
GtkWidget
*
mobile
;
static
GtkWidget
*
home
;
enum
{
COLUMN_BOOK_ACTIVE
,
COLUMN_BOOK_NAME
,
COLUMN_BOOK_UID
...
...
@@ -310,7 +320,6 @@ addressbook_config_fill_book_list()
GtkWidget
*
create_addressbook_settings
()
{
GtkWidget
*
ret
,
*
result_frame
,
*
table
,
*
value
,
*
item
;
GtkListStore
*
store
;
...
...
@@ -325,8 +334,6 @@ create_addressbook_settings()
gnome_main_section_new_with_table
(
_
(
"General"
),
&
result_frame
,
&
table
,
3
,
3
);
gtk_box_pack_start
(
GTK_BOX
(
ret
),
result_frame
,
FALSE
,
FALSE
,
0
);
// gtk_widget_show (result_frame);
// PHOTO DISPLAY
item
=
gtk_check_button_new_with_mnemonic
(
_
(
"_Use Evolution address books"
));
...
...
@@ -348,19 +355,15 @@ create_addressbook_settings()
gtk_table_attach
(
GTK_TABLE
(
table
),
cards_label
,
2
,
3
,
1
,
2
,
GTK_EXPAND
|
GTK_FILL
,
GTK_EXPAND
|
GTK_FILL
,
0
,
0
);
gtk_widget_show_all
(
scale_button
);
// PHOTO DISPLAY
photo
=
gtk_check_button_new_with_mnemonic
(
_
(
"_Display contact photo if available"
));
gtk_toggle_button_set_active
(
GTK_TOGGLE_BUTTON
(
photo
),
addressbook_config
->
display_contact_photo
);
g_signal_connect
(
G_OBJECT
(
photo
)
,
"clicked"
,
G_CALLBACK
(
display_contact_photo_cb
),
NULL
);
gtk_table_attach
(
GTK_TABLE
(
table
),
photo
,
1
,
3
,
2
,
3
,
GTK_EXPAND
|
GTK_FILL
,
GTK_EXPAND
|
GTK_FILL
,
0
,
0
);
// Fields
gnome_main_section_new_with_table
(
_
(
"Fields from Evolution's address books"
),
&
result_frame
,
&
table
,
1
,
3
);
gtk_box_pack_start
(
GTK_BOX
(
ret
),
result_frame
,
FALSE
,
FALSE
,
0
);
// gtk_widget_show (result_frame);
business
=
gtk_check_button_new_with_mnemonic
(
_
(
"_Work"
));
gtk_toggle_button_set_active
(
GTK_TOGGLE_BUTTON
(
business
),
addressbook_config
->
search_phone_business
);
...
...
@@ -379,7 +382,6 @@ create_addressbook_settings()
g_signal_connect
(
G_OBJECT
(
mobile
)
,
"clicked"
,
G_CALLBACK
(
search_phone_mobile_cb
)
,
NULL
);
gtk_table_attach
(
GTK_TABLE
(
table
),
mobile
,
0
,
1
,
2
,
3
,
GTK_EXPAND
|
GTK_FILL
,
GTK_EXPAND
|
GTK_FILL
,
0
,
0
);
// Address Book
gnome_main_section_new_with_table
(
_
(
"Address Books"
),
&
result_frame
,
&
table
,
2
,
3
);
gtk_box_pack_start
(
GTK_BOX
(
ret
),
result_frame
,
TRUE
,
TRUE
,
0
);
...
...
@@ -397,8 +399,6 @@ create_addressbook_settings()
gtk_table_attach
(
GTK_TABLE
(
table
),
scrolled_window
,
1
,
4
,
2
,
3
,
GTK_EXPAND
|
GTK_FILL
,
GTK_EXPAND
|
GTK_FILL
,
0
,
0
);
store
=
gtk_list_store_new
(
3
,
G_TYPE_BOOLEAN
,
// Active
G_TYPE_STRING
,
// uid
...
...
@@ -436,21 +436,15 @@ create_addressbook_settings()
gboolean
addressbook_display
(
AddressBook_Config
*
settings
,
const
gchar
*
field
)
{
gboolean
display
=
FALSE
;
gboolean
display
;
if
(
g_strcasecmp
(
field
,
ADDRESSBOOK_DISPLAY_CONTACT_PHOTO
)
==
0
)
display
=
(
settings
->
display_contact_photo
==
1
)
?
TRUE
:
FALSE
;
else
if
(
g_strcasecmp
(
field
,
ADDRESSBOOK_DISPLAY_PHONE_BUSINESS
)
==
0
)
display
=
(
settings
->
search_phone_business
==
1
)
?
TRUE
:
FALSE
;
else
if
(
g_strcasecmp
(
field
,
ADDRESSBOOK_DISPLAY_PHONE_HOME
)
==
0
)
display
=
(
settings
->
search_phone_home
==
1
)
?
TRUE
:
FALSE
;
else
if
(
g_strcasecmp
(
field
,
ADDRESSBOOK_DISPLAY_PHONE_MOBILE
)
==
0
)
display
=
(
settings
->
search_phone_mobile
==
1
)
?
TRUE
:
FALSE
;
else
display
=
FALSE
;
...
...
gnome/src/config/assistant.c
View file @
7d1a1332
...
...
@@ -31,6 +31,8 @@
#include <string.h>
#include "assistant.h"
#include "logger.h"
#include "dbus.h"
#include "reqaccount.h"
#define SFLPHONE_ORG_SERVER "sip.sflphone.org"
...
...
@@ -38,8 +40,8 @@
struct
_wizard
*
wiz
;
static
int
account_type
;
static
int
use_sflphone_org
=
1
;
account_t
*
current
;
char
message
[
1024
];
static
account_t
*
current
;
static
char
message
[
1024
];
/**
* Forward function
*/
...
...
@@ -53,11 +55,10 @@ void prefill_sip (void) ;
void
set_account_type
(
GtkWidget
*
widget
,
gpointer
data
UNUSED
)
{
if
(
gtk_toggle_button_get_active
(
GTK_TOGGLE_BUTTON
(
widget
)))
{
if
(
gtk_toggle_button_get_active
(
GTK_TOGGLE_BUTTON
(
widget
)))
account_type
=
_SIP
;
}
else
{
else
account_type
=
_IAX
;
}
}
static
void
show_password_cb
(
GtkWidget
*
widget
UNUSED
,
gpointer
data
)
...
...
@@ -70,7 +71,7 @@ static void show_password_cb (GtkWidget *widget UNUSED, gpointer data)
* Fills string message with the final message of account registration
* with alias, server and username specified.
*/
void
getMessageSummary
(
c
har
*
message
,
c
onst
gchar
*
alias
,
const
gchar
*
server
,
const
gchar
*
username
,
const
gboolean
zrtp
)
void
getMessageSummary
(
const
gchar
*
alias
,
const
gchar
*
server
,
const
gchar
*
username
,
const
gboolean
zrtp
)
{
char
var
[
64
];
sprintf
(
message
,
_
(
"This assistant is now finished."
));
...
...
@@ -92,11 +93,10 @@ void getMessageSummary (char * message , const gchar * alias, const gchar * serv
strcat
(
message
,
_
(
"Security: "
));
if
(
zrtp
)
{
if
(
zrtp
)
strcat
(
message
,
_
(
"SRTP/ZRTP draft-zimmermann"
));
}
else
{
else
strcat
(
message
,
_
(
"None"
));
}
}
void
set_sflphone_org
(
GtkWidget
*
widget
,
gpointer
data
UNUSED
)
...
...
@@ -178,8 +178,7 @@ static void sip_apply_callback (void)
g_hash_table_insert
(
current
->
properties
,
g_strdup
(
PUBLISHED_ADDRESS
),
g_strdup
(
(
gchar
*
)
*
iface
));
dbus_add_account
(
current
);
getMessageSummary
(
message
,
gtk_entry_get_text
(
GTK_ENTRY
(
wiz
->
sip_alias
)),
getMessageSummary
(
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
)),
(
gboolean
)
(
gtk_toggle_button_get_active
(
GTK_TOGGLE_BUTTON
(
wiz
->
zrtp_enable
)))
...
...
@@ -205,8 +204,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
);
getMessageSummary
(
message
,
gtk_entry_get_text
(
GTK_ENTRY
(
wiz
->
iax_alias
)),
getMessageSummary
(
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
)),
FALSE
...
...
gnome/src/config/audioconf.c
View file @
7d1a1332
...
...
@@ -29,10 +29,10 @@
*/
#include
<audioconf.h>
#include
<utils.h>
#include
<string.h>
#include
<eel-gconf-extensions.h>
#include
"audioconf.h"
#include
"utils.h"
#include
"logger.h"
#include
"eel-gconf-extensions.h"
#include "dbus/dbus.h"
#include "uimanager.h"
#include "mainwindow.h"
...
...
@@ -124,10 +124,10 @@ preferences_dialog_fill_output_audio_device_list()
// Call dbus to retrieve list
for
(
gchar
**
list
=
dbus_get_audio_output_device_list
();
*
list
;
list
++
)
{
int
index
=
dbus_get_audio_device_index
(
*
list
);
int
device_
index
=
dbus_get_audio_device_index
(
*
list
);
GtkTreeIter
iter
;
gtk_list_store_append
(
outputlist
,
&
iter
);
gtk_list_store_set
(
outputlist
,
&
iter
,
0
,
*
list
,
1
,
index
,
-
1
);
gtk_list_store_set
(
outputlist
,
&
iter
,
0
,
*
list
,
1
,
device_
index
,
-
1
);
}
}
...
...
@@ -138,10 +138,10 @@ preferences_dialog_fill_ringtone_audio_device_list()
// Call dbus to retreive output device
for
(
gchar
**
list
=
dbus_get_audio_output_device_list
();
*
list
;
list
++
)
{
int
index
=
dbus_get_audio_device_index
(
*
list
);
int
device_
index
=
dbus_get_audio_device_index
(
*
list
);
GtkTreeIter
iter
;
gtk_list_store_append
(
ringtonelist
,
&
iter
);
gtk_list_store_set
(
ringtonelist
,
&
iter
,
0
,
*
list
,
1
,
index
,
-
1
);
gtk_list_store_set
(
ringtonelist
,
&
iter
,
0
,
*
list
,
1
,
device_
index
,
-
1
);
}
}
...
...
@@ -220,10 +220,10 @@ preferences_dialog_fill_input_audio_device_list()
// For each device name included in list
for
(;
*
list
;
list
++
)
{
int
index
=
dbus_get_audio_device_index
(
*
list
);
int
device_
index
=
dbus_get_audio_device_index
(
*
list
);
GtkTreeIter
iter
;
gtk_list_store_append
(
inputlist
,
&
iter
);
gtk_list_store_set
(
inputlist
,
&
iter
,
0
,
*
list
,
1
,
index
,
-
1
);
gtk_list_store_set
(
inputlist
,
&
iter
,
0
,
*
list
,
1
,
device_
index
,
-
1
);
}
}
...
...
gnome/src/config/hooks-config.c
View file @
7d1a1332
...
...
@@ -29,6 +29,7 @@
*/
#include "hooks-config.h"
#include "dbus.h"
URLHook_Config
*
_urlhook_config
;
...
...
gnome/src/config/preferencesdialog.c
View file @
7d1a1332
...
...
@@ -37,7 +37,9 @@
#include <stdio.h>
#include <string.h>
#include "eel-gconf-extensions.h"
#include "dbus.h"
#include "logger.h"
#include "statusicon.h"
#include "addrbookfactory.h"
#include "preferencesdialog.h"
#include "addressbook-config.h"
...
...
@@ -146,18 +148,15 @@ clean_history (void)
void
showstatusicon_cb
(
GtkWidget
*
widget
,
gpointer
data
UNUSED
)
{
gboolean
currentstatus
=
FALSE
;
// data contains the previous value of dbus_is_status_icon_enabled () - ie before the click.
currentstatus
=
(
gboolean
)
gtk_toggle_button_get_active
(
GTK_TOGGLE_BUTTON
(
widget
));
gboolean
currentstatus
=
gtk_toggle_button_get_active
(
GTK_TOGGLE_BUTTON
(
widget
));
// Update the widget states
gtk_widget_set_sensitive
(
GTK_WIDGET
(
popupwindow
),
currentstatus
);
gtk_widget_set_sensitive
(
GTK_WIDGET
(
neverpopupwindow
),
currentstatus
);
gtk_widget_set_sensitive
(
GTK_WIDGET
(
starthidden
),
currentstatus
);
currentstatus
?
show_status_icon
()
:
hide_status_icon
();
currentstatus
?
show_status_icon
()
:
hide_status_icon
();
// Update through D-Bus
eel_gconf_set_integer
(
SHOW_STATUSICON
,
currentstatus
);
...
...
@@ -294,7 +293,6 @@ save_configuration_parameters (void)
// History config
dbus_set_history_limit
(
history_limit
);
}