Loading services/core/java/com/android/server/hdmi/HdmiControlService.java +6 −3 Original line number Diff line number Diff line Loading @@ -856,8 +856,11 @@ public final class HdmiControlService extends SystemService { device.onDeviceRemoved(); // There is no explicit event for device removal unlike capability register event // used for device addition . Hence we remove the device on hotplug event. invokeDeviceEventListeners(device.getInfo(), DEVICE_EVENT_REMOVE_DEVICE); HdmiDeviceInfo deviceInfo = device.getInfo(); if (deviceInfo != null) { invokeDeviceEventListeners(deviceInfo, DEVICE_EVENT_REMOVE_DEVICE); updateSafeMhlInput(); } } else { Slog.w(TAG, "No device to remove:[portId=" + portId); } Loading Loading @@ -1082,7 +1085,7 @@ public final class HdmiControlService extends SystemService { // the connected mobile device, start routing control to switch ports. // callback is handled by MHL action. device.turnOn(callback); tv.doManualPortSwitching(device.getInfo().getPortId(), null); tv.doManualPortSwitching(device.getPortId(), null); return; } tv.deviceSelect(deviceId, callback); Loading Loading
services/core/java/com/android/server/hdmi/HdmiControlService.java +6 −3 Original line number Diff line number Diff line Loading @@ -856,8 +856,11 @@ public final class HdmiControlService extends SystemService { device.onDeviceRemoved(); // There is no explicit event for device removal unlike capability register event // used for device addition . Hence we remove the device on hotplug event. invokeDeviceEventListeners(device.getInfo(), DEVICE_EVENT_REMOVE_DEVICE); HdmiDeviceInfo deviceInfo = device.getInfo(); if (deviceInfo != null) { invokeDeviceEventListeners(deviceInfo, DEVICE_EVENT_REMOVE_DEVICE); updateSafeMhlInput(); } } else { Slog.w(TAG, "No device to remove:[portId=" + portId); } Loading Loading @@ -1082,7 +1085,7 @@ public final class HdmiControlService extends SystemService { // the connected mobile device, start routing control to switch ports. // callback is handled by MHL action. device.turnOn(callback); tv.doManualPortSwitching(device.getInfo().getPortId(), null); tv.doManualPortSwitching(device.getPortId(), null); return; } tv.deviceSelect(deviceId, callback); Loading