Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 07e234c9 authored by Makoto Onuki's avatar Makoto Onuki Committed by Android (Google) Code Review
Browse files

Merge "Hide more shortcut APIs" into nyc-mr1-dev

parents f638978b f805b43d
Loading
Loading
Loading
Loading
+0 −2
Original line number Diff line number Diff line
@@ -10108,8 +10108,6 @@ package android.content.pm {
    method public java.util.List<android.content.pm.ShortcutInfo> getManifestShortcuts();
    method public int getMaxShortcutCountPerActivity();
    method public java.util.List<android.content.pm.ShortcutInfo> getPinnedShortcuts();
    method public long getRateLimitResetTime();
    method public int getRemainingCallCount();
    method public void removeAllDynamicShortcuts();
    method public void removeDynamicShortcuts(java.util.List<java.lang.String>);
    method public void reportShortcutUsed(java.lang.String);
+0 −2
Original line number Diff line number Diff line
@@ -10533,8 +10533,6 @@ package android.content.pm {
    method public java.util.List<android.content.pm.ShortcutInfo> getManifestShortcuts();
    method public int getMaxShortcutCountPerActivity();
    method public java.util.List<android.content.pm.ShortcutInfo> getPinnedShortcuts();
    method public long getRateLimitResetTime();
    method public int getRemainingCallCount();
    method public void removeAllDynamicShortcuts();
    method public void removeDynamicShortcuts(java.util.List<java.lang.String>);
    method public void reportShortcutUsed(java.lang.String);
+0 −2
Original line number Diff line number Diff line
@@ -10122,8 +10122,6 @@ package android.content.pm {
    method public java.util.List<android.content.pm.ShortcutInfo> getManifestShortcuts();
    method public int getMaxShortcutCountPerActivity();
    method public java.util.List<android.content.pm.ShortcutInfo> getPinnedShortcuts();
    method public long getRateLimitResetTime();
    method public int getRemainingCallCount();
    method public void removeAllDynamicShortcuts();
    method public void removeDynamicShortcuts(java.util.List<java.lang.String>);
    method public void reportShortcutUsed(java.lang.String);
+4 −18
Original line number Diff line number Diff line
@@ -63,24 +63,6 @@ import java.util.List;
 * published, existing shortcuts with the same ID will be updated.  Note this may include a
 * pinned shortcut.
 *
 * <h3>Rate limiting</h3>
 *
 * Calls to {@link #setDynamicShortcuts(List)}, {@link #addDynamicShortcuts(List)},
 * and {@link #updateShortcuts(List)} from <b>background applications</b> will be
 * rate-limited.  An application can call these methods at most
 * {@link #getRemainingCallCount()} times until the rate-limiting counter is reset,
 * which happens at a certain time every day.
 *
 * <p>An application can use {@link #getRateLimitResetTime()} to get the next reset time.
 *
 * <p>Foreground applications (i.e. ones with a foreground activity or a foreground services)
 * will not be throttled. Also, when an application comes to foreground,
 * {@link #getRemainingCallCount()} will be reset to the initial value.
 *
 * <p>For testing purposes, use "Developer Options" (found in the Settings menu) to reset the
 * internal rate-limiting counter.  Automated tests can use the following ADB shell command to
 * achieve the same effect:</p>
 * <pre>adb shell cmd shortcut reset-throttling</pre>
 *
 * <h3>Backup and Restore</h3>
 *
@@ -328,6 +310,8 @@ public class ShortcutManager {
     * before the rate limit counter is reset.
     *
     * @see #getRateLimitResetTime()
     *
     * @hide
     */
    public int getRemainingCallCount() {
        try {
@@ -342,6 +326,8 @@ public class ShortcutManager {
     *
     * @see #getRemainingCallCount()
     * @see System#currentTimeMillis()
     *
     * @hide
     */
    public long getRateLimitResetTime() {
        try {