summaryrefslogtreecommitdiffstats
path: root/src/com/android/launcher3/Folder.java
diff options
context:
space:
mode:
authorAdam Cohen <adamcohen@google.com>2013-09-20 12:05:49 -0700
committerAdam Cohen <adamcohen@google.com>2013-09-20 14:13:44 -0700
commit477828cc83b60a17eb9b6fc8ee08b4abbc3d2fb1 (patch)
treec22828ede8209ec8da2290c246b47f6108849caf /src/com/android/launcher3/Folder.java
parent89f9705077c054b541af7da52be832760e2ae2e8 (diff)
downloadandroid_packages_apps_Trebuchet-477828cc83b60a17eb9b6fc8ee08b4abbc3d2fb1.tar.gz
android_packages_apps_Trebuchet-477828cc83b60a17eb9b6fc8ee08b4abbc3d2fb1.tar.bz2
android_packages_apps_Trebuchet-477828cc83b60a17eb9b6fc8ee08b4abbc3d2fb1.zip
New folder look / assets
-> Restricting the number of items in folders to prevent scrolling (excess items deleted) Change-Id: I4af2590cd5ea7677c875c031f84d4d5bcca3e6e9
Diffstat (limited to 'src/com/android/launcher3/Folder.java')
-rw-r--r--src/com/android/launcher3/Folder.java9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/com/android/launcher3/Folder.java b/src/com/android/launcher3/Folder.java
index 808d85d66..47fc6c3f4 100644
--- a/src/com/android/launcher3/Folder.java
+++ b/src/com/android/launcher3/Folder.java
@@ -143,7 +143,8 @@ public class Folder extends LinearLayout implements DragSource, View.OnClickList
Resources res = getResources();
mMaxCountX = (int) grid.numColumns;
- mMaxCountY = mMaxNumItems = Integer.MAX_VALUE;
+ mMaxCountY = (int) grid.numRows;
+ mMaxNumItems = mMaxCountX * mMaxCountY;
mInputMethodManager = (InputMethodManager)
getContext().getSystemService(Context.INPUT_METHOD_SERVICE);
@@ -526,12 +527,14 @@ public class Folder extends LinearLayout implements DragSource, View.OnClickList
}
protected boolean createAndAddShortcut(ShortcutInfo item) {
- final TextView textView =
- (TextView) mInflater.inflate(R.layout.application, this, false);
+ final BubbleTextView textView =
+ (BubbleTextView) mInflater.inflate(R.layout.application, this, false);
textView.setCompoundDrawablesWithIntrinsicBounds(null,
new FastBitmapDrawable(item.getIcon(mIconCache)), null, null);
textView.setText(item.title);
textView.setTag(item);
+ textView.setTextColor(getResources().getColor(R.color.folder_items_text_color));
+ textView.setShadowsEnabled(false);
textView.setOnClickListener(this);
textView.setOnLongClickListener(this);