Bug 928349 - Add a build-time setting to use only the JavaScript API for downloads, and enable it in Firefox for Desktop. r=enn
authorPaolo Amadini <paolo.mozmail@amadzone.org>
Wed, 23 Oct 2013 21:46:47 +0200
changeset 165626 70e1e02b917ddca12f258ceb7fb7f8773900066c
parent 165625 b185e2dd95d49dc60a82173b173726c198de78f6
child 165627 1bab2224b51a05a1bab282dc04f4c74dc5d4870c
push id3066
push userakeybl@mozilla.com
push dateMon, 09 Dec 2013 19:58:46 +0000
treeherdermozilla-beta@a31a0dce83aa [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersenn
bugs928349
milestone27.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 928349 - Add a build-time setting to use only the JavaScript API for downloads, and enable it in Firefox for Desktop. r=enn
browser/app/profile/firefox.js
browser/components/downloads/src/DownloadsCommon.jsm
browser/components/downloads/src/DownloadsStartup.js
browser/components/nsBrowserGlue.js
browser/confvars.sh
configure.in
security/manager/ssl/tests/mochitest/mixedcontent/test_bug383369.html
toolkit/components/downloads/nsDownloadManager.cpp
toolkit/components/downloads/test/moz.build
toolkit/components/downloads/test/unit/head_download_manager.js
toolkit/forgetaboutsite/ForgetAboutSite.jsm
toolkit/forgetaboutsite/test/unit/head_forgetaboutsite.js
toolkit/forgetaboutsite/test/unit/test_removeDataFromDomain.js
toolkit/forgetaboutsite/test/unit/test_removeDataFromDomain_activeDownloads.js
toolkit/mozapps/downloads/DownloadTaskbarProgress.jsm
toolkit/mozapps/downloads/tests/chrome/test_taskbarprogress_service.xul
toolkit/mozapps/downloads/tests/chrome/utils.js
uriloader/exthandler/tests/moz.build
--- a/browser/app/profile/firefox.js
+++ b/browser/app/profile/firefox.js
@@ -360,22 +360,16 @@ pref("browser.download.manager.showWhenS
 pref("browser.download.manager.closeWhenDone", false);
 pref("browser.download.manager.focusWhenStarting", false);
 pref("browser.download.manager.flashCount", 2);
 pref("browser.download.manager.addToRecentDocs", true);
 pref("browser.download.manager.quitBehavior", 0);
 pref("browser.download.manager.scanWhenDone", true);
 pref("browser.download.manager.resumeOnWakeDelay", 10000);
 
-// Enables the asynchronous Downloads API in the Downloads Panel.
-pref("browser.download.useJSTransfer", true);
-
-// This allows disabling the Downloads Panel in favor of the old interface.
-pref("browser.download.useToolkitUI", false);
-
 // This allows disabling the animated notifications shown by
 // the Downloads Indicator when a download starts or completes.
 pref("browser.download.animateNotifications", true);
 
 // This records whether or not the panel has been shown at least once.
 pref("browser.download.panel.shown", false);
 
 // This records whether or not at least one session with the Downloads Panel
--- a/browser/components/downloads/src/DownloadsCommon.jsm
+++ b/browser/components/downloads/src/DownloadsCommon.jsm
@@ -230,25 +230,22 @@ this.DownloadsCommon = {
     if (hours < 48) { // two days
       return DownloadsCommon.strings["shortTimeLeftHours"](hours);
     }
     let days = Math.round(hours / 24);
     return DownloadsCommon.strings["shortTimeLeftDays"](Math.min(days, 99));
   },
 
   /**
-   * Indicates whether we should show the full Download Manager window interface
-   * instead of the simplified panel interface.  The behavior of downloads
-   * across browsing session is consistent with the selected interface.
+   * Indicates that we should show the simplified panel interface instead of the
+   * full Download Manager window interface.  The code associated with the
+   * Download Manager window interface will be removed in bug 899110.
    */
   get useToolkitUI()
   {
-    try {
-      return Services.prefs.getBoolPref("browser.download.useToolkitUI");
-    } catch (ex) { }
     return false;
   },
 
   /**
    * Indicates whether we should show visual notification on the indicator
    * when a download event is triggered.
    */
   get animateNotifications()
@@ -565,27 +562,22 @@ XPCOMUtils.defineLazyGetter(DownloadsCom
   if (os != "WINNT") {
     return false;
   }
   let sysInfo = Cc["@mozilla.org/system-info;1"].getService(Ci.nsIPropertyBag2);
   return parseFloat(sysInfo.getProperty("version")) >= 6;
 });
 
 /**
- * Returns true if we should hook the panel to the JavaScript API for downloads
- * instead of the nsIDownloadManager back-end.  In order for the logic to work
- * properly, this value never changes during the execution of the application,
- * even if the underlying preference value has changed.  A restart is required
- * for the change to take effect.
+ * Returns true to indicate that we should hook the panel to the JavaScript API
+ * for downloads instead of the nsIDownloadManager back-end.  The code
+ * associated with nsIDownloadManager will be removed in bug 899110.
  */
 XPCOMUtils.defineLazyGetter(DownloadsCommon, "useJSTransfer", function () {
-  try {
-    return Services.prefs.getBoolPref("browser.download.useJSTransfer");
-  } catch (ex) { }
-  return false;
+  return true;
 });
 
 ////////////////////////////////////////////////////////////////////////////////
 //// DownloadsData
 
 /**
  * Retrieves the list of past and completed downloads from the underlying
  * Download Manager data, and provides asynchronous notifications allowing to
--- a/browser/components/downloads/src/DownloadsStartup.js
+++ b/browser/components/downloads/src/DownloadsStartup.js
@@ -88,39 +88,23 @@ DownloadsStartup.prototype = {
       case "profile-after-change":
         // Override Toolkit's nsIDownloadManagerUI implementation with our own.
         // This must be done at application startup and not in the manifest to
         // ensure that our implementation overrides the original one.
         Components.manager.QueryInterface(Ci.nsIComponentRegistrar)
                           .registerFactory(kDownloadsUICid, "",
                                            kDownloadsUIContractId, null);
 
-        // If the integration preference is enabled, override Toolkit's
-        // nsITransfer implementation with the one from the JavaScript API for
-        // downloads.  This should be used only by developers while testing new
-        // code that uses the JavaScript API, and will eventually be removed
-        // when nsIDownloadManager will not be available anymore (bug 851471).
-        let useJSTransfer = false;
-        try {
-          // For performance reasons, we don't want to load the DownloadsCommon
-          // module during startup, so we read the preference value directly.
-          useJSTransfer =
-            Services.prefs.getBoolPref("browser.download.useJSTransfer");
-        } catch (ex) { }
-        if (useJSTransfer) {
-          Components.manager.QueryInterface(Ci.nsIComponentRegistrar)
-                            .registerFactory(kTransferCid, "",
-                                             kTransferContractId, null);
-        } else {
-          // The other notifications are handled internally by the JavaScript
-          // API for downloads, no need to observe when that API is enabled.
-          for (let topic of kObservedTopics) {
-            Services.obs.addObserver(this, topic, true);
-          }
-        }
+        // Override Toolkit's nsITransfer implementation with the one from the
+        // JavaScript API for downloads.  This will eventually be removed when
+        // nsIDownloadManager will not be available anymore (bug 851471).  The
+        // old code in this module will be removed in bug 899110.
+        Components.manager.QueryInterface(Ci.nsIComponentRegistrar)
+                          .registerFactory(kTransferCid, "",
+                                           kTransferContractId, null);
         break;
 
       case "sessionstore-windows-restored":
       case "sessionstore-browser-state-restored":
         // Unless there is no saved session, there is a chance that we are
         // starting up after a restart or a crash.  We should check the disk
         // database to see if there are completed downloads to recover and show
         // in the panel, in addition to in-progress downloads.
--- a/browser/components/nsBrowserGlue.js
+++ b/browser/components/nsBrowserGlue.js
@@ -1415,19 +1415,16 @@ BrowserGlue.prototype = {
           currentset = currentset.replace(/(^|,)home-button($|,)/,
                                           "$1downloads-button,home-button$2")
         } else {
           currentset = currentset.replace(/(^|,)window-controls($|,)/,
                                           "$1downloads-button,window-controls$2")
         }
         this._setPersist(toolbarResource, currentsetResource, currentset);
       }
-
-      Services.prefs.clearUserPref("browser.download.useToolkitUI");
-      Services.prefs.clearUserPref("browser.library.useNewDownloadsView");
     }
 
 #ifdef XP_WIN
     if (currentUIVersion < 10) {
       // For Windows systems with display set to > 96dpi (i.e. systemDefaultScale
       // will return a value > 1.0), we want to discard any saved full-zoom settings,
       // as we'll now be scaling the content according to the system resolution
       // scale factor (Windows "logical DPI" setting)
--- a/browser/confvars.sh
+++ b/browser/confvars.sh
@@ -56,8 +56,10 @@ MOZ_APP_STATIC_INI=1
 MOZ_WEBAPP_RUNTIME=1
 MOZ_MEDIA_NAVIGATOR=1
 if test "$OS_TARGET" = "WINNT" -o "$OS_TARGET" = "Darwin"; then
   MOZ_FOLD_LIBS=1
 fi
 MOZ_WEBGL_CONFORMANT=1
 # Enable navigator.mozPay
 MOZ_PAY=1
+MOZ_JSDOWNLOADS=1
+
--- a/configure.in
+++ b/configure.in
@@ -8337,16 +8337,21 @@ AC_SUBST(USE_DEPENDENT_LIBS)
 
 AC_SUBST(MOZ_BUILD_ROOT)
 AC_SUBST(MOZ_OS2_TOOLS)
 
 AC_SUBST(MOZ_POST_DSO_LIB_COMMAND)
 AC_SUBST(MOZ_POST_PROGRAM_COMMAND)
 AC_SUBST(MOZ_LINKER_EXTRACT)
 
+AC_SUBST(MOZ_JSDOWNLOADS)
+if test -n "$MOZ_JSDOWNLOADS"; then
+  AC_DEFINE(MOZ_JSDOWNLOADS)
+fi
+
 dnl ========================================================
 dnl = Mac bundle name prefix
 dnl ========================================================
 MOZ_ARG_WITH_STRING(macbundlename-prefix,
 [  --with-macbundlename-prefix=prefix
                           Prefix for MOZ_MACBUNDLE_NAME],
 [ MOZ_MACBUNDLE_NAME_PREFIX="$withval"])
 
--- a/security/manager/ssl/tests/mochitest/mixedcontent/test_bug383369.html
+++ b/security/manager/ssl/tests/mochitest/mixedcontent/test_bug383369.html
@@ -41,18 +41,21 @@
     prefs.setIntPref("folderList", 2);
     prefs.setBoolPref("manager.closeWhenDone", true);
     prefs.setBoolPref("manager.showWhenStarting", false);
   
     var theWindow = window;
 
     var useJSTransfer = false;
     try {
-      useJSTransfer = prefs.getBoolPref("useJSTransfer");
-    } catch (ex) { }
+      // This method throws an exception if the old Download Manager is disabled.
+      Services.downloads.activeDownloadCount;
+    } catch (ex) {
+      useJSTransfer = true;
+    }
 
     if (useJSTransfer) {
       var Downloads = SpecialPowers.Cu.import("resource://gre/modules/Downloads.jsm").Downloads;
       Downloads.getList(Downloads.PUBLIC).then(list => {
         list = SpecialPowers.wrap(list);
         list.addView({
           onDownloadAdded: function (aDownload) {
             list.removeView(this);
--- a/toolkit/components/downloads/nsDownloadManager.cpp
+++ b/toolkit/components/downloads/nsDownloadManager.cpp
@@ -35,16 +35,17 @@
 #include "nsToolkitCompsCID.h"
 
 #include "SQLFunctions.h"
 
 #include "mozilla/Preferences.h"
 
 #ifdef XP_WIN
 #include <shlobj.h>
+#include "nsWindowsHelpers.h"
 #ifdef DOWNLOAD_SCANNER
 #include "nsDownloadScanner.h"
 #endif
 #endif
 
 #ifdef XP_MACOSX
 #include <CoreFoundation/CoreFoundation.h>
 #endif
@@ -932,17 +933,35 @@ nsDownloadManager::Init()
     mozilla::services::GetStringBundleService();
   if (!bundleService)
     return NS_ERROR_FAILURE;
 
   rv = bundleService->CreateBundle(DOWNLOAD_MANAGER_BUNDLE,
                                    getter_AddRefs(mBundle));
   NS_ENSURE_SUCCESS(rv, rv);
 
+#if defined(MOZ_JSDOWNLOADS) && !defined(XP_WIN)
+
+  // When MOZ_JSDOWNLOADS is defined on a non-Windows platform, this component
+  // is always disabled and we can safely omit the initialization code.
+  mUseJSTransfer = true;
+
+#else
+
+#if defined(MOZ_JSDOWNLOADS) && defined(XP_WIN)
+  // When MOZ_JSDOWNLOADS is defined on Windows, this component is disabled
+  // unless we are running in Windows Metro.  The conversion of Windows Metro
+  // to use the JavaScript API for downloads is tracked in bug 906042.
+  mUseJSTransfer = !IsRunningInWindowsMetro();
+#else
+  // When MOZ_JSDOWNLOADS is undefined, we still check the preference that can
+  // be used to enable the JavaScript API during the migration process.
   mUseJSTransfer = Preferences::GetBool(PREF_BD_USEJSTRANSFER, false);
+#endif
+
   if (mUseJSTransfer)
     return NS_OK;
 
   // Clean up any old downloads.rdf files from before Firefox 3
   {
     nsCOMPtr<nsIFile> oldDownloadsFile;
     bool fileExists;
     if (NS_SUCCEEDED(NS_GetSpecialDirectory(NS_APP_DOWNLOADS_50_FILE,
@@ -1003,16 +1022,18 @@ nsDownloadManager::Init()
   (void)mObserverService->AddObserver(this, NS_IOSERVICE_GOING_OFFLINE_TOPIC, true);
   (void)mObserverService->AddObserver(this, NS_IOSERVICE_OFFLINE_STATUS_TOPIC, true);
   (void)mObserverService->AddObserver(this, "last-pb-context-exited", true);
   (void)mObserverService->AddObserver(this, "last-pb-context-exiting", true);
 
   if (history)
     (void)history->AddObserver(this, true);
 
+#endif // defined(MOZ_JSDOWNLOADS) && !defined(XP_WIN)
+
   return NS_OK;
 }
 
 int32_t
 nsDownloadManager::GetRetentionBehavior()
 {
   // We use 0 as the default, which is "remove when done"
   nsresult rv;
--- a/toolkit/components/downloads/test/moz.build
+++ b/toolkit/components/downloads/test/moz.build
@@ -1,11 +1,13 @@
 # -*- Mode: python; c-basic-offset: 4; indent-tabs-mode: nil; tab-width: 40 -*-
 # vim: set filetype=python:
 # This Source Code Form is subject to the terms of the Mozilla Public
 # License, v. 2.0. If a copy of the MPL was not distributed with this
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
-TEST_DIRS += ['browser']
-
 MODULE = 'test_dm'
 
-XPCSHELL_TESTS_MANIFESTS += ['schema_migration/xpcshell.ini', 'unit/xpcshell.ini']
+if not CONFIG['MOZ_JSDOWNLOADS']:
+    TEST_DIRS += ['browser']
+    XPCSHELL_TESTS_MANIFESTS += ['schema_migration/xpcshell.ini']
+
+XPCSHELL_TESTS_MANIFESTS += ['unit/xpcshell.ini']
--- a/toolkit/components/downloads/test/unit/head_download_manager.js
+++ b/toolkit/components/downloads/test/unit/head_download_manager.js
@@ -238,14 +238,15 @@ XPCOMUtils.defineLazyGetter(this, "Servi
 Services.prefs.setBoolPref("browser.download.manager.showAlertOnComplete", false);
 
 do_register_cleanup(function() {
   Services.obs.notifyObservers(null, "quit-application", null);
 });
 
 function oldDownloadManagerDisabled() {
   try {
-    if (Services.prefs.getBoolPref("browser.download.useJSTransfer")) {
-      return true;
-    }
-  } catch (ex) { }
+    // This method throws an exception if the old Download Manager is disabled.
+    Services.downloads.activeDownloadCount;
+  } catch (ex) {
+    return true;
+  }
   return false;
 }
\ No newline at end of file
--- a/toolkit/forgetaboutsite/ForgetAboutSite.jsm
+++ b/toolkit/forgetaboutsite/ForgetAboutSite.jsm
@@ -93,18 +93,21 @@ this.ForgetAboutSite = {
           // Ignore errors from the plugin
         }
       }
     }
 
     // Downloads
     let useJSTransfer = false;
     try {
-      useJSTransfer = Services.prefs.getBoolPref("browser.download.useJSTransfer");
-    } catch(ex) { }
+      // This method throws an exception if the old Download Manager is disabled.
+      Services.downloads.activeDownloadCount;
+    } catch (ex) {
+      useJSTransfer = true;
+    }
 
     if (useJSTransfer) {
       Task.spawn(function() {
         let list = yield Downloads.getList(Downloads.ALL);
         list.removeFinished(download => hasRootDomain(
              NetUtil.newURI(download.source.url).host, aDomain));
       }).then(null, Cu.reportError);
     }
--- a/toolkit/forgetaboutsite/test/unit/head_forgetaboutsite.js
+++ b/toolkit/forgetaboutsite/test/unit/head_forgetaboutsite.js
@@ -25,8 +25,19 @@ function cleanUp()
   for (let i = 0; i < files.length; i++) {
     let file = dirSvc.get("ProfD", Ci.nsIFile);
     file.append(files[i]);
     if (file.exists())
       file.remove(false);
   }
 }
 cleanUp();
+
+function oldDownloadManagerDisabled()
+{
+  try {
+    // This method throws an exception if the old Download Manager is disabled.
+    Services.downloads.activeDownloadCount;
+  } catch (ex) {
+    return true;
+  }
+  return false;
+}
--- a/toolkit/forgetaboutsite/test/unit/test_removeDataFromDomain.js
+++ b/toolkit/forgetaboutsite/test/unit/test_removeDataFromDomain.js
@@ -440,32 +440,44 @@ function test_cookie_not_cleared_with_ur
   add_cookie(TEST_DOMAIN);
   ForgetAboutSite.removeDataFromDomain("mozilla.org");
   check_cookie_exists(TEST_DOMAIN, true);
 }
 
 // Download Manager
 function test_download_history_cleared_with_direct_match()
 {
+  if (oldDownloadManagerDisabled()) {
+    return;
+  }
+
   const TEST_URI = "http://mozilla.org/foo";
   add_download(TEST_URI, false);
   ForgetAboutSite.removeDataFromDomain("mozilla.org");
   check_downloaded(TEST_URI, false);
 }
 
 function test_download_history_cleared_with_subdomain()
 {
+  if (oldDownloadManagerDisabled()) {
+    return;
+  }
+
   const TEST_URI = "http://www.mozilla.org/foo";
   add_download(TEST_URI, false);
   ForgetAboutSite.removeDataFromDomain("mozilla.org");
   check_downloaded(TEST_URI, false);
 }
 
 function test_download_history_not_cleared_with_active_direct_match()
 {
+  if (oldDownloadManagerDisabled()) {
+    return;
+  }
+
   // Tests that downloads marked as active in the db are not deleted from the db
   const TEST_URI = "http://mozilla.org/foo";
   add_download(TEST_URI, true);
   ForgetAboutSite.removeDataFromDomain("mozilla.org");
   check_downloaded(TEST_URI, true);
 
   // Reset state
   let db = Cc["@mozilla.org/download-manager;1"].
--- a/toolkit/forgetaboutsite/test/unit/test_removeDataFromDomain_activeDownloads.js
+++ b/toolkit/forgetaboutsite/test/unit/test_removeDataFromDomain_activeDownloads.js
@@ -77,16 +77,20 @@ function makeGUID() {
   let guid = "";
   for (var i = 0; i < 12; i++)
     guid += Math.floor(Math.random() * 10);
   return guid;
 }
 
 function run_test()
 {
+  if (oldDownloadManagerDisabled()) {
+    return;
+  }
+
   // We add this data to the database first, but we cannot instantiate the
   // download manager service, otherwise these downloads will not be placed in
   // the active downloads array.
 
   // Copy the empty downloads database to our profile directory
   let downloads = do_get_file("downloads.empty.sqlite");
   downloads.copyTo(dirSvc.get("ProfD", Ci.nsIFile), "downloads.sqlite");
 
--- a/toolkit/mozapps/downloads/DownloadTaskbarProgress.jsm
+++ b/toolkit/mozapps/downloads/DownloadTaskbarProgress.jsm
@@ -112,25 +112,16 @@ var DownloadTaskbarProgressUpdater =
    */
   _init: function DTPU_init()
   {
     if (this._initialized) {
       return; // Already initialized
     }
     this._initialized = true;
 
-    // Taskbar progress is disabled until this component is updated to use the
-    // asynchronous JavaScript API for downloads.
-    try {
-      if (Services.prefs.getBoolPref("browser.download.useJSTransfer")) {
-        DownloadTaskbarProgressUpdater = null;
-        return;
-      }
-    } catch (ex) { }
-
     if (kTaskbarIDWin in Cc) {
       this._taskbar = Cc[kTaskbarIDWin].getService(Ci.nsIWinTaskbar);
       if (!this._taskbar.available) {
         // The Windows version is probably too old
         DownloadTaskbarProgressUpdater = null;
         return;
       }
     } else if (kTaskbarIDMac in Cc) {
--- a/toolkit/mozapps/downloads/tests/chrome/test_taskbarprogress_service.xul
+++ b/toolkit/mozapps/downloads/tests/chrome/test_taskbarprogress_service.xul
@@ -24,16 +24,22 @@ const DOWNLOAD_MANAGER_URL = "chrome://m
 const DLMGR_UI_DONE = "download-manager-ui-done";
 
 Components.utils.import("resource://gre/modules/Services.jsm");
 
 let DownloadTaskbarProgress, TaskbarService, observerService, wwatch, chromeWindow;
 let gGen = null;
 
 function test() {
+  var dmui = getDMUI();
+  if (!dmui) {
+    todo(false, "skip test for toolkit download manager UI");
+    return;
+  }
+
   let isWin7OrHigher = false;
   try {
     let version = Cc["@mozilla.org/system-info;1"]
                     .getService(Ci.nsIPropertyBag2)
                     .getProperty("version");
     isWin7OrHigher = (parseFloat(version) >= 6.1);
   } catch (ex) { }
 
--- a/toolkit/mozapps/downloads/tests/chrome/utils.js
+++ b/toolkit/mozapps/downloads/tests/chrome/utils.js
@@ -18,20 +18,21 @@ Components.utils.import("resource://gre/
  * SeaMonkey doesn't package that version but an own implementation that calls
  * different UI), then returns false (see bug 483781).
  *
  * @returns toolkit's nsIDownloadManagerUI implementation or false if not found
  */
 function getDMUI()
 {
   try {
-    if (Services.prefs.getBoolPref("browser.download.useJSTransfer")) {
-      return false;
-    }
-  } catch (ex) { }
+    // This method throws an exception if the old Download Manager is disabled.
+    Services.downloads.activeDownloadCount;
+  } catch (ex) {
+    return false;
+  }
   if (Components.classesByID["{7dfdf0d1-aff6-4a34-bad1-d0fe74601642}"])
     return Components.classesByID["{7dfdf0d1-aff6-4a34-bad1-d0fe74601642}"].
            getService(Ci.nsIDownloadManagerUI);
   return false;
 }
 
 /**
  * Adds a live download to the download manager.
--- a/uriloader/exthandler/tests/moz.build
+++ b/uriloader/exthandler/tests/moz.build
@@ -9,17 +9,20 @@ DIRS += ['mochitest']
 FAIL_ON_WARNINGS = True
 
 MODULE = 'test_uriloader_exthandler'
 
 XPCSHELL_TESTS_MANIFESTS += ['unit/xpcshell.ini']
 
 #FIXME/bug 575918: out-of-process xpcshell is broken on OS X
 if CONFIG['OS_ARCH'] != 'Darwin':
-    XPCSHELL_TESTS_MANIFESTS += ['unit_ipc/xpcshell.ini']
+    # The encoding test is already implemented in the Downloads API by a set of
+    # test cases with the string "content_encoding" in their names.
+    if not CONFIG['MOZ_JSDOWNLOADS']:
+        XPCSHELL_TESTS_MANIFESTS += ['unit_ipc/xpcshell.ini']
 
 sources = [
     'WriteArgument',
 ]
 
 CPP_SOURCES += [
     '%s.cpp' % s for s in sources
 ]