Fixed terminatiing issue
authorHeeJu Kang <mobum.kang@samsung.com>
Sat, 5 Jan 2013 07:25:55 +0000 (16:25 +0900)
committerHeeJu Kang <mobum.kang@samsung.com>
Sat, 5 Jan 2013 07:25:55 +0000 (16:25 +0900)
Change-Id: Ibc4c6e4f0b095ae6178317201aeddabcb3836a31
Signed-off-by: HeeJu Kang <mobum.kang@samsung.com>
src/FShell_LiveboxFrame.cpp
src/FShell_LiveboxFrame.h
src/FShell_LiveboxPopup.cpp
src/FShell_LiveboxPopup.h

index 4e7d5cb..1ba2640 100644 (file)
@@ -42,6 +42,9 @@ namespace Tizen { namespace Shell
 
 _LiveboxFrame::_LiveboxFrame(void)
        : __pLiveboxFramePresenter(new (std::nothrow) _LiveboxFramePresenter(*this))
+#if defined(MULTI_WINDOW)
+       , __pLiveboxLayer(null)
+#endif // MULTI_WINDOW
        , __pLiveboxFrameRootVisualElement(null)
        , __pEventManager(null)
 {
@@ -61,6 +64,10 @@ _LiveboxFrame::~_LiveboxFrame(void)
                __pEventManager->UnregisterTouchEventHandler(*this);
        }
 
+#if defined(MULTI_WINDOW)
+       __pLiveboxLayer = null;
+       __pLiveboxFrameRootVisualElement = null;
+#else // MULTI_WINDOW
        if (__pLiveboxFrameRootVisualElement)
        {
                _VisualElement* pVisualElement = GetVisualElement();
@@ -69,6 +76,7 @@ _LiveboxFrame::~_LiveboxFrame(void)
                        __pLiveboxFrameRootVisualElement->DetachChild(*pVisualElement);
                }
        }
+#endif // !MULTI_WINDOW
 }
 
 _LiveboxFrame*
@@ -220,10 +228,10 @@ _LiveboxFrame::CreateLayer(void)
        result r = pLayer->Construct();
        SysTryReturn(NID_UI_CTRL, r == E_SUCCESS, r, r, "[%s] Propagating.", GetErrorMessage(r));
 
-       __pLiveboxLayer = move(pLayer);
+       __pLiveboxLayer = pLayer.release();
        __pLiveboxFrameRootVisualElement = __pLiveboxLayer->GetRootVisualElement();
 
-       SetLayer(*__pLiveboxLayer.get());
+       SetLayer(*__pLiveboxLayer);
        SetRootVisualElement(*__pLiveboxFrameRootVisualElement);
 
        return r;
index eaaadfe..a53e992 100644 (file)
@@ -79,7 +79,11 @@ private:
 
 private:
        std::unique_ptr<_LiveboxFramePresenter> __pLiveboxFramePresenter; 
+#if defined(MULTI_WINDOW)
+       _LiveboxLayer* __pLiveboxLayer;
+#else // MULTI_WINDOW
        std::unique_ptr<_LiveboxLayer> __pLiveboxLayer;
+#endif // !MULTI_WINDOW
        Tizen::Ui::Animations::_RootVisualElement* __pLiveboxFrameRootVisualElement;
        Tizen::Ui::_IUiEventManager* __pEventManager;
 }; // _LiveboxFrame
index 3fd89a9..ca67738 100644 (file)
@@ -130,6 +130,9 @@ _LiveboxPopupLayer::ReleasePixmap(void)
 
 _LiveboxPopup::_LiveboxPopup(void)
        : __pLiveboxPopupPresenter(new (std::nothrow) _LiveboxPopupPresenter(*this))
+#if defined(MULTI_WINDOW)
+       , __pLiveboxPopupLayer(null)
+#endif // MULTI_WINDOW
        , __pLiveboxPopupRootVisualElement(null)
        , __pEventManager(null)
 {
@@ -149,6 +152,10 @@ _LiveboxPopup::~_LiveboxPopup(void)
                __pEventManager->UnregisterTouchEventHandler(*this);
        }
 
+#if defined(MULTI_WINDOW)
+       __pLiveboxPopupLayer = null;
+       __pLiveboxPopupRootVisualElement = null;
+#else // MULTI_WINDOW
        if (__pLiveboxPopupRootVisualElement)
        {
                _VisualElement* pVisualElement = GetVisualElement();
@@ -157,6 +164,7 @@ _LiveboxPopup::~_LiveboxPopup(void)
                        __pLiveboxPopupRootVisualElement->DetachChild(*pVisualElement);
                }
        }
+#endif // !MULTI_WINDOW
 }
 
 _LiveboxPopup*
@@ -300,10 +308,10 @@ _LiveboxPopup::CreateLayer(void)
        result r = pLayer->Construct();
        SysTryReturn(NID_UI_CTRL, r == E_SUCCESS, r, r, "[%s] Propagating.", GetErrorMessage(r));
 
-       __pLiveboxPopupLayer = move(pLayer);
+       __pLiveboxPopupLayer = pLayer.release();
        __pLiveboxPopupRootVisualElement = __pLiveboxPopupLayer->GetRootVisualElement();
 
-       SetLayer(*__pLiveboxPopupLayer.get());
+       SetLayer(*__pLiveboxPopupLayer);
        SetRootVisualElement(*__pLiveboxPopupRootVisualElement);
 
        return r;
index ed0f1a7..5987014 100644 (file)
@@ -79,7 +79,11 @@ private:
 
 private:
        std::unique_ptr<_LiveboxPopupPresenter> __pLiveboxPopupPresenter;
+#if defined(MULTI_WINDOW)
+       _LiveboxPopupLayer* __pLiveboxPopupLayer;
+#else // MULTI_WINDOW
        std::unique_ptr<_LiveboxPopupLayer> __pLiveboxPopupLayer;
+#endif // !MULTI_WINDOW
        Tizen::Ui::Animations::_RootVisualElement* __pLiveboxPopupRootVisualElement;
        Tizen::Ui::_IUiEventManager* __pEventManager;
 }; // _LiveboxPopup