am b595e094: Merge "Return display name in SipConnection.getCnapName()." into gingerbread

Merge commit 'b595e094e3901ff8a224eaf7d4869e7d2e5649dd' into gingerbread-plus-aosp

* commit 'b595e094e3901ff8a224eaf7d4869e7d2e5649dd':
  Return display name in SipConnection.getCnapName().
This commit is contained in:
Hung-ying Tyan
2010-10-19 23:03:25 -07:00
committed by Android Git Automerger

View File

@ -28,6 +28,7 @@ import android.os.AsyncResult;
import android.os.Message;
import android.telephony.PhoneNumberUtils;
import android.telephony.ServiceState;
import android.text.TextUtils;
import android.util.Log;
import com.android.internal.telephony.Call;
@ -673,6 +674,18 @@ public class SipPhone extends SipPhoneBase {
this(owner, callee, getUriString(callee));
}
@Override
public String getCnapName() {
String displayName = mPeer.getDisplayName();
return TextUtils.isEmpty(displayName) ? null
: displayName;
}
@Override
public int getNumberPresentation() {
return Connection.PRESENTATION_ALLOWED;
}
void initIncomingCall(SipAudioCall sipAudioCall, Call.State newState) {
setState(newState);
mSipAudioCall = sipAudioCall;