diff options
author | blong <blong@codeaurora.org> | 2014-08-27 17:54:38 +0800 |
---|---|---|
committer | blong <blong@codeaurora.org> | 2015-09-06 15:01:52 +0800 |
commit | 7c4b95f00c1bffaa238428d325aa49de6ebc7c59 (patch) | |
tree | 634dd4cc05cd8bc52b5006b0644dd628ea80db9e /src/com/android | |
parent | cce7fa32a6bc960478eb217446cff58ad6fa0bab (diff) | |
download | packages_providers_ContactsProvider-7c4b95f00c1bffaa238428d325aa49de6ebc7c59.zip packages_providers_ContactsProvider-7c4b95f00c1bffaa238428d325aa49de6ebc7c59.tar.gz packages_providers_ContactsProvider-7c4b95f00c1bffaa238428d325aa49de6ebc7c59.tar.bz2 |
Support to delete single call log
- Add the case to delete single call log
Change-Id: I9d33108b9fc66c73bf71757823b2d2a92727e65d
Diffstat (limited to 'src/com/android')
-rw-r--r-- | src/com/android/providers/contacts/CallLogProvider.java | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/com/android/providers/contacts/CallLogProvider.java b/src/com/android/providers/contacts/CallLogProvider.java index f83e4a7..9070e78 100644 --- a/src/com/android/providers/contacts/CallLogProvider.java +++ b/src/com/android/providers/contacts/CallLogProvider.java @@ -49,6 +49,7 @@ import com.android.providers.contacts.ContactsDatabaseHelper.DbProperties; import com.android.providers.contacts.ContactsDatabaseHelper.Tables; import com.android.providers.contacts.util.SelectionBuilder; import com.android.providers.contacts.util.UserUtils; + import com.google.common.annotations.VisibleForTesting; import java.util.HashMap; @@ -364,6 +365,10 @@ public class CallLogProvider extends ContentProvider { case CALLS: return getDatabaseModifier(db).delete(Tables.CALLS, selectionBuilder.build(), selectionArgs); + case CALLS_ID: + return getDatabaseModifier(db).delete(Tables.CALLS, + new SelectionBuilder(Calls._ID + "=?").build(), + new String[] { uri.getLastPathSegment() }); default: throw new UnsupportedOperationException("Cannot delete that URL: " + uri); } |