fix: Add more logs
This commit is contained in:
parent
359fd00c73
commit
45fad5ab19
@ -422,6 +422,7 @@ class CameraView(context: Context) : FrameLayout(context), LifecycleOwner {
|
|||||||
}
|
}
|
||||||
|
|
||||||
val preview = previewBuilder.build()
|
val preview = previewBuilder.build()
|
||||||
|
Log.i(TAG, "Attaching ${useCases.size} use-cases...")
|
||||||
camera = cameraProvider.bindToLifecycle(this, cameraSelector, preview, *useCases.toTypedArray())
|
camera = cameraProvider.bindToLifecycle(this, cameraSelector, preview, *useCases.toTypedArray())
|
||||||
preview.setSurfaceProvider(previewView.surfaceProvider)
|
preview.setSurfaceProvider(previewView.surfaceProvider)
|
||||||
|
|
||||||
@ -447,12 +448,9 @@ class CameraView(context: Context) : FrameLayout(context), LifecycleOwner {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onLayout(changed: Boolean, left: Int, top: Int, right: Int, bottom: Int) {
|
|
||||||
super.onLayout(changed, left, top, right, bottom)
|
|
||||||
Log.i(TAG, "onLayout($changed, $left, $top, $right, $bottom) was called! (Width: $width, Height: $height)")
|
|
||||||
}
|
|
||||||
|
|
||||||
private fun invokeOnInitialized() {
|
private fun invokeOnInitialized() {
|
||||||
|
Log.i(TAG, "invokeOnInitialized()")
|
||||||
|
|
||||||
val reactContext = context as ReactContext
|
val reactContext = context as ReactContext
|
||||||
reactContext.getJSModule(RCTEventEmitter::class.java).receiveEvent(id, "cameraInitialized", null)
|
reactContext.getJSModule(RCTEventEmitter::class.java).receiveEvent(id, "cameraInitialized", null)
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user