Internal issue Fixes
authorravi.n2 <ravi.n2@samsung.com>
Wed, 12 Jun 2013 07:30:20 +0000 (13:00 +0530)
committerravi.n2 <ravi.n2@samsung.com>
Wed, 12 Jun 2013 07:30:20 +0000 (13:00 +0530)
Change-Id: If3e03937a972e07a6bb4b8de98ccc0cbb9a01fb5

inc/CmCameraStarterThread.h
src/CmCamcorderForm.cpp
src/CmCameraApp.cpp
src/CmCameraForm.cpp
src/CmCameraStarterThread.cpp

index dfe17b2..0bcb0f8 100644 (file)
@@ -50,6 +50,8 @@ private:
        static result CreateInstance(void);
        static void DestroyInstance(void);
        static void DestroyCameraStarterThreadInstance(void);
+       virtual bool OnStart(void);
+       virtual void OnStop(void);
        virtual Tizen::Base::Object* Run(void);
        friend class CameraApp;
 
index fbf2bb4..85222c4 100644 (file)
@@ -336,11 +336,9 @@ CamcorderForm::CamcorderForm(void)
        , __settingWhiteBalance(0)
        , __settingTimeInterval(0)
        , __settingExposure(0)
-
        , __recordTimeCount(0)
        , __recordingMaxTime(0)
        , _closeTimerValue(0)
-
        , __previewResolutionWidth(0)
        , __previewResolutionHeight(0)
        , __pRecordingResolutionWidth(0)
@@ -352,7 +350,6 @@ CamcorderForm::CamcorderForm(void)
        , __isOrientationChanged(false)
        , __doRecording(false)
        ,__recorderStopped(false)
-
        , __pSettingPanel(null)
        , __pActionPanel(null)
        , __dir(ORIENTATION_STATUS_NONE)
@@ -383,7 +380,6 @@ CamcorderForm::CamcorderForm(void)
        , __uri(L"")
        , __mime(L"")
        , __isCapacityBelow(false)
-       
        , __pCancelPopup(null)
        , __setTimerInterval(false)
        , __pRecordPauseBitmap(null)
@@ -1943,7 +1939,6 @@ CamcorderForm::OnCameraActionPerformed(CameraActionEvent event)
                        {
                                __recorderStopped = true;
                                DoStopRecording();
-                               __recorderStopped = false;
                                ShowMemoryFull();
                                ReInitialise();
                                Update(false);
@@ -1973,6 +1968,9 @@ CamcorderForm::OnCameraActionPerformed(CameraActionEvent event)
                        {
                                DoStopRecording();
                                ShowMemoryFull();
+                       }
+                       else
+                       {
                                __recorderStopped = false;
                        }
 
@@ -3341,7 +3339,6 @@ CamcorderForm::OnTouchReleased(const Tizen::Ui::Control& source, const Tizen::Gr
                        AppLogDebug("DoStopRecording");
                        __recorderStopped = true;
                        DoStopRecording();
-                       __recorderStopped = false;
                }
        }
 
index 364a98a..8af600e 100644 (file)
@@ -389,11 +389,16 @@ CameraApp::OnAppControlRequestReceived(RequestId reqId, const Tizen::Base::Strin
                IList* pKeyList = pExtraData->GetKeysN();
                int loopCount = pKeyList->GetCount();
 
+               AppLogDebug("Loopcount is %d",loopCount);
+
                for (int i = 0; i < loopCount; ++i)
                {
                        pKey = static_cast<const String*>(pKeyList->GetAt(i));
                        pValue = static_cast<const String*>(pExtraData->GetValue(*pKey));
 
+                       AppLogDebug("Key is %ls",pKey->GetPointer());
+                       AppLogDebug("pValue is %ls",pValue->GetPointer());
+
                        AppLogDebug("(%ls:%ls)", pKey == null ? L"(null)" : pKey->GetPointer(), pValue == null ? L"(null)" : pValue->GetPointer());
                        pArguments->Add(new (std::nothrow) String(*pKey), new (std::nothrow) String(*pValue));
                }
index e5e590f..d3ce735 100644 (file)
@@ -7596,6 +7596,7 @@ CameraForm::AppControlRequestHideButton(void)
        }
        else
        {
+               AppLogDebug("pAllowSwitch is not null");
                const String* pAllowSwitch = static_cast<const String*>(pArguments->GetValue(String(ALLOW_SWITCH)));
                if (pAllowSwitch->Equals(ALLOW_SWITCH_TRUE, false) == true)
                {
index d19b161..1038590 100644 (file)
@@ -71,6 +71,8 @@ CameraStarterThread::CreateInstance(void)
        if (IsFailed(r))
        {
                AppLogDebug("IsFailed");
+               __pCameraStarterThread->Stop();
+               __pCameraStarterThread->Join();
                delete __pCameraStarterThread;
                __pCameraStarterThread = null;
                return r;
@@ -85,6 +87,9 @@ void
 CameraStarterThread::DestroyInstance(void)
 {
        AppLogDebug("ENTER");
+
+       __pCameraStarterThread->Stop();
+       __pCameraStarterThread->Join();
        delete __pCameraStarterThread;
        __pCameraStarterThread = null;
        AppLogDebug("EXIT");
@@ -126,6 +131,18 @@ CameraStarterThread::SetBufferinfo(Tizen::Graphics::BufferInfo* bufferinfo)
        return E_SUCCESS;
 }
 
+bool
+CameraStarterThread::OnStart(void)
+{
+       return true;
+}
+
+void
+CameraStarterThread::OnStop(void)
+{
+       //empty implementation
+}
+
 Object*
 CameraStarterThread::Run(void)
 {