Fix dialer hang button sometimes doesn't hang calls.

This commit is contained in:
Guillaume Beraudo 2011-10-10 15:03:37 +02:00
parent 01674c3b1a
commit 7f2efdb451

View file

@ -136,18 +136,19 @@ public class DialerActivity extends Activity implements LinphoneGuiListener, Lin
mInCallAddressLayout = findViewById(R.id.IncallAddressLayout); mInCallAddressLayout = findViewById(R.id.IncallAddressLayout);
mInCallAddressLayout.setVisibility(View.GONE); mInCallAddressLayout.setVisibility(View.GONE);
if (useConferenceActivity) { HangCallButton hang = (HangCallButton) findViewById(R.id.HangUp);
mHangup = findViewById(R.id.HangUp); HangCallButton decline = (HangCallButton) findViewById(R.id.Decline);
((HangCallButton)mHangup).setTerminateAllCalls(true); hang.setTerminateAllCalls(true);
} else if (useIncallActivity) { decline.setTerminateAllCalls(true);
mHangup = findViewById(R.id.HangUp);
if (useConferenceActivity || useIncallActivity) {
mHangup = hang;
} else { } else {
mMute = (MuteMicButton) findViewById(R.id.mic_mute_button); mMute = (MuteMicButton) findViewById(R.id.mic_mute_button);
mSpeaker = (SpeakerButton) findViewById(R.id.speaker_button); mSpeaker = (SpeakerButton) findViewById(R.id.speaker_button);
mHangup = findViewById(R.id.Decline); mHangup = decline;
} }
mStatus = (TextView) findViewById(R.id.status_label); mStatus = (TextView) findViewById(R.id.status_label);
AddressAware numpad = (AddressAware) findViewById(R.id.Dialer); AddressAware numpad = (AddressAware) findViewById(R.id.Dialer);