Merge "Move Wallpaper RPC call to background thread." into udc-dev am: 5961d96235 am: ee59b7a824

Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/22912335

Change-Id: I899c6301428fc7863bc7d72080864fb40ff5959f
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
Stefan Andonian
2023-04-28 21:40:06 +00:00
committed by Automerger Merge Worker
@@ -18,6 +18,7 @@ package com.android.launcher3;
import static com.android.launcher3.util.DisplayController.CHANGE_ROTATION;
import static com.android.launcher3.util.Executors.MAIN_EXECUTOR;
import static com.android.launcher3.util.Executors.THREAD_POOL_EXECUTOR;
import android.app.WallpaperColors;
import android.app.WallpaperManager;
@@ -76,8 +77,8 @@ public abstract class BaseDraggingActivity extends BaseActivity
// Update theme
if (Utilities.ATLEAST_P) {
getSystemService(WallpaperManager.class)
.addOnColorsChangedListener(this, MAIN_EXECUTOR.getHandler());
THREAD_POOL_EXECUTOR.execute(() -> getSystemService(WallpaperManager.class)
.addOnColorsChangedListener(this, MAIN_EXECUTOR.getHandler()));
}
int themeRes = Themes.getActivityThemeRes(this);
if (themeRes != mThemeRes) {