diff options
| author | Lucas Dupin <dupin@google.com> | 2020-03-12 04:07:51 +0000 |
|---|---|---|
| committer | Android (Google) Code Review <android-gerrit@google.com> | 2020-03-12 04:07:51 +0000 |
| commit | 888edd6fdcb57723b6dbd8fd3eeba3709c8541aa (patch) | |
| tree | 3aab46fc1d05ca5279813205109acdcc6005debe /core/java/android/view | |
| parent | 84b4877d85b30df12963db416b53d03edff40ea2 (diff) | |
| parent | 13f4b8a158683c9f8b91146e9d0fad6424f6a369 (diff) | |
Merge "Implement wallpaper zoom hooking it to the shade" into rvc-dev
Diffstat (limited to 'core/java/android/view')
| -rw-r--r-- | core/java/android/view/IWindow.aidl | 4 | ||||
| -rw-r--r-- | core/java/android/view/IWindowSession.aidl | 13 | ||||
| -rw-r--r-- | core/java/android/view/ViewRootImpl.java | 2 | ||||
| -rw-r--r-- | core/java/android/view/WindowlessWindowManager.java | 8 |
4 files changed, 24 insertions, 3 deletions
diff --git a/core/java/android/view/IWindow.aidl b/core/java/android/view/IWindow.aidl index 3927ebfdb5a8..9f2d36de61cd 100644 --- a/core/java/android/view/IWindow.aidl +++ b/core/java/android/view/IWindow.aidl @@ -102,9 +102,9 @@ oneway interface IWindow { void closeSystemDialogs(String reason); /** - * Called for wallpaper windows when their offsets change. + * Called for wallpaper windows when their offsets or zoom level change. */ - void dispatchWallpaperOffsets(float x, float y, float xStep, float yStep, boolean sync); + void dispatchWallpaperOffsets(float x, float y, float xStep, float yStep, float zoom, boolean sync); void dispatchWallpaperCommand(String action, int x, int y, int z, in Bundle extras, boolean sync); diff --git a/core/java/android/view/IWindowSession.aidl b/core/java/android/view/IWindowSession.aidl index 91000a93b17c..dfe89a37a229 100644 --- a/core/java/android/view/IWindowSession.aidl +++ b/core/java/android/view/IWindowSession.aidl @@ -221,6 +221,19 @@ interface IWindowSession { */ void setWallpaperPosition(IBinder windowToken, float x, float y, float xstep, float ystep); + /** + * For wallpaper windows, sets the scale of the wallpaper based on + * SystemUI behavior. + */ + void setWallpaperZoomOut(IBinder windowToken, float scale); + + /** + * For wallpaper windows, sets whether the wallpaper should actually be + * scaled when setWallpaperZoomOut is called. If set to false, the WallpaperService will + * receive the zoom out value but the surface won't be scaled. + */ + void setShouldZoomOutWallpaper(IBinder windowToken, boolean shouldZoom); + @UnsupportedAppUsage void wallpaperOffsetsComplete(IBinder window); diff --git a/core/java/android/view/ViewRootImpl.java b/core/java/android/view/ViewRootImpl.java index 9e5298b04497..26ac4fc4ddc2 100644 --- a/core/java/android/view/ViewRootImpl.java +++ b/core/java/android/view/ViewRootImpl.java @@ -9054,7 +9054,7 @@ public final class ViewRootImpl implements ViewParent, @Override public void dispatchWallpaperOffsets(float x, float y, float xStep, float yStep, - boolean sync) { + float zoom, boolean sync) { if (sync) { try { mWindowSession.wallpaperOffsetsComplete(asBinder()); diff --git a/core/java/android/view/WindowlessWindowManager.java b/core/java/android/view/WindowlessWindowManager.java index 87dcba0490ee..144f8e3a7108 100644 --- a/core/java/android/view/WindowlessWindowManager.java +++ b/core/java/android/view/WindowlessWindowManager.java @@ -312,6 +312,14 @@ public class WindowlessWindowManager implements IWindowSession { } @Override + public void setWallpaperZoomOut(android.os.IBinder windowToken, float zoom) { + } + + @Override + public void setShouldZoomOutWallpaper(android.os.IBinder windowToken, boolean shouldZoom) { + } + + @Override public void wallpaperOffsetsComplete(android.os.IBinder window) { } |
