Loading core/api/current.txt +7 −7 Original line number Diff line number Diff line Loading @@ -46814,6 +46814,11 @@ package android.view { method public void onActionProviderVisibilityChanged(boolean); } @UiThread public interface AttachedSurfaceControl { method public boolean applyTransactionOnDraw(@NonNull android.view.SurfaceControl.Transaction); method @Nullable public android.view.SurfaceControl.Transaction buildReparentTransaction(@NonNull android.view.SurfaceControl); } public final class Choreographer { method public static android.view.Choreographer getInstance(); method public void postFrameCallback(android.view.Choreographer.FrameCallback); Loading Loading @@ -48714,6 +48719,7 @@ package android.view { method public final int getRight(); method protected float getRightFadingEdgeStrength(); method protected int getRightPaddingOffset(); method @Nullable public android.view.AttachedSurfaceControl getRootSurfaceControl(); method public android.view.View getRootView(); method public android.view.WindowInsets getRootWindowInsets(); method public float getRotation(); Loading Loading @@ -48758,7 +48764,6 @@ package android.view { method @Nullable public android.graphics.drawable.Drawable getVerticalScrollbarThumbDrawable(); method @Nullable public android.graphics.drawable.Drawable getVerticalScrollbarTrackDrawable(); method public int getVerticalScrollbarWidth(); method @Nullable public android.view.ViewRoot getViewRoot(); method @Nullable public android.view.translation.ViewTranslationResponse getViewTranslationResponse(); method public android.view.ViewTreeObserver getViewTreeObserver(); method public int getVisibility(); Loading Loading @@ -49834,11 +49839,6 @@ package android.view { method public android.view.ViewPropertyAnimator zBy(float); } @UiThread public interface ViewRoot { method public boolean applyTransactionOnDraw(@NonNull android.view.SurfaceControl.Transaction); method @Nullable public android.view.SurfaceControl.Transaction buildReparentTransaction(@NonNull android.view.SurfaceControl); } public abstract class ViewStructure { ctor public ViewStructure(); method public abstract int addChildCount(int); Loading Loading @@ -50025,6 +50025,7 @@ package android.view { method @ColorInt public int getNavigationBarDividerColor(); method public android.transition.Transition getReenterTransition(); method public android.transition.Transition getReturnTransition(); method @Nullable public android.view.AttachedSurfaceControl getRootSurfaceControl(); method public android.transition.Transition getSharedElementEnterTransition(); method public android.transition.Transition getSharedElementExitTransition(); method public android.transition.Transition getSharedElementReenterTransition(); Loading @@ -50034,7 +50035,6 @@ package android.view { method @NonNull public java.util.List<android.graphics.Rect> getSystemGestureExclusionRects(); method public long getTransitionBackgroundFadeDuration(); method public android.transition.TransitionManager getTransitionManager(); method @Nullable public android.view.ViewRoot getViewRoot(); method public abstract int getVolumeControlStream(); method public android.view.WindowManager getWindowManager(); method public final android.content.res.TypedArray getWindowStyle(); core/java/android/view/ViewRoot.java→core/java/android/view/AttachedSurfaceControl.java +12 −9 Original line number Diff line number Diff line Loading @@ -22,16 +22,19 @@ import android.annotation.UiThread; /** * Provides an interface to the root-Surface of a View Hierarchy or Window. This * is used in combination with the {@link android.view.SurfaceControl} API to enable * attaching app created SurfaceControl to the ViewRoot's surface hierarchy, and enable * SurfaceTransactions to be performed in sync with the ViewRoot drawing. This object * is obtained from {@link android.view.View#getViewRoot} and * {@link android.view.Window#getViewRoot}. It must be used from the UI thread of * attaching app created SurfaceControl to the SurfaceControl hierarchy used * by the app, and enable SurfaceTransactions to be performed in sync with the * View hierarchy drawing. * * This object is obtained from {@link android.view.View#getRootSurfaceControl} and * {@link android.view.Window#getRootSurfaceControl}. It must be used from the UI thread of * the object it was obtained from. */ @UiThread public interface ViewRoot { public interface AttachedSurfaceControl { /** * Create a transaction which will reparent {@param child} to the ViewRoot. See * Create a transaction which will reparent {@param child} to the View hierarchy * root SurfaceControl. See * {@link SurfaceControl.Transaction#reparent}. This transacton must be applied * or merged in to another transaction by the caller, otherwise it will have * no effect. Loading @@ -42,9 +45,9 @@ public interface ViewRoot { @Nullable SurfaceControl.Transaction buildReparentTransaction(@NonNull SurfaceControl child); /** * Consume the passed in transaction, and request the ViewRoot to apply it with the * next draw. This transaction will be merged with the buffer transaction from the ViewRoot * and they will show up on-screen atomically synced. * Consume the passed in transaction, and request the View hierarchy to apply it atomically * with the next draw. This transaction will be merged with the buffer transaction from the * ViewRoot and they will show up on-screen atomically synced. * * This will not cause a draw to be scheduled, and if there are no other changes * to the View hierarchy you may need to call {@link android.view.View#invalidate} Loading core/java/android/view/View.java +10 −10 Original line number Diff line number Diff line Loading @@ -29599,7 +29599,7 @@ public class View implements Drawable.Callback, KeyEvent.Callback, return mScrollCaptureInternal; } ViewRoot getViewRoot() { AttachedSurfaceControl getRootSurfaceControl() { return mViewRootImpl; } Loading Loading @@ -31043,17 +31043,17 @@ public class View implements Drawable.Callback, KeyEvent.Callback, } /** * @return The {@link android.view.ViewRoot} interface for this View. This will only * return a non-null value when called between {@link #onAttachedToWindow} and * {@link #onDetachedFromWindow}. * * The ViewRoot itself is not a View, it is just the interface to the windowing-system * object that contains the entire view hierarchy. For the root View of a given hierarchy * see {@link #getRootView}. * The AttachedSurfaceControl itself is not a View, it is just the interface to the * windowing-system object that contains the entire view hierarchy. * For the root View of a given hierarchy see {@link #getRootView}. * @return The {@link android.view.AttachedSurfaceControl} interface for this View. * This will only return a non-null value when called between {@link #onAttachedToWindow} * and {@link #onDetachedFromWindow}. */ public @Nullable ViewRoot getViewRoot() { public @Nullable AttachedSurfaceControl getRootSurfaceControl() { if (mAttachInfo != null) { return mAttachInfo.getViewRoot(); return mAttachInfo.getRootSurfaceControl(); } return null; } core/java/android/view/ViewRootImpl.java +2 −1 Original line number Diff line number Diff line Loading @@ -224,7 +224,8 @@ import java.util.concurrent.CountDownLatch; */ @SuppressWarnings({"EmptyCatchBlock", "PointlessBooleanExpression"}) public final class ViewRootImpl implements ViewParent, View.AttachInfo.Callbacks, ThreadedRenderer.DrawCallbacks, ViewRoot { View.AttachInfo.Callbacks, ThreadedRenderer.DrawCallbacks, AttachedSurfaceControl { private static final String TAG = "ViewRootImpl"; private static final boolean DBG = false; private static final boolean LOCAL_LOGV = false; Loading core/java/android/view/Window.java +4 −3 Original line number Diff line number Diff line Loading @@ -2722,11 +2722,12 @@ public abstract class Window { /** * This will be null before a content view is added, e.g. via * {@link #setContentView} or {@link #addContentView}. * {@link #setContentView} or {@link #addContentView}. See * {@link android.view.View#getRootSurfaceControl}. * * @return The {@link android.view.ViewRoot} interface for this Window * @return The {@link android.view.AttachedSurfaceControl} interface for this Window */ public @Nullable ViewRoot getViewRoot() { public @Nullable AttachedSurfaceControl getRootSurfaceControl() { return null; } } Loading
core/api/current.txt +7 −7 Original line number Diff line number Diff line Loading @@ -46814,6 +46814,11 @@ package android.view { method public void onActionProviderVisibilityChanged(boolean); } @UiThread public interface AttachedSurfaceControl { method public boolean applyTransactionOnDraw(@NonNull android.view.SurfaceControl.Transaction); method @Nullable public android.view.SurfaceControl.Transaction buildReparentTransaction(@NonNull android.view.SurfaceControl); } public final class Choreographer { method public static android.view.Choreographer getInstance(); method public void postFrameCallback(android.view.Choreographer.FrameCallback); Loading Loading @@ -48714,6 +48719,7 @@ package android.view { method public final int getRight(); method protected float getRightFadingEdgeStrength(); method protected int getRightPaddingOffset(); method @Nullable public android.view.AttachedSurfaceControl getRootSurfaceControl(); method public android.view.View getRootView(); method public android.view.WindowInsets getRootWindowInsets(); method public float getRotation(); Loading Loading @@ -48758,7 +48764,6 @@ package android.view { method @Nullable public android.graphics.drawable.Drawable getVerticalScrollbarThumbDrawable(); method @Nullable public android.graphics.drawable.Drawable getVerticalScrollbarTrackDrawable(); method public int getVerticalScrollbarWidth(); method @Nullable public android.view.ViewRoot getViewRoot(); method @Nullable public android.view.translation.ViewTranslationResponse getViewTranslationResponse(); method public android.view.ViewTreeObserver getViewTreeObserver(); method public int getVisibility(); Loading Loading @@ -49834,11 +49839,6 @@ package android.view { method public android.view.ViewPropertyAnimator zBy(float); } @UiThread public interface ViewRoot { method public boolean applyTransactionOnDraw(@NonNull android.view.SurfaceControl.Transaction); method @Nullable public android.view.SurfaceControl.Transaction buildReparentTransaction(@NonNull android.view.SurfaceControl); } public abstract class ViewStructure { ctor public ViewStructure(); method public abstract int addChildCount(int); Loading Loading @@ -50025,6 +50025,7 @@ package android.view { method @ColorInt public int getNavigationBarDividerColor(); method public android.transition.Transition getReenterTransition(); method public android.transition.Transition getReturnTransition(); method @Nullable public android.view.AttachedSurfaceControl getRootSurfaceControl(); method public android.transition.Transition getSharedElementEnterTransition(); method public android.transition.Transition getSharedElementExitTransition(); method public android.transition.Transition getSharedElementReenterTransition(); Loading @@ -50034,7 +50035,6 @@ package android.view { method @NonNull public java.util.List<android.graphics.Rect> getSystemGestureExclusionRects(); method public long getTransitionBackgroundFadeDuration(); method public android.transition.TransitionManager getTransitionManager(); method @Nullable public android.view.ViewRoot getViewRoot(); method public abstract int getVolumeControlStream(); method public android.view.WindowManager getWindowManager(); method public final android.content.res.TypedArray getWindowStyle();
core/java/android/view/ViewRoot.java→core/java/android/view/AttachedSurfaceControl.java +12 −9 Original line number Diff line number Diff line Loading @@ -22,16 +22,19 @@ import android.annotation.UiThread; /** * Provides an interface to the root-Surface of a View Hierarchy or Window. This * is used in combination with the {@link android.view.SurfaceControl} API to enable * attaching app created SurfaceControl to the ViewRoot's surface hierarchy, and enable * SurfaceTransactions to be performed in sync with the ViewRoot drawing. This object * is obtained from {@link android.view.View#getViewRoot} and * {@link android.view.Window#getViewRoot}. It must be used from the UI thread of * attaching app created SurfaceControl to the SurfaceControl hierarchy used * by the app, and enable SurfaceTransactions to be performed in sync with the * View hierarchy drawing. * * This object is obtained from {@link android.view.View#getRootSurfaceControl} and * {@link android.view.Window#getRootSurfaceControl}. It must be used from the UI thread of * the object it was obtained from. */ @UiThread public interface ViewRoot { public interface AttachedSurfaceControl { /** * Create a transaction which will reparent {@param child} to the ViewRoot. See * Create a transaction which will reparent {@param child} to the View hierarchy * root SurfaceControl. See * {@link SurfaceControl.Transaction#reparent}. This transacton must be applied * or merged in to another transaction by the caller, otherwise it will have * no effect. Loading @@ -42,9 +45,9 @@ public interface ViewRoot { @Nullable SurfaceControl.Transaction buildReparentTransaction(@NonNull SurfaceControl child); /** * Consume the passed in transaction, and request the ViewRoot to apply it with the * next draw. This transaction will be merged with the buffer transaction from the ViewRoot * and they will show up on-screen atomically synced. * Consume the passed in transaction, and request the View hierarchy to apply it atomically * with the next draw. This transaction will be merged with the buffer transaction from the * ViewRoot and they will show up on-screen atomically synced. * * This will not cause a draw to be scheduled, and if there are no other changes * to the View hierarchy you may need to call {@link android.view.View#invalidate} Loading
core/java/android/view/View.java +10 −10 Original line number Diff line number Diff line Loading @@ -29599,7 +29599,7 @@ public class View implements Drawable.Callback, KeyEvent.Callback, return mScrollCaptureInternal; } ViewRoot getViewRoot() { AttachedSurfaceControl getRootSurfaceControl() { return mViewRootImpl; } Loading Loading @@ -31043,17 +31043,17 @@ public class View implements Drawable.Callback, KeyEvent.Callback, } /** * @return The {@link android.view.ViewRoot} interface for this View. This will only * return a non-null value when called between {@link #onAttachedToWindow} and * {@link #onDetachedFromWindow}. * * The ViewRoot itself is not a View, it is just the interface to the windowing-system * object that contains the entire view hierarchy. For the root View of a given hierarchy * see {@link #getRootView}. * The AttachedSurfaceControl itself is not a View, it is just the interface to the * windowing-system object that contains the entire view hierarchy. * For the root View of a given hierarchy see {@link #getRootView}. * @return The {@link android.view.AttachedSurfaceControl} interface for this View. * This will only return a non-null value when called between {@link #onAttachedToWindow} * and {@link #onDetachedFromWindow}. */ public @Nullable ViewRoot getViewRoot() { public @Nullable AttachedSurfaceControl getRootSurfaceControl() { if (mAttachInfo != null) { return mAttachInfo.getViewRoot(); return mAttachInfo.getRootSurfaceControl(); } return null; }
core/java/android/view/ViewRootImpl.java +2 −1 Original line number Diff line number Diff line Loading @@ -224,7 +224,8 @@ import java.util.concurrent.CountDownLatch; */ @SuppressWarnings({"EmptyCatchBlock", "PointlessBooleanExpression"}) public final class ViewRootImpl implements ViewParent, View.AttachInfo.Callbacks, ThreadedRenderer.DrawCallbacks, ViewRoot { View.AttachInfo.Callbacks, ThreadedRenderer.DrawCallbacks, AttachedSurfaceControl { private static final String TAG = "ViewRootImpl"; private static final boolean DBG = false; private static final boolean LOCAL_LOGV = false; Loading
core/java/android/view/Window.java +4 −3 Original line number Diff line number Diff line Loading @@ -2722,11 +2722,12 @@ public abstract class Window { /** * This will be null before a content view is added, e.g. via * {@link #setContentView} or {@link #addContentView}. * {@link #setContentView} or {@link #addContentView}. See * {@link android.view.View#getRootSurfaceControl}. * * @return The {@link android.view.ViewRoot} interface for this Window * @return The {@link android.view.AttachedSurfaceControl} interface for this Window */ public @Nullable ViewRoot getViewRoot() { public @Nullable AttachedSurfaceControl getRootSurfaceControl() { return null; } }