do not change intent to retracted if end card had already been reached
This commit is contained in:
parent
f106cbccf5
commit
8374df84aa
|
@ -108,9 +108,13 @@ public class RtpSessionActivity extends XmppActivity implements XmppConnectionSe
|
||||||
|
|
||||||
private void retractSessionProposal() {
|
private void retractSessionProposal() {
|
||||||
final Intent intent = getIntent();
|
final Intent intent = getIntent();
|
||||||
|
final String action = intent.getAction();
|
||||||
final Account account = extractAccount(intent);
|
final Account account = extractAccount(intent);
|
||||||
final Jid with = Jid.of(intent.getStringExtra(EXTRA_WITH));
|
final Jid with = Jid.of(intent.getStringExtra(EXTRA_WITH));
|
||||||
resetIntent(account, with, RtpEndUserState.RETRACTED, actionToMedia(intent.getAction()));
|
final String state = intent.getStringExtra(EXTRA_LAST_REPORTED_STATE);
|
||||||
|
if (!Intent.ACTION_VIEW.equals(action) || state == null || !END_CARD.contains(RtpEndUserState.valueOf(state))) {
|
||||||
|
resetIntent(account, with, RtpEndUserState.RETRACTED, actionToMedia(intent.getAction()));
|
||||||
|
}
|
||||||
xmppConnectionService.getJingleConnectionManager().retractSessionProposal(account, with.asBareJid());
|
xmppConnectionService.getJingleConnectionManager().retractSessionProposal(account, with.asBareJid());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue