diff options
author | nebkat <nebkat@teamhacksung.org> | 2012-12-28 22:18:49 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@review.cyanogenmod.com> | 2012-12-29 02:05:44 -0800 |
commit | 3786ed8df9344d365d063406828afee8293acda8 (patch) | |
tree | 36697f8caa98447f65ef9e538f0dcc6d114fadaa /src/com/cyanogenmod/trebuchet/AppsCustomizePagedView.java | |
parent | ce7dcdd77320ff852f4b8b53ededd4220379fe44 (diff) | |
download | packages_apps_trebuchet-3786ed8df9344d365d063406828afee8293acda8.zip packages_apps_trebuchet-3786ed8df9344d365d063406828afee8293acda8.tar.gz packages_apps_trebuchet-3786ed8df9344d365d063406828afee8293acda8.tar.bz2 |
Launcher: Remove long-press menu
Change-Id: Ie513c0c815fcfa0daa2d5503d3c060ae8e2109c0
Diffstat (limited to 'src/com/cyanogenmod/trebuchet/AppsCustomizePagedView.java')
-rw-r--r-- | src/com/cyanogenmod/trebuchet/AppsCustomizePagedView.java | 26 |
1 files changed, 0 insertions, 26 deletions
diff --git a/src/com/cyanogenmod/trebuchet/AppsCustomizePagedView.java b/src/com/cyanogenmod/trebuchet/AppsCustomizePagedView.java index 127f28f..d1a2006 100644 --- a/src/com/cyanogenmod/trebuchet/AppsCustomizePagedView.java +++ b/src/com/cyanogenmod/trebuchet/AppsCustomizePagedView.java @@ -646,7 +646,6 @@ public class AppsCustomizePagedView extends PagedViewWithDraggableItems implemen AppWidgetManager.getInstance(mLauncher).getInstalledProviders(); Intent shortcutsIntent = new Intent(Intent.ACTION_CREATE_SHORTCUT); List<ResolveInfo> shortcuts = mPackageManager.queryIntentActivities(shortcutsIntent, 0); - List<LauncherAction.Action> launcherActions = LauncherAction.getAllActions(); for (AppWidgetProviderInfo widget : widgets) { if (widget.minWidth > 0 && widget.minHeight > 0) { // Ensure that all widgets we show can be added on a workspace of this size @@ -667,7 +666,6 @@ public class AppsCustomizePagedView extends PagedViewWithDraggableItems implemen } } mWidgets.addAll(shortcuts); - mWidgets.addAll(launcherActions); Collections.sort(mWidgets, new LauncherModel.WidgetAndShortcutNameComparator(mLauncher, mPackageManager)); updatePageCounts(); @@ -1434,19 +1432,6 @@ public class AppsCustomizePagedView extends PagedViewWithDraggableItems implemen return preview; } - private Bitmap getShortcutPreview(LauncherAction.Action info) { - int offset = 0; - int bitmapSize = mAppIconSize; - Bitmap preview = Bitmap.createBitmap(bitmapSize, bitmapSize, Config.ARGB_8888); - - final Resources res = getContext().getResources(); - - // Render the icon - Drawable icon = res.getDrawable(info.getDrawable()); - renderDrawableToBitmap(icon, preview, offset, offset, mAppIconSize, mAppIconSize); - return preview; - } - private Bitmap getWidgetPreview(ComponentName provider, int previewImage, int iconId, int cellHSpan, int cellVSpan, int maxWidth, int maxHeight) { // Load the preview image if possible @@ -1620,14 +1605,6 @@ public class AppsCustomizePagedView extends PagedViewWithDraggableItems implemen info.activityInfo.name); widget.applyFromResolveInfo(mPackageManager, info); widget.setTag(createItemInfo); - } else if (rawInfo instanceof LauncherAction.Action) { - // Fill in the actions information - LauncherAction.Action info = (LauncherAction.Action) rawInfo; - createItemInfo = new PendingAddActionInfo(); - ((PendingAddActionInfo)createItemInfo).action = info; - createItemInfo.itemType = LauncherSettings.Favorites.ITEM_TYPE_LAUNCHER_ACTION; - widget.applyFromLauncherAction(info); - widget.setTag(createItemInfo); } widget.setOnClickListener(this); widget.setOnLongClickListener(this); @@ -1714,9 +1691,6 @@ public class AppsCustomizePagedView extends PagedViewWithDraggableItems implemen // Fill in the shortcuts information ResolveInfo info = (ResolveInfo) item; images.add(getShortcutPreview(info, data.maxImageWidth, data.maxImageHeight)); - } else if (item instanceof LauncherAction.Action) { - LauncherAction.Action info = (LauncherAction.Action) item; - images.add(getShortcutPreview(info)); } } } |