Added security for BT + fix incoming call when no sdp
This commit is contained in:
parent
9b5cd0471a
commit
3cf1b6cd63
2 changed files with 2 additions and 5 deletions
|
@ -156,11 +156,6 @@ public class IncomingCallActivity extends Activity implements LinphoneOnCallStat
|
||||||
|
|
||||||
private void answer() {
|
private void answer() {
|
||||||
LinphoneCallParams params = LinphoneManager.getLc().createDefaultCallParameters();
|
LinphoneCallParams params = LinphoneManager.getLc().createDefaultCallParameters();
|
||||||
if (mCall != null && mCall.getRemoteParams() != null && mCall.getRemoteParams().getVideoEnabled() && LinphonePreferences.instance().shouldAutomaticallyAcceptVideoRequests()) {
|
|
||||||
params.setVideoEnabled(true);
|
|
||||||
} else {
|
|
||||||
params.setVideoEnabled(false);
|
|
||||||
}
|
|
||||||
|
|
||||||
boolean isLowBandwidthConnection = !LinphoneUtils.isHightBandwidthConnection(this);
|
boolean isLowBandwidthConnection = !LinphoneUtils.isHightBandwidthConnection(this);
|
||||||
if (isLowBandwidthConnection) {
|
if (isLowBandwidthConnection) {
|
||||||
|
|
|
@ -854,6 +854,8 @@ public class LinphoneManager implements LinphoneCoreListener {
|
||||||
else if (state == State.IncomingReceived || (state == State.CallIncomingEarlyMedia && mR.getBoolean(R.bool.allow_ringing_while_early_media))) {
|
else if (state == State.IncomingReceived || (state == State.CallIncomingEarlyMedia && mR.getBoolean(R.bool.allow_ringing_while_early_media))) {
|
||||||
// Brighten screen for at least 10 seconds
|
// Brighten screen for at least 10 seconds
|
||||||
if (mLc.getCallsNb() == 1) {
|
if (mLc.getCallsNb() == 1) {
|
||||||
|
BluetoothManager.getInstance().disableBluetoothSCO(); // Just in case
|
||||||
|
|
||||||
ringingCall = call;
|
ringingCall = call;
|
||||||
startRinging();
|
startRinging();
|
||||||
// otherwise there is the beep
|
// otherwise there is the beep
|
||||||
|
|
Loading…
Reference in a new issue