summaryrefslogtreecommitdiffstats
path: root/src/com/android/launcher3/IconCache.java
Commit message (Collapse)AuthorAgeFilesLines
...
| * Preventing launcher crashes due to low disk space.Sunny Goyal2015-12-181-80/+71
| | | | | | | | | | | | | | | | | | | | In case of low disk space, all write operations to the IconCache are silently ignored. This will not affect the Launcher behavior and user will still see the latest icons, but in some cases, icon loading would appear slow Bug: 24585352 Change-Id: I85ccc519046fc3708403388bba89e019a3f2ce3d
* | resolve merge conflicts of d896ee43cd to ub-launcher3-master.Sunny Goyal2015-12-171-1/+5
|\| | | | | | | Change-Id: If09db8d99e7065c08fcb81b8d97a68a2557d53d7
| * Protecting Icon normalization behind a feature flagSunny Goyal2015-12-171-1/+5
| | | | | | | | Change-Id: I91b7126765049372a3ffec3ad6f661715dc83bab
* | Reverting the cache version change, so that users on release version do not ↵Sunny Goyal2015-12-161-1/+1
|\| | | | | | | | | | | | | | | | | get the cache reset am: 2b84b652b3 * commit '2b84b652b33977d82e0af4ab9fdc7a97cb8d5a33': Reverting the cache version change, so that users on release version do not get the cache reset
| * Reverting the cache version change, so that users on release version do not ↵Sunny Goyal2015-12-151-1/+1
| | | | | | | | | | | | get the cache reset Change-Id: I61b06ca001e6ae47693e8d6f467565314d66f1b4
* | resolve merge conflicts of 39b700fcc5 to ub-launcher3-master.Sunny Goyal2015-12-041-1/+1
|\| | | | | | | Change-Id: I394258be0c75289cab2f5141c0fb765504527420
| * Normalizing app icons based on the standard icon guidelinesSunny Goyal2015-12-021-1/+1
| | | | | | | | | | Bug: 18245189 Change-Id: Iaadcddbe3f966733a13b2e1fb60ba09a8b3aef9a
| * Scaling down the icon before applying the user badgeSunny Goyal2015-11-251-14/+7
| | | | | | | | | | | | | | > This also saves memory only create one new bitmap while loading instead of two Bug: 25027252 Change-Id: Ia594dd65a30f32e99404190f649b334615c9e17f
* | Scaling down the icon before applying the user badgeSunny Goyal2015-10-191-14/+7
| | | | | | | | | | | | | | > This also saves memory only create one new bitmap while loading instead of two Bug: 25027252 Change-Id: Ia594dd65a30f32e99404190f649b334615c9e17f
* | Prevent full sized icons from being stored when low-res icons are requested.Winson2015-08-311-23/+33
|/ | | | | | | | | | | - When LauncherModel loads for the first time, the full set of widget package icons are loaded, which loads and stores full resolution icons even if low-res icons are requested. This CL ensures that if we query for package icons, the low res icon is returned if it is requested, only loading the high-res icons when the user goes into the widgets tray. Bug: 22797443 Change-Id: I45cd23c302c5e654ba7e0306a4b07b2fbeb70d2b
* Using GET_UNINSTALLED_PACKAGES flag when getting packageInfo for a managed ↵Sunny Goyal2015-08-281-2/+4
| | | | | | | profile app Bug: 23515512 Change-Id: I60678eccd4b60225ff30960f7197d633f72c7659
* Merge "Fixing widget restore" into ub-launcher3-burnabySunny Goyal2015-07-211-12/+23
|\
| * Fixing widget restoreSunny Goyal2015-07-201-12/+23
| | | | | | | | | | | | | | | | > Widget restore active flag was not cleared when the app was downloaded > Icon from session info was not getting cached Bug: 22413379 Change-Id: Ie096b929252200675a76dadd8c25cc3aa433671b
* | Resizing the bitmap before caching it in the DBSunny Goyal2015-07-201-2/+4
|/ | | | | | | | | > The icon size in the backup can be different that what is required by the device. We should resize the icon, before caching it. Bug: 22413328 Change-Id: Id77c53edf8ea5e95a2d32dbe22be553120279ebd
* Using highres icons for backupSunny Goyal2015-07-151-1/+1
| | | | | Bug: 22410445 Change-Id: I0fbc2d1217127556af806f12dbb5960712627ab7
* Using RGB_565 for low-res iconsSunny Goyal2015-07-011-27/+67
| | | | | | | | | > Using a non-transparent image with flat background for low-res icons > Changing the scale factor from 8 to 5 > The overall size change is 1/50 instead of 1/64 Bug: 22204941 Change-Id: I6cda4b4b3450c23a7bb8218ebd2de2b09af9c414
* Fixing backup restoreSunny Goyal2015-06-251-5/+11
| | | | | | | | | | | | | | | > Not deleting icons from cache, which have not been restored yet > Not checking if activity exists during DB migration. Missing components are removed during loader anyway > Backing up and restoring bitmaps even when iconType is resource. This allows us to show a proper bitmap icon, until the correct resource is available. > Loading proper shortcutResource icon for promiseIcons > Checking against promise intent when verifying duplicates > A launcher App intent can contain EXTRA_PROFILE Bug: 22094970 Change-Id: I982971338846733833ec133119393af0bea0eb08
* Cancelling launcher reload on mcc changeSunny Goyal2015-06-181-6/+4
| | | | | Bug: 21022833 Change-Id: Iccd477e7b1638d162e1a500cdb7a52b8d359c657
* Deleting empty folders based on DB stateSunny Goyal2015-06-121-1/+1
| | | | | | | | | > Previously folders were getting deleted based on in-memory loader state. If for some reason, an item failed to load, we would delete the folder from DB as well. Bug: 21354058 Change-Id: I5318ee8a99afa9cafd93ed2b9ef0e155f502a41b
* Updating widget list when iconCache updatesSunny Goyal2015-06-041-1/+4
| | | | | | | | | > Fixing bug where items were not getting removed from the memcache > Fixing bug where package entries were not getting removing because of component mismatch. Bug: 21612532 Change-Id: Ie56f3272f7fb7e1a37c5ff9bfa523d814edc1a02
* Fixing different bitmap sizes in different orientationsSunny Goyal2015-06-031-10/+2
| | | | | | | | | > Using a single bitmap icon size > Picking up appropriate density for satisfy the required icon size > Fixing some icon size assumptions during icon animations Bug: 19514688 Change-Id: Ia7a1d0d2c03a9d39ccc241fa4ae3eb8a0f374585
* Removing some synthetic method creationSunny Goyal2015-06-021-9/+9
| | | | | | > Make package-private and @Thunk all private methods and constructors accessed from inner classes. Change-Id: Ie5913860a0c33e48e9bf68f9b5b1699f64c2f174
* Merge "Ensuring that each CacheEntry has a default title and content ↵Winson Chung2015-05-281-3/+9
|\ | | | | | | description." into ub-launcher3-burnaby
| * Ensuring that each CacheEntry has a default title and content description.Winson Chung2015-05-281-5/+9
| | | | | | | | | | | | | | | | - Also defer adding entry to cache until we know that it has correctly loaded Bug: 21446070 Change-Id: Ia7aae65ecdc5d9d7741f75d3fb6e7b85daeafeff
* | Removing file IO used for checking configuration changeSunny Goyal2015-05-261-9/+0
|/ | | | | | | > This check was used for flushing the cache, but since the cache is backed by a DB, this has no effect as same icons are loaded again Change-Id: Ib7d8a8598c5d225d922e095c899dc11ad06f2b7a
* Refactoring DeviceProfileAdam Cohen2015-05-211-15/+1
| | | | | | | | | | | | | | | | | | | | -> Pulling out the parts of device profile which can (and need to be) initialized and accessed without access to an Activity context, ie. the invariant bits. -> The invariant bits are stored in InvariantDeviceProfile which is initialized statically from LauncherAppState. -> The DeviceProfile contains the Activity context-dependent bits, and we will create one of these for each Activity instance, and this instance is accessed through the Launcher activity. -> It's possible that we can continue to refactor this such that all appropriate dimensions can be computed without an Activity context (by only specifying orientation). This would be an extension of this CL and allow us to know exactly how launcher will look in both orientations from any context. Sets the stage for some improvements around b/19514688 Change-Id: Ia7daccf14d8ca2b9cb340b8780b684769e9f1892
* Merge "Breaking icon update task so that it doesn't block worker thread" ↵Sunny Goyal2015-05-211-26/+69
|\ | | | | | | into ub-launcher3-burnaby
| * Breaking icon update task so that it doesn't block worker threadSunny Goyal2015-05-211-26/+69
| | | | | | | | | | Bug: 20945600 Change-Id: Iaf516577898b51ad6e8a813d7f018ecad969c100
* | Load PackageItemInfo in background thread to prevent ANRHyunyoung Song2015-05-211-1/+1
|/ | | | | | | | | | | - Decoupled widget model from widget view, and placed the creation to LauncherModel. - As a result packagemanager operation, iconcache retrieval is all done inside LauncherModel on background thread b/21311085 b/21325319 Change-Id: I294698527db58b89f3da558090a367530c058776
* Avoiding blocking worker thread when adding icons to DBSunny Goyal2015-05-191-12/+58
| | | | | Bug: 20945600 Change-Id: If12b21ac62c55c769838ce17d5421f147c396256
* Using BubbleTextView for widget section headersSunny Goyal2015-05-121-0/+3
| | | | | | > Loading highres icons on the worker thread. Change-Id: I5b68a86820aa4c132c156339e497354cf57f0fca
* Trim all whitespace from titles and labels.Winson Chung2015-05-081-5/+5
| | | | | | Bug: 20953160 Change-Id: I1610df5e445a4139522226f68fa6439926bc70c6
* Updating the icon cache after all apps has been bound.Sunny Goyal2015-05-061-1/+15
| | | | | | | > Updating the cache DB version to reset existing cache. Bug: 20834835 Change-Id: I298ca9ddcc4dd270b25b767447ecde01ef41a916
* Fixing missing updates in package install sessionsSunny Goyal2015-04-221-6/+10
| | | | | | | | | | | | > Ensure icon cache never returns null icon > Enabling install shortuct receiver only after workspace has finished binding > Making all the model changes for package installs on worker thread and only posting the updaes on the UI > Making shortcut exists check on the loaded items and not on the DB > Explicitely using worker thread for PckageInstallListener > Removing backward compatibility support from PackageInstallerCompat Change-Id: I9592771b9670c1c1c84c8208cae8dafa7b393e65
* Wrong icon getting set for an app on secondary user during updatesSunny Goyal2015-04-131-2/+2
| | | | | Bug: 20163841 Change-Id: Ief91db56f7831f89e34c4540981a9d2db96b8bed
* WidgetTray revamp workHyunyoung Song2015-04-081-5/+7
| | | | | | | | | | | | | | | | | | | | | | | - RecyclerView is rendering - Animation is connected - Drag and drop is now handled - UI tweaking: background, margins, more to come. - Flicker and preview not loading issue: fixed height for the horizontal scroll view. - Shortcuts are added - Widget Preview loading should support shortPress for drop - UI tweaks left: overlay of arrow when there are more items to scroll - icons are added in the section header - Sorting of widget sections and widget horizontal list - Adding all the padding constants to dimen.xml file - RecyclerView should only support one view type For items to be addressed in follow up patches OR CLs, TODO is added to the comment. b/19897708 Change-Id: Ibfc4da1696a23d20bada93db46e126706eb13cdc
* Merge "Adding support for loading package icon in iconCache" into ↵Sunny Goyal2015-04-061-19/+58
|\ | | | | | | ub-launcher3-burnaby
| * Adding support for loading package icon in iconCacheSunny Goyal2015-04-061-19/+58
| | | | | | | | | | | | | | > package icons need to be retrieved from IconCache for the new widget tray Bug: 19897708 Change-Id: Iaafc5e16477aaa4e9a7c46b5abf8146cd1101ffd
* | Adding a system status column in icon cache & invalidating items based on itSunny Goyal2015-04-011-6/+23
|/ | | | | Bug: 20034430 Change-Id: Icd6c6426fc7ed26cd104bf22a9d2b0263cb0fa67
* Rewrite: Widget preview loader logicSunny Goyal2015-03-201-2/+2
| | | | | | | | | > Widget previews are saved in data dir instead of cache dir > Expiring widget previews similar to IconCache > Removed support for setting thread priorities Bug: 19865031 Change-Id: Ib6033c2b1ff8ae61bba8762ca994ccd8217d3c75
* Reducing method count by eliminating synthetic accessorsAdam Cohen2015-03-201-1/+2
| | | | | | | | | | | Elimates 304 methods based on dex analysis The java compiler generates sythetic accessor methods for all private fields, methods and contructors accessed from inner classes. By marking them package-private and @Thunk instead, sythentic accessor methods are no longer needeed. These annotated elements should be treated as private. Change-Id: Id0dc2c92733474250d8ff12fa793d3a8adeb1f26
* Using MainThreadExecuter instead of View.postSunny Goyal2015-03-181-3/+4
| | | | Change-Id: Ie7ba88bd3bb412d998ecb51095cbaa74b3b39c10
* Lazy loading high res iconsSunny Goyal2015-03-171-22/+103
| | | | | | | > Loading low-res icons for icons which are not visible on the homescreen. Change-Id: I8ac7bf09f6030ed554cb60a4cd402f3f36ffe12b
* Extracting out CacheKey to a separate classSunny Goyal2015-03-161-31/+11
| | | | Change-Id: Ifdd7cc79668b34298e3f788ee684080cecb86c3e
* Updating IconCache to maintain a persistent of iconsSunny Goyal2015-02-261-163/+250
| | | | | | | | | | > IconDB maintains a DB of icons keyed on ComponentName + User > During loader, icons & labels are loaded first from the DB, and if the entry doesn't exist, loaded using packageManager > After the loader completes, IconDB updates any entry which might have changed, while the launcher was dead. Change-Id: I7a6021cb6d1ca1e66fa5a0bdd21e1543e0cf66fc
* Fixing some IconCache methods not thread safeSunny Goyal2014-10-161-107/+69
| | | | | Bug: 17981568 Change-Id: I0d49604c2e38bc9017cba527d87e24e8b086f1da
* Updating icons for sortcuts when the target app updates.Sunny Goyal2014-10-071-1/+1
| | | | | Bug: 17398260 Change-Id: I055abb971d1f72245e8616ac2ce07bcdf37cdd52
* Cleaning up icon resizing codeSunny Goyal2014-10-071-3/+1
| | | | | | | | > For resizing icons, scaling them down instead of cropping them > Removing duplicate methods and variables Bug: 17663119 Change-Id: I0f270860c0edaaa939495e63e05da841a603f6e9
* Updating promise icon's bitmap and label when onBadgingChanged is receivedSunny Goyal2014-09-191-1/+5
| | | | | Bug: 17583799 Change-Id: I68b4f9d4086c43bd949ad8b46b574ec78edb32db
* Null check in flushInvalidIconsSunny Goyal2014-09-151-1/+2
| | | | | | | | > Icons in a CacheEntry can be null, for a restored app. No need to flush such entries on DeviceProfileChange Bug: 17489687 Change-Id: If6e76206ae5bd8201c9928257706224f2f34c232