diff options
| author | 2015-01-05 16:07:28 +0900 | |
|---|---|---|
| committer | 2015-01-05 16:07:28 +0900 | |
| commit | e416d0f67bfed9c8a65573091016d49777c56e8f (patch) | |
| tree | 317265ee8c333501c41aa2e3dc97894bd6a8078b | |
| parent | ad1e3d7df42376cd2a257b6c3b2fed540658a6e3 (diff) | |
CEC: Let MHL device be of type 'source'
MHL devices should be of type source that can stream AV contents
to the connected TV. This should be supported by the API
HdmiDeviceInfo.isSourceType().
Bug: 18897172
Change-Id: I7dcbd7773127bf26797c204504a12c3e2ebbd83b
| -rw-r--r-- | core/java/android/hardware/hdmi/HdmiDeviceInfo.java | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/core/java/android/hardware/hdmi/HdmiDeviceInfo.java b/core/java/android/hardware/hdmi/HdmiDeviceInfo.java index fe414e6b11b5..c4c7f2d77a8a 100644 --- a/core/java/android/hardware/hdmi/HdmiDeviceInfo.java +++ b/core/java/android/hardware/hdmi/HdmiDeviceInfo.java @@ -336,9 +336,15 @@ public class HdmiDeviceInfo implements Parcelable { * Returns {@code true} if the device is of a type that can be an input source. */ public boolean isSourceType() { - return mDeviceType == DEVICE_PLAYBACK - || mDeviceType == DEVICE_RECORDER - || mDeviceType == DEVICE_TUNER; + if (isCecDevice()) { + return mDeviceType == DEVICE_PLAYBACK + || mDeviceType == DEVICE_RECORDER + || mDeviceType == DEVICE_TUNER; + } else if (isMhlDevice()) { + return true; + } else { + return false; + } } /** |