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

Commit 719a6937 authored by Jayant Chowdhary's avatar Jayant Chowdhary Committed by Automerger Merge Worker
Browse files

Merge "getCameraIdListNoLazy : remove system cameras from mTorchStatus as...

Merge "getCameraIdListNoLazy : remove system cameras from mTorchStatus as well." into rvc-qpr-dev am: 3a6b247e

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14071306

Change-Id: Ie89d317127ad31866256a290899e91acc730cfc6
parents 66ead4fb 3a6b247e
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -1363,6 +1363,8 @@ public final class CameraManager {
                    // devices going offline (in real world scenarios, these permissions aren't
                    // changeable). Future calls to getCameraIdList() will reflect the changes in
                    // the camera id list after getCameraIdListNoLazy() is called.
                    // We need to remove the torch ids which may have been associated with the
                    // devices removed as well. This is the same situation.
                    cameraStatuses = mCameraService.addListener(testListener);
                    mCameraService.removeListener(testListener);
                    for (CameraStatus c : cameraStatuses) {
@@ -1381,6 +1383,7 @@ public final class CameraManager {
                    }
                    for (String id : deviceIdsToRemove) {
                        onStatusChangedLocked(ICameraServiceListener.STATUS_NOT_PRESENT, id);
                        mTorchStatus.remove(id);
                    }
                } catch (ServiceSpecificException e) {
                    // Unexpected failure