Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ed3723f8 authored by Zongheng Wang's avatar Zongheng Wang
Browse files

Remove getLine1AlphaTag() in Bluetooth code

getLine1AlphaTag() always returns null or an empty string.

Bug: 140562205
Test: Manual
Change-Id: Ib98574740c10f368e302e57c63b245e9c6408f90
parent c9cfbd07
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -2190,7 +2190,6 @@ public class BluetoothMapContent {
        if (tm != null) {
            fi.mPhoneType = tm.getPhoneType();
            fi.mPhoneNum = tm.getLine1Number();
            fi.mPhoneAlphaTag = tm.getLine1AlphaTag();
        }
    }

+1 −4
Original line number Diff line number Diff line
@@ -1454,12 +1454,9 @@ public class BluetoothMapContentObserver {
                                                    Context.TELEPHONY_SERVICE);
                                    if (tm != null) {
                                        phone = tm.getLine1Number();
                                        name = tm.getLine1AlphaTag();
                                        if (name == null || name.isEmpty()) {
                                        name = phone;
                                    }
                                }
                                }
                                String priority = "no"; // no priority for sms
                                /* Incoming message from the network */
                                if (mMapEventReportVersion
+1 −5
Original line number Diff line number Diff line
@@ -50,7 +50,6 @@ import android.os.Message;
import android.os.PowerManager;
import android.os.UserManager;
import android.telephony.TelephonyManager;
import android.text.TextUtils;
import android.util.Log;

import com.android.bluetooth.IObexConnectionHandler;
@@ -785,11 +784,8 @@ public class BluetoothPbapService extends ProfileService implements IObexConnect
        TelephonyManager tm = (TelephonyManager) getSystemService(Context.TELEPHONY_SERVICE);
        if (tm != null) {
            sLocalPhoneNum = tm.getLine1Number();
            sLocalPhoneName = tm.getLine1AlphaTag();
            if (TextUtils.isEmpty(sLocalPhoneName)) {
            sLocalPhoneName = this.getString(R.string.localPhoneName);
        }
        }
        if (VERBOSE)
            Log.v(TAG, "Local Phone Details- Number:" + sLocalPhoneNum
                    + ", Name:" + sLocalPhoneName);