diff options
author | TreeHugger Robot <treehugger-gerrit@google.com> | 2020-04-07 16:41:47 +0000 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2020-04-07 16:41:47 +0000 |
commit | bd745f763aae2e6f49343391349da7fc4bdeded0 (patch) | |
tree | 997809becb9c80193501da8f6290f810df01ee0f | |
parent | f7ef70e669397b8a1826bc12bdd9bd0ff72fe041 (diff) | |
parent | 29d5b8f43eec2b5d2d9c906ebb81107dd603be62 (diff) |
Merge "Expose Display.getType() via TestApi." into rvc-dev
-rw-r--r-- | api/test-current.txt | 7 | ||||
-rw-r--r-- | core/java/android/view/Display.java | 7 |
2 files changed, 14 insertions, 0 deletions
diff --git a/api/test-current.txt b/api/test-current.txt index 629ce4e6470e..23c1a23dc651 100644 --- a/api/test-current.txt +++ b/api/test-current.txt @@ -4814,7 +4814,14 @@ package android.view { public final class Display { method @NonNull public android.graphics.ColorSpace[] getSupportedWideColorGamut(); + method public int getType(); method public boolean hasAccess(int); + field public static final int TYPE_EXTERNAL = 2; // 0x2 + field public static final int TYPE_INTERNAL = 1; // 0x1 + field public static final int TYPE_OVERLAY = 4; // 0x4 + field public static final int TYPE_UNKNOWN = 0; // 0x0 + field public static final int TYPE_VIRTUAL = 5; // 0x5 + field public static final int TYPE_WIFI = 3; // 0x3 } public class FocusFinder { diff --git a/core/java/android/view/Display.java b/core/java/android/view/Display.java index 0ccb1e055c46..4469fdbb12ec 100644 --- a/core/java/android/view/Display.java +++ b/core/java/android/view/Display.java @@ -253,12 +253,14 @@ public final class Display { * @hide */ @UnsupportedAppUsage + @TestApi public static final int TYPE_UNKNOWN = 0; /** * Display type: Physical display connected through an internal port. * @hide */ + @TestApi public static final int TYPE_INTERNAL = 1; /** @@ -266,6 +268,7 @@ public final class Display { * @hide */ @UnsupportedAppUsage + @TestApi public static final int TYPE_EXTERNAL = 2; /** @@ -273,12 +276,14 @@ public final class Display { * @hide */ @UnsupportedAppUsage + @TestApi public static final int TYPE_WIFI = 3; /** * Display type: Overlay display. * @hide */ + @TestApi public static final int TYPE_OVERLAY = 4; /** @@ -286,6 +291,7 @@ public final class Display { * @hide */ @UnsupportedAppUsage + @TestApi public static final int TYPE_VIRTUAL = 5; /** @@ -569,6 +575,7 @@ public final class Display { * @hide */ @UnsupportedAppUsage + @TestApi public int getType() { return mType; } |