|
@@ -5,6 +5,7 @@ import android.content.ContentValues;
|
|
|
import android.content.Context;
|
|
import android.content.Context;
|
|
|
import android.content.Intent;
|
|
import android.content.Intent;
|
|
|
import android.net.Uri;
|
|
import android.net.Uri;
|
|
|
|
|
+import android.os.Build;
|
|
|
import android.provider.ContactsContract;
|
|
import android.provider.ContactsContract;
|
|
|
|
|
|
|
|
import com.usai.redant.rautils.contactkit.element.EmailAddress;
|
|
import com.usai.redant.rautils.contactkit.element.EmailAddress;
|
|
@@ -195,7 +196,11 @@ public class ContactUIHelper {
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
if (address.street != null) {
|
|
if (address.street != null) {
|
|
|
- values.put(ContactsContract.CommonDataKinds.StructuredPostal.STREET, address.street);
|
|
|
|
|
|
|
+
|
|
|
|
|
+ if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O)
|
|
|
|
|
+ values.put(ContactsContract.CommonDataKinds.StructuredPostal.FORMATTED_ADDRESS, address.street);
|
|
|
|
|
+ else
|
|
|
|
|
+ values.put(ContactsContract.CommonDataKinds.StructuredPostal.STREET, address.street);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
if (address.postalCode != null) {
|
|
if (address.postalCode != null) {
|