Bug 806011 - Remember URL of message opened from file so that changing the text encoding works. r=mkmelin a=jorgk
authorJorg K
Sat, 30 Jan 2016 23:16:15 +0100
changeset 26749 d61d865c805ee5fd00d33d7e757adf0a8a56e681
parent 26748 1b95355889056a95e118dfcbb5e67d867f31f16c
child 26750 e4b79af8a54b49d2e5142d135f4818cb44fa40a7
push id1850
push userclokep@gmail.com
push dateWed, 08 Mar 2017 19:29:12 +0000
treeherdercomm-esr52@028df196b2d9 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmkmelin, jorgk
bugs806011
Bug 806011 - Remember URL of message opened from file so that changing the text encoding works. r=mkmelin a=jorgk
mailnews/base/src/nsMessenger.cpp
--- a/mailnews/base/src/nsMessenger.cpp
+++ b/mailnews/base/src/nsMessenger.cpp
@@ -560,16 +560,17 @@ nsMessenger::LoadURL(nsIDOMWindow *aWin,
   }
 
   nsCOMPtr<nsIDocShellLoadInfo> loadInfo;
   rv = mDocShell->CreateLoadInfo(getter_AddRefs(loadInfo));
   NS_ENSURE_SUCCESS(rv, rv);
   loadInfo->SetLoadType(nsIDocShellLoadInfo::loadNormal);
   AddMsgUrlToNavigateHistory(aURL);
   mNavigatingToUri.Truncate();
+  mLastDisplayURI = aURL; // Remember the last uri we displayed.
   return mDocShell->LoadURI(uri, loadInfo, 0, true);
 }
 
 NS_IMETHODIMP nsMessenger::SaveAttachmentToFile(nsIFile *aFile,
                                                 const nsACString &aURL,
                                                 const nsACString &aMessageUri,
                                                 const nsACString &aContentType,
                                                 nsIUrlListener *aListener)