Using resource override instead of code-swap for ApiWrapper

Bug: 330920490
Flag: None
Test: Presubmit
Change-Id: Iac19f32e64d2c76ed5b4f8592943ee4ae7af51b5
This commit is contained in:
Sunny Goyal
2024-03-25 16:12:10 -07:00
parent 8ecbaa422f
commit 11117d9b2a
22 changed files with 247 additions and 301 deletions

View File

@@ -17,7 +17,6 @@
package com.android.launcher3.pm;
import static com.android.launcher3.Utilities.ATLEAST_U;
import static com.android.launcher3.uioverrides.ApiWrapper.queryAllUsers;
import static com.android.launcher3.util.Executors.MODEL_EXECUTOR;
import android.content.Context;
@@ -34,6 +33,7 @@ import androidx.annotation.WorkerThread;
import com.android.launcher3.icons.BitmapInfo;
import com.android.launcher3.icons.UserBadgeDrawable;
import com.android.launcher3.util.ApiWrapper;
import com.android.launcher3.util.FlagOp;
import com.android.launcher3.util.MainThreadInitializedObject;
import com.android.launcher3.util.SafeCloseable;
@@ -119,7 +119,7 @@ public class UserCache implements SafeCloseable {
@WorkerThread
private void updateCache() {
mUserToSerialMap = queryAllUsers(mContext);
mUserToSerialMap = ApiWrapper.INSTANCE.get(mContext).queryAllUsers();
}
/**