summaryrefslogtreecommitdiffstats
path: root/core/java/android/hardware/display/DisplayManager.java
diff options
context:
space:
mode:
authorJeff Brown <jeffbrown@google.com>2012-08-23 19:48:44 -0700
committerJeff Brown <jeffbrown@google.com>2012-08-31 15:42:45 -0700
commita492c3a7b2c18426fd0cb4d017eacbc368195dc5 (patch)
tree67744a8d91519d997cb761a697600041d74165fa /core/java/android/hardware/display/DisplayManager.java
parent00453e7a0182b50cf01e65c97650b526284fe084 (diff)
downloadframeworks_base-a492c3a7b2c18426fd0cb4d017eacbc368195dc5.zip
frameworks_base-a492c3a7b2c18426fd0cb4d017eacbc368195dc5.tar.gz
frameworks_base-a492c3a7b2c18426fd0cb4d017eacbc368195dc5.tar.bz2
Initial draft of high-level multi-display APIs.
This patch introduces the ability to create a Context that is bound to a Display. The context gets its configuration and metrics from that display and is able to provide a WindowManager that is bound to the display. To make it easier to use, we also add a new kind of Dialog called a Presentation. Presentation takes care of setting up the context as needed and watches for significant changes in the display configuration. If the display is removed, then the presentation simply dismisses itself. Change-Id: Idc54b4ec84b1ff91505cfb78910cf8cd09696d7d
Diffstat (limited to 'core/java/android/hardware/display/DisplayManager.java')
-rw-r--r--core/java/android/hardware/display/DisplayManager.java11
1 files changed, 1 insertions, 10 deletions
diff --git a/core/java/android/hardware/display/DisplayManager.java b/core/java/android/hardware/display/DisplayManager.java
index 74996da..2814301 100644
--- a/core/java/android/hardware/display/DisplayManager.java
+++ b/core/java/android/hardware/display/DisplayManager.java
@@ -19,7 +19,6 @@ package android.hardware.display;
import android.content.Context;
import android.os.Handler;
import android.util.SparseArray;
-import android.view.CompatibilityInfoHolder;
import android.view.Display;
/**
@@ -92,7 +91,7 @@ public final class DisplayManager {
Display display = mDisplays.get(displayId);
if (display == null) {
display = mGlobal.getCompatibleDisplay(displayId,
- getCompatibilityInfoForDisplayLocked(displayId));
+ mContext.getCompatibilityInfo(displayId));
if (display != null) {
mDisplays.put(displayId, display);
}
@@ -102,14 +101,6 @@ public final class DisplayManager {
return display;
}
- private CompatibilityInfoHolder getCompatibilityInfoForDisplayLocked(int displayId) {
- CompatibilityInfoHolder cih = null;
- if (displayId == Display.DEFAULT_DISPLAY) {
- cih = mContext.getCompatibilityInfo();
- }
- return cih;
- }
-
/**
* Registers an display listener to receive notifications about when
* displays are added, removed or changed.