summaryrefslogtreecommitdiff
path: root/InCallUI
diff options
context:
space:
mode:
authorWenyi Wang <wenyiw@google.com>2015-09-15 17:02:17 -0700
committerWenyi Wang <wenyiw@google.com>2015-09-16 13:02:42 -0700
commit96c2b755cf0c503fc152268e3e5761f3074ac6b1 (patch)
tree3aa0c057f86de3bbab52182bb4f9f3f908abcc56 /InCallUI
parent7aa3c70e32c26933db5e7e98069ed3c8a814b979 (diff)
Modified getCallerInfo() to handle silent ringtone
Bug: 12800232 Change-Id: I002c3df378cbaf367f212bf266d3682f6119daec Modified code here so that it is consistent with framework/base/... and this module will be used in the future.
Diffstat (limited to 'InCallUI')
-rw-r--r--InCallUI/src/com/android/incallui/CallerInfo.java7
1 files changed, 6 insertions, 1 deletions
diff --git a/InCallUI/src/com/android/incallui/CallerInfo.java b/InCallUI/src/com/android/incallui/CallerInfo.java
index 88d1be1ab..8979b7f4b 100644
--- a/InCallUI/src/com/android/incallui/CallerInfo.java
+++ b/InCallUI/src/com/android/incallui/CallerInfo.java
@@ -243,7 +243,12 @@ public class CallerInfo {
// in the database.
columnIndex = cursor.getColumnIndex(PhoneLookup.CUSTOM_RINGTONE);
if ((columnIndex != -1) && (cursor.getString(columnIndex) != null)) {
- info.contactRingtoneUri = Uri.parse(cursor.getString(columnIndex));
+ if (cursor.getString(columnIndex).equals("")) {
+ // make it consistent with frameworks/base/.../CallerInfo.java
+ info.contactRingtoneUri = Uri.EMPTY;
+ } else {
+ info.contactRingtoneUri = Uri.parse(cursor.getString(columnIndex));
+ }
} else {
info.contactRingtoneUri = null;
}