Trying to reland only the refactoring changes from bug 392251 without the actual distro bundles code, to see if that affects Ts (original r=dmills)
authorbenjamin@smedbergs.us
Tue, 04 Sep 2007 05:55:29 -0700
changeset 5629 5367c71006e2463c02611eb63cb292faf758ed3b
parent 5628 18a1dd5c569707949fac0077c02f1e0f3fb49871
child 5630 31d545e4c084fea59d63aad96b2dd211c6894ef8
push idunknown
push userunknown
push dateunknown
reviewersdmills
bugs392251
milestone1.9a8pre
Trying to reland only the refactoring changes from bug 392251 without the actual distro bundles code, to see if that affects Ts (original r=dmills)
toolkit/xre/nsXREDirProvider.cpp
toolkit/xre/nsXREDirProvider.h
--- a/toolkit/xre/nsXREDirProvider.cpp
+++ b/toolkit/xre/nsXREDirProvider.cpp
@@ -40,16 +40,17 @@
  * ***** END LICENSE BLOCK ***** */
 
 #include "nsAppRunner.h"
 #include "nsXREDirProvider.h"
 
 #include "jsapi.h"
 
 #include "nsIJSContextStack.h"
+#include "nsIDirectoryEnumerator.h"
 #include "nsILocalFile.h"
 #include "nsIObserverService.h"
 #include "nsIProfileChangeStatus.h"
 #include "nsISimpleEnumerator.h"
 #include "nsIToolkitChromeRegistry.h"
 
 #include "nsAppDirectoryServiceDefs.h"
 #include "nsDirectoryServiceDefs.h"
@@ -95,17 +96,18 @@
 #define APP_REGISTRY_NAME "appreg"
 #endif
 
 #define PREF_OVERRIDE_DIRNAME "preferences"
 
 nsXREDirProvider* gDirServiceProvider = nsnull;
 
 nsXREDirProvider::nsXREDirProvider() :
-  mProfileNotified(PR_FALSE)
+  mProfileNotified(PR_FALSE),
+  mExtensionsLoaded(PR_FALSE)
 {
   gDirServiceProvider = this;
 }
 
 nsXREDirProvider::~nsXREDirProvider()
 {
   gDirServiceProvider = nsnull;
 }
@@ -386,161 +388,65 @@ nsXREDirProvider::GetFile(const char* aP
     }
   }
 
   NS_ADDREF(*aFile = file);
   return NS_OK;
 }
 
 static void
-LoadDirsIntoArray(nsIFile* aComponentsList, const char* aSection,
-                  const char *const* aAppendList,
-                  nsCOMArray<nsIFile>& aDirectories)
+LoadPlatformDirectory(nsIFile* aBundleDirectory,
+                      nsCOMArray<nsIFile> &aDirectories)
 {
-  nsINIParser parser;
-  nsCOMPtr<nsILocalFile> lf(do_QueryInterface(aComponentsList));
-  nsresult rv =  parser.Init(lf);
+  nsCOMPtr<nsIFile> platformDir;
+  nsresult rv = aBundleDirectory->Clone(getter_AddRefs(platformDir));
   if (NS_FAILED(rv))
     return;
 
-  NS_NAMED_LITERAL_CSTRING(platform, "platform");
-  NS_NAMED_LITERAL_CSTRING(osTarget, OS_TARGET);
-#ifdef TARGET_OS_ABI
-  NS_NAMED_LITERAL_CSTRING(targetOSABI, TARGET_OS_ABI);
-#endif
-
-  PRInt32 i = 0;
-  do {
-    nsCAutoString buf("Extension");
-    buf.AppendInt(i++);
-
-    nsCAutoString path;
-    rv = parser.GetString(aSection, buf.get(), path);
-    if (NS_FAILED(rv))
-      break;
-
-    nsCOMPtr<nsILocalFile> dir = do_CreateInstance("@mozilla.org/file/local;1", &rv);
-    if (NS_FAILED(rv))
-      continue;
-
-    nsCOMPtr<nsIFile> platformDir;
-#ifdef TARGET_OS_ABI
-    nsCOMPtr<nsIFile> platformABIDir;
-#endif
-    rv = dir->SetPersistentDescriptor(path);
-    if (NS_FAILED(rv))
-      continue;
-
-    rv = dir->Clone(getter_AddRefs(platformDir));
-    if (NS_FAILED(rv))
-      continue;
-
-    platformDir->AppendNative(platform);
-    platformDir->AppendNative(osTarget);
+  platformDir->AppendNative(NS_LITERAL_CSTRING("platform"));
 
 #ifdef TARGET_OS_ABI
-    rv = dir->Clone(getter_AddRefs(platformABIDir));
-    if (NS_FAILED(rv))
-      continue;
-
-    platformABIDir->AppendNative(platform);
-    platformABIDir->AppendNative(targetOSABI);
+  nsCOMPtr<nsIFile> platformABIDir;
+  rv = platformDir->Clone(getter_AddRefs(platformABIDir));
+  if (NS_FAILED(rv))
+    return;
 #endif
 
-    const char* const* a = aAppendList;
-    while (*a) {
-      nsDependentCString directory(*a);
-      dir->AppendNative(directory);
-      platformDir->AppendNative(directory);
-#ifdef TARGET_OS_ABI
-      platformABIDir->AppendNative(directory);
-#endif
-      ++a;
-    }
+  platformDir->AppendNative(NS_LITERAL_CSTRING(OS_TARGET));
 
-    PRBool exists;
-    rv = dir->Exists(&exists);
-    if (NS_SUCCEEDED(rv) && exists)
-      aDirectories.AppendObject(dir);
-
-    rv = platformDir->Exists(&exists);
-    if (NS_SUCCEEDED(rv) && exists)
-      aDirectories.AppendObject(platformDir);
+  PRBool exists;
+  if (NS_SUCCEEDED(platformDir->Exists(&exists)) && exists)
+    aDirectories.AppendObject(platformDir);
 
 #ifdef TARGET_OS_ABI
-    rv = platformABIDir->Exists(&exists);
-    if (NS_SUCCEEDED(rv) && exists)
-      aDirectories.AppendObject(platformABIDir);
+  platformABIDir->AppendNative(NS_LITERAL_CSTRING(TARGET_OS_ABI));
+  if (NS_SUCCEEDED(platformABIDir->Exists(&exists)) && exists)
+    aDirectories.AppendObject(platformABIDir);
 #endif
-  }
-  while (PR_TRUE);
 }
 
-
 static void
-LoadAppPlatformDirIntoArray(nsIFile* aXULAppDir,
+LoadDirsIntoArray(nsCOMArray<nsIFile>& aSourceDirs,
                   const char *const* aAppendList,
                   nsCOMArray<nsIFile>& aDirectories)
 {
-  NS_NAMED_LITERAL_CSTRING(platform, "platform");
-  NS_NAMED_LITERAL_CSTRING(osTarget, OS_TARGET);
-#ifdef TARGET_OS_ABI
-  NS_NAMED_LITERAL_CSTRING(targetOSABI, TARGET_OS_ABI);
-#endif
-
-  nsCOMPtr<nsIFile> dir;
-  nsresult rv = aXULAppDir->Clone(getter_AddRefs(dir));
-  if (NS_FAILED(rv))
-    return;
-
-  nsCOMPtr<nsIFile> platformDir;
-#ifdef TARGET_OS_ABI
-  nsCOMPtr<nsIFile> platformABIDir;
-#endif
-  rv = dir->Clone(getter_AddRefs(platformDir));
-  if (NS_FAILED(rv))
-    return;
-
-  platformDir->AppendNative(platform);
-  platformDir->AppendNative(osTarget);
-
-#ifdef TARGET_OS_ABI
-  rv = dir->Clone(getter_AddRefs(platformABIDir));
-  if (NS_FAILED(rv))
-    return;
+  nsCOMPtr<nsIFile> appended;
+  PRBool exists;
 
-  platformABIDir->AppendNative(platform);
-  platformABIDir->AppendNative(targetOSABI);
-#endif
-
-  const char* const* a = aAppendList;
-  while (*a) {
-    nsDependentCString directory(*a);
-    dir->AppendNative(directory);
-    platformDir->AppendNative(directory);
-#ifdef TARGET_OS_ABI
-    platformABIDir->AppendNative(directory);
-#endif
-    ++a;
-  }
+  for (PRInt32 i = 0; i < aSourceDirs.Count(); ++i) {
+    aSourceDirs[i]->Clone(getter_AddRefs(appended));
+    if (!appended)
+      continue;
 
-  PRBool exists;
-  rv = dir->Exists(&exists);
-  if (NS_SUCCEEDED(rv) && exists)
-    aDirectories.AppendObject(dir);
+    for (const char *const *a = aAppendList; *a; ++a)
+      appended->AppendNative(nsDependentCString(*a));
 
-  rv = platformDir->Exists(&exists);
-  if (NS_SUCCEEDED(rv) && exists)
-    aDirectories.AppendObject(platformDir);
-
-#ifdef TARGET_OS_ABI
-  rv = platformABIDir->Exists(&exists);
-  if (NS_SUCCEEDED(rv) && exists)
-    aDirectories.AppendObject(platformABIDir);
-#endif
+    if (NS_SUCCEEDED(appended->Exists(&exists)) && exists)
+      aDirectories.AppendObject(appended);
+  }
 }
 
 static const char *const kAppendChromeManifests[] =
   { "chrome.manifest", nsnull };
 
 NS_IMETHODIMP
 nsXREDirProvider::GetFiles(const char* aProperty, nsISimpleEnumerator** aResult)
 {
@@ -573,97 +479,181 @@ nsXREDirProvider::GetFiles(const char* a
 
   rv = NS_NewUnionEnumerator(aResult, appEnum, xreEnum);
   if (NS_FAILED(rv))
     return rv;
 
   return NS_SUCCESS_AGGREGATE_RESULT;
 }
 
+static void
+LoadExtensionDirectories(nsINIParser &parser,
+                         const char *aSection, 
+                         nsCOMArray<nsIFile> &aDirectories)
+{
+  nsresult rv;
+  PRInt32 i = 0;
+  do {
+    nsCAutoString buf("Extension");
+    buf.AppendInt(i++);
+
+    nsCAutoString path;
+    rv = parser.GetString(aSection, buf.get(), path);
+    if (NS_FAILED(rv))
+      return;
+
+    nsCOMPtr<nsILocalFile> dir = do_CreateInstance("@mozilla.org/file/local;1", &rv);
+    if (NS_FAILED(rv))
+      continue;
+
+    rv = dir->SetPersistentDescriptor(path);
+    if (NS_FAILED(rv))
+      continue;
+
+    aDirectories.AppendObject(dir);
+    LoadPlatformDirectory(dir, aDirectories);
+  }
+  while (PR_TRUE);
+}
+
+void
+nsXREDirProvider::LoadBundleDirectories()
+{
+  if (mExtensionsLoaded)
+    return;
+
+  mExtensionsLoaded = PR_TRUE;
+
+  // first load distribution/bundles
+  if (mXULAppDir) {
+    mAppBundleDirectories.AppendObject(mXULAppDir);
+    LoadPlatformDirectory(mXULAppDir, mAppBundleDirectories);
+
+#ifdef LOAD_DISTRO_BUNDLES
+    LoadAppBundleDirs();
+#endif
+  }
+
+  if (mProfileDir && !gSafeMode) {
+    nsCOMPtr<nsIFile> extensionsINI;
+    mProfileDir->Clone(getter_AddRefs(extensionsINI));
+    if (!extensionsINI)
+      return;
+
+    extensionsINI->AppendNative(NS_LITERAL_CSTRING("extensions.ini"));
+
+    nsCOMPtr<nsILocalFile> extensionsINILF =
+      do_QueryInterface(extensionsINI);
+    if (!extensionsINILF)
+      return;
+
+    nsINIParser parser;
+    nsresult rv = parser.Init(extensionsINILF);
+    if (NS_FAILED(rv))
+      return;
+
+    LoadExtensionDirectories(parser, "ExtensionDirs", mExtensionDirectories);
+    LoadExtensionDirectories(parser, "ThemeDirs", mThemeDirectories);
+  }
+}
+
+#ifdef LOAD_DISTRO_BUNDLES
+void
+nsXREDirProvider::LoadAppBundleDirs()
+{
+  if (!mXULAppDir)
+    return;
+
+  nsCOMPtr<nsIFile> dir;
+  nsresult rv = mXULAppDir->Clone(getter_AddRefs(dir));
+  if (NS_FAILED(rv))
+    return;
+  
+  dir->AppendNative(NS_LITERAL_CSTRING("distribution"));
+  dir->AppendNative(NS_LITERAL_CSTRING("bundles"));
+
+  PRBool exists;
+  if (NS_FAILED(dir->Exists(&exists)) || !exists)
+    return;
+
+  nsCOMPtr<nsISimpleEnumerator> e;
+  rv = dir->GetDirectoryEntries(getter_AddRefs(e));
+  if (NS_FAILED(rv))
+    return;
+
+  nsCOMPtr<nsIDirectoryEnumerator> files = do_QueryInterface(e);
+  if (!files)
+    return;
+
+  nsCOMPtr<nsIFile> subdir;
+  while (NS_SUCCEEDED(files->GetNextFile(getter_AddRefs(subdir))) && subdir) {
+    mAppBundleDirectories.AppendObject(subdir);
+    LoadPlatformDirectory(subdir, mAppBundleDirectories);
+  }
+}
+#endif // LOAD_DISTRO_BUNDLES
+
+static const char *const kAppendPrefDir[] = { "defaults", "preferences", nsnull };
+
 nsresult
 nsXREDirProvider::GetFilesInternal(const char* aProperty,
                                    nsISimpleEnumerator** aResult)
 {
   nsresult rv = NS_OK;
   *aResult = nsnull;
 
-  nsCOMPtr<nsIFile> profileFile;
-  if (mProfileDir) {
-    mProfileDir->Clone(getter_AddRefs(profileFile));
-    profileFile->AppendNative(NS_LITERAL_CSTRING("extensions.ini"));
-  }
-
   if (!strcmp(aProperty, XRE_EXTENSIONS_DIR_LIST)) {
     nsCOMArray<nsIFile> directories;
     
-    if (mProfileDir && !gSafeMode) {
-      static const char *const kAppendNothing[] = { nsnull };
+    static const char *const kAppendNothing[] = { nsnull };
 
-      LoadDirsIntoArray(profileFile, "ExtensionDirs",
-                        kAppendNothing, directories);
-    }
+    LoadBundleDirectories();
+    LoadDirsIntoArray(mAppBundleDirectories,
+                      kAppendNothing, directories);
+    LoadDirsIntoArray(mExtensionDirectories,
+                      kAppendNothing, directories);
 
     rv = NS_NewArrayEnumerator(aResult, directories);
   }
   else if (!strcmp(aProperty, NS_XPCOM_COMPONENT_DIR_LIST)) {
     static const char *const kAppendCompDir[] = { "components", nsnull };
     nsCOMArray<nsIFile> directories;
 
-    if (mXULAppDir) {
-      nsCOMPtr<nsIFile> file;
-      mXULAppDir->Clone(getter_AddRefs(file));
-      file->AppendNative(NS_LITERAL_CSTRING("components"));
-      PRBool exists;
-      if (NS_SUCCEEDED(file->Exists(&exists)) && exists)
-        directories.AppendObject(file);
-
-       LoadAppPlatformDirIntoArray(mXULAppDir, kAppendCompDir, directories);
-    }
-
-    if (mProfileDir && !gSafeMode) {
-      LoadDirsIntoArray(profileFile, "ExtensionDirs",
-                        kAppendCompDir, directories);
-    }
+    LoadBundleDirectories();
+    LoadDirsIntoArray(mAppBundleDirectories,
+                      kAppendCompDir, directories);
+    LoadDirsIntoArray(mExtensionDirectories,
+                      kAppendCompDir, directories);
 
     rv = NS_NewArrayEnumerator(aResult, directories);
   }
   else if (!strcmp(aProperty, NS_APP_PREFS_DEFAULTS_DIR_LIST)) {
-    static const char *const kAppendPrefDir[] = { "defaults", "preferences", nsnull };
     nsCOMArray<nsIFile> directories;
-    PRBool exists;
 
-    if (mXULAppDir) {
-      nsCOMPtr<nsIFile> file;
-      mXULAppDir->Clone(getter_AddRefs(file));
-      file->AppendNative(NS_LITERAL_CSTRING("defaults"));
-      file->AppendNative(NS_LITERAL_CSTRING("preferences"));
-      if (NS_SUCCEEDED(file->Exists(&exists)) && exists)
-        directories.AppendObject(file);
-
-       LoadAppPlatformDirIntoArray(mXULAppDir, kAppendPrefDir, directories);
-    }
+    LoadBundleDirectories();
+    LoadDirsIntoArray(mAppBundleDirectories,
+                      kAppendPrefDir, directories);
 
     rv = NS_NewArrayEnumerator(aResult, directories);
   }
   else if (!strcmp(aProperty, NS_EXT_PREFS_DEFAULTS_DIR_LIST)) {
-    static const char *const kAppendPrefDir[] = { "defaults", "preferences", nsnull };
     nsCOMArray<nsIFile> directories;
-    PRBool exists;
+
+    LoadBundleDirectories();
+    LoadDirsIntoArray(mExtensionDirectories,
+                      kAppendPrefDir, directories);
 
     if (mProfileDir) {
       nsCOMPtr<nsIFile> overrideFile;
       mProfileDir->Clone(getter_AddRefs(overrideFile));
       overrideFile->AppendNative(NS_LITERAL_CSTRING(PREF_OVERRIDE_DIRNAME));
+
+      PRBool exists;
       if (NS_SUCCEEDED(overrideFile->Exists(&exists)) && exists)
         directories.AppendObject(overrideFile);
-
-      if (!gSafeMode) {
-        LoadDirsIntoArray(profileFile, "ExtensionDirs",
-                          kAppendPrefDir, directories);
-      }
     }
 
     rv = NS_NewArrayEnumerator(aResult, directories);
   }
   else if (!strcmp(aProperty, NS_CHROME_MANIFESTS_FILE_LIST)) {
     nsCOMArray<nsIFile> manifests;
 
     nsCOMPtr<nsIFile> manifest;
@@ -673,88 +663,66 @@ nsXREDirProvider::GetFilesInternal(const
 
     if (mXULAppDir) {
       nsCOMPtr<nsIFile> file;
       mXULAppDir->Clone(getter_AddRefs(file));
       file->AppendNative(NS_LITERAL_CSTRING("chrome"));
       PRBool exists;
       if (NS_SUCCEEDED(file->Exists(&exists)) && exists)
         manifests.AppendObject(file);
-
-      mXULAppDir->Clone(getter_AddRefs(file));
-      file->AppendNative(NS_LITERAL_CSTRING("chrome.manifest"));
-      if (NS_SUCCEEDED(file->Exists(&exists)) && exists)
-        manifests.AppendObject(file);
-
-      LoadAppPlatformDirIntoArray(mXULAppDir, kAppendChromeManifests,
-                                  manifests);
     }
 
-    if (mProfileDir && !gSafeMode) {
-      LoadDirsIntoArray(profileFile, "ExtensionDirs",
-                        kAppendChromeManifests, manifests);
-    }
+    LoadBundleDirectories();
+    LoadDirsIntoArray(mAppBundleDirectories,
+                      kAppendChromeManifests,
+                      manifests);
+    LoadDirsIntoArray(mExtensionDirectories,
+                      kAppendChromeManifests,
+                      manifests);
 
     rv = NS_NewArrayEnumerator(aResult, manifests);
   }  
   else if (!strcmp(aProperty, NS_SKIN_MANIFESTS_FILE_LIST)) {
     nsCOMArray<nsIFile> manifests;
-    if (mProfileDir && !gSafeMode) {
-      LoadDirsIntoArray(profileFile, "ThemeDirs",
-                        kAppendChromeManifests, manifests);
-    }
+
+    LoadBundleDirectories();
+    LoadDirsIntoArray(mThemeDirectories,
+                      kAppendChromeManifests, manifests);
 
     rv = NS_NewArrayEnumerator(aResult, manifests);
   }
   else if (!strcmp(aProperty, NS_APP_CHROME_DIR_LIST)) {
     // NS_APP_CHROME_DIR_LIST is only used to get default (native) icons
     // for OS window decoration.
 
     static const char *const kAppendChromeDir[] = { "chrome", nsnull };
     nsCOMArray<nsIFile> directories;
-
-    if (mXULAppDir) {
-      nsCOMPtr<nsIFile> file;
-      mXULAppDir->Clone(getter_AddRefs(file));
-      file->AppendNative(NS_LITERAL_CSTRING("chrome"));
-      PRBool exists;
-      if (NS_SUCCEEDED(file->Exists(&exists)) && exists)
-        directories.AppendObject(file);
-
-      LoadAppPlatformDirIntoArray(mXULAppDir, kAppendChromeDir, directories);
-    }
-
-    if (mProfileDir && !gSafeMode) {
-      LoadDirsIntoArray(profileFile, "ExtensionDirs",
-                        kAppendChromeDir, directories);
-    }
+    LoadBundleDirectories();
+    LoadDirsIntoArray(mAppBundleDirectories,
+                      kAppendChromeDir,
+                      directories);
+    LoadDirsIntoArray(mExtensionDirectories,
+                      kAppendChromeDir,
+                      directories);
 
     rv = NS_NewArrayEnumerator(aResult, directories);
   }
   else if (!strcmp(aProperty, NS_APP_PLUGINS_DIR_LIST)) {
     static const char *const kAppendPlugins[] = { "plugins", nsnull };
     nsCOMArray<nsIFile> directories;
 
     // The root dirserviceprovider does quite a bit for us: we're mainly
     // interested in xulapp and extension-provided plugins.
-    if (mXULAppDir) {
-      nsCOMPtr<nsIFile> file;
-      mXULAppDir->Clone(getter_AddRefs(file));
-      file->AppendNative(NS_LITERAL_CSTRING("plugins"));
-      PRBool exists;
-      if (NS_SUCCEEDED(file->Exists(&exists)) && exists)
-        directories.AppendObject(file);
-
-      LoadAppPlatformDirIntoArray(mXULAppDir, kAppendPlugins, directories);
-    }
-
-    if (mProfileDir && !gSafeMode) {
-      LoadDirsIntoArray(profileFile, "ExtensionDirs",
-                        kAppendPlugins, directories);
-    }
+    LoadBundleDirectories();
+    LoadDirsIntoArray(mAppBundleDirectories,
+                      kAppendPlugins,
+                      directories);
+    LoadDirsIntoArray(mExtensionDirectories,
+                      kAppendPlugins,
+                      directories);
 
     rv = NS_NewArrayEnumerator(aResult, directories);
     NS_ENSURE_SUCCESS(rv, rv);
 
     rv = NS_SUCCESS_AGGREGATE_RESULT;
   }
   else
     rv = NS_ERROR_FAILURE;
--- a/toolkit/xre/nsXREDirProvider.h
+++ b/toolkit/xre/nsXREDirProvider.h
@@ -38,16 +38,19 @@
 
 #ifndef _nsXREDirProvider_h__
 #define _nsXREDirProvider_h__
 
 #include "nsIDirectoryService.h"
 #include "nsIProfileMigrator.h"
 #include "nsILocalFile.h"
 
+#include "nsCOMPtr.h"
+#include "nsCOMArray.h"
+
 class nsXREDirProvider : public nsIDirectoryServiceProvider2,
                          public nsIProfileStartup
 {
 public:
   // we use a custom isupports implementation (no refcount)
   NS_IMETHOD QueryInterface(REFNSIID aIID, void** aInstancePtr);
   NS_IMETHOD_(nsrefcnt) AddRef(void);
   NS_IMETHOD_(nsrefcnt) Release(void);
@@ -111,17 +114,31 @@ public:
   nsresult GetProfileDir(nsIFile* *aResult);
 
 protected:
   nsresult GetFilesInternal(const char* aProperty, nsISimpleEnumerator** aResult);
   static nsresult GetUserDataDirectory(nsILocalFile* *aFile, PRBool aLocal);
   static nsresult EnsureDirectoryExists(nsIFile* aDirectory);
   void EnsureProfileFileExists(nsIFile* aFile);
 
+  // Calculate all bundle directories, including distribution bundles,
+  // extensions, and themes
+  void LoadBundleDirectories();
+
+#ifdef LOAD_DISTRO_BUNDLES
+  void LoadAppBundleDirs();
+#endif
+
+  void Append(nsIFile* aDirectory);
+
   nsCOMPtr<nsIDirectoryServiceProvider> mAppProvider;
   nsCOMPtr<nsILocalFile> mGREDir;
   nsCOMPtr<nsIFile>      mXULAppDir;
   nsCOMPtr<nsIFile>      mProfileDir;
   nsCOMPtr<nsIFile>      mProfileLocalDir;
-  PRBool                 mProfileNotified;
+  PRPackedBool           mProfileNotified;
+  PRPackedBool           mExtensionsLoaded;
+  nsCOMArray<nsIFile>    mAppBundleDirectories;
+  nsCOMArray<nsIFile>    mExtensionDirectories;
+  nsCOMArray<nsIFile>    mThemeDirectories;
 };
 
 #endif