Fixed issue 47315
authorHimanshu <himanshu.t@samsung.com>
Fri, 26 Jul 2013 09:41:10 +0000 (15:11 +0530)
committerHimanshu <himanshu.t@samsung.com>
Fri, 26 Jul 2013 09:41:10 +0000 (15:11 +0530)
Change-Id: Ia09c1c1f6ad2781e211f1bf76e90ee5d8a532ca1
Signed-off-by: Himanshu <himanshu.t@samsung.com>
src/GlFileListEditorForm.cpp
src/GlFileListForm.cpp

index 0bdac54..fe02b20 100644 (file)
@@ -120,15 +120,6 @@ FileListEditorForm::OnInitializing(void)
        SetOrientation(ORIENTATION_AUTOMATIC);
        AddOrientationEventListener(*this);
 
-       __pPopUp = new (std::nothrow) SlideShowPopUp();
-
-       if (__pPopUp != null)
-       {
-               __pPopUp->Initialize();
-               __pPopUp->SetEventListner(this);
-               AddControl(__pPopUp);
-       }
-
        __pPresentationModel = FileListPresentationModel::GetInstance();
        __pPresentationModel->ClearThumbnailRequests();
 
@@ -491,8 +482,17 @@ FileListEditorForm::OnActionPerformed(const Control& source, int actionId)
 
        case IDA_CONTEXT_MENU_MORE_SLIDE_SHOW:
        {
+               if (__pPopUp != NULL)
+               {
+                       delete __pPopUp;
+                       __pPopUp = NULL;
+               }
+               __pPopUp = new (std::nothrow) SlideShowPopUp();
+
                if (__pPopUp != null)
                {
+                       __pPopUp->Initialize();
+                       __pPopUp->SetEventListner(this);
                        __pPopUp->SetShowState(true);
                        __pPopUp->Show();
                }
index e4a47d9..dc276e0 100644 (file)
@@ -83,15 +83,6 @@ FileListForm::OnInitializing(void)
        __pPresentationModel = FileListPresentationModel::GetInstance();
        __pPresentationModel->ClearThumbnailRequests();
 
-       __pPopUp = new (std::nothrow) SlideShowPopUp();
-
-       if (__pPopUp != null)
-       {
-               __pPopUp->Initialize();
-               __pPopUp->SetEventListner(this);
-               AddControl(__pPopUp);
-       }
-
        InitializeFooter();
        SetFormBackEventListener(this);
        SetOrientation(ORIENTATION_AUTOMATIC);
@@ -159,8 +150,17 @@ FileListForm::OnActionPerformed(const Control& source, int actionId)
        case IDA_FOOTER_SLIDESHOW:
        {
 
+               if (__pPopUp != NULL)
+               {
+                       delete __pPopUp;
+                       __pPopUp = NULL;
+               }
+               __pPopUp = new (std::nothrow) SlideShowPopUp();
+
                if (__pPopUp != null)
                {
+                       __pPopUp->Initialize();
+                       __pPopUp->SetEventListner(this);
                        __pPopUp->SetShowState(true);
                        __pPopUp->Show();
                }