Remove checks for SDK <= 21
WebRTC’s minSdk is 21, so all those checks are dead code. Change-Id: I26497fd92259b66d9e5ac6afbb393adf4d904c77 Bug: webrtc:13780 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/253124 Reviewed-by: Henrik Andreassson <henrika@webrtc.org> Reviewed-by: Linus Nilsson <lnilsson@webrtc.org> Commit-Queue: Xavier Lepaul <xalep@webrtc.org> Cr-Commit-Position: refs/heads/main@{#36140}
This commit is contained in:
committed by
WebRTC LUCI CQ
parent
7befe8e5e4
commit
0f50cc2849
@ -10,7 +10,6 @@
|
||||
|
||||
package org.webrtc;
|
||||
|
||||
import android.annotation.TargetApi;
|
||||
import android.content.Context;
|
||||
import android.graphics.Rect;
|
||||
import android.graphics.SurfaceTexture;
|
||||
@ -30,7 +29,6 @@ import java.util.List;
|
||||
import java.util.Map;
|
||||
import org.webrtc.CameraEnumerationAndroid.CaptureFormat;
|
||||
|
||||
@TargetApi(21)
|
||||
public class Camera2Enumerator implements CameraEnumerator {
|
||||
private final static String TAG = "Camera2Enumerator";
|
||||
private final static double NANO_SECONDS_PER_SECOND = 1.0e9;
|
||||
@ -107,10 +105,6 @@ public class Camera2Enumerator implements CameraEnumerator {
|
||||
* Checks if API is supported and all cameras have better than legacy support.
|
||||
*/
|
||||
public static boolean isSupported(Context context) {
|
||||
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.LOLLIPOP) {
|
||||
return false;
|
||||
}
|
||||
|
||||
CameraManager cameraManager = (CameraManager) context.getSystemService(Context.CAMERA_SERVICE);
|
||||
try {
|
||||
String[] cameraIds = cameraManager.getCameraIdList();
|
||||
|
||||
Reference in New Issue
Block a user