Bug 564900 - Add a Downloads view to the Library.
authorMehdi Mulani <mars.martian+bugmail@gmail.com>, Jared Wein <jwein@mozilla.com>
Fri, 05 Aug 2011 21:08:33 +0200
changeset 73913 bb71b8c9441d0163cbb2b16d687ca5acc356d357
parent 73912 03f472cf0a5bd3bedda4bfb55fda62495c151b4c
child 73914 a8bca81215eadf4691cd31c5d38799a0fcb5996e
push id2
push userbsmedberg@mozilla.com
push dateFri, 19 Aug 2011 14:38:13 +0000
bugs564900
milestone8.0a1
Bug 564900 - Add a Downloads view to the Library. Patch further modified and fixed by Jared Wein <jwein@mozilla.com>. r=mak
browser/components/places/content/places.js
browser/components/places/src/PlacesUIUtils.jsm
browser/components/places/tests/browser/Makefile.in
browser/components/places/tests/browser/browser_library_downloads.js
browser/components/places/tests/browser/head.js
browser/components/places/tests/chrome/test_0_bug510634.xul
browser/components/places/tests/chrome/test_bug427633_no_newfolder_if_noip.xul
browser/themes/gnomestripe/browser/jar.mn
browser/themes/gnomestripe/browser/places/downloads.png
browser/themes/gnomestripe/browser/places/places.css
browser/themes/pinstripe/browser/jar.mn
browser/themes/pinstripe/browser/places/downloads.png
browser/themes/pinstripe/browser/places/places.css
browser/themes/winstripe/browser/jar.mn
browser/themes/winstripe/browser/places/downloads.png
browser/themes/winstripe/browser/places/places.css
--- a/browser/components/places/content/places.js
+++ b/browser/components/places/content/places.js
@@ -67,17 +67,17 @@ var PlacesOrganizer = {
   },
 
   init: function PO_init() {
     this._places = document.getElementById("placesList");
     this._content = document.getElementById("placeContent");
     this._initFolderTree();
 
     var leftPaneSelection = "AllBookmarks"; // default to all-bookmarks
-    if ("arguments" in window && window.arguments.length > 0)
+    if (window.arguments && window.arguments[0])
       leftPaneSelection = window.arguments[0];
 
     this.selectLeftPaneQuery(leftPaneSelection);
     // clear the back-stack
     this._backHistory.splice(0);
     document.getElementById("OrganizerCommand:Back").setAttribute("disabled", true);
 
     var view = this._content.treeBoxObject.view;
--- a/browser/components/places/src/PlacesUIUtils.jsm
+++ b/browser/components/places/src/PlacesUIUtils.jsm
@@ -51,17 +51,17 @@ Cu.import("resource://gre/modules/XPCOMU
 Cu.import("resource://gre/modules/Services.jsm");
 
 XPCOMUtils.defineLazyGetter(this, "PlacesUtils", function() {
   Cu.import("resource://gre/modules/PlacesUtils.jsm");
   return PlacesUtils;
 });
 
 var PlacesUIUtils = {
-  ORGANIZER_LEFTPANE_VERSION: 6,
+  ORGANIZER_LEFTPANE_VERSION: 7,
   ORGANIZER_FOLDER_ANNO: "PlacesOrganizer/OrganizerFolder",
   ORGANIZER_QUERY_ANNO: "PlacesOrganizer/OrganizerQuery",
 
   LOAD_IN_SIDEBAR_ANNO: "bookmarkProperties/loadInSidebar",
   DESCRIPTION_ANNO: "bookmarkProperties/description",
 
   TYPE_TAB_DROP: "application/x-moz-tabbrowser-tab",
 
@@ -983,33 +983,34 @@ var PlacesUIUtils = {
     // Shortcuts to services.
     let bs = PlacesUtils.bookmarks;
     let as = PlacesUtils.annotations;
 
     // This is the list of the left pane queries.
     let queries = {
       "PlacesRoot": { title: "" },
       "History": { title: this.getString("OrganizerQueryHistory") },
+      "Downloads": { title: this.getString("OrganizerQueryDownloads") },
       "Tags": { title: this.getString("OrganizerQueryTags") },
       "AllBookmarks": { title: this.getString("OrganizerQueryAllBookmarks") },
       "BookmarksToolbar":
         { title: null,
           concreteTitle: PlacesUtils.getString("BookmarksToolbarFolderTitle"),
           concreteId: PlacesUtils.toolbarFolderId },
       "BookmarksMenu":
         { title: null,
           concreteTitle: PlacesUtils.getString("BookmarksMenuFolderTitle"),
           concreteId: PlacesUtils.bookmarksMenuFolderId },
       "UnfiledBookmarks":
         { title: null,
           concreteTitle: PlacesUtils.getString("UnsortedBookmarksFolderTitle"),
           concreteId: PlacesUtils.unfiledBookmarksFolderId },
     };
     // All queries but PlacesRoot.
-    const EXPECTED_QUERY_COUNT = 6;
+    const EXPECTED_QUERY_COUNT = 7;
 
     // Removes an item and associated annotations, ignoring eventual errors.
     function safeRemoveItem(aItemId) {
       try {
         if (as.itemHasAnnotation(aItemId, PlacesUIUtils.ORGANIZER_QUERY_ANNO) &&
             !(as.getItemAnnotation(aItemId, PlacesUIUtils.ORGANIZER_QUERY_ANNO) in queries)) {
           // Some extension annotated their roots with our query annotation,
           // so we should not delete them.
@@ -1172,17 +1173,22 @@ var PlacesUIUtils = {
 
         // History Query.
         this.create_query("History", leftPaneRoot,
                           "place:type=" +
                           Ci.nsINavHistoryQueryOptions.RESULTS_AS_DATE_QUERY +
                           "&sort=" +
                           Ci.nsINavHistoryQueryOptions.SORT_BY_DATE_DESCENDING);
 
-        // XXX: Downloads.
+        // Downloads.
+        this.create_query("Downloads", leftPaneRoot,
+                          "place:transition=" +
+                          Ci.nsINavHistoryService.TRANSITION_DOWNLOAD +
+                          "&sort=" +
+                          Ci.nsINavHistoryQueryOptions.SORT_BY_DATE_DESCENDING);
 
         // Tags Query.
         this.create_query("Tags", leftPaneRoot,
                           "place:type=" +
                           Ci.nsINavHistoryQueryOptions.RESULTS_AS_TAG_QUERY +
                           "&sort=" +
                           Ci.nsINavHistoryQueryOptions.SORT_BY_TITLE_ASCENDING);
 
--- a/browser/components/places/tests/browser/Makefile.in
+++ b/browser/components/places/tests/browser/Makefile.in
@@ -69,12 +69,13 @@ include $(topsrcdir)/config/rules.mk
 	browser_markPageAsFollowedLink.js \
 	framedPage.html \
 	frameLeft.html \
 	frameRight.html \
 	browser_toolbar_migration.js \
 	browser_library_batch_delete.js \
 	browser_555547.js \
 	browser_416459_cut.js \
+	browser_library_downloads.js \
 	$(NULL)
 
 libs:: $(_BROWSER_TEST_FILES)
 	$(INSTALL) $(foreach f,$^,"$f") $(DEPTH)/_tests/testing/mochitest/browser/$(relativesrcdir)
new file mode 100644
--- /dev/null
+++ b/browser/components/places/tests/browser/browser_library_downloads.js
@@ -0,0 +1,89 @@
+/* ***** BEGIN LICENSE BLOCK *****
+ * Version: MPL 1.1/GPL 2.0/LGPL 2.1
+ *
+ * The contents of this file are subject to the Mozilla Public License Version
+ * 1.1 (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ * http://www.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ * for the specific language governing rights and limitations under the
+ * License.
+ *
+ * The Original Code is Places test code.
+ *
+ * The Initial Developer of the Original Code is Mozilla Foundation.
+ * Portions created by the Initial Developer are Copyright (C) 2010
+ * the Initial Developer. All Rights Reserved.
+ *
+ * Contributor(s):
+ *   Mehdi Mulani <mmulani@mozilla.com> (original author)
+ *   Jared Wein <jwein@mozilla.com>
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 2 or later (the "GPL"), or
+ * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+ * in which case the provisions of the GPL or the LGPL are applicable instead
+ * of those above. If you wish to allow use of your version of this file only
+ * under the terms of either the GPL or the LGPL, and not to allow others to
+ * use your version of this file under the terms of the MPL, indicate your
+ * decision by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL or the LGPL. If you do not delete
+ * the provisions above, a recipient may use your version of this file under
+ * the terms of any one of the MPL, the GPL or the LGPL.
+ *
+ * ***** END LICENSE BLOCK ***** */
+
+/*
+ * Tests bug 564900: Add folder specifically for downloads to Library left pane.
+ * https://bugzilla.mozilla.org/show_bug.cgi?id=564900
+ * This test visits various pages then opens the Library and ensures
+ * that both the Downloads folder shows up and that the correct visits
+ * are shown in it.
+ */
+
+let now = Date.now();
+
+function test() {
+  waitForExplicitFinish();
+
+  function onLibraryReady(win) {
+    // Add visits to compare contents with.
+    fastAddVisit("http://mozilla.com",
+                  PlacesUtils.history.TRANSITION_TYPED);
+    fastAddVisit("http://google.com",
+                  PlacesUtils.history.TRANSITION_DOWNLOAD);
+    fastAddVisit("http://en.wikipedia.org",
+                  PlacesUtils.history.TRANSITION_TYPED);
+    fastAddVisit("http://ubuntu.org",
+                  PlacesUtils.history.TRANSITION_DOWNLOAD);
+
+    // Make sure Downloads is present.
+    isnot(win.PlacesOrganizer._places.selectedNode, null,
+          "Downloads is present and selected");
+
+    // Make sure content in right pane exists.
+    let tree = win.document.getElementById("placeContent");
+    isnot(tree, null, "placeContent tree exists");
+
+    // Check results.
+    var contentRoot = tree.result.root;
+    var len = contentRoot.childCount;
+    var testUris = ["http://ubuntu.org/", "http://google.com/"];
+    for (var i = 0; i < len; i++) {
+      is(contentRoot.getChild(i).uri, testUris[i],
+          "Comparing downloads shown at index " + i);
+    }
+
+    win.close();
+    waitForClearHistory(finish);
+  }
+
+  openLibrary(onLibraryReady, "Downloads");
+}
+
+function fastAddVisit(uri, transition) {
+  PlacesUtils.history.addVisit(PlacesUtils._uri(uri), now++ * 1000,
+                               null, transition, false, 0);
+}
--- a/browser/components/places/tests/browser/head.js
+++ b/browser/components/places/tests/browser/head.js
@@ -1,28 +1,38 @@
+/* Any copyright is dedicated to the Public Domain.
+   http://creativecommons.org/publicdomain/zero/1.0/ */
+
+Components.utils.import("resource://gre/modules/NetUtil.jsm");
 
 // We need to cache this before test runs...
 let cachedLeftPaneFolderIdGetter;
 let (getter = PlacesUIUtils.__lookupGetter__("leftPaneFolderId")) {
   if (!cachedLeftPaneFolderIdGetter && typeof(getter) == "function")
     cachedLeftPaneFolderIdGetter = getter;
 }
 // ...And restore it when test ends.
 registerCleanupFunction(function(){
   let (getter = PlacesUIUtils.__lookupGetter__("leftPaneFolderId")) {
     if (cachedLeftPaneFolderIdGetter && typeof(getter) != "function")
       PlacesUIUtils.__defineGetter__("leftPaneFolderId",
                                      cachedLeftPaneFolderIdGetter);
   }
 });
 
-
-function openLibrary(callback) {
+function openLibrary(callback, aLeftPaneRoot) {
   let library = window.openDialog("chrome://browser/content/places/places.xul",
-                                  "", "chrome,toolbar=yes,dialog=no,resizable");
+                                  "", "chrome,toolbar=yes,dialog=no,resizable",
+                                  aLeftPaneRoot);
   waitForFocus(function () {
     callback(library);
   }, library);
 
   return library;
 }
 
-Components.utils.import("resource://gre/modules/NetUtil.jsm");
+function waitForClearHistory(aCallback) {
+  Services.obs.addObserver(function observeCH(aSubject, aTopic, aData) {
+    Services.obs.removeObserver(observeCH, PlacesUtils.TOPIC_EXPIRATION_FINISHED);
+    aCallback();
+  }, PlacesUtils.TOPIC_EXPIRATION_FINISHED, false);
+  PlacesUtils.bhistory.removeAllPages();
+}
--- a/browser/components/places/tests/chrome/test_0_bug510634.xul
+++ b/browser/components/places/tests/chrome/test_0_bug510634.xul
@@ -92,47 +92,59 @@
       return results;
     }
 
     function runTest() {
       // We need to cache and restore this getter in order to simulate
       // Bug 510634
       let cachedLeftPaneFolderIdGetter =
         PlacesUIUtils.__lookupGetter__("leftPaneFolderId");
+      // Must also cache and restore this getter as it is affected by
+      // leftPaneFolderId, from bug 564900.
+      let cachedAllBookmarksFolderIdGetter =
+        PlacesUIUtils.__lookupGetter__("allBookmarksFolderId");
 
       let leftPaneFolderId = PlacesUIUtils.leftPaneFolderId;
 
       // restore the getter
       PlacesUIUtils.__defineGetter__("leftPaneFolderId", cachedLeftPaneFolderIdGetter);
 
       // Setup the places tree contents.
       let tree = document.getElementById("tree");
       tree.place = "place:queryType=1&folder=" + leftPaneFolderId;
 
-      // Open All Bookmarks
-      PlacesUtils.asContainer(tree.view.nodeForTreeIndex(2)).containerOpen = true;
-      
       // The query-property is set on the title column for each row.
       let titleColumn = tree.treeBoxObject.columns.getColumnAt(0);
 
-      ["History", "Tags", "AllBookmarks", "BookmarksToolbar",
+      // Open All Bookmarks
+      tree.selectItems([PlacesUIUtils.leftPaneQueries["AllBookmarks"]]);
+      PlacesUtils.asContainer(tree.selectedNode).containerOpen = true;
+      is(PlacesUIUtils.allBookmarksFolderId, tree.selectedNode.itemId,
+         "Opened All Bookmarks");
+
+      ["History", "Downloads", "Tags", "AllBookmarks", "BookmarksToolbar",
        "BookmarksMenu", "UnfiledBookmarks"].forEach(
-         function(aQueryName, aRow) {
-           let rowProperties = createSupportsArray();
-           tree.view.getCellProperties(aRow, titleColumn, rowProperties);
-           rowProperties = convertPropertiesToJSArray(rowProperties);
-           ok(rowProperties.indexOf("OrganizerQuery_" + aQueryName) != -1,
-             "OrganizerQuery_" + aQueryName + " is set");
-         }
-       );
+        function(aQueryName, aRow) {
+          let found = false;
+          for (let i = 0; i < tree.view.rowCount && !found; i++) {
+            let rowProperties = createSupportsArray();
+            tree.view.getCellProperties(i, titleColumn, rowProperties);
+            rowProperties = convertPropertiesToJSArray(rowProperties);
+            found = rowProperties.indexOf("OrganizerQuery_" + aQueryName) != -1;
+          }
+          ok(found, "OrganizerQuery_" + aQueryName + " is set");
+        }
+      );
 
       // Close the root node
       tree.result.root.containerOpen = false;
 
-      // Restore the getter for the next test.
+      // Restore the getters for the next test.
       PlacesUIUtils.__defineGetter__("leftPaneFolderId", cachedLeftPaneFolderIdGetter);
+      PlacesUIUtils.__defineGetter__("allBookmarksFolderId",
+                                     cachedAllBookmarksFolderIdGetter);
 
       SimpleTest.finish();
     }
 
   ]]>
   </script>
 </window>
--- a/browser/components/places/tests/chrome/test_bug427633_no_newfolder_if_noip.xul
+++ b/browser/components/places/tests/chrome/test_bug427633_no_newfolder_if_noip.xul
@@ -80,17 +80,17 @@
                getService(Ci.nsINavBookmarksService);
       var ios = Cc["@mozilla.org/network/io-service;1"].
                 getService(Ci.nsIIOService);
       function uri(spec) {
         return ios.newURI(spec, null, null);
       }
 
       // Add a bookmark.
-      var itemId = bs.insertBookmark(bs.toolbarFolder,
+      var itemId = bs.insertBookmark(PlacesUtils.toolbarFolderId,
                                      uri("http://www.example.com/"),
                                      bs.DEFAULT_INDEX,
                                      "mozilla");
 
       // Init panel.
       ok(gEditItemOverlay, "gEditItemOverlay is in context");
       gEditItemOverlay.initPanel(itemId);
       ok(gEditItemOverlay._initialized, "gEditItemOverlay is initialized");
--- a/browser/themes/gnomestripe/browser/jar.mn
+++ b/browser/themes/gnomestripe/browser/jar.mn
@@ -58,16 +58,17 @@ browser.jar:
   skin/classic/browser/places/organizer.css           (places/organizer.css)
 * skin/classic/browser/places/organizer.xml           (places/organizer.xml)
   skin/classic/browser/places/query.png               (places/query.png)
   skin/classic/browser/places/searching_16.png        (places/searching_16.png)
   skin/classic/browser/places/starPage.png            (places/starPage.png)
   skin/classic/browser/places/tag.png                 (places/tag.png)
   skin/classic/browser/places/toolbarDropMarker.png   (places/toolbarDropMarker.png)
   skin/classic/browser/places/unsortedBookmarks.png   (places/unsortedBookmarks.png)
+  skin/classic/browser/places/downloads.png           (places/downloads.png)
   skin/classic/browser/preferences/alwaysAsk.png      (preferences/alwaysAsk.png)
   skin/classic/browser/preferences/mail.png           (preferences/mail.png)
   skin/classic/browser/preferences/Options.png        (preferences/Options.png)
 #ifdef MOZ_SERVICES_SYNC
   skin/classic/browser/preferences/Options-sync.png   (preferences/Options-sync.png)
 #endif
 * skin/classic/browser/preferences/preferences.css    (preferences/preferences.css)
   skin/classic/browser/preferences/applications.css   (preferences/applications.css)
new file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..d641714aabe56751e54e0a24d1d6cb2188bee968
GIT binary patch
literal 599
zc$@)O0;v6oP)<h;3K|Lk000e1NJLTq000mG000mO1^@s6AM^iV0000PbVXQnQ*UN;
zcVTj606}DLVr3vnZDD6+Qe|Oed2z{QJOBUz`AI}URCwBA{Qv(y10{eFn*kAXq<0C*
zvAQy`K=}XuFfe?0{QKbY<fjf8ia`dT<BXm1|IdD0`~SiBGhlr7)7t-;yX60e&z9mx
zSIdIUSs<JLG5%pV@^Lnpug>Mfz{JXk)e9`R{Pz3*cZNUzf5O?g08Rt`{{IEn2x60L
z0Lb>A|GvQ4BpJZU!2~tnE8GB9c06GKjJ6wm5-jShoQw>toJ<Uy0?Z75{{3S31v3E1
z28l^%vwz6mr@-+0+kb{nFaF$Fk@8d(=7IticE)vHx@nwz>>^-+r#~+-{DOwThrdr5
zJf%t*7^HygAI}-KU!D(=$b}~)Mn*;kU>rM1D+_KhQ*-0I^JhQY`7prF#Lb|>;=pk7
z*6#1m?!Na~nfh!WSTD=~kYORyByDBYg|?ZiyK>+8eSqQTe~2L*OneN=EVc}%Zted1
z=*By*HCfLOL((9^0FVhF%<S7GZmn!6vdLW2mG{w~lMKN0#vsRH#&GKTp0D>Vy!GEy
z`tlGcW}ycBhZ(>GN`TNnWpOMKw$ODIUt_Fc%g+cj_sq@1U#{(c8MdeW4anv{Q2Y<5
z_aCwgU<R-QF^_RHzlEj;&t#x}rW-rI=ABvm;TTXHlrVlE8Soz^44{Uv0x=iJ5GV}-
l-=La7^ly-6SQr2V7yvlA508N*8PNa$002ovPDHLkV1kWpAIAUy
--- a/browser/themes/gnomestripe/browser/places/places.css
+++ b/browser/themes/gnomestripe/browser/places/places.css
@@ -65,16 +65,21 @@ treechildren::-moz-tree-image(container,
   -moz-image-region: auto;
 }
 
 /* query-nodes should be styled even if they're not expandable */
 treechildren::-moz-tree-image(title, query) {
   list-style-image: url("chrome://browser/skin/places/query.png");
 }
 
+treechildren::-moz-tree-image(query, OrganizerQuery_Downloads) {
+  list-style-image: url("chrome://browser/skin/places/downloads.png");
+  -moz-image-region: auto;
+}
+
 treechildren::-moz-tree-image(title, query, tagContainer),
 treechildren::-moz-tree-image(query, OrganizerQuery_Tags) {
   list-style-image: url("chrome://mozapps/skin/places/tagContainerIcon.png");
 }
 
 /* calendar icon for folders grouping items by date */
 treechildren::-moz-tree-image(title, query, dayContainer) {
   list-style-image: url("chrome://browser/skin/places/calendar.png");
--- a/browser/themes/pinstripe/browser/jar.mn
+++ b/browser/themes/pinstripe/browser/jar.mn
@@ -78,16 +78,17 @@ browser.jar:
   skin/classic/browser/places/pageStarred.png               (places/pageStarred.png)
   skin/classic/browser/places/searching_16.png              (places/searching_16.png)
   skin/classic/browser/places/starred48.png                 (places/starred48.png)
   skin/classic/browser/places/unstarred48.png               (places/unstarred48.png)
   skin/classic/browser/places/unfiledBookmarks.png          (places/unfiledBookmarks.png)
   skin/classic/browser/places/twisty-open.gif               (places/twisty-open.gif)
   skin/classic/browser/places/twisty-closed.gif             (places/twisty-closed.gif)
   skin/classic/browser/places/tag.png                       (places/tag.png)
+  skin/classic/browser/places/downloads.png                 (places/downloads.png)
   skin/classic/browser/places/expander-closed-active.png    (places/expander-closed-active.png)
   skin/classic/browser/places/expander-closed.png           (places/expander-closed.png)
   skin/classic/browser/places/expander-open-active.png      (places/expander-open-active.png)
   skin/classic/browser/places/expander-open.png             (places/expander-open.png)
   skin/classic/browser/preferences/alwaysAsk.png            (preferences/alwaysAsk.png)
   skin/classic/browser/preferences/application.png          (preferences/application.png)
   skin/classic/browser/preferences/Options.png              (preferences/Options.png)
 #ifdef MOZ_SERVICES_SYNC
new file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..0756cb6806dd77f905f97344937c7bebe8fbbfba
GIT binary patch
literal 678
zc$@*I0$KfuP)<h;3K|Lk000e1NJLTq000mG000mO1^@s6AM^iV0000PbVXQnQ*UN;
zcVTj606}DLVr3vnZDD6+Qe|Oed2z{QJOBU!NJ&INRCwB?Q%z_SQ4pTDyUE711>2-5
zLbZY(1gk_MrFsy(2_jPbgHn&;!6<m`K|B<1B1Ev~N)aoT-t<%rQfgOivDlNM#Rgk7
zsbHJU?!G_Yyza&{)RP0V`{sKy-^`nNk4P!uf5gI1zIYi(9XNb%awfLd%#hf+Eg1m)
z%s=$!j&((Tm^arkyiTA&1zb}A%E<nGnR6%3!}jD3ZGU%{Vf5wbfuX^P_W1|JpZ75#
zsjEQ8*OkC+0Zs8O@YVaM?Y8(f;0Xa>{^JNTsv;C7I8=oTOmc1OwZbT4a#I3mfVmJ5
zsDOYoZ3l#FY@?7m0)3#rER3scf+`ZKZCoQ3_`K#ML;tXe66&W(Ev$gm2yjg;zDa&X
zKveeKed#Zx6FToE+X1!$7&|TSm=9H@C~*itv=~6Td1=ob<x^1=EWl!JgzVB4cow~B
zri@2@CokHm<}{eZf(7>zc%14~gs;NYgI9oeaaj7j3{MJAeNhxQYL(;{`{DNB_^I@v
z)L75qY{HLKLCB3wGl&6pkbtS#cV6jzx%bw<*=M<qhhRiQC=IPXUvhq&E=*5Xq-TQ9
zm^wnBHBb#itl&5m^g&<Q&<hf(*>u4^-qzhZmOYYb@vW-fj8PkA-p;vYXQkJD>`&mN
z!@M%OTSllBo#)>?@TSVvuQRDsI)Q_jeKWUKda-iJ8xLO9rr2<SNkpL3R@!W4jUM}G
zB9FNL+PlsjF{##T*mJxpN=3s9sFC0sOd?76M{&bo{L?5HH~t7P0D^rIGn}>e`v3p{
M07*qoM6N<$f^%9tk^lez
--- a/browser/themes/pinstripe/browser/places/places.css
+++ b/browser/themes/pinstripe/browser/places/places.css
@@ -139,16 +139,20 @@ treechildren::-moz-tree-image(container,
   list-style-image: url("chrome://browser/skin/places/unfiledBookmarks.png");
 }
 
 /* query-nodes should be styled even if they're not expandable */
 treechildren::-moz-tree-image(query) {
   list-style-image: url("chrome://browser/skin/places/query.png");
 }
 
+treechildren::-moz-tree-image(query, OrganizerQuery_Downloads) {
+  list-style-image: url("chrome://browser/skin/places/downloads.png");
+}
+
 treechildren::-moz-tree-image(title, query, tagContainer),
 treechildren::-moz-tree-image(query, OrganizerQuery_Tags) {
   list-style-image: url("chrome://mozapps/skin/places/tagContainerIcon.png");
 }
 
 /* calendar icon for folders grouping items by date */
 treechildren::-moz-tree-image(title, query, dayContainer) {
   list-style-image: url("chrome://browser/skin/places/history.png");
--- a/browser/themes/winstripe/browser/jar.mn
+++ b/browser/themes/winstripe/browser/jar.mn
@@ -70,16 +70,17 @@ browser.jar:
         skin/classic/browser/places/libraryToolbar.png               (places/libraryToolbar.png)
         skin/classic/browser/places/starred48.png                    (places/starred48.png)
         skin/classic/browser/places/unstarred48.png                  (places/unstarred48.png)
         skin/classic/browser/places/tag.png                          (places/tag.png)
         skin/classic/browser/places/history.png                      (places/history.png)
         skin/classic/browser/places/allBookmarks.png                 (places/allBookmarks.png)
         skin/classic/browser/places/unsortedBookmarks.png            (places/unsortedBookmarks.png)
         skin/classic/browser/places/searching_16.png                 (places/searching_16.png)
+        skin/classic/browser/places/downloads.png                    (places/downloads.png)
         skin/classic/browser/preferences/alwaysAsk.png               (preferences/alwaysAsk.png)
         skin/classic/browser/preferences/application.png             (preferences/application.png)
         skin/classic/browser/preferences/mail.png                    (preferences/mail.png)
         skin/classic/browser/preferences/Options.png                 (preferences/Options.png)
 #ifdef MOZ_SERVICES_SYNC
         skin/classic/browser/preferences/Options-sync.png            (preferences/Options-sync.png)
 #endif
         skin/classic/browser/preferences/saveFile.png                (preferences/saveFile.png)
@@ -184,16 +185,17 @@ browser.jar:
         skin/classic/aero/browser/places/libraryToolbar.png          (places/libraryToolbar-aero.png)
         skin/classic/aero/browser/places/starred48.png               (places/starred48-aero.png)
         skin/classic/aero/browser/places/unstarred48.png             (places/unstarred48.png)
         skin/classic/aero/browser/places/tag.png                     (places/tag-aero.png)
         skin/classic/aero/browser/places/history.png                 (places/history-aero.png)
         skin/classic/aero/browser/places/allBookmarks.png            (places/allBookmarks-aero.png)
         skin/classic/aero/browser/places/unsortedBookmarks.png       (places/unsortedBookmarks-aero.png)
         skin/classic/aero/browser/places/searching_16.png            (places/searching_16-aero.png)
+        skin/classic/aero/browser/places/downloads.png               (places/downloads.png)
         skin/classic/aero/browser/preferences/alwaysAsk.png          (preferences/alwaysAsk-aero.png)
         skin/classic/aero/browser/preferences/application.png        (preferences/application-aero.png)
         skin/classic/aero/browser/preferences/mail.png               (preferences/mail-aero.png)
         skin/classic/aero/browser/preferences/Options.png            (preferences/Options-aero.png)
 #ifdef MOZ_SERVICES_SYNC
         skin/classic/aero/browser/preferences/Options-sync.png       (preferences/Options-sync.png)
 #endif
         skin/classic/aero/browser/preferences/plugin.png             (preferences/plugin-aero.png)
new file mode 100644
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..d37bc40b642d3826e7a74f2e391706299ea455c8
GIT binary patch
literal 674
zc$@*E0$u%yP)<h;3K|Lk000e1NJLTq000mG000mO1^@s6AM^iV0000PbVXQnQ*UN;
zcVTj606}DLVr3vnZDD6+Qe|Oed2z{QJOBU!L`g(JRCwB?Q_pJ?Q4s##Zgyj%ZB62j
zQetb`gGDLYA|e$*dQ=fb?OD8eDR`2CH~#}q9t5%8dl63}SdwN<N|RQlR79ysj3zOg
zq|J{__Pu?+Y+?veO2C2HS?0a(+nH}>3FjRDV~&3%uiSYQ^G%;S1G#m~C{nT2^_R~c
zPIccU-4zi3jlsJM^My+@Q#jZs2*i2bU|0^tkdH==E<JgW*}H;1C%DUn0wYN1)J`2x
zh@FG#=%EEg0V4zq5=_#p&H}M>?Uwc=kOj~ZAW1|4wF#tV&Y+a{AR<AHF<1gn;}Ys3
zQp3Vmy@b+Fo%KM#QGtqNnIe#;*flvO1|)11If`GB?C;MBo4vJ=kVj7V%>9Fi%Pv$r
zKAayvj1T$d{Ykfs;O7j~Y#fKmMWC2N;r;4%eC@g4u3(4YzHTWmMvjl~JMDH0v1Mc`
zCRnXG1-&d|cFcqNu>oXrd91t*RZ%hS*^)ILsm<VKUiNAwuFee~@ha<CicDEZ$SmOu
zdGVg!slfvS8_{UB`YC)B(Z$zo0^1VN?TW)2$WiI`w0}tbWdLTKf>Q>k80V>eif}km
z%Ef}05qi4Z9$JSM1j*R<DqLFDblf~UHmnwe`VO&)C;KgE+Pkv8_U1Ywiz~L$T?A6g
z9Y}rrVbpjyZ7SC$M~9qVl|c(>yM^$pIczM2+M{Yk(ouob8mqIhy%?RjAWvL;Z2wDJ
zfq8rjHNYj|qB&4|K|2UKNfhBOo1_^VR%wA7(fk8$9Q+nw0BgSjtIXmUdH?_b07*qo
IM6N<$f=vW2H2?qr
--- a/browser/themes/winstripe/browser/places/places.css
+++ b/browser/themes/winstripe/browser/places/places.css
@@ -80,16 +80,21 @@ treechildren::-moz-tree-image(title, que
 }
 
 treechildren::-moz-tree-image(title, query, tagContainer),
 treechildren::-moz-tree-image(query, OrganizerQuery_Tags) {
   list-style-image: url("chrome://mozapps/skin/places/tagContainerIcon.png");
   -moz-image-region: auto;
 }
 
+treechildren::-moz-tree-image(query, OrganizerQuery_Downloads) {
+  list-style-image: url("chrome://browser/skin/places/downloads.png");
+  -moz-image-region: auto;
+}
+
 /* calendar icon for folders grouping items by date */
 treechildren::-moz-tree-image(title, query, dayContainer) {
   list-style-image: url("chrome://browser/skin/places/calendar.png");
   -moz-image-region: auto;
 }
 
 treechildren::-moz-tree-image(title, query, hostContainer) {
   list-style-image: url("chrome://global/skin/icons/folder-item.png");