Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f762e7a2 authored by Chris Poultney's avatar Chris Poultney Committed by Automerger Merge Worker
Browse files

Merge "Clean up naming of getWallpaperInfo functions." into tm-qpr-dev am:...

Merge "Clean up naming of getWallpaperInfo functions." into tm-qpr-dev am: 7fcaee53 am: 76111f60

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/20501449



Change-Id: I0c3cecaaca373a54bab381115b3167e6f0dac50e
Signed-off-by: default avatarAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
parents 85a346ad 76111f60
Loading
Loading
Loading
Loading
+3 −3
Original line number Original line Diff line number Diff line
@@ -188,17 +188,17 @@ final class DisabledWallpaperManager extends WallpaperManager {
    }
    }


    @Override
    @Override
    public WallpaperInfo getWallpaperInfo(int userId) {
    public WallpaperInfo getWallpaperInfoForUser(int userId) {
        return unsupported();
        return unsupported();
    }
    }


    @Override
    @Override
    public WallpaperInfo getWallpaperInfoWithFlags(@SetWallpaperFlags int which) {
    public WallpaperInfo getWallpaperInfo(@SetWallpaperFlags int which) {
        return unsupported();
        return unsupported();
    }
    }


    @Override
    @Override
    public WallpaperInfo getWallpaperInfoWithFlags(@SetWallpaperFlags int which, int userId) {
    public WallpaperInfo getWallpaperInfo(@SetWallpaperFlags int which, int userId) {
        return unsupported();
        return unsupported();
    }
    }


+15 −9
Original line number Original line Diff line number Diff line
@@ -1322,7 +1322,7 @@ public class WallpaperManager {
     * wallpaper component. Otherwise, if the wallpaper is a static image, this returns null.
     * wallpaper component. Otherwise, if the wallpaper is a static image, this returns null.
     */
     */
    public WallpaperInfo getWallpaperInfo() {
    public WallpaperInfo getWallpaperInfo() {
        return getWallpaperInfo(mContext.getUserId());
        return getWallpaperInfoForUser(mContext.getUserId());
    }
    }


    /**
    /**
@@ -1332,7 +1332,7 @@ public class WallpaperManager {
     * @param userId Owner of the wallpaper.
     * @param userId Owner of the wallpaper.
     * @hide
     * @hide
     */
     */
    public WallpaperInfo getWallpaperInfo(int userId) {
    public WallpaperInfo getWallpaperInfoForUser(int userId) {
        try {
        try {
            if (sGlobals.mService == null) {
            if (sGlobals.mService == null) {
                Log.w(TAG, "WallpaperService not running");
                Log.w(TAG, "WallpaperService not running");
@@ -1347,25 +1347,31 @@ public class WallpaperManager {


    /**
    /**
     * Returns the information about the home screen wallpaper if its current wallpaper is a live
     * Returns the information about the home screen wallpaper if its current wallpaper is a live
     * wallpaper component. Otherwise, if the wallpaper is a static image, this returns null.
     * wallpaper component. Otherwise, if the wallpaper is a static image or is not set, this
     * returns null.
     *
     *
     * @param which Specifies wallpaper destination (home or lock).
     * @param which Specifies wallpaper to request (home or lock).
     * @throws IllegalArgumentException if {@code which} is not exactly one of
     * {{@link #FLAG_SYSTEM},{@link #FLAG_LOCK}}.
     * @hide
     * @hide
     */
     */
    public WallpaperInfo getWallpaperInfoWithFlags(@SetWallpaperFlags int which) {
    public WallpaperInfo getWallpaperInfo(@SetWallpaperFlags int which) {
        return getWallpaperInfo();
        return getWallpaperInfo();
    }
    }


    /**
    /**
     * Returns the information about the designated wallpaper if its current wallpaper is a live
     * Returns the information about the designated wallpaper if its current wallpaper is a live
     * wallpaper component. Otherwise, if the wallpaper is a static image, this returns null.
     * wallpaper component. Otherwise, if the wallpaper is a static image or is not set, this
     * returns null.
     *
     *
     * @param which Specifies wallpaper destination (home or lock).
     * @param which Specifies wallpaper to request (home or lock).
     * @param userId Owner of the wallpaper.
     * @param userId Owner of the wallpaper.
     * @throws IllegalArgumentException if {@code which} is not exactly one of
     * {{@link #FLAG_SYSTEM},{@link #FLAG_LOCK}}.
     * @hide
     * @hide
     */
     */
    public WallpaperInfo getWallpaperInfoWithFlags(@SetWallpaperFlags int which, int userId) {
    public WallpaperInfo getWallpaperInfo(@SetWallpaperFlags int which, int userId) {
        return getWallpaperInfo(userId);
        return getWallpaperInfoForUser(userId);
    }
    }


    /**
    /**