Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
jami-daemon
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
savoirfairelinux
jami-daemon
Commits
5a3731bf
Commit
5a3731bf
authored
12 years ago
by
Tristan Matthews
Browse files
Options
Downloads
Patches
Plain Diff
* #14568: gnome: add checkbox for SIP auto answer
parent
c5f5750c
No related branches found
No related tags found
No related merge requests found
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
gnome/src/account_schema.h
+1
-0
1 addition, 0 deletions
gnome/src/account_schema.h
gnome/src/config/accountconfigdialog.c
+18
-3
18 additions, 3 deletions
gnome/src/config/accountconfigdialog.c
gnome/src/config/accountconfigdialog.h
+1
-1
1 addition, 1 deletion
gnome/src/config/accountconfigdialog.h
with
20 additions
and
4 deletions
gnome/src/account_schema.h
+
1
−
0
View file @
5a3731bf
...
@@ -74,6 +74,7 @@ static const char *const CONFIG_DEFAULT_ADDRESS = "0.0.0.0";
...
@@ -74,6 +74,7 @@ static const char *const CONFIG_DEFAULT_ADDRESS = "0.0.0.0";
// SIP specific parameters
// SIP specific parameters
static
const
char
*
const
CONFIG_SIP_PROXY
=
"SIP.proxy"
;
static
const
char
*
const
CONFIG_SIP_PROXY
=
"SIP.proxy"
;
static
const
char
*
const
CONFIG_SIP_AUTOANSWER
=
"SIP.autoAnswer"
;
static
const
char
*
const
CONFIG_STUN_SERVER
=
"STUN.server"
;
static
const
char
*
const
CONFIG_STUN_SERVER
=
"STUN.server"
;
static
const
char
*
const
CONFIG_STUN_ENABLE
=
"STUN.enable"
;
static
const
char
*
const
CONFIG_STUN_ENABLE
=
"STUN.enable"
;
...
...
This diff is collapsed.
Click to expand it.
gnome/src/config/accountconfigdialog.c
+
18
−
3
View file @
5a3731bf
...
@@ -123,6 +123,14 @@ static void reset()
...
@@ -123,6 +123,14 @@ static void reset()
entry_mailbox
=
NULL
;
entry_mailbox
=
NULL
;
}
}
/* GtkCheckButton is derived from GtkToggleButton */
static
void
auto_answer_cb
(
GtkToggleButton
*
widget
,
account_t
*
account
)
{
account_replace
(
account
,
CONFIG_SIP_AUTOANSWER
,
gtk_toggle_button_get_active
(
widget
)
?
"true"
:
"false"
);
}
/*
/*
* Display / Hide the password
* Display / Hide the password
*/
*/
...
@@ -202,7 +210,8 @@ static void update_credential_cb(GtkWidget *widget, gpointer data UNUSED)
...
@@ -202,7 +210,8 @@ static void update_credential_cb(GtkWidget *widget, gpointer data UNUSED)
}
}
}
}
static
GtkWidget
*
create_basic_tab
(
const
account_t
*
account
)
static
GtkWidget
*
create_basic_tab
(
account_t
*
account
)
{
{
g_assert
(
account
);
g_assert
(
account
);
gchar
*
password
=
NULL
;
gchar
*
password
=
NULL
;
...
@@ -221,7 +230,7 @@ static GtkWidget* create_basic_tab(const account_t *account)
...
@@ -221,7 +230,7 @@ static GtkWidget* create_basic_tab(const account_t *account)
GtkWidget
*
table
=
NULL
;
GtkWidget
*
table
=
NULL
;
if
(
account_is_SIP
(
account
))
if
(
account_is_SIP
(
account
))
table
=
gtk_table_new
(
9
,
2
,
FALSE
/* homogeneous */
);
table
=
gtk_table_new
(
10
,
2
,
FALSE
/* homogeneous */
);
else
if
(
account_is_IAX
(
account
))
else
if
(
account_is_IAX
(
account
))
table
=
gtk_table_new
(
8
,
2
,
FALSE
);
table
=
gtk_table_new
(
8
,
2
,
FALSE
);
else
{
else
{
...
@@ -368,6 +377,11 @@ static GtkWidget* create_basic_tab(const account_t *account)
...
@@ -368,6 +377,11 @@ static GtkWidget* create_basic_tab(const account_t *account)
gtk_entry_set_text
(
GTK_ENTRY
(
entry_user_agent
),
user_agent
);
gtk_entry_set_text
(
GTK_ENTRY
(
entry_user_agent
),
user_agent
);
gtk_table_attach
(
GTK_TABLE
(
table
),
entry_user_agent
,
1
,
2
,
row
,
row
+
1
,
GTK_EXPAND
|
GTK_FILL
,
GTK_EXPAND
|
GTK_FILL
,
0
,
0
);
gtk_table_attach
(
GTK_TABLE
(
table
),
entry_user_agent
,
1
,
2
,
row
,
row
+
1
,
GTK_EXPAND
|
GTK_FILL
,
GTK_EXPAND
|
GTK_FILL
,
0
,
0
);
row
++
;
GtkWidget
*
auto_answer_checkbox
=
gtk_check_button_new_with_mnemonic
(
_
(
"_Auto-answer calls"
));
g_signal_connect
(
auto_answer_checkbox
,
"toggled"
,
G_CALLBACK
(
auto_answer_cb
),
account
);
gtk_table_attach
(
GTK_TABLE
(
table
),
auto_answer_checkbox
,
0
,
1
,
row
,
row
+
1
,
GTK_EXPAND
|
GTK_FILL
,
GTK_EXPAND
|
GTK_FILL
,
0
,
0
);
gtk_widget_show_all
(
table
);
gtk_widget_show_all
(
table
);
gtk_container_set_border_width
(
GTK_CONTAINER
(
table
),
10
);
gtk_container_set_border_width
(
GTK_CONTAINER
(
table
),
10
);
...
@@ -1305,7 +1319,8 @@ void update_account_from_dialog(GtkWidget *dialog, account_t *account)
...
@@ -1305,7 +1319,8 @@ void update_account_from_dialog(GtkWidget *dialog, account_t *account)
gtk_widget_destroy
(
dialog
);
gtk_widget_destroy
(
dialog
);
}
}
GtkWidget
*
show_account_window
(
const
account_t
*
account
)
GtkWidget
*
show_account_window
(
account_t
*
account
)
{
{
// First we reset
// First we reset
reset
();
reset
();
...
...
This diff is collapsed.
Click to expand it.
gnome/src/config/accountconfigdialog.h
+
1
−
1
View file @
5a3731bf
...
@@ -42,7 +42,7 @@
...
@@ -42,7 +42,7 @@
* @param a The account you want to display
* @param a The account you want to display
* @return The dialog with the pertinent account information
* @return The dialog with the pertinent account information
*/
*/
GtkWidget
*
show_account_window
(
const
account_t
*
a
);
GtkWidget
*
show_account_window
(
account_t
*
a
);
/*
/*
* @param dialog The dialog the account will be update from
* @param dialog The dialog the account will be update from
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment