Bug 784519 - Part 2: Fix success callback event names r=jesup

This commit is contained in:
Adam Roach [:abr] 2013-05-07 21:13:42 -05:00
parent 54fda8e709
commit afe02ec55b
5 changed files with 29 additions and 29 deletions

View File

@ -135,7 +135,7 @@ public:
mRemoteStream = mPC->media()->GetRemoteStream(streams->media_stream_id);
MOZ_ASSERT(mRemoteStream);
}
if ((mCallState == CREATEOFFER) || (mCallState == CREATEANSWER)) {
if ((mCallState == CREATEOFFERSUCCESS) || (mCallState == CREATEANSWERSUCCESS)) {
mSdpStr = aInfo->getSDP();
}
}
@ -165,11 +165,11 @@ public:
}
switch (mCallState) {
case CREATEOFFER:
case CREATEOFFERSUCCESS:
mObserver->OnCreateOfferSuccess(mSdpStr.c_str());
break;
case CREATEANSWER:
case CREATEANSWERSUCCESS:
mObserver->OnCreateAnswerSuccess(mSdpStr.c_str());
break;
@ -181,7 +181,7 @@ public:
mObserver->OnCreateAnswerError(mCode, mReason.c_str());
break;
case SETLOCALDESC:
case SETLOCALDESCSUCCESS:
// TODO: The SDP Parse error list should be copied out and sent up
// to the Javascript layer before being cleared here. Even though
// there was not a failure, it is possible that the SDP parse generated
@ -191,7 +191,7 @@ public:
mObserver->OnSetLocalDescriptionSuccess();
break;
case SETREMOTEDESC:
case SETREMOTEDESCSUCCESS:
// TODO: The SDP Parse error list should be copied out and sent up
// to the Javascript layer before being cleared here. Even though
// there was not a failure, it is possible that the SDP parse generated
@ -1278,12 +1278,12 @@ PeerConnectionImpl::onCallEvent(ccapi_call_event_e aCallEvent,
}
switch (event) {
case SETLOCALDESC:
case SETLOCALDESCSUCCESS:
case UPDATELOCALDESC:
mLocalSDP = aInfo->getSDP();
break;
case SETREMOTEDESC:
case SETREMOTEDESCSUCCESS:
case ADDICECANDIDATE:
mRemoteSDP = aInfo->getSDP();
break;

View File

@ -3156,7 +3156,7 @@ fsmdef_ev_createoffer (sm_event_t *event) {
return (fsmdef_release(fcb, cause, FALSE));
}
ui_create_offer(evCreateOffer, line, call_id,
ui_create_offer(evCreateOfferSuccess, line, call_id,
dcb->caller_id.call_instance_id,
strlib_malloc(local_sdp,-1), PC_NO_ERROR, NULL);
free(local_sdp);
@ -3228,7 +3228,7 @@ fsmdef_ev_createoffer (sm_event_t *event) {
dcb->local_sdp_complete = TRUE;
/* Pass offer SDP back to UI */
ui_create_offer(evCreateOffer, line, call_id,
ui_create_offer(evCreateOfferSuccess, line, call_id,
dcb->caller_id.call_instance_id,
strlib_malloc(msg_body.parts[0].body, -1), PC_NO_ERROR, NULL);
cc_free_msg_body_parts(&msg_body);
@ -3298,7 +3298,7 @@ fsmdef_ev_createanswer (sm_event_t *event) {
return (fsmdef_release(fcb, cause, FALSE));
}
ui_create_answer(evCreateAnswer, line, call_id,
ui_create_answer(evCreateAnswerSuccess, line, call_id,
dcb->caller_id.call_instance_id,
strlib_malloc(local_sdp,-1), PC_NO_ERROR, NULL);
free(local_sdp);
@ -3398,7 +3398,7 @@ fsmdef_ev_createanswer (sm_event_t *event) {
dcb->local_sdp_complete = TRUE;
/* Pass SDP back to UI */
ui_create_answer(evCreateAnswer, line, call_id,
ui_create_answer(evCreateAnswerSuccess, line, call_id,
dcb->caller_id.call_instance_id,
strlib_malloc(msg_body.parts[0].body, -1), PC_NO_ERROR, NULL);
cc_free_msg_body_parts(&msg_body);
@ -3555,7 +3555,7 @@ fsmdef_ev_setlocaldesc(sm_event_t *event) {
return (SM_RC_END);
}
ui_set_local_description(evSetLocalDesc, msg->line, msg->call_id,
ui_set_local_description(evSetLocalDescSuccess, msg->line, msg->call_id,
dcb->caller_id.call_instance_id, strlib_malloc(local_sdp,-1),
PC_NO_ERROR, NULL);
@ -3781,7 +3781,7 @@ fsmdef_ev_setremotedesc(sm_event_t *event) {
return (SM_RC_END);
}
ui_set_remote_description(evSetRemoteDesc, line, call_id,
ui_set_remote_description(evSetRemoteDescSuccess, line, call_id,
dcb->caller_id.call_instance_id, strlib_malloc(remote_sdp,-1),
PC_NO_ERROR, NULL);

View File

@ -31,12 +31,12 @@ typedef enum {
evHoldRevert = HOLDREVERT,
evWhisper = WHISPER,
evWaitingForDigits = WAITINGFORDIGITS,
evCreateOffer = CREATEOFFER,
evCreateAnswer = CREATEANSWER,
evCreateOfferSuccess = CREATEOFFERSUCCESS,
evCreateAnswerSuccess = CREATEANSWERSUCCESS,
evCreateOfferError = CREATEOFFERERROR,
evCreateAnswerError = CREATEANSWERERROR,
evSetLocalDesc = SETLOCALDESC,
evSetRemoteDesc = SETREMOTEDESC,
evSetLocalDescSuccess = SETLOCALDESCSUCCESS,
evSetRemoteDescSuccess = SETREMOTEDESCSUCCESS,
evUpdateLocalDesc = UPDATELOCALDESC,
evSetLocalDescError = SETLOCALDESCERROR,
evSetRemoteDescError = SETREMOTEDESCERROR,

View File

@ -276,12 +276,12 @@ typedef enum {
WHISPER,
PRESERVATION,
WAITINGFORDIGITS = 21,
CREATEOFFER,
CREATEANSWER,
CREATEOFFERSUCCESS,
CREATEANSWERSUCCESS,
CREATEOFFERERROR,
CREATEANSWERERROR,
SETLOCALDESC,
SETREMOTEDESC,
SETLOCALDESCSUCCESS,
SETREMOTEDESCSUCCESS,
UPDATELOCALDESC,
UPDATEREMOTEDESC,
SETLOCALDESCERROR,

View File

@ -115,11 +115,11 @@ std::string CC_SIPCCCallInfo::callStateToString (cc_call_state_t state)
case WAITINGFORDIGITS:
statestr = "WAITINGFORDIGITS";
break;
case CREATEOFFER:
statestr = "CREATEOFFER";
case CREATEOFFERSUCCESS:
statestr = "CREATEOFFERSUCCESS";
break;
case CREATEANSWER:
statestr = "CREATEANSWER";
case CREATEANSWERSUCCESS:
statestr = "CREATEANSWERSUCCESS";
break;
case CREATEOFFERERROR:
statestr = "CREATEOFFERERROR";
@ -127,11 +127,11 @@ std::string CC_SIPCCCallInfo::callStateToString (cc_call_state_t state)
case CREATEANSWERERROR:
statestr = "CREATEANSWERERROR";
break;
case SETLOCALDESC:
statestr = "SETLOCALDESC";
case SETLOCALDESCSUCCESS:
statestr = "SETLOCALDESCSUCCESS";
break;
case SETREMOTEDESC:
statestr = "SETREMOTEDESC";
case SETREMOTEDESCSUCCESS:
statestr = "SETREMOTEDESCSUCCESS";
break;
case UPDATELOCALDESC:
statestr = "UPDATELOCALDESC";