summaryrefslogtreecommitdiff
path: root/core/java/android/view/ViewRootImpl.java
diff options
context:
space:
mode:
authorTreeHugger Robot <treehugger-gerrit@google.com>2022-03-10 09:34:19 +0000
committerAndroid (Google) Code Review <android-gerrit@google.com>2022-03-10 09:34:19 +0000
commit771ed53fc207b491d3fda66c907cc87ce4dd1413 (patch)
treefe5ae304718d5315211a3583755d6992bc302da2 /core/java/android/view/ViewRootImpl.java
parent8507e74ef6700a1ea1f8a791798984cdcf9f5428 (diff)
parent40c0b8bdb97d872ce9278db9a2ac4ee9ac14bb8f (diff)
Merge "Introduce a flag to enable shell caption" into tm-dev
Diffstat (limited to 'core/java/android/view/ViewRootImpl.java')
-rw-r--r--core/java/android/view/ViewRootImpl.java9
1 files changed, 9 insertions, 0 deletions
diff --git a/core/java/android/view/ViewRootImpl.java b/core/java/android/view/ViewRootImpl.java
index bde761e59620..18e65c9f3a37 100644
--- a/core/java/android/view/ViewRootImpl.java
+++ b/core/java/android/view/ViewRootImpl.java
@@ -277,6 +277,12 @@ public final class ViewRootImpl implements ViewParent,
private static final boolean ENABLE_INPUT_LATENCY_TRACKING = true;
/**
+ * Whether the caption is drawn by the shell.
+ * @hide
+ */
+ public static final boolean CAPTION_ON_SHELL = false;
+
+ /**
* Set this system property to true to force the view hierarchy to render
* at 60 Hz. This can be used to measure the potential framerate.
*/
@@ -2561,6 +2567,9 @@ public final class ViewRootImpl implements ViewParent,
}
private boolean updateCaptionInsets() {
+ if (CAPTION_ON_SHELL) {
+ return false;
+ }
if (!(mView instanceof DecorView)) return false;
final int captionInsetsHeight = ((DecorView) mView).getCaptionInsetsHeight();
final Rect captionFrame = new Rect();