Merge "Do not force relayout for wallpaper visibility change" into tm-qpr-dev
This commit is contained in:
@@ -1536,8 +1536,9 @@ public abstract class WallpaperService extends Service {
|
||||
// may have been destroyed so now we need to make
|
||||
// sure it is re-created.
|
||||
doOffsetsChanged(false);
|
||||
// force relayout to get new surface
|
||||
updateSurface(true, false, false);
|
||||
// It will check mSurfaceCreated so no need to force relayout.
|
||||
updateSurface(false /* forceRelayout */, false /* forceReport */,
|
||||
false /* redrawNeeded */);
|
||||
}
|
||||
onVisibilityChanged(visible);
|
||||
if (mReportedVisible && mFrozenRequested) {
|
||||
|
||||
@@ -139,6 +139,12 @@ class WindowSurfaceController {
|
||||
"Destroying surface %s called by %s", this, Debug.getCallers(8));
|
||||
try {
|
||||
if (mSurfaceControl != null) {
|
||||
if (mAnimator.mIsWallpaper && !mAnimator.mWin.mWindowRemovalAllowed
|
||||
&& !mAnimator.mWin.mRemoveOnExit) {
|
||||
// The wallpaper surface should have the same lifetime as its window.
|
||||
Slog.e(TAG, "Unexpected removing wallpaper surface of " + mAnimator.mWin
|
||||
+ " by " + Debug.getCallers(8));
|
||||
}
|
||||
t.remove(mSurfaceControl);
|
||||
}
|
||||
} catch (RuntimeException e) {
|
||||
|
||||
Reference in New Issue
Block a user