Loading core/java/android/service/wallpaper/WallpaperService.java +3 −2 Original line number Diff line number Diff line Loading @@ -40,6 +40,7 @@ import android.os.Process; import android.os.RemoteException; import android.util.Log; import android.util.LogPrinter; import android.view.Display; import android.view.Gravity; import android.view.IWindowSession; import android.view.InputChannel; Loading Loading @@ -612,8 +613,8 @@ public abstract class WallpaperService extends Service { mLayout.windowAnimations = com.android.internal.R.style.Animation_Wallpaper; mInputChannel = new InputChannel(); if (mSession.add(mWindow, mWindow.mSeq, mLayout, View.VISIBLE, mContentInsets, mInputChannel) < 0) { if (mSession.addToDisplay(mWindow, mWindow.mSeq, mLayout, View.VISIBLE, Display.DEFAULT_DISPLAY, mContentInsets, mInputChannel) < 0) { Log.w(TAG, "Failed to add window while updating wallpaper surface."); return; } Loading core/java/android/view/IWindowManager.aidl +0 −1 Original line number Diff line number Diff line Loading @@ -25,7 +25,6 @@ import android.graphics.Bitmap; import android.graphics.Point; import android.graphics.Rect; import android.os.IRemoteCallback; import android.view.DisplayInfo; import android.view.IApplicationToken; import android.view.IOnKeyguardExitResult; import android.view.IRotationWatcher; Loading core/java/android/view/IWindowSession.aidl +5 −0 Original line number Diff line number Diff line Loading @@ -37,8 +37,13 @@ interface IWindowSession { int add(IWindow window, int seq, in WindowManager.LayoutParams attrs, in int viewVisibility, out Rect outContentInsets, out InputChannel outInputChannel); int addToDisplay(IWindow window, int seq, in WindowManager.LayoutParams attrs, in int viewVisibility, in int layerStackId, out Rect outContentInsets, out InputChannel outInputChannel); int addWithoutInputChannel(IWindow window, int seq, in WindowManager.LayoutParams attrs, in int viewVisibility, out Rect outContentInsets); int addToDisplayWithoutInputChannel(IWindow window, int seq, in WindowManager.LayoutParams attrs, in int viewVisibility, in int layerStackId, out Rect outContentInsets); void remove(IWindow window); /** Loading core/java/android/view/Surface.java +5 −5 Original line number Diff line number Diff line Loading @@ -248,7 +248,7 @@ public class Surface implements Parcelable { /** create a surface @hide */ public Surface(SurfaceSession s, int pid, int display, int w, int h, int format, int flags) int pid, int displayId, int w, int h, int format, int flags) throws OutOfResourcesException { checkHeadless(); Loading @@ -256,12 +256,12 @@ public class Surface implements Parcelable { mCreationStack = new Exception(); } mCanvas = new CompatibleCanvas(); init(s,pid,null,display,w,h,format,flags); init(s,pid,null,displayId,w,h,format,flags); } /** create a surface with a name @hide */ public Surface(SurfaceSession s, int pid, String name, int display, int w, int h, int format, int flags) int pid, String name, int displayId, int w, int h, int format, int flags) throws OutOfResourcesException { checkHeadless(); Loading @@ -269,7 +269,7 @@ public class Surface implements Parcelable { mCreationStack = new Exception(); } mCanvas = new CompatibleCanvas(); init(s,pid,name,display,w,h,format,flags); init(s,pid,name,displayId,w,h,format,flags); mName = name; } Loading Loading @@ -508,7 +508,7 @@ public class Surface implements Parcelable { } private native void init(SurfaceSession s, int pid, String name, int display, int w, int h, int format, int flags) int pid, String name, int displayId, int w, int h, int format, int flags) throws OutOfResourcesException; private native void init(Parcel source); Loading core/java/android/view/SurfaceView.java +2 −2 Original line number Diff line number Diff line Loading @@ -459,8 +459,8 @@ public class SurfaceView extends View { mWindow = new MyWindow(this); mLayout.type = mWindowType; mLayout.gravity = Gravity.START|Gravity.TOP; mSession.addWithoutInputChannel(mWindow, mWindow.mSeq, mLayout, mVisible ? VISIBLE : GONE, mContentInsets); mSession.addToDisplayWithoutInputChannel(mWindow, mWindow.mSeq, mLayout, mVisible ? VISIBLE : GONE, Display.DEFAULT_DISPLAY, mContentInsets); } boolean realSizeChanged; Loading Loading
core/java/android/service/wallpaper/WallpaperService.java +3 −2 Original line number Diff line number Diff line Loading @@ -40,6 +40,7 @@ import android.os.Process; import android.os.RemoteException; import android.util.Log; import android.util.LogPrinter; import android.view.Display; import android.view.Gravity; import android.view.IWindowSession; import android.view.InputChannel; Loading Loading @@ -612,8 +613,8 @@ public abstract class WallpaperService extends Service { mLayout.windowAnimations = com.android.internal.R.style.Animation_Wallpaper; mInputChannel = new InputChannel(); if (mSession.add(mWindow, mWindow.mSeq, mLayout, View.VISIBLE, mContentInsets, mInputChannel) < 0) { if (mSession.addToDisplay(mWindow, mWindow.mSeq, mLayout, View.VISIBLE, Display.DEFAULT_DISPLAY, mContentInsets, mInputChannel) < 0) { Log.w(TAG, "Failed to add window while updating wallpaper surface."); return; } Loading
core/java/android/view/IWindowManager.aidl +0 −1 Original line number Diff line number Diff line Loading @@ -25,7 +25,6 @@ import android.graphics.Bitmap; import android.graphics.Point; import android.graphics.Rect; import android.os.IRemoteCallback; import android.view.DisplayInfo; import android.view.IApplicationToken; import android.view.IOnKeyguardExitResult; import android.view.IRotationWatcher; Loading
core/java/android/view/IWindowSession.aidl +5 −0 Original line number Diff line number Diff line Loading @@ -37,8 +37,13 @@ interface IWindowSession { int add(IWindow window, int seq, in WindowManager.LayoutParams attrs, in int viewVisibility, out Rect outContentInsets, out InputChannel outInputChannel); int addToDisplay(IWindow window, int seq, in WindowManager.LayoutParams attrs, in int viewVisibility, in int layerStackId, out Rect outContentInsets, out InputChannel outInputChannel); int addWithoutInputChannel(IWindow window, int seq, in WindowManager.LayoutParams attrs, in int viewVisibility, out Rect outContentInsets); int addToDisplayWithoutInputChannel(IWindow window, int seq, in WindowManager.LayoutParams attrs, in int viewVisibility, in int layerStackId, out Rect outContentInsets); void remove(IWindow window); /** Loading
core/java/android/view/Surface.java +5 −5 Original line number Diff line number Diff line Loading @@ -248,7 +248,7 @@ public class Surface implements Parcelable { /** create a surface @hide */ public Surface(SurfaceSession s, int pid, int display, int w, int h, int format, int flags) int pid, int displayId, int w, int h, int format, int flags) throws OutOfResourcesException { checkHeadless(); Loading @@ -256,12 +256,12 @@ public class Surface implements Parcelable { mCreationStack = new Exception(); } mCanvas = new CompatibleCanvas(); init(s,pid,null,display,w,h,format,flags); init(s,pid,null,displayId,w,h,format,flags); } /** create a surface with a name @hide */ public Surface(SurfaceSession s, int pid, String name, int display, int w, int h, int format, int flags) int pid, String name, int displayId, int w, int h, int format, int flags) throws OutOfResourcesException { checkHeadless(); Loading @@ -269,7 +269,7 @@ public class Surface implements Parcelable { mCreationStack = new Exception(); } mCanvas = new CompatibleCanvas(); init(s,pid,name,display,w,h,format,flags); init(s,pid,name,displayId,w,h,format,flags); mName = name; } Loading Loading @@ -508,7 +508,7 @@ public class Surface implements Parcelable { } private native void init(SurfaceSession s, int pid, String name, int display, int w, int h, int format, int flags) int pid, String name, int displayId, int w, int h, int format, int flags) throws OutOfResourcesException; private native void init(Parcel source); Loading
core/java/android/view/SurfaceView.java +2 −2 Original line number Diff line number Diff line Loading @@ -459,8 +459,8 @@ public class SurfaceView extends View { mWindow = new MyWindow(this); mLayout.type = mWindowType; mLayout.gravity = Gravity.START|Gravity.TOP; mSession.addWithoutInputChannel(mWindow, mWindow.mSeq, mLayout, mVisible ? VISIBLE : GONE, mContentInsets); mSession.addToDisplayWithoutInputChannel(mWindow, mWindow.mSeq, mLayout, mVisible ? VISIBLE : GONE, Display.DEFAULT_DISPLAY, mContentInsets); } boolean realSizeChanged; Loading