Commit Graph

7 Commits

Author SHA1 Message Date
Jon Miranda
e6f3fa47d6 Fix bug where folder items preview remain in low res state.
- We update the ranks of all folder items after loading, to ensure there are
  no gaps caused by removed folder items. This also ensures that we load
  the high resolution icons for all preview items.
- FolderIconPreviewVerifier#setFolderInfo was not always called
- Init mGridSize with [1, 1] to prevent divide by zero error in case
  setFolderInfo is not called

Bug: 126268196
Change-Id: I856489968665a39303e2922c78cf90f2b3ee6ebb
2019-03-08 12:43:09 -08:00
Sunny Goyal
add3d8322d Removing some folder customization options
The old folder preview and animation relied on creating bitmaps for transition.
As we move to hardware bitmaps, creating custom bitmaps which rely on icon bitmaps
would be costly (hardware bitmaps are immutable and cannot be drawn on a software canvas).

Bug: 35428783
Change-Id: I39869ed44feb6a886985ad15775bc1ab55565727
2017-09-08 12:07:24 -07:00
Jon Miranda
4dd024b974 Add new motion for when Folder preview changes due to onDrop.
Instead of changing the display order of the Folder to preserve
the upper left quadrant, we are opting to change the Folder Icon
preview to always show the upper left quadrant.

This means that when adding items to a Folder, the preview items
may change. (They will change when the column size increases).

Bug: 27944225
Bug: 63140071
Change-Id: I863c2479469d68559cab2878030c2087d48217d6
2017-07-14 14:27:44 -07:00
Jonathan Miranda
8701cd58cf Revert "Match items in icon preview with items in Folder using permutations."
This reverts commit 69c340a05e.

Change-Id: I4178b58e847a87e5cd7e5fa4b6886f0d72ba387b
2017-07-13 16:49:33 -07:00
Jon Miranda
27bdbcae7f Slide in first page preview items in FolderIcon after Folder closes.
If the Folder is not closed on on the first page, we animate the
current page items as if they are in the preview.

When the Folder finishes closing, the first page preview items
slide in as the current page preview items slide out.

Bug: 36022592
Bug: 35064148
Change-Id: I7ede7ed9e091e2a0c3cbe11731744bfe9ce36595
2017-07-10 11:28:57 -07:00
Jon Miranda
69c340a05e Match items in icon preview with items in Folder using permutations.
Before, with the FolderIconPreviewVerifier, we would
adjust which items are displayed in the FolderIcon.
This caused some issues where the apps in the folder
icon would jump to whatever was in the upper left quadrant.

Now, we always display the 4 first items in the icon by
modifying the XY positions of the items within the Folder.

Bug: 27944225
Bug: 35064148
Change-Id: I46c0fbb064d4da4da155e29963bfb92b14e40f07
2017-06-28 09:52:11 -07:00
Jon Miranda
655ec42ce5 Added FolderIconPreviewVerifier class.
This class verifies whether an item in a Foder is displayed in
the FolderIcon preview, based on the item's rank.

We use this class to determine which items in a Folder will be
displayed in the preview.

Bug: 35064148
Change-Id: Ia21bccbd95c348efeac62591ae3696a4c60b5339
2017-02-28 11:57:26 -08:00