Set camera capture orientation to potrait always
authorrahul varna <rahul.varna@samsung.com>
Tue, 2 Jul 2013 08:27:31 +0000 (13:57 +0530)
committerrahul varna <rahul.varna@samsung.com>
Tue, 2 Jul 2013 08:27:31 +0000 (13:57 +0530)
Signed-off-by: rahul varna <rahul.varna@samsung.com>
project/src/Camera/CameraCaptureForm.cpp
project/src/Camera/CameraCaptureForm.h

index af9fb7c..4ded716 100644 (file)
@@ -201,7 +201,6 @@ CameraCaptureForm::CameraCaptureForm(void)
        , __flashModeIndex(INIT)
        , __previewFormatIndex(INIT)
        , __deviceOrientation(DEVICE_PORTRAIT)
-       , __orientationAtCapture(DEVICE_PORTRAIT)
        , __currentListViewId(INIT)
        , __brightnessSliderValue(INIT)
        , __contrastSliderValue(INIT)
@@ -1634,8 +1633,6 @@ CameraCaptureForm::Capture(void)
                TryCatch(r == E_SUCCESS, ShowError(r, METHOD_FILE_LINENO),"[%s] __pCamera->Capture()", GetErrorMessage(r));
        }
 
-       __orientationAtCapture = __deviceOrientation;
-
        return r;
 CATCH:
        EnableFooterItem(ID_BUTTON_SETTING, true);
@@ -1968,7 +1965,7 @@ CameraCaptureForm::ShowCapturedImageThumbnail(String* pFileName)
        String* pCapturedFilePath = null;
        Image capturedImage;
        result r = E_SUCCESS;
-       int deviceOrientation = 0;
+       int deviceOrientation = 0; // fix for potrait mode
 
        pCapturedFilePath = new (std::nothrow) String;
        TryReturn(pCapturedFilePath != null, ShowErrorVoid(r, METHOD_FILE_LINENO),"pCapturedFilePath failed, no memory");
@@ -2066,7 +2063,7 @@ CameraCaptureForm::LaunchImageViewer(String* pFile)
        pFilePath->Clear();
        pFilePath->Append(*pFile);
 
-       pDeviceOrientation = new (std::nothrow) Integer(__orientationAtCapture);
+       pDeviceOrientation = new (std::nothrow) Integer(0);
        TryReturnVoid(pDeviceOrientation != null, "pDeviceOrientation string is null, no memory");
 
        pArg = new (std::nothrow) ArrayList;
@@ -2105,7 +2102,8 @@ CameraCaptureForm::LaunchImageViewer(int index)
        pFilePath->Clear();
        pFilePath->Append(*(String*)__pCapturedFileNameList->GetAt(index));
 
-       pDeviceOrientation = new (std::nothrow) Integer(__orientationAtCapture);
+       //Always in potrait mode
+       pDeviceOrientation = new (std::nothrow) Integer(0);
        TryReturnVoid(pDeviceOrientation != null, "pDeviceOrientation string is null, no memory");
 
        pArg = new (std::nothrow) ArrayList;
index 9c90acf..3e4cfa7 100644 (file)
@@ -286,7 +286,6 @@ private:
        int __flashModeIndex;
        int __previewFormatIndex;
        int __deviceOrientation;
-       int __orientationAtCapture;
        int __currentListViewId;
        int __brightnessSliderValue;
        int __contrastSliderValue;