rename the photo video toggling functions

This commit is contained in:
tibbi 2017-03-26 14:41:58 +02:00
parent fa9eb58012
commit e44e1ccdbf
1 changed files with 4 additions and 4 deletions

View File

@ -323,20 +323,20 @@ class MainActivity : SimpleActivity(), SensorEventListener, PreviewListener, Pho
private fun checkButtons() { private fun checkButtons() {
if (mIsInPhotoMode) { if (mIsInPhotoMode) {
initPhotoButtons() initPhotoMode()
} else { } else {
tryInitVideoButtons() tryInitVideoMode()
} }
} }
private fun initPhotoButtons() { private fun initPhotoMode() {
toggle_photo_video.setImageDrawable(mRes.getDrawable(R.drawable.ic_video)) toggle_photo_video.setImageDrawable(mRes.getDrawable(R.drawable.ic_video))
shutter.setImageDrawable(mRes.getDrawable(R.drawable.ic_shutter)) shutter.setImageDrawable(mRes.getDrawable(R.drawable.ic_shutter))
mPreview?.initPhotoMode() mPreview?.initPhotoMode()
setupPreviewImage(true) setupPreviewImage(true)
} }
private fun tryInitVideoButtons() { private fun tryInitVideoMode() {
if (mPreview?.initRecorder() == true) { if (mPreview?.initRecorder() == true) {
initVideoButtons() initVideoButtons()
} else { } else {