diff options
| author | 2022-11-28 17:11:06 +0000 | |
|---|---|---|
| committer | 2022-11-28 17:11:06 +0000 | |
| commit | aebffa1f2ab66ff34f5f9035c2aa35e3d31c1cee (patch) | |
| tree | 4b2bdc4a6a94ac2f8d24159d2787568f97ae589e | |
| parent | 36c8d8681b982ca14485bd16217938fcd228b941 (diff) | |
| parent | 79fac3a45af0657efe693636fad1705f31508703 (diff) | |
Merge "Add override to WallpaperManager.peekBitmapDimensions with `which` param" into tm-qpr-dev
| -rw-r--r-- | core/java/android/app/WallpaperManager.java | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/core/java/android/app/WallpaperManager.java b/core/java/android/app/WallpaperManager.java index 14fe5226b9d9..3e6283e25aa5 100644 --- a/core/java/android/app/WallpaperManager.java +++ b/core/java/android/app/WallpaperManager.java @@ -1132,12 +1132,26 @@ public class WallpaperManager { * @return the dimensions of system wallpaper * @hide */ + @Nullable public Rect peekBitmapDimensions() { return sGlobals.peekWallpaperDimensions( mContext, true /* returnDefault */, mContext.getUserId()); } /** + * Peek the dimensions of given wallpaper of the user without decoding it. + * + * @param which Wallpaper type. Must be either {@link #FLAG_SYSTEM} or + * {@link #FLAG_LOCK}. + * @return the dimensions of system wallpaper + * @hide + */ + @Nullable + public Rect peekBitmapDimensions(@SetWallpaperFlags int which) { + return peekBitmapDimensions(); + } + + /** * Get an open, readable file descriptor to the given wallpaper image file. * The caller is responsible for closing the file descriptor when done ingesting the file. * |