mirror of
https://github.com/FossifyOrg/Camera.git
synced 2026-06-12 18:17:28 -04:00
remember the last flashlight state
This commit is contained in:
@@ -78,4 +78,12 @@ public class Config {
|
||||
public void setLastUsedCamera(int cameraId) {
|
||||
mPrefs.edit().putInt(Constants.LAST_USED_CAMERA, cameraId).apply();
|
||||
}
|
||||
|
||||
public boolean getLastFlashlightState() {
|
||||
return mPrefs.getBoolean(Constants.LAST_FLASHLIGHT_STATE, false);
|
||||
}
|
||||
|
||||
public void setLastFlashlightState(boolean enabled) {
|
||||
mPrefs.edit().putBoolean(Constants.LAST_FLASHLIGHT_STATE, enabled).apply();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user