Loading apex/jobscheduler/service/java/com/android/server/usage/AppStandbyController.java +1 −1 Original line number Diff line number Diff line Loading @@ -190,7 +190,7 @@ public class AppStandbyController ONE_HOUR, ONE_HOUR, 2 * ONE_HOUR, 4 * ONE_DAY 4 * ONE_HOUR }; private static final int[] THRESHOLD_BUCKETS = { Loading core/java/android/provider/Settings.java +1 −1 Original line number Diff line number Diff line Loading @@ -13112,7 +13112,7 @@ public final class Settings { * @see #ENABLE_RESTRICTED_BUCKET * @hide */ public static final int DEFAULT_ENABLE_RESTRICTED_BUCKET = 0; public static final int DEFAULT_ENABLE_RESTRICTED_BUCKET = 1; /** * Whether or not app auto restriction is enabled. When it is enabled, settings app will Loading services/tests/servicestests/src/com/android/server/usage/AppStandbyControllerTests.java +16 −1 Original line number Diff line number Diff line Loading @@ -940,7 +940,22 @@ public class AppStandbyControllerTests { .setLong("elapsed_threshold_restricted", -1); mInjector.mPropertiesChangedListener .onPropertiesChanged(mInjector.getDeviceConfigProperties()); testTimeout(); reportEvent(mController, USER_INTERACTION, 0, PACKAGE_1); mController.checkIdleStates(USER_ID); assertBucket(STANDBY_BUCKET_ACTIVE); mInjector.mElapsedRealtime = HOUR_MS; mController.checkIdleStates(USER_ID); assertBucket(STANDBY_BUCKET_FREQUENT); mInjector.mElapsedRealtime = 2 * HOUR_MS; mController.checkIdleStates(USER_ID); assertBucket(STANDBY_BUCKET_RARE); mInjector.mElapsedRealtime = 4 * HOUR_MS; mController.checkIdleStates(USER_ID); assertBucket(STANDBY_BUCKET_RESTRICTED); } /** Loading Loading
apex/jobscheduler/service/java/com/android/server/usage/AppStandbyController.java +1 −1 Original line number Diff line number Diff line Loading @@ -190,7 +190,7 @@ public class AppStandbyController ONE_HOUR, ONE_HOUR, 2 * ONE_HOUR, 4 * ONE_DAY 4 * ONE_HOUR }; private static final int[] THRESHOLD_BUCKETS = { Loading
core/java/android/provider/Settings.java +1 −1 Original line number Diff line number Diff line Loading @@ -13112,7 +13112,7 @@ public final class Settings { * @see #ENABLE_RESTRICTED_BUCKET * @hide */ public static final int DEFAULT_ENABLE_RESTRICTED_BUCKET = 0; public static final int DEFAULT_ENABLE_RESTRICTED_BUCKET = 1; /** * Whether or not app auto restriction is enabled. When it is enabled, settings app will Loading
services/tests/servicestests/src/com/android/server/usage/AppStandbyControllerTests.java +16 −1 Original line number Diff line number Diff line Loading @@ -940,7 +940,22 @@ public class AppStandbyControllerTests { .setLong("elapsed_threshold_restricted", -1); mInjector.mPropertiesChangedListener .onPropertiesChanged(mInjector.getDeviceConfigProperties()); testTimeout(); reportEvent(mController, USER_INTERACTION, 0, PACKAGE_1); mController.checkIdleStates(USER_ID); assertBucket(STANDBY_BUCKET_ACTIVE); mInjector.mElapsedRealtime = HOUR_MS; mController.checkIdleStates(USER_ID); assertBucket(STANDBY_BUCKET_FREQUENT); mInjector.mElapsedRealtime = 2 * HOUR_MS; mController.checkIdleStates(USER_ID); assertBucket(STANDBY_BUCKET_RARE); mInjector.mElapsedRealtime = 4 * HOUR_MS; mController.checkIdleStates(USER_ID); assertBucket(STANDBY_BUCKET_RESTRICTED); } /** Loading