messagingappbase/mce/src/MceMessageListView.cpp
branchRCL_3
changeset 9 1d7827e39b52
parent 5 4697dfb2d7ad
child 14 c6838af47512
--- a/messagingappbase/mce/src/MceMessageListView.cpp	Tue Feb 02 00:08:43 2010 +0200
+++ b/messagingappbase/mce/src/MceMessageListView.cpp	Fri Feb 19 22:47:38 2010 +0200
@@ -2539,7 +2539,26 @@
         == KErrNone )
         {
         iMsgListContainer->ClearSelection();
-        SetFolderL( aNewFolderId );
+        
+        if ((oldId == KMsvGlobalOutBoxIndexEntryId) || (aNewFolderId == KMsvGlobalOutBoxIndexEntryId))
+            {
+            iFolderId = aNewFolderId;    
+            iMsgListContainer->MakeVisible(EFalse);
+            AppUi()->RemoveFromStack(iMsgListContainer);
+            delete iMsgListContainer;
+            iMsgListContainer = NULL;
+            CreateListboxL();
+            iMsgListContainer->SetRect(ClientRect());
+            AppUi()->AddToStackL( *this,iMsgListContainer );
+            iMsgListContainer->ActivateL();
+            iMsgListContainer->MakeVisible(ETrue);
+            iMsgListContainer->SetFolderL( iFolderId );
+            }
+        else
+            {
+            SetFolderL( aNewFolderId );
+            }
+        
         TUid mtm = iMsgListContainer->FolderEntry().iMtm;
         if ( mtm == KSenduiMtmImap4Uid )
             {