Merge "Merge "Check for mSurfaceController in setWallpaperPositionAndScale" into rvc-dev am: c45de5abfa am: c754a3207d" into rvc-d1-dev-plus-aosp

This commit is contained in:
Automerger Merge Worker
2020-05-20 12:06:15 +00:00
committed by Android (Google) Code Review

View File

@@ -1257,8 +1257,11 @@ class WindowStateAnimator {
mYOffset = dy; mYOffset = dy;
mWallpaperScale = scale; mWallpaperScale = scale;
if (mSurfaceController != null) {
try { try {
if (SHOW_LIGHT_TRANSACTIONS) Slog.i(TAG, ">>> OPEN TRANSACTION setWallpaperOffset"); if (SHOW_LIGHT_TRANSACTIONS) {
Slog.i(TAG, ">>> OPEN TRANSACTION setWallpaperOffset");
}
mService.openSurfaceTransaction(); mService.openSurfaceTransaction();
setWallpaperPositionAndScale(dx, dy, scale, false); setWallpaperPositionAndScale(dx, dy, scale, false);
} catch (RuntimeException e) { } catch (RuntimeException e) {
@@ -1266,11 +1269,14 @@ class WindowStateAnimator {
+ " pos=(" + dx + "," + dy + ")", e); + " pos=(" + dx + "," + dy + ")", e);
} finally { } finally {
mService.closeSurfaceTransaction("setWallpaperOffset"); mService.closeSurfaceTransaction("setWallpaperOffset");
if (SHOW_LIGHT_TRANSACTIONS) Slog.i(TAG, if (SHOW_LIGHT_TRANSACTIONS) {
"<<< CLOSE TRANSACTION setWallpaperOffset"); Slog.i(TAG, "<<< CLOSE TRANSACTION setWallpaperOffset");
return true;
} }
} }
}
return true;
}
private void setWallpaperPositionAndScale(int dx, int dy, float scale, private void setWallpaperPositionAndScale(int dx, int dy, float scale,
boolean recoveringMemory) { boolean recoveringMemory) {