Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 885c7ef7 authored by Treehugger Robot's avatar Treehugger Robot Committed by Automerger Merge Worker
Browse files

Merge "Remove some hdmi ro properties" am: 5bfe628d am: 4a52b8ee

Change-Id: I3eaa1abce5f5e1f0079677c4bad838ce711e374f
parents a68c1741 4a52b8ee
Loading
Loading
Loading
Loading
+1 −11
Original line number Diff line number Diff line
@@ -22,7 +22,6 @@ import android.hardware.tv.cec.V1_0.SendMessageResult;
import android.os.Handler;
import android.os.Looper;
import android.os.MessageQueue;
import android.os.SystemProperties;
import android.util.Slog;
import android.util.SparseArray;

@@ -117,18 +116,10 @@ final class HdmiCecController {

    private final NativeWrapper mNativeWrapperImpl;

    /** List of logical addresses that should not be assigned to the current device.
     *
     * <p>Parsed from {@link Constants#PROPERTY_HDMI_CEC_NEVER_ASSIGN_LOGICAL_ADDRESSES}
     */
    private final List<Integer> mNeverAssignLogicalAddresses;

    // Private constructor.  Use HdmiCecController.create().
    private HdmiCecController(HdmiControlService service, NativeWrapper nativeWrapper) {
        mService = service;
        mNativeWrapperImpl = nativeWrapper;
        mNeverAssignLogicalAddresses = mService.getIntList(SystemProperties.get(
            Constants.PROPERTY_HDMI_CEC_NEVER_ASSIGN_LOGICAL_ADDRESSES));
    }

    /**
@@ -221,8 +212,7 @@ final class HdmiCecController {
        for (int i = 0; i < NUM_LOGICAL_ADDRESS; ++i) {
            int curAddress = (startAddress + i) % NUM_LOGICAL_ADDRESS;
            if (curAddress != Constants.ADDR_UNREGISTERED
                    && deviceType == HdmiUtils.getTypeFromAddress(curAddress)
                    && !mNeverAssignLogicalAddresses.contains(curAddress)) {
                    && deviceType == HdmiUtils.getTypeFromAddress(curAddress)) {
                boolean acked = false;
                for (int j = 0; j < HdmiConfig.ADDRESS_ALLOCATION_RETRY; ++j) {
                    if (sendPollMessage(curAddress, curAddress, 1)) {
+2 −8
Original line number Diff line number Diff line
@@ -181,10 +181,6 @@ public class HdmiControlService extends SystemService {
    @GuardedBy("mLock")
    private boolean mSystemAudioActivated = false;

    private static final boolean isHdmiCecNeverClaimPlaybackLogicAddr =
            SystemProperties.getBoolean(
                    Constants.PROPERTY_HDMI_CEC_NEVER_CLAIM_PLAYBACK_LOGICAL_ADDRESS, false);

    /**
     * Interface to report send result.
     */
@@ -772,8 +768,7 @@ public class HdmiControlService extends SystemService {
        // A container for [Device type, Local device info].
        ArrayList<HdmiCecLocalDevice> localDevices = new ArrayList<>();
        for (int type : mLocalDevices) {
            if (type == HdmiDeviceInfo.DEVICE_PLAYBACK
                    && isHdmiCecNeverClaimPlaybackLogicAddr) {
            if (type == HdmiDeviceInfo.DEVICE_PLAYBACK) {
                continue;
            }
            HdmiCecLocalDevice localDevice = mCecController.getLocalDevice(type);
@@ -1190,8 +1185,7 @@ public class HdmiControlService extends SystemService {
            }
            ArrayList<HdmiCecLocalDevice> localDevices = new ArrayList<>();
            for (int type : mLocalDevices) {
                if (type == HdmiDeviceInfo.DEVICE_PLAYBACK
                        && isHdmiCecNeverClaimPlaybackLogicAddr) {
                if (type == HdmiDeviceInfo.DEVICE_PLAYBACK) {
                    continue;
                }
                HdmiCecLocalDevice localDevice = mCecController.getLocalDevice(type);