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

Commit 0648f5fe authored by Yixiao Luo's avatar Yixiao Luo Committed by Android (Google) Code Review
Browse files

Merge "External TV Input Logging: skip duplicate adding for HardwareInput and HdmiInput" into main

parents 98b8623c 8c251757
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -3472,6 +3472,10 @@ public final class TvInputManagerService extends SystemService {
            final long identity = Binder.clearCallingIdentity();
            try {
                synchronized (mLock) {
                    ServiceState serviceState = getServiceStateLocked(mComponent, mUserId);
                    if (serviceState.hardwareInputMap.containsKey(inputInfo.getId())) {
                        return;
                    }
                    mTvInputHardwareManager.addHardwareInput(deviceId, inputInfo);
                    addHardwareInputLocked(inputInfo);
                }
@@ -3486,6 +3490,10 @@ public final class TvInputManagerService extends SystemService {
            final long identity = Binder.clearCallingIdentity();
            try {
                synchronized (mLock) {
                    ServiceState serviceState = getServiceStateLocked(mComponent, mUserId);
                    if (serviceState.hardwareInputMap.containsKey(inputInfo.getId())) {
                        return;
                    }
                    mTvInputHardwareManager.addHdmiInput(id, inputInfo);
                    addHardwareInputLocked(inputInfo);
                    if (mOnScreenInputId != null && mOnScreenSessionState != null) {