Skip to content

Commit bf6ee4f

Browse files
author
Christopher Tate
committed
Fix wallpaper restore
Following a restore of the wallpaper data files, the settingsRestored() method was binding the new wallpaper by passing null as the component, because once upon a time that meant just use the configuration that had just been loaded from the [newly restored] settings filed. However, at some point this broke when the load from settings was made a staging operation, not also the commitment of the changes. This CL passes the newly-determined component configuration explicitly to the bind, overriding the product default that may already have been emplaced by the time the restore happens. It also turns off the (minor) debugging that had been enabled in WallpaperBackupHelper while digging into the issue. Bug 5416839 Change-Id: I963893c236e24c75d10dde75836805295ea42cbb
1 parent 2461fef commit bf6ee4f

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

core/java/android/app/backup/WallpaperBackupHelper.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
*/
3636
public class WallpaperBackupHelper extends FileBackupHelperBase implements BackupHelper {
3737
private static final String TAG = "WallpaperBackupHelper";
38-
private static final boolean DEBUG = true;
38+
private static final boolean DEBUG = false;
3939

4040
// This path must match what the WallpaperManagerService uses
4141
private static final String WALLPAPER_IMAGE = "/data/data/com.android.settings/files/wallpaper";

services/java/com/android/server/WallpaperManagerService.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -834,7 +834,7 @@ void settingsRestored() {
834834
}
835835
if (DEBUG) Slog.v(TAG, "settingsRestored: success=" + success);
836836
if (success) {
837-
bindWallpaperComponentLocked(null, false, false);
837+
bindWallpaperComponentLocked(mNextWallpaperComponent, false, false);
838838
}
839839
}
840840
}

0 commit comments

Comments
 (0)