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
|
// may have been destroyed so now we need to make
|
||||||
// sure it is re-created.
|
// sure it is re-created.
|
||||||
doOffsetsChanged(false);
|
doOffsetsChanged(false);
|
||||||
// force relayout to get new surface
|
// It will check mSurfaceCreated so no need to force relayout.
|
||||||
updateSurface(true, false, false);
|
updateSurface(false /* forceRelayout */, false /* forceReport */,
|
||||||
|
false /* redrawNeeded */);
|
||||||
}
|
}
|
||||||
onVisibilityChanged(visible);
|
onVisibilityChanged(visible);
|
||||||
if (mReportedVisible && mFrozenRequested) {
|
if (mReportedVisible && mFrozenRequested) {
|
||||||
|
|||||||
@@ -139,6 +139,12 @@ class WindowSurfaceController {
|
|||||||
"Destroying surface %s called by %s", this, Debug.getCallers(8));
|
"Destroying surface %s called by %s", this, Debug.getCallers(8));
|
||||||
try {
|
try {
|
||||||
if (mSurfaceControl != null) {
|
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);
|
t.remove(mSurfaceControl);
|
||||||
}
|
}
|
||||||
} catch (RuntimeException e) {
|
} catch (RuntimeException e) {
|
||||||
|
|||||||
Reference in New Issue
Block a user