Loading core/java/android/app/WallpaperManager.java +15 −0 Original line number Diff line number Diff line Loading @@ -2079,6 +2079,21 @@ public class WallpaperManager { } } /** * Set the live wallpaper for the given screen(s). * * This can only be called by packages with android.permission.SET_WALLPAPER_COMPONENT * permission. The caller must hold the INTERACT_ACROSS_USERS_FULL permission to change * another user's wallpaper. * * @hide */ @RequiresPermission(android.Manifest.permission.SET_WALLPAPER_COMPONENT) public boolean setWallpaperComponentWithFlags(@NonNull ComponentName name, @SetWallpaperFlags int which) { return setWallpaperComponent(name); } /** * Set the display position of the current wallpaper within any larger space, when * that wallpaper is visible behind the given window. The X and Y offsets Loading core/java/android/service/wallpaper/IWallpaperService.aidl +1 −1 Original line number Diff line number Diff line Loading @@ -25,6 +25,6 @@ import android.service.wallpaper.IWallpaperConnection; oneway interface IWallpaperService { void attach(IWallpaperConnection connection, IBinder windowToken, int windowType, boolean isPreview, int reqWidth, int reqHeight, in Rect padding, int displayId); int reqWidth, int reqHeight, in Rect padding, int displayId, int which); void detach(); } core/java/android/service/wallpaper/WallpaperService.java +2 −1 Original line number Diff line number Diff line Loading @@ -18,6 +18,7 @@ package android.service.wallpaper; import static android.app.WallpaperManager.COMMAND_FREEZE; import static android.app.WallpaperManager.COMMAND_UNFREEZE; import static android.app.WallpaperManager.SetWallpaperFlags; import static android.graphics.Matrix.MSCALE_X; import static android.graphics.Matrix.MSCALE_Y; import static android.graphics.Matrix.MSKEW_X; Loading Loading @@ -2427,7 +2428,7 @@ public abstract class WallpaperService extends Service { @Override public void attach(IWallpaperConnection conn, IBinder windowToken, int windowType, boolean isPreview, int reqWidth, int reqHeight, Rect padding, int displayId) { int displayId, @SetWallpaperFlags int which) { mEngineWrapper = new IWallpaperEngineWrapper(mTarget, conn, windowToken, windowType, isPreview, reqWidth, reqHeight, padding, displayId); } Loading services/core/java/com/android/server/wallpaper/WallpaperManagerService.java +1 −1 Original line number Diff line number Diff line Loading @@ -1166,7 +1166,7 @@ public class WallpaperManagerService extends IWallpaperManager.Stub try { connection.mService.attach(connection, mToken, TYPE_WALLPAPER, false, wpdData.mWidth, wpdData.mHeight, wpdData.mPadding, mDisplayId); wpdData.mPadding, mDisplayId, FLAG_SYSTEM | FLAG_LOCK); } catch (RemoteException e) { Slog.w(TAG, "Failed attaching wallpaper on display", e); if (wallpaper != null && !wallpaper.wallpaperUpdating Loading Loading
core/java/android/app/WallpaperManager.java +15 −0 Original line number Diff line number Diff line Loading @@ -2079,6 +2079,21 @@ public class WallpaperManager { } } /** * Set the live wallpaper for the given screen(s). * * This can only be called by packages with android.permission.SET_WALLPAPER_COMPONENT * permission. The caller must hold the INTERACT_ACROSS_USERS_FULL permission to change * another user's wallpaper. * * @hide */ @RequiresPermission(android.Manifest.permission.SET_WALLPAPER_COMPONENT) public boolean setWallpaperComponentWithFlags(@NonNull ComponentName name, @SetWallpaperFlags int which) { return setWallpaperComponent(name); } /** * Set the display position of the current wallpaper within any larger space, when * that wallpaper is visible behind the given window. The X and Y offsets Loading
core/java/android/service/wallpaper/IWallpaperService.aidl +1 −1 Original line number Diff line number Diff line Loading @@ -25,6 +25,6 @@ import android.service.wallpaper.IWallpaperConnection; oneway interface IWallpaperService { void attach(IWallpaperConnection connection, IBinder windowToken, int windowType, boolean isPreview, int reqWidth, int reqHeight, in Rect padding, int displayId); int reqWidth, int reqHeight, in Rect padding, int displayId, int which); void detach(); }
core/java/android/service/wallpaper/WallpaperService.java +2 −1 Original line number Diff line number Diff line Loading @@ -18,6 +18,7 @@ package android.service.wallpaper; import static android.app.WallpaperManager.COMMAND_FREEZE; import static android.app.WallpaperManager.COMMAND_UNFREEZE; import static android.app.WallpaperManager.SetWallpaperFlags; import static android.graphics.Matrix.MSCALE_X; import static android.graphics.Matrix.MSCALE_Y; import static android.graphics.Matrix.MSKEW_X; Loading Loading @@ -2427,7 +2428,7 @@ public abstract class WallpaperService extends Service { @Override public void attach(IWallpaperConnection conn, IBinder windowToken, int windowType, boolean isPreview, int reqWidth, int reqHeight, Rect padding, int displayId) { int displayId, @SetWallpaperFlags int which) { mEngineWrapper = new IWallpaperEngineWrapper(mTarget, conn, windowToken, windowType, isPreview, reqWidth, reqHeight, padding, displayId); } Loading
services/core/java/com/android/server/wallpaper/WallpaperManagerService.java +1 −1 Original line number Diff line number Diff line Loading @@ -1166,7 +1166,7 @@ public class WallpaperManagerService extends IWallpaperManager.Stub try { connection.mService.attach(connection, mToken, TYPE_WALLPAPER, false, wpdData.mWidth, wpdData.mHeight, wpdData.mPadding, mDisplayId); wpdData.mPadding, mDisplayId, FLAG_SYSTEM | FLAG_LOCK); } catch (RemoteException e) { Slog.w(TAG, "Failed attaching wallpaper on display", e); if (wallpaper != null && !wallpaper.wallpaperUpdating Loading