Merge "Reduce widget exemption status." into rvc-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
691ca6fd78
@@ -1098,8 +1098,7 @@ public class AppStandbyController implements AppStandbyInternal {
|
|||||||
|
|
||||||
if (mAppWidgetManager != null
|
if (mAppWidgetManager != null
|
||||||
&& mInjector.isBoundWidgetPackage(mAppWidgetManager, packageName, userId)) {
|
&& mInjector.isBoundWidgetPackage(mAppWidgetManager, packageName, userId)) {
|
||||||
// TODO: consider lowering to ACTIVE
|
return STANDBY_BUCKET_ACTIVE;
|
||||||
return STANDBY_BUCKET_EXEMPTED;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (isDeviceProvisioningPackage(packageName)) {
|
if (isDeviceProvisioningPackage(packageName)) {
|
||||||
|
|||||||
@@ -387,7 +387,7 @@ public class AppStandbyControllerTests {
|
|||||||
@Test
|
@Test
|
||||||
public void testBoundWidgetPackageExempt() throws Exception {
|
public void testBoundWidgetPackageExempt() throws Exception {
|
||||||
assumeTrue(mInjector.getContext().getSystemService(AppWidgetManager.class) != null);
|
assumeTrue(mInjector.getContext().getSystemService(AppWidgetManager.class) != null);
|
||||||
assertEquals(STANDBY_BUCKET_EXEMPTED,
|
assertEquals(STANDBY_BUCKET_ACTIVE,
|
||||||
mController.getAppStandbyBucket(PACKAGE_EXEMPTED_1, USER_ID,
|
mController.getAppStandbyBucket(PACKAGE_EXEMPTED_1, USER_ID,
|
||||||
mInjector.mElapsedRealtime, false));
|
mInjector.mElapsedRealtime, false));
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user