Bug 516630 - "timeline doesn't stay collapsed if you change sort order" [r+a=Standard8] THUNDERBIRD_3_0b4_BUILD2
authorDavid Ascher <david.ascher@gmail.com>
Tue, 15 Sep 2009 09:31:14 +0100
changeset 3802 9125466f2b341841a2068347e1205f1464c3a914
parent 3801 77d79dc4ef45020aef6d0a21232f3e356372d2e9
child 3803 08a42154f0223624d508516ca2f7756c9ca08f76
child 3804 a5581acb61c0c62d04d1c9e71812a951ed8ebdbe
push idunknown
push userunknown
push dateunknown
bugs516630
Bug 516630 - "timeline doesn't stay collapsed if you change sort order" [r+a=Standard8]
mail/base/content/glodaFacetView.js
--- a/mail/base/content/glodaFacetView.js
+++ b/mail/base/content/glodaFacetView.js
@@ -374,18 +374,16 @@ var FacetContext = {
     if (this.searcher)
       queryExplanation.setFulltext(this.searcher);
     else
       queryExplanation.setQuery(this.collection.query);
     // we like to sort them so should clone the list
     this.faceters = this.facetDriver.faceters.concat();
 
     this._timelineShown = ! Application.prefs.getValue('gloda.facetview.hidetimeline', true);
-    if (! this._timelineShown)
-      this._hideTimeline(true);
 
     this.everFaceted = false;
     this._activeConstraints = {};
     try {
       if (this.searcher) {
         this._sortBy = '-dascore';
         this._relevantSortedItems = this._collection.items.concat();
         this._dateSortedItems = this._relevantSortedItems.concat().sort(function(a,b) b.date-a.date);
@@ -505,16 +503,19 @@ var FacetContext = {
         else {
           faceter.xblNode.orderedGroups = faceter.orderedGroups;
           faceter.xblNode.build(false);
           $(faceter.xblNode).show();
         }
       }
     }
 
+    if (! this._timelineShown)
+      this._hideTimeline(true);
+
     this._showResults();
 
     if (this._callbackOnFacetComplete) {
       let callback = this._callbackOnFacetComplete;
       this._callbackOnFacetComplete = null;
       callback();
     }
   },