Loading core/java/android/view/ViewRootImpl.java +1 −1 Original line number Diff line number Diff line Loading @@ -291,7 +291,7 @@ public final class ViewRootImpl implements ViewParent, * @hide */ public static final boolean CAPTION_ON_SHELL = SystemProperties.getBoolean("persist.wm.debug.caption_on_shell", false); SystemProperties.getBoolean("persist.wm.debug.caption_on_shell", true); /** * Whether the client should compute the window frame on its own. Loading core/tests/coretests/src/android/view/InsetsSourceTest.java +0 −14 Original line number Diff line number Diff line Loading @@ -19,7 +19,6 @@ package android.view; import static android.view.WindowInsets.Type.FIRST; import static android.view.WindowInsets.Type.LAST; import static android.view.WindowInsets.Type.SIZE; import static android.view.WindowInsets.Type.captionBar; import static android.view.WindowInsets.Type.ime; import static android.view.WindowInsets.Type.navigationBars; Loading Loading @@ -52,13 +51,11 @@ public class InsetsSourceTest { private final InsetsSource mSource = new InsetsSource(0 /* id */, navigationBars()); private final InsetsSource mImeSource = new InsetsSource(1 /* id */, ime()); private final InsetsSource mCaptionSource = new InsetsSource(2 /* id */, captionBar()); @Before public void setUp() { mSource.setVisible(true); mImeSource.setVisible(true); mCaptionSource.setVisible(true); } @Test Loading Loading @@ -109,17 +106,6 @@ public class InsetsSourceTest { assertEquals(Insets.of(0, 0, 0, 100), insets); } @Test public void testCalculateInsets_caption_resizing() { mCaptionSource.setFrame(new Rect(0, 0, 100, 100)); Insets insets = mCaptionSource.calculateInsets(new Rect(0, 0, 200, 200), false); assertEquals(Insets.of(0, 100, 0, 0), insets); insets = mCaptionSource.calculateInsets(new Rect(0, 0, 50, 200), false); assertEquals(Insets.of(0, 100, 0, 0), insets); insets = mCaptionSource.calculateInsets(new Rect(100, 100, 200, 500), false); assertEquals(Insets.of(0, 100, 0, 0), insets); } @Test public void testCalculateInsets_invisible() { mSource.setFrame(new Rect(0, 0, 500, 100)); Loading core/tests/coretests/src/android/view/InsetsStateTest.java +0 −12 Original line number Diff line number Diff line Loading @@ -247,18 +247,6 @@ public class InsetsStateTest { assertEquals(Insets.of(0, 300, 0, 0), visibleInsets); } @Test public void testCalculateInsets_captionBarOffset() { mState.getOrCreateSource(ID_CAPTION_BAR, captionBar()) .setFrame(new Rect(0, 0, 100, 300)) .setVisible(true); Insets visibleInsets = mState.calculateVisibleInsets( new Rect(0, 0, 150, 400), TYPE_APPLICATION, WINDOWING_MODE_UNDEFINED, SOFT_INPUT_ADJUST_NOTHING, 0 /* windowFlags */); assertEquals(Insets.of(0, 300, 0, 0), visibleInsets); } @Test public void testCalculateInsets_extraNavRightStatusTop() { mState.getOrCreateSource(ID_STATUS_BAR, statusBars()) Loading Loading
core/java/android/view/ViewRootImpl.java +1 −1 Original line number Diff line number Diff line Loading @@ -291,7 +291,7 @@ public final class ViewRootImpl implements ViewParent, * @hide */ public static final boolean CAPTION_ON_SHELL = SystemProperties.getBoolean("persist.wm.debug.caption_on_shell", false); SystemProperties.getBoolean("persist.wm.debug.caption_on_shell", true); /** * Whether the client should compute the window frame on its own. Loading
core/tests/coretests/src/android/view/InsetsSourceTest.java +0 −14 Original line number Diff line number Diff line Loading @@ -19,7 +19,6 @@ package android.view; import static android.view.WindowInsets.Type.FIRST; import static android.view.WindowInsets.Type.LAST; import static android.view.WindowInsets.Type.SIZE; import static android.view.WindowInsets.Type.captionBar; import static android.view.WindowInsets.Type.ime; import static android.view.WindowInsets.Type.navigationBars; Loading Loading @@ -52,13 +51,11 @@ public class InsetsSourceTest { private final InsetsSource mSource = new InsetsSource(0 /* id */, navigationBars()); private final InsetsSource mImeSource = new InsetsSource(1 /* id */, ime()); private final InsetsSource mCaptionSource = new InsetsSource(2 /* id */, captionBar()); @Before public void setUp() { mSource.setVisible(true); mImeSource.setVisible(true); mCaptionSource.setVisible(true); } @Test Loading Loading @@ -109,17 +106,6 @@ public class InsetsSourceTest { assertEquals(Insets.of(0, 0, 0, 100), insets); } @Test public void testCalculateInsets_caption_resizing() { mCaptionSource.setFrame(new Rect(0, 0, 100, 100)); Insets insets = mCaptionSource.calculateInsets(new Rect(0, 0, 200, 200), false); assertEquals(Insets.of(0, 100, 0, 0), insets); insets = mCaptionSource.calculateInsets(new Rect(0, 0, 50, 200), false); assertEquals(Insets.of(0, 100, 0, 0), insets); insets = mCaptionSource.calculateInsets(new Rect(100, 100, 200, 500), false); assertEquals(Insets.of(0, 100, 0, 0), insets); } @Test public void testCalculateInsets_invisible() { mSource.setFrame(new Rect(0, 0, 500, 100)); Loading
core/tests/coretests/src/android/view/InsetsStateTest.java +0 −12 Original line number Diff line number Diff line Loading @@ -247,18 +247,6 @@ public class InsetsStateTest { assertEquals(Insets.of(0, 300, 0, 0), visibleInsets); } @Test public void testCalculateInsets_captionBarOffset() { mState.getOrCreateSource(ID_CAPTION_BAR, captionBar()) .setFrame(new Rect(0, 0, 100, 300)) .setVisible(true); Insets visibleInsets = mState.calculateVisibleInsets( new Rect(0, 0, 150, 400), TYPE_APPLICATION, WINDOWING_MODE_UNDEFINED, SOFT_INPUT_ADJUST_NOTHING, 0 /* windowFlags */); assertEquals(Insets.of(0, 300, 0, 0), visibleInsets); } @Test public void testCalculateInsets_extraNavRightStatusTop() { mState.getOrCreateSource(ID_STATUS_BAR, statusBars()) Loading