ac2898228edea493c76287338adf6dd8ca21303a |
|
31-Oct-2016 |
Makoto Onuki <omakoto@google.com> |
Always scan the Settings app for updated shortcuts. The setting apps' version code is 25 for both DR and MR1, so the shortcut manager will not notice when it's changed. Let's just always scan this app. Bug 32554059 Change-Id: Ia05363b30a5eeb989dc4c44cf5dbd71cde96de96
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
c8c3329dd918b8ea16d6317d19ddee12325800f3 |
|
13-Sep-2016 |
Makoto Onuki <omakoto@google.com> |
Don't update publisher version code without scanning manifest - It was (theoretically) possible for shortcut manager to update the version code for a publisher package without rescanning manifest shortcuts, if backup happens right after unlocking a user before SM searches for updated packages. If it happens, then SM will not scan the manifest for this package until it's updated next time. So don't refresh the version code during backup, which we only have to do for launchers but not publishers. - Also fix the owner-user-id for launchers. (Luckily it's not causing any issues.) Bug 31402152 Change-Id: I5d898eb3882b74edaca8b2d5f960849370ffc23b
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
fc4cf2da34335fd7e84c020f51eea1a341d3f134 |
|
24-Aug-2016 |
Makoto Onuki <omakoto@google.com> |
Shortcut: Improve backup & restore * Catch RuntimeException from restore, in case restoring from a partner device with an incompatible file format. * When a restore target app is already installed, and - if it has allowBackup=true, we'll restore normally, so all existing shortcuts will be replaced. (but manifest shortcuts will be re-published anyway.) We log a warning on logcat. - if it has allowBackup=false, we don't touch any of the existing shortcuts. Bug 31057974 Bug 30766177 Change-Id: Ic3f7e860e7ea0d086fc589d8cbed8c4cebdd4bc6
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
3366328245621fa6e8fd764a4d3c2f073774d096 |
|
23-Aug-2016 |
Makoto Onuki <omakoto@google.com> |
Do not scan system apps unless after OTA Bug 30956231 Change-Id: I4af34cdd39cfaf0b8712b9ded1ef119efa3e04b0
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
64183d518813cc65efcaeaf0d4c28de092b32868 |
|
08-Aug-2016 |
Makoto Onuki <omakoto@google.com> |
ShortcutManager improve app udpate check - Don't use lastUpdateTime for system apps since it's not reliable. - Scan downgraded apps too. Bug 30708050 Bug 30734178 Change-Id: I98253f4c635466197548385275ab08c5e3a1a10b
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
440a1ea8e2204ecb171e0187318beb2f08f6012c |
|
20-Jul-2016 |
Makoto Onuki <omakoto@google.com> |
Support multiple intents in ShortcutInfo Also fix b/30230996. TODO: Support the sourceBounds argument to LauncherApps. startShortcut(). Bug 30218829 Bug 30230996 Change-Id: Ibb6c59d5b7c0a320c21d09436d016d0eac94644f
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
76269928e677725e2d9b28e2e3aa79961a60a1d0 |
|
15-Jul-2016 |
Makoto Onuki <omakoto@google.com> |
Implement dumpsys --checkin for shortcut manager Dump the very basic stuff for now. We need to update GMS-core to actually collect the information. Bug 28535604 Change-Id: I6ce17ee2014786a0ef97f3dc973b8a01c2d2a814
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
4e6cef49ef11bbb5bfc0e9f0fb865188492d88b0 |
|
14-Jul-2016 |
Makoto Onuki <omakoto@google.com> |
Handle locale change and pacakge change in different way - Stop using a custom callback from AM to detect locale changes and use the LOCALE_CHANGED broadcast instead. - This would open up a chance where a publisher app fetches its won manifest shortcuts after a locale change but ShortcutManager hasn't updated string resources. - So instead, at every entry point from ShortcutManager, check if the locale has changed, and if so, update all resources (and reset throttling). - Do the same for package change events too. At every entry point from ShortcutManager, check if the caller package has been updated, or any target activities have been disabled. If so, rescan the caller package. - We do *not* do the same check at the LauncherApps entry points, because the launcher should use the callback to listen to shortcut changes. - Also stopped using PackageMonitor for now because we want to set a higher priority and changing PackageMonitor at this point seems too much for DR. Bug 29895275 Bug 30123329 Change-Id: Ib4a2f626a936c7328e2cc032324f5c3d1c3b9122
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
f3ba2e04be20d33fee989e782ba1966322e7e263 |
|
12-Jul-2016 |
Makoto Onuki <omakoto@google.com> |
Don't backup & restore disabled shortcuts. Also a backup & restore test where an app has manifest shortcuts. Bug 30016960 Bug 29921267 Change-Id: I8c4c3ece50f26d778b2f8f42251c317eb25d1e14
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
ff14f73152775f91fe211729e2cb16a5da6933ab |
|
01-Jul-2016 |
Makoto Onuki <omakoto@google.com> |
Make sure re-published dynamic shortcuts are always enabled - Originally there was explicit code to take over the disabled flag, which was simply not necessary. - Also fix the startShortcut() tests that have temporarily been disabled. (Also remove the stale TODOs to avoid conflict with Ia18301ba) Bug 29633681 Change-Id: I58b12ad6918d7fef4b79059b0c2c7f2df6e32269
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
dd097812fa84b898a46cb5dd253422e78779a150 |
|
29-Jun-2016 |
Makoto Onuki <omakoto@google.com> |
Fix updateShortcuts() with icons But 29822569 Change-Id: I72a0903ccc8acffc42f40d9df7b99ed6de26b66d
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
b08790c3b2f3bdb0c2e2f7ff46e4584fb1127769 |
|
23-Jun-2016 |
Makoto Onuki <omakoto@google.com> |
Shortcut: Only "main" activities can have shortcuts. - Don't publish shortcuts when their target activities are not main. - Only scan manifest shortcuts for main activities. - When an app is updated, remove shortcuts that no longer belong to valid main activities. - Also re-publish manifest shortcuts after 'clear data' - Also listen to PACKAGE_CHANGED and disable/re-publish shortcuts properly. Bug 29355786 Bug 29582255 Bug 29601844 Change-Id: I6c701ce669cf30a227bc2af4aa01de467ef73e3a
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
df6da040e00cba255cad64d2d231aae62928607a |
|
16-Jun-2016 |
Makoto Onuki <omakoto@google.com> |
Update manifest shortcut XML schema Use the standard <intent> tag instead of custom tags. - Also fix setDynamicShortcuts(), which was broken in the previous CL. - Also tolerate runtime exceptions while parsing XMLs - Also fix b/29422018 while I'm at it Bug 29390156 Bug 29077932 Bug 29422018 Change-Id: I2756c9d66c6d7b2962a982d9e57a7d84a5755b28
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
70a91541e9eb2acc6ee5a34785abdc420127a5ec |
|
15-Jun-2016 |
Makoto Onuki <omakoto@google.com> |
Merge "ShortcutManger: Auto-adjust ranks." into nyc-mr1-dev
|
9e1f5595bd7ffe3af6ca35b3235dfca0ecd07978 |
|
08-Jun-2016 |
Makoto Onuki <omakoto@google.com> |
ShortcutManger: Auto-adjust ranks. Spec: go/shortcutmanager-spec-ranks Bug 28984376 Bug 28536066 Change-Id: Ibffb92233c62792af06eeadc5a9a6379d0506a3c
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
a1d38b3c95cd6a38ee7336fd90729d3b3be6ae25 |
|
11-Jun-2016 |
Makoto Onuki <omakoto@google.com> |
Fix some exception messages and enhance unit tets Bug 29275393 Change-Id: Idaa8564d41f86de2a2cbefa4ff3c08b89a3a6dd2
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
157b1628fd84dc3ef0355fddd8d281618f94d33e |
|
03-Jun-2016 |
Makoto Onuki <omakoto@google.com> |
ShortcutManager: deal with changing resource IDs on app update - When an app is upgraded, all the resource IDs may change. So if a shortcut is previously published with an icon for res ID 100 and the publisher is upgraded, resource #100 may refer to something different. - So now the service also remembers resource names for icon resources, as wells as string resources. When an app is updated, the service fetch the updated resource IDs by name. - Also extract all string resources when a shortcut is published and persist them, so that even when the original string resources are removed from the app, the launcher can still show the extracted strings. - When the system locale changes, re-extract all string resources. - Also really hide the constants in ShortcutInfo that were accidentally made public. Change-Id: I23c29b45c1de5d76175229190a1533c9c62c5960
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
7001a6154088c87a31d56641762ff0c2a48f1d57 |
|
27-May-2016 |
Makoto Onuki <omakoto@google.com> |
ShortcutManager: Implement max # of shortcuts - Each activity (launcher icon) can have at most 5 dynamic + manifest shortcuts. Bug 28536066 Change-Id: Id34371d51c4a1c5e3df7debe3b71b535eb157b6c
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
eddbfecb8dd751161339a9ed16d07ce2e108a575 |
|
01-Jun-2016 |
Makoto Onuki <omakoto@google.com> |
ShortcutManager: API rename The words "title" and "text" implies that "text" is a secondary label that's shown with the title, but it turned out the launcher would show only one of those depending on how much space it has. So now we change them to "shortLabel" and "longLabel" Note we're only changing the API surface -- in order to mimimize the impact to the code, internally we'll keep using the old names. - Also remove "shortcutRank" while I'm here -- it should be implied from the order of the XML elements. Bug 29057378 Change-Id: I3203f63b0318c7462c1c61fef43cf9755fa8c008
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
22fcc68e6be0edaa98f3dacf79d580a5e5d50005 |
|
17-May-2016 |
Makoto Onuki <omakoto@google.com> |
ShortcutManager: Support manifest shortcuts - Now apps can publish shortcuts via AndroidManifest.xml (Sample: I5b127150) - Rename some APIs per API council feedback - Publishers can now "disable" shortcuts. (https://docs.google.com/presentation/d/1raUn1QBURDb1yrd6mSmVxII9ezNh3MWukODdtufJ29U/edit#slide=id.g13ef592464_7_39) Bug 28785283 Bug 28536066 Change-Id: I4a126841e43e40139bb4baa6d0f98ad7b3a75ac1
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
20c95f854e54b71caa49f0efe07d47d1e6afd435 |
|
12-May-2016 |
Makoto Onuki <omakoto@google.com> |
ShortcutManager: API changes for DR See https://goto.google.com/shortcutmanager-spec-dr for the details. This CL contains changes to ShortcutInfo and all the new API entry points, but not the implementation of the new APIs. - ShortcutInfo.activityComponent is now mandatory. - Publishers can now disable shortcuts. ShortcutInfo can now have "disabled message". - ShortcutInfo now supports string resources for all the String fields. -> When launcher fetches shortcuts, ShortcutService will automatically load resources and expose as strings. - LauncherApps now supports getShortcutIconDrawable() and getShortcutBadgedIconDrawable() to be consistent with LauncherActivityInfo. - ShortcutInfo.weight is replaced with "rank". - Added ShortcutManager.reportShortcutUsed(), which will be used for usage tracking / suggestion. Bug 28536054 Bug 28536066 Bug 28564134 Bug 28594168 Change-Id: Ib8245b39bb1e753991a9de89c0b73accacd90355
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
c51b2876ec5c0af449469a0f76bb38c51cfcff04 |
|
05-May-2016 |
Makoto Onuki <omakoto@google.com> |
Refactoring ShortcutManager + bug fixes. - Don't pass the ShortcutService instance as an argument. This tiny optimization is no longer meaningful now that PackageShortcut and PackageLauncher have reference to ShortcutUser. - Rename mLauncherComponent to mDefaultLauncherComponent for clarity. - Don't instantiate ShortcutPackage instances when not needed. - Don't allow intents with a null action. - Also improve javadoc. Bug 28592642 Bug 28474517 Bug 28557169 Change-Id: I8790d3494bf3b92c143c02824b0ed0e514504baa
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
6c1dbd577bcf2b8bccb9a0d04d741ff7337898f2 |
|
03-May-2016 |
Makoto Onuki <omakoto@google.com> |
Clean up dangling bitmaps. Bug 28471799 Change-Id: I48785ccc533a7499d46e35264c6a0cbf0c5398d5
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
4d36b3a8c5ba1289d851ef337e46709bba333100 |
|
27-Apr-2016 |
Makoto Onuki <omakoto@google.com> |
ShortcutManager: finishing touches - Change back the throttling quota to 10 calls / day - Foreground apps are no longer throttled, and when an app comes to foreground the call counter will be reset. - When the system locale changes, reset throttling for all packages for all users. See LocalService.onSystemLocaleChangedNoLock() for how it's performed. Because the reset must happen before any other apps have a chance to publish shortcuts, the logic is not straightforward. - Added an internal API to reset the throttling upon inline-reply from a notification. - Stop supporting icons from "content:" URIs - Improved javadoc on several APIs. Also internal refactor needed to this: - ShortcutUser.getAllPackages()/getAllLaunchers() are no longer accessible to outer code to prevent accidentally adding/removing the content. Outer code should use forAllPackages() / forAllLaunchers(). Bug 27923857 Change-Id: I002511193d1d33718163bb1dabe77610bde58198
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
711ffe620ed06c8517cad8d4d0a8f4fca588f921 |
|
26-Apr-2016 |
Makoto Onuki <omakoto@google.com> |
Merge "When app is updated, save the new version code, and update shortcuts with resource based icons." into nyc-dev
|
be73a8068ff3babe5b0a4f12656731ba8eea6149 |
|
15-Apr-2016 |
Makoto Onuki <omakoto@google.com> |
ShortcutManager: Categories should be Set, not List. Bug 27923857 Change-Id: Ife859da8e66478174f6c4463316886a23e5aa4e0
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
39686e8cdec3550c941d376929084f59ac0d78cd |
|
14-Apr-2016 |
Makoto Onuki <omakoto@google.com> |
When app is updated, save the new version code, and update shortcuts with resource based icons. Bug 28152054 Change-Id: I14f537c08b1a0ba48dd508b0c42fc1d3ed4f5eb0
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
b6d3523dfb5d73ddda4b750a82c059cdc42acf8e |
|
05-Apr-2016 |
Makoto Onuki <omakoto@google.com> |
ShortcutManager: Address API review feedback. - "delete" -> "remove" - add/deleteDynamicShortcut() now takes a list. - Throttling default settings is now 2 calls / hour. - Add categories to ShortcutInfo. - getIconResourceId() is now public Bug 27923857 Bug 27548047 Change-Id: I8457b30e4b2f7c63ab2988648b37178fd16ea45b
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
abe8442951ff88aa01ed882adb54fb1b3472ca3e |
|
07-Apr-2016 |
Makoto Onuki <omakoto@google.com> |
Add UserHandle to ShortcutInfo, and simplify LauncherApps APIs. - Also fixes the bitmap recycle bug in the service. Fixes 28053541 Change-Id: I2b244feda0f85c60e2c15af427fcad95ad5e6da5
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
2e210c4d0f766e52ea4c087a1d54213c36a4e0ea |
|
30-Mar-2016 |
Makoto Onuki <omakoto@google.com> |
ShortcutManager: implement backup & restore Also: - Fix cross profile pinning. Now ShortcutLauncher correctly keeps track of target package user IDs. - Add performance stats for package manager calls and show them on dumpsys. Bug 27548047 Change-Id: I2472980b2955b6c70947aaaa9b76f75d0616db6e
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
e3ae7ec14a3204ee502219b6bb46dc9ab8e24a36 |
|
30-Mar-2016 |
Makoto Onuki <omakoto@google.com> |
ShortcutManager: Support secondary text field. Bug 27548047 Change-Id: I2d184bab2c26e351b7326945fa0cacf826f16d1e
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
9da23fc6ac565b38129d52f4f8f174c833a9bd01 |
|
29-Mar-2016 |
Makoto Onuki <omakoto@google.com> |
ShortcutManager: proper work profile support Bug 27548047 Change-Id: I8acea3355f8974a551f53814624dec30732f7b2f
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
d99c6f04bbb68f8be78f2c3ca625a3a8d5645275 |
|
28-Mar-2016 |
Makoto Onuki <omakoto@google.com> |
ShortcutManager: Fix work profile - Pinned shortcuts need to know not only which package has pinned them, but also on which user's, due to work profile. - Launcher can always launch shortcuts that it has pinned. Bug 27548047 Change-Id: I23b4e7dfbb6ecc42099d31008bcfd61d44e2c7fb
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
0acbb14574d859b5f1cc0b7c6bbdfbeba38f3e55 |
|
23-Mar-2016 |
Makoto Onuki <omakoto@google.com> |
ShortcutManager: Handle package broadcasts. - Do a cleanup when an app is gone. - Record the app version and signatures. - Also make saveToXml() capable of saving for backup. Bug 27548047 Change-Id: I7eb2bbec7665b4d625630e7312c0f2a8b03c5ffa
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|
3145924596ad0db9e8f1f5aead90fb50127243cb |
|
22-Mar-2016 |
Makoto Onuki <omakoto@google.com> |
ShortcutManager: Extract helper classes. Bug 27548047 Change-Id: I08656291a8dd509fde169f229ca9c503362254f3
/frameworks/base/services/core/java/com/android/server/pm/ShortcutPackage.java
|