diff options
author | Matt A. Tobin <email@mattatobin.com> | 2020-02-06 08:31:14 -0500 |
---|---|---|
committer | Matt A. Tobin <email@mattatobin.com> | 2020-02-06 08:31:14 -0500 |
commit | 180543f6c37887cdb19c07cf47491b52154f1157 (patch) | |
tree | b70ab3e835dc5fd9f11b6d32154ed1d9d2f38cd9 /toolkit/components/jsdownloads/src/DownloadIntegration.jsm | |
parent | 2e6782afb5a340c777d3dab1c5e82f3e4af06ad2 (diff) | |
download | UXP-180543f6c37887cdb19c07cf47491b52154f1157.tar UXP-180543f6c37887cdb19c07cf47491b52154f1157.tar.gz UXP-180543f6c37887cdb19c07cf47491b52154f1157.tar.lz UXP-180543f6c37887cdb19c07cf47491b52154f1157.tar.xz UXP-180543f6c37887cdb19c07cf47491b52154f1157.zip |
Issue #65 - Remove AppConstants from toolkit/components/jsdownloads
Diffstat (limited to 'toolkit/components/jsdownloads/src/DownloadIntegration.jsm')
-rw-r--r-- | toolkit/components/jsdownloads/src/DownloadIntegration.jsm | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/toolkit/components/jsdownloads/src/DownloadIntegration.jsm b/toolkit/components/jsdownloads/src/DownloadIntegration.jsm index a6875ec48..995cc0669 100644 --- a/toolkit/components/jsdownloads/src/DownloadIntegration.jsm +++ b/toolkit/components/jsdownloads/src/DownloadIntegration.jsm @@ -28,8 +28,7 @@ Cu.import("resource://gre/modules/XPCOMUtils.jsm"); XPCOMUtils.defineLazyModuleGetter(this, "AsyncShutdown", "resource://gre/modules/AsyncShutdown.jsm"); -XPCOMUtils.defineLazyModuleGetter(this, "AppConstants", - "resource://gre/modules/AppConstants.jsm"); + XPCOMUtils.defineLazyModuleGetter(this, "DeferredTask", "resource://gre/modules/DeferredTask.jsm"); XPCOMUtils.defineLazyModuleGetter(this, "Downloads", @@ -696,8 +695,11 @@ this.DownloadIntegration = { fileExtension = match[1]; } - let isWindowsExe = AppConstants.platform == "win" && - fileExtension.toLowerCase() == "exe"; +#ifdef XP_WIN + let isWindowsExe = fileExtension.toLowerCase() == "exe"; +#else + let isWindowsExe = false; +#endif // Ask for confirmation if the file is executable, except for .exe on // Windows where the operating system will show the prompt based on the |