From 11f4ae76f016d72486aedd33cfef47ba41e6592e Mon Sep 17 00:00:00 2001 From: Peter Visontay Date: Fri, 25 Feb 2011 12:37:33 +0000 Subject: [PATCH] Removed launch count increase API from Applications. Bug: 3431684 Change-Id: I5bcf8fc6c917cc0ec60302a6c994e4e47b77c357 --- core/java/android/provider/Applications.java | 39 +------------------- 1 file changed, 1 insertion(+), 38 deletions(-) diff --git a/core/java/android/provider/Applications.java b/core/java/android/provider/Applications.java index 3686d173052bb..7aabc5080928a 100644 --- a/core/java/android/provider/Applications.java +++ b/core/java/android/provider/Applications.java @@ -18,7 +18,6 @@ package android.provider; import android.content.ComponentName; import android.content.ContentResolver; -import android.content.ContentValues; import android.database.Cursor; import android.net.Uri; @@ -27,12 +26,10 @@ import java.util.List; /** * The Applications provider gives information about installed applications. * - * @hide Only used by ApplicationsProvider and Launchers so far. + * @hide Only used by ApplicationsProvider so far. */ public class Applications { - private static final String TAG = "ApplicationsProvider"; - /** * The content authority for this provider. */ @@ -67,26 +64,6 @@ public class Applications { public static final String APPLICATION_DIR_TYPE = ContentResolver.CURSOR_DIR_BASE_TYPE + "/" + APPLICATION_SUB_TYPE; - /** - * The path that should be used when an application is launched. The aim is - * to help ApplicationsProvider keep track of which applications the user - * uses the most, and improve app ranking based on this. - */ - public static final String INCREASE_LAUNCH_COUNT_PATH = "increase_launch_count"; - - public static final Uri INCREASE_LAUNCH_COUNT_URI = CONTENT_URI.buildUpon() - .appendPath(INCREASE_LAUNCH_COUNT_PATH).build(); - - /** - * The package name parameter for the "increase launch count" call. - */ - public static final String INCREASE_LAUNCH_COUNT_PACKAGE = "packageName"; - - /** - * The classname parameter for the "increase launch count" call. - */ - public static final String INCREASE_LAUNCH_COUNT_CLASS = "className"; - /** * no public constructor since this is a utility class */ @@ -101,20 +78,6 @@ public class Applications { return resolver.query(searchUri, null, null, null, null); } - /** - * Increases the launch count of an application. Launch counts are used - * by the ApplicationsProvider to improve ranking. - */ - public static void increaseLaunchCount( - final ContentResolver resolver, final ComponentName componentName) { - - ContentValues parameters = new ContentValues(); - parameters.put(INCREASE_LAUNCH_COUNT_PACKAGE, componentName.getPackageName()); - parameters.put(INCREASE_LAUNCH_COUNT_CLASS, componentName.getClassName()); - - resolver.insert(INCREASE_LAUNCH_COUNT_URI, parameters); - } - /** * Gets the application component name from an application URI. *