From f34b76c5e63f85a9ccd416c8d403eb576069bcc1 Mon Sep 17 00:00:00 2001 From: Mathieu Parent Date: Tue, 24 Aug 2010 22:13:44 +0200 Subject: [PATCH] Skinny: MODSKINNY-12 (Cisco phone 7910 transfer button will not work) --- src/mod/endpoints/mod_skinny/skinny_server.c | 7 +++++++ src/mod/endpoints/mod_skinny/skinny_tables.c | 1 + src/mod/endpoints/mod_skinny/skinny_tables.h | 3 ++- 3 files changed, 10 insertions(+), 1 deletion(-) diff --git a/src/mod/endpoints/mod_skinny/skinny_server.c b/src/mod/endpoints/mod_skinny/skinny_server.c index 4de568b72c..4fca4108cb 100644 --- a/src/mod/endpoints/mod_skinny/skinny_server.c +++ b/src/mod/endpoints/mod_skinny/skinny_server.c @@ -1202,6 +1202,13 @@ switch_status_t skinny_handle_stimulus_message(listener_t *listener, skinny_mess status = skinny_session_hold_line(session, listener, line_instance); } break; + case SKINNY_BUTTON_TRANSFER: + session = skinny_profile_find_session(listener->profile, listener, &line_instance, call_id); + + if(session) { + status = skinny_session_transfer(session, listener, line_instance); + } + break; case SKINNY_BUTTON_VOICEMAIL: skinny_create_incoming_session(listener, &line_instance, &session); skinny_session_process_dest(session, listener, line_instance, "vmain", '\0', 0); diff --git a/src/mod/endpoints/mod_skinny/skinny_tables.c b/src/mod/endpoints/mod_skinny/skinny_tables.c index d9f0aad0ef..f76e84320e 100644 --- a/src/mod/endpoints/mod_skinny/skinny_tables.c +++ b/src/mod/endpoints/mod_skinny/skinny_tables.c @@ -141,6 +141,7 @@ struct skinny_table SKINNY_BUTTONS[] = { {"LastNumberRedial", SKINNY_BUTTON_LAST_NUMBER_REDIAL}, {"SpeedDial", SKINNY_BUTTON_SPEED_DIAL}, {"Hold", SKINNY_BUTTON_HOLD}, + {"Transfer", SKINNY_BUTTON_TRANSFER}, {"Line", SKINNY_BUTTON_LINE}, {"Voicemail", SKINNY_BUTTON_VOICEMAIL}, {"Privacy", SKINNY_BUTTON_PRIVACY}, diff --git a/src/mod/endpoints/mod_skinny/skinny_tables.h b/src/mod/endpoints/mod_skinny/skinny_tables.h index 0b2c544242..6c9182516e 100644 --- a/src/mod/endpoints/mod_skinny/skinny_tables.h +++ b/src/mod/endpoints/mod_skinny/skinny_tables.h @@ -160,13 +160,14 @@ enum skinny_button_definition { SKINNY_BUTTON_LAST_NUMBER_REDIAL = 0x01, SKINNY_BUTTON_SPEED_DIAL = 0x02, SKINNY_BUTTON_HOLD = 0x03, + SKINNY_BUTTON_TRANSFER = 0x04, SKINNY_BUTTON_LINE = 0x09, SKINNY_BUTTON_VOICEMAIL = 0x0F, SKINNY_BUTTON_PRIVACY = 0x13, SKINNY_BUTTON_SERVICE_URL = 0x14, SKINNY_BUTTON_UNDEFINED = 0xFF, }; -extern struct skinny_table SKINNY_BUTTONS[10]; +extern struct skinny_table SKINNY_BUTTONS[11]; const char *skinny_button2str(uint32_t id); uint32_t skinny_str2button(const char *str); #define SKINNY_PUSH_STIMULI SKINNY_DECLARE_PUSH_MATCH(SKINNY_BUTTONS)