package com.android.internal.telephony;
import android.annotation.UnsupportedAppUsage;
+import android.content.ComponentName;
import android.content.ContentResolver;
import android.content.Context;
import android.database.Cursor;
import android.provider.ContactsContract.RawContacts;
import android.telephony.PhoneNumberUtils;
import android.telephony.Rlog;
+import android.telephony.SubscriptionManager;
import android.telephony.TelephonyManager;
import android.text.TextUtils;
import android.util.Log;
-import com.android.i18n.phonenumbers.geocoding.PhoneNumberOfflineGeocoder;
import com.android.i18n.phonenumbers.NumberParseException;
import com.android.i18n.phonenumbers.PhoneNumberUtil;
import com.android.i18n.phonenumbers.Phonenumber.PhoneNumber;
-import android.telephony.SubscriptionManager;
+import com.android.i18n.phonenumbers.geocoding.PhoneNumberOfflineGeocoder;
import java.util.Locale;
public Uri contactRefUri;
public String lookupKey;
+ public ComponentName preferredPhoneAccountComponent;
+ public String preferredPhoneAccountId;
+
public long userType;
/**
info.contactDisplayPhotoUri = null;
}
+ columnIndex = cursor.getColumnIndex(Data.PREFERRED_PHONE_ACCOUNT_COMPONENT_NAME);
+ if ((columnIndex != -1) && (cursor.getString(columnIndex) != null)) {
+ info.preferredPhoneAccountComponent =
+ ComponentName.unflattenFromString(cursor.getString(columnIndex));
+ }
+
+ columnIndex = cursor.getColumnIndex(Data.PREFERRED_PHONE_ACCOUNT_ID);
+ if ((columnIndex != -1) && (cursor.getString(columnIndex) != null)) {
+ info.preferredPhoneAccountId = cursor.getString(columnIndex);
+ }
+
// look for the custom ringtone, create from the string stored
// in the database.
// An empty string ("") in the database indicates a silent ringtone,