Bug 1277844 - Make search result listen to mail.threadpane.use_correspondents. r=aceman a=jorgk
authorJorg K
Sat, 04 Jun 2016 16:45:14 +0200
changeset 27213 a580b291487a334c4d4047a88bc89b028418c4b8
parent 27212 58afa30efe7bd622917b9d88a11caf2151347aec
child 27214 c5eb848ac878e7a7665087bdcb23e722a1386c12
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)
reviewersaceman, jorgk
bugs1277844
Bug 1277844 - Make search result listen to mail.threadpane.use_correspondents. r=aceman a=jorgk
mail/base/content/SearchDialog.js
--- a/mail/base/content/SearchDialog.js
+++ b/mail/base/content/SearchDialog.js
@@ -238,17 +238,18 @@ function searchOnLoad()
   gFolderDisplay.tree = document.getElementById("threadTree");
   gFolderDisplay.treeBox = gFolderDisplay.tree.boxObject.QueryInterface(
                              Components.interfaces.nsITreeBoxObject);
   gFolderDisplay.view.openSearchView();
   gFolderDisplay.makeActive();
 
   gFolderDisplay.setColumnStates({
     subjectCol: { visible: true },
-    correspondentCol: { visible: true },
+    correspondentCol: { visible: Services.prefs.getBoolPref("mail.threadpane.use_correspondents") },
+    senderCol: { visible: !Services.prefs.getBoolPref("mail.threadpane.use_correspondents") },
     dateCol: { visible: true },
     locationCol: { visible: true },
   });
 
   if (window.arguments && window.arguments[0])
       updateSearchFolderPicker(window.arguments[0].folder);
 
   // trigger searchTermOverlay.js to create the first criterion