This repository was archived by the owner on Apr 4, 2023. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -94,14 +94,14 @@ export abstract class MLKitCameraView extends MLKitCameraViewBase {
9494 application . on ( "resume" , arg => this . runCamera ( ) ) ;
9595 }
9696
97- private hasCamera ( ) {
97+ private hasCamera ( ) : boolean {
9898 return ! ! utils . ad
9999 . getApplicationContext ( )
100100 . getPackageManager ( )
101101 . hasSystemFeature ( "android.hardware.camera" ) ;
102102 }
103103
104- private initView ( nativeView ) {
104+ private initView ( nativeView ) : void {
105105 this . surfaceView = new android . view . SurfaceView ( utils . ad . getApplicationContext ( ) ) ;
106106 nativeView . addView ( this . surfaceView ) ;
107107 this . runCamera ( ) ;
Original file line number Diff line number Diff line change @@ -31,7 +31,7 @@ export abstract class MLKitCameraView extends MLKitCameraViewBase {
3131 return v ;
3232 }
3333
34- private canUseCamera ( ) {
34+ private canUseCamera ( ) : boolean {
3535 try {
3636 return ! ! AVCaptureDeviceDiscoverySession &&
3737 AVCaptureDevice . defaultDeviceWithMediaType ( AVMediaTypeVideo ) !== null &&
@@ -41,7 +41,7 @@ export abstract class MLKitCameraView extends MLKitCameraViewBase {
4141 }
4242 }
4343
44- private initView ( ) {
44+ private initView ( ) : void {
4545 // find a suitable device
4646 this . captureDevice = AVCaptureDeviceDiscoverySession . discoverySessionWithDeviceTypesMediaTypePosition (
4747 < any > [ AVCaptureDeviceTypeBuiltInWideAngleCamera ] ,
You can’t perform that action at this time.
0 commit comments