1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/toolkit/components/downloads/test/unit/downloads_manifest.js Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,24 @@ 1.4 +/* Any copyright is dedicated to the Public Domain. 1.5 + http://creativecommons.org/publicdomain/zero/1.0/ */ 1.6 + 1.7 +// Shared functions for files testing Bug 593815 1.8 + 1.9 +Components.utils.import("resource://gre/modules/XPCOMUtils.jsm"); 1.10 + 1.11 +const Cc = Components.classes; 1.12 +const Ci = Components.interfaces; 1.13 + 1.14 +function HelperAppDlg() { } 1.15 +HelperAppDlg.prototype = { 1.16 + QueryInterface: XPCOMUtils.generateQI([Ci.nsIHelperAppLauncherDialog]), 1.17 + classID: Components.ID("49456eda-4dc4-4d1a-b8e8-0b94749bf99e"), 1.18 + show: function (launcher, ctx, reason) { 1.19 + launcher.MIMEInfo.preferredAction = Ci.nsIMIMEInfo.saveToDisk; 1.20 + launcher.launchWithApplication(null, false); 1.21 + }, 1.22 + 1.23 + promptForSaveToFile: function (launcher, ctx, defaultFile, suggestedExtension, forcePrompt) { } 1.24 +} 1.25 + 1.26 + 1.27 +this.NSGetFactory = XPCOMUtils.generateNSGetFactory([HelperAppDlg]);