diff options
author | James Dong <jdong@google.com> | 2011-11-18 15:22:22 -0800 |
---|---|---|
committer | Android Git Automerger <android-git-automerger@android.com> | 2011-11-18 15:22:22 -0800 |
commit | dcd1d678aba941d64e8bf3b03b3803ed1a8d7bff (patch) | |
tree | b146e83c6ac6b116454530a3ff7d564ff82d7126 /camera/OMXCameraAdapter | |
parent | 34fbce778afddcb1a9c7a9f1e23ae1f6ab1c53c3 (diff) | |
parent | 0422753ed364b79002f5afe64c009cb4a00df471 (diff) | |
download | hardware_ti_omap4-dcd1d678aba941d64e8bf3b03b3803ed1a8d7bff.zip hardware_ti_omap4-dcd1d678aba941d64e8bf3b03b3803ed1a8d7bff.tar.gz hardware_ti_omap4-dcd1d678aba941d64e8bf3b03b3803ed1a8d7bff.tar.bz2 |
am 089c480c: am d31eec66: am 0bb54549: Ignore camera.flash_off system property for user build
* commit '089c480c4e657653673854f0e3d92faa0fec75a5':
Ignore camera.flash_off system property for user build
Diffstat (limited to 'camera/OMXCameraAdapter')
-rw-r--r-- | camera/OMXCameraAdapter/OMX3A.cpp | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/camera/OMXCameraAdapter/OMX3A.cpp b/camera/OMXCameraAdapter/OMX3A.cpp index be4c0e7..ef02e49 100644 --- a/camera/OMXCameraAdapter/OMX3A.cpp +++ b/camera/OMXCameraAdapter/OMX3A.cpp @@ -482,14 +482,20 @@ static bool isFlashDisabled() { #error "PROPERTY_VALUE_MAX must be at least 5" #endif + // Ignore flash_off system property for user build. + char buildType[PROPERTY_VALUE_MAX]; + if (property_get("ro.build.type", buildType, NULL) && + !strcasecmp(buildType, "user")) { + return false; + } + char value[PROPERTY_VALUE_MAX]; if (property_get("camera.flash_off", value, NULL) && (!strcasecmp(value, "true") || !strcasecmp(value, "1"))) { - LOGW("flash is turned off"); + LOGW("flash is disabled for testing purpose"); return true; } - LOGI("flash is turned on"); return false; } |