handle toggling between photo and video modes

This commit is contained in:
tibbi
2018-06-06 15:09:09 +02:00
parent 440180f79a
commit 9e3e732bbf
4 changed files with 60 additions and 17 deletions

View File

@ -50,6 +50,10 @@ class Config(context: Context) : BaseConfig(context) {
get() = prefs.getString(LAST_USED_CAMERA, context.getMyCamera().getBackCameraId().toString())
set(cameraId) = prefs.edit().putString(LAST_USED_CAMERA, cameraId).apply()
var initPhotoMode: Boolean
get() = prefs.getBoolean(INIT_PHOTO_MODE, false)
set(initPhotoMode) = prefs.edit().putBoolean(INIT_PHOTO_MODE, initPhotoMode).apply()
var flashlightState: Int
get() = prefs.getInt(FLASHLIGHT_STATE, FLASH_OFF)
set(state) = prefs.edit().putInt(FLASHLIGHT_STATE, state).apply()