Is there any way to listen for when the camera has loaded in? cwac-camera

前端 未结 2 327
滥情空心
滥情空心 2021-01-14 19:12

I\'ve got my CWAC Camera fragment setup, and everything is working nicely. There\'s a few customizations I\'d like to do.

  1. I\'d like to show a ProgressBar as th
2条回答
  •  再見小時候
    2021-01-14 19:57

    I'd like to show a ProgressBar as the camera is loading into the Activity/Fragment

    I have no idea what "loading into the Activity/Fragment" means.

    After a user has taken a picture, I want to show a ProgressBar again overlay on the picture taking button, so they understand they can't immediately take a picture until the camera is ready again

    You know when you are calling takePicture(). You can know when saveImage() is called on your CameraHost by creating your own implementation of CameraHost or own subclass of SimpleCameraHost. You can do your ProgressBar work at those times. You can see this in the demo app, where I disable and re-enable the action bar item for the same purpose.

提交回复
热议问题