diff options
author | Chih-Chung Chang <chihchung@google.com> | 2010-01-22 17:49:48 -0800 |
---|---|---|
committer | Chih-Chung Chang <chihchung@google.com> | 2010-01-26 11:07:07 -0800 |
commit | f091e833d339d344fbc4815bcc87ce97d8535cd8 (patch) | |
tree | abf06e2d345aa1d73348c8380194633973dff6b6 /libs/ui | |
parent | fafd2adbaac51b801af6503a7fc80d1cc2dc3794 (diff) | |
download | frameworks_native-f091e833d339d344fbc4815bcc87ce97d8535cd8.zip frameworks_native-f091e833d339d344fbc4815bcc87ce97d8535cd8.tar.gz frameworks_native-f091e833d339d344fbc4815bcc87ce97d8535cd8.tar.bz2 |
Add support for setting camera display orientation.
Diffstat (limited to 'libs/ui')
-rw-r--r-- | libs/ui/CameraParameters.cpp | 20 |
1 files changed, 0 insertions, 20 deletions
diff --git a/libs/ui/CameraParameters.cpp b/libs/ui/CameraParameters.cpp index 2e0409b..a94f6b9 100644 --- a/libs/ui/CameraParameters.cpp +++ b/libs/ui/CameraParameters.cpp @@ -121,9 +121,6 @@ const char CameraParameters::FOCUS_MODE_INFINITY[] = "infinity"; const char CameraParameters::FOCUS_MODE_MACRO[] = "macro"; const char CameraParameters::FOCUS_MODE_FIXED[] = "fixed"; -static const char* portrait = "portrait"; -static const char* landscape = "landscape"; - CameraParameters::CameraParameters() : mMap() { @@ -282,23 +279,6 @@ void CameraParameters::setPreviewFormat(const char *format) set(KEY_PREVIEW_FORMAT, format); } -int CameraParameters::getOrientation() const -{ - const char* orientation = get("orientation"); - if (orientation && !strcmp(orientation, portrait)) - return CAMERA_ORIENTATION_PORTRAIT; - return CAMERA_ORIENTATION_LANDSCAPE; -} - -void CameraParameters::setOrientation(int orientation) -{ - if (orientation == CAMERA_ORIENTATION_PORTRAIT) { - set("orientation", portrait); - } else { - set("orientation", landscape); - } -} - const char *CameraParameters::getPreviewFormat() const { return get(KEY_PREVIEW_FORMAT); |