Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
savoirfairelinux
jami-daemon
Commits
bfc45748
Commit
bfc45748
authored
Mar 05, 2009
by
Emmanuel Milou
Browse files
add home/business/mobile differenciation for a contact
parent
c6b9609a
Changes
5
Expand all
Hide whitespace changes
Inline
Side-by-side
sflphone-gtk/pixmaps/Makefile.am
View file @
bfc45748
...
...
@@ -2,6 +2,6 @@ icondir = $(datadir)/pixmaps
icon_DATA
=
sflphone.png
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 history.svg history2.svg sflphone.png stock_person.svg icon_rec.svg rec_call.svg addressbook.svg contact_default.svg face-monkey.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 history.svg history2.svg sflphone.png stock_person.svg icon_rec.svg rec_call.svg addressbook.svg contact_default.svg face-monkey.svg
users.svg home.svg
buttonsdir
=
$(datadir)
/sflphone
EXTRA_DIST
=
$(buttons_DATA)
$(icon_DATA)
sflphone-gtk/pixmaps/home.svg
0 → 100644
View file @
bfc45748
This diff is collapsed.
Click to expand it.
sflphone-gtk/pixmaps/users.svg
0 → 100644
View file @
bfc45748
This diff is collapsed.
Click to expand it.
sflphone-gtk/src/calllist.h
View file @
bfc45748
...
...
@@ -106,6 +106,7 @@ typedef struct {
call_state_t
state
;
/** The history state if necessary */
history_state_t
history_state
;
contact_type_t
contact_type
;
time_t
_start
;
time_t
_stop
;
...
...
sflphone-gtk/src/calltree.c
View file @
bfc45748
...
...
@@ -259,11 +259,11 @@ show_contacts_tab(GtkToggleToolButton *toggle_tool_button UNUSED,
if
(
entry
)
{
/* Create entry for business phone information */
create_new_entry_in_contactlist
(
entry
->
name
,
entry
->
phone_business
);
create_new_entry_in_contactlist
(
entry
->
name
,
entry
->
phone_business
,
CONTACT_PHONE_BUSINESS
);
/* Create entry for home phone information */
create_new_entry_in_contactlist
(
entry
->
name
,
entry
->
phone_home
);
create_new_entry_in_contactlist
(
entry
->
name
,
entry
->
phone_home
,
CONTACT_PHONE_HOME
);
/* Create entry for mobile phone information */
create_new_entry_in_contactlist
(
entry
->
name
,
entry
->
phone_mobile
);
create_new_entry_in_contactlist
(
entry
->
name
,
entry
->
phone_mobile
,
CONTACT_PHONE_MOBILE
);
}
free_hit
(
entry
);
}
...
...
@@ -279,7 +279,7 @@ show_contacts_tab(GtkToggleToolButton *toggle_tool_button UNUSED,
toolbar_update_buttons
();
}
void
create_new_entry_in_contactlist
(
gchar
*
contact_name
,
gchar
*
contact_phone
){
void
create_new_entry_in_contactlist
(
gchar
*
contact_name
,
gchar
*
contact_phone
,
contact_type_t
type
){
gchar
*
from
;
call_t
*
new_call
;
...
...
@@ -288,6 +288,7 @@ void create_new_entry_in_contactlist (gchar *contact_name, gchar *contact_phone)
if
(
strcmp
(
contact_phone
,
EMPTY_ENTRY
)
!=
0
){
from
=
g_strconcat
(
"
\"
"
,
contact_name
,
"
\"
<"
,
contact_phone
,
">"
,
NULL
);
create_new_call
(
from
,
from
,
CALL_STATE_DIALING
,
""
,
&
new_call
);
new_call
->
contact_type
=
type
;
call_list_add
(
contacts
,
new_call
);
update_call_tree_add
(
contacts
,
new_call
);
}
...
...
@@ -940,23 +941,21 @@ update_call_tree_add (calltab_t* tab, call_t * c)
}
else
if
(
tab
==
contacts
)
{
/*
switch (c->contact_type)
switch
(
c
->
contact_type
)
{
case
CONTACT_PHONE_HOME
:
pixbuf = gdk_pixbuf_new_from_file(ICONS_DIR "/
face-monkey
.svg", NULL);
pixbuf
=
gdk_pixbuf_new_from_file
(
ICONS_DIR
"/
home
.svg"
,
NULL
);
break
;
case
CONTACT_PHONE_BUSINESS
:
pixbuf
=
gdk_pixbuf_new_from_file
(
ICONS_DIR
"/face-monkey.svg"
,
NULL
);
break
;
case
CONTACT_PHONE_MOBILE
:
pixbuf = gdk_pixbuf_new_from_file(ICONS_DIR "/
contact_default
.svg", NULL);
pixbuf
=
gdk_pixbuf_new_from_file
(
ICONS_DIR
"/
users
.svg"
,
NULL
);
break
;
default:
pixbuf
=
gdk_pixbuf_new_from_file
(
ICONS_DIR
"/contact_default.svg"
,
NULL
);
break
;
}*/
pixbuf
=
gdk_pixbuf_new_from_file
(
ICONS_DIR
"/face-monkey.svg"
,
NULL
);
}
description
=
g_strconcat
(
description
,
NULL
);
}
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment