toolkit/library/nsStaticXULComponents.cpp

Thu, 22 Jan 2015 13:21:57 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Thu, 22 Jan 2015 13:21:57 +0100
branch
TOR_BUG_9701
changeset 15
b8a032363ba2
permissions
-rw-r--r--

Incorporate requested changes from Mozilla in review:
https://bugzilla.mozilla.org/show_bug.cgi?id=1123480#c6

michael@0 1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
michael@0 2 /* This Source Code Form is subject to the terms of the Mozilla Public
michael@0 3 * License, v. 2.0. If a copy of the MPL was not distributed with this
michael@0 4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
michael@0 5
michael@0 6 #include "mozilla/Module.h"
michael@0 7 #include "nsXPCOM.h"
michael@0 8 #include "nsMemory.h"
michael@0 9
michael@0 10 #ifdef MOZ_AUTH_EXTENSION
michael@0 11 #define AUTH_MODULE MODULE(nsAuthModule)
michael@0 12 #else
michael@0 13 #define AUTH_MODULE
michael@0 14 #endif
michael@0 15
michael@0 16 #ifdef MOZ_PERMISSIONS
michael@0 17 #define PERMISSIONS_MODULES \
michael@0 18 MODULE(nsCookieModule) \
michael@0 19 MODULE(nsPermissionsModule)
michael@0 20 #else
michael@0 21 #define PERMISSIONS_MODULES
michael@0 22 #endif
michael@0 23
michael@0 24 #ifdef MOZ_UNIVERSALCHARDET
michael@0 25 #define UNIVERSALCHARDET_MODULE MODULE(nsUniversalCharDetModule)
michael@0 26 #else
michael@0 27 #define UNIVERSALCHARDET_MODULE
michael@0 28 #endif
michael@0 29
michael@0 30 #ifdef XP_WIN
michael@0 31 # define WIDGET_MODULES MODULE(nsWidgetModule)
michael@0 32 #elif defined(XP_MACOSX)
michael@0 33 # define WIDGET_MODULES MODULE(nsWidgetMacModule)
michael@0 34 #elif defined(MOZ_WIDGET_GTK)
michael@0 35 # define WIDGET_MODULES MODULE(nsWidgetGtk2Module)
michael@0 36 #elif defined(MOZ_WIDGET_QT)
michael@0 37 # define WIDGET_MODULES MODULE(nsWidgetQtModule)
michael@0 38 #elif defined(MOZ_WIDGET_ANDROID)
michael@0 39 # define WIDGET_MODULES MODULE(nsWidgetAndroidModule)
michael@0 40 #elif defined(MOZ_WIDGET_GONK)
michael@0 41 # define WIDGET_MODULES MODULE(nsWidgetGonkModule)
michael@0 42 #else
michael@0 43 # error Unknown widget module.
michael@0 44 #endif
michael@0 45
michael@0 46 #ifndef MOZ_B2G
michael@0 47 #define CONTENT_PROCESS_WIDGET_MODULES MODULE(nsContentProcessWidgetModule)
michael@0 48 #else
michael@0 49 #define CONTENT_PROCESS_WIDGET_MODULES
michael@0 50 #endif
michael@0 51
michael@0 52 #ifdef ICON_DECODER
michael@0 53 #define ICON_MODULE MODULE(nsIconDecoderModule)
michael@0 54 #else
michael@0 55 #define ICON_MODULE
michael@0 56 #endif
michael@0 57
michael@0 58 #ifdef MOZ_ENABLE_XREMOTE
michael@0 59 #define XREMOTE_MODULES MODULE(RemoteServiceModule)
michael@0 60 #else
michael@0 61 #define XREMOTE_MODULES
michael@0 62 #endif
michael@0 63
michael@0 64 #ifdef MOZ_PREF_EXTENSIONS
michael@0 65 #define SYSTEMPREF_MODULES MODULE(nsAutoConfigModule)
michael@0 66 #else
michael@0 67 #define SYSTEMPREF_MODULES
michael@0 68 #endif
michael@0 69
michael@0 70 #ifdef ENABLE_LAYOUTDEBUG
michael@0 71 #define LAYOUT_DEBUG_MODULE MODULE(nsLayoutDebugModule)
michael@0 72 #else
michael@0 73 #define LAYOUT_DEBUG_MODULE
michael@0 74 #endif
michael@0 75
michael@0 76 #ifdef MOZ_JSDEBUGGER
michael@0 77 #define JSDEBUGGER_MODULES \
michael@0 78 MODULE(JavaScript_Debugger)
michael@0 79 #else
michael@0 80 #define JSDEBUGGER_MODULES
michael@0 81 #endif
michael@0 82
michael@0 83 #if defined(MOZ_FILEVIEW) && defined(MOZ_XUL)
michael@0 84 #define FILEVIEW_MODULE MODULE(nsFileViewModule)
michael@0 85 #else
michael@0 86 #define FILEVIEW_MODULE
michael@0 87 #endif
michael@0 88
michael@0 89 #ifdef MOZ_ZIPWRITER
michael@0 90 #define ZIPWRITER_MODULE MODULE(ZipWriterModule)
michael@0 91 #else
michael@0 92 #define ZIPWRITER_MODULE
michael@0 93 #endif
michael@0 94
michael@0 95 #ifdef MOZ_PLACES
michael@0 96 #define PLACES_MODULES \
michael@0 97 MODULE(nsPlacesModule)
michael@0 98 #else
michael@0 99 #define PLACES_MODULES
michael@0 100 #endif
michael@0 101
michael@0 102 #ifdef MOZ_XUL
michael@0 103 #define XULENABLED_MODULES \
michael@0 104 MODULE(tkAutoCompleteModule) \
michael@0 105 MODULE(satchel) \
michael@0 106 MODULE(PKI)
michael@0 107 #else
michael@0 108 #define XULENABLED_MODULES
michael@0 109 #endif
michael@0 110
michael@0 111 #ifdef MOZ_SPELLCHECK
michael@0 112 #define SPELLCHECK_MODULE MODULE(mozSpellCheckerModule)
michael@0 113 #else
michael@0 114 #define SPELLCHECK_MODULE
michael@0 115 #endif
michael@0 116
michael@0 117 #ifdef MOZ_XUL
michael@0 118 #ifdef MOZ_WIDGET_GTK
michael@0 119 #define UNIXPROXY_MODULE MODULE(nsUnixProxyModule)
michael@0 120 #endif
michael@0 121 #if defined(MOZ_WIDGET_QT)
michael@0 122 #define UNIXPROXY_MODULE MODULE(nsUnixProxyModule)
michael@0 123 #endif
michael@0 124 #endif
michael@0 125 #ifndef UNIXPROXY_MODULE
michael@0 126 #define UNIXPROXY_MODULE
michael@0 127 #endif
michael@0 128
michael@0 129 #if defined(XP_MACOSX)
michael@0 130 #define OSXPROXY_MODULE MODULE(nsOSXProxyModule)
michael@0 131 #else
michael@0 132 #define OSXPROXY_MODULE
michael@0 133 #endif
michael@0 134
michael@0 135 #if defined(XP_WIN)
michael@0 136 #define WINDOWSPROXY_MODULE MODULE(nsWindowsProxyModule)
michael@0 137 #else
michael@0 138 #define WINDOWSPROXY_MODULE
michael@0 139 #endif
michael@0 140
michael@0 141 #if defined(MOZ_WIDGET_ANDROID)
michael@0 142 #define ANDROIDPROXY_MODULE MODULE(nsAndroidProxyModule)
michael@0 143 #else
michael@0 144 #define ANDROIDPROXY_MODULE
michael@0 145 #endif
michael@0 146
michael@0 147 #if defined(BUILD_CTYPES)
michael@0 148 #define JSCTYPES_MODULE MODULE(jsctypes)
michael@0 149 #else
michael@0 150 #define JSCTYPES_MODULE
michael@0 151 #endif
michael@0 152
michael@0 153 #ifndef MOZ_APP_COMPONENT_MODULES
michael@0 154 #if defined(MOZ_APP_COMPONENT_INCLUDE)
michael@0 155 #include MOZ_APP_COMPONENT_INCLUDE
michael@0 156 #define MOZ_APP_COMPONENT_MODULES APP_COMPONENT_MODULES
michael@0 157 #else
michael@0 158 #define MOZ_APP_COMPONENT_MODULES
michael@0 159 #endif
michael@0 160 #endif
michael@0 161
michael@0 162 #if defined(MOZ_ENABLE_PROFILER_SPS)
michael@0 163 #define PROFILER_MODULE MODULE(nsProfilerModule)
michael@0 164 #else
michael@0 165 #define PROFILER_MODULE
michael@0 166 #endif
michael@0 167
michael@0 168 #if defined(MOZ_WEBRTC)
michael@0 169 #define PEERCONNECTION_MODULE MODULE(peerconnection)
michael@0 170 #else
michael@0 171 #define PEERCONNECTION_MODULE
michael@0 172 #endif
michael@0 173
michael@0 174 #if defined(MOZ_GIO_COMPONENT)
michael@0 175 #define GIO_MODULE MODULE(nsGIOModule)
michael@0 176 #else
michael@0 177 #define GIO_MODULE
michael@0 178 #endif
michael@0 179
michael@0 180 #if defined(MOZ_SYNTH_PICO)
michael@0 181 #define SYNTH_PICO_MODULE MODULE(synthpico)
michael@0 182 #else
michael@0 183 #define SYNTH_PICO_MODULE
michael@0 184 #endif
michael@0 185
michael@0 186 #define XUL_MODULES \
michael@0 187 MODULE(nsUConvModule) \
michael@0 188 MODULE(nsI18nModule) \
michael@0 189 MODULE(nsChardetModule) \
michael@0 190 UNIVERSALCHARDET_MODULE \
michael@0 191 MODULE(necko) \
michael@0 192 PERMISSIONS_MODULES \
michael@0 193 AUTH_MODULE \
michael@0 194 MODULE(nsJarModule) \
michael@0 195 ZIPWRITER_MODULE \
michael@0 196 MODULE(StartupCacheModule) \
michael@0 197 MODULE(nsPrefModule) \
michael@0 198 MODULE(nsRDFModule) \
michael@0 199 MODULE(nsWindowDataSourceModule) \
michael@0 200 MODULE(nsParserModule) \
michael@0 201 MODULE(nsImageLib2Module) \
michael@0 202 MODULE(nsMediaSnifferModule) \
michael@0 203 MODULE(nsGfxModule) \
michael@0 204 PROFILER_MODULE \
michael@0 205 WIDGET_MODULES \
michael@0 206 CONTENT_PROCESS_WIDGET_MODULES \
michael@0 207 ICON_MODULE \
michael@0 208 MODULE(nsPluginModule) \
michael@0 209 MODULE(nsLayoutModule) \
michael@0 210 MODULE(docshell_provider) \
michael@0 211 MODULE(embedcomponents) \
michael@0 212 MODULE(Browser_Embedding_Module) \
michael@0 213 MODULE(appshell) \
michael@0 214 MODULE(nsTransactionManagerModule) \
michael@0 215 MODULE(nsComposerModule) \
michael@0 216 MODULE(application) \
michael@0 217 MODULE(Apprunner) \
michael@0 218 MODULE(CommandLineModule) \
michael@0 219 FILEVIEW_MODULE \
michael@0 220 MODULE(mozStorageModule) \
michael@0 221 PLACES_MODULES \
michael@0 222 XULENABLED_MODULES \
michael@0 223 MODULE(nsToolkitCompsModule) \
michael@0 224 XREMOTE_MODULES \
michael@0 225 JSDEBUGGER_MODULES \
michael@0 226 MODULE(BOOT) \
michael@0 227 MODULE(NSS) \
michael@0 228 SYSTEMPREF_MODULES \
michael@0 229 SPELLCHECK_MODULE \
michael@0 230 LAYOUT_DEBUG_MODULE \
michael@0 231 UNIXPROXY_MODULE \
michael@0 232 OSXPROXY_MODULE \
michael@0 233 WINDOWSPROXY_MODULE \
michael@0 234 ANDROIDPROXY_MODULE \
michael@0 235 JSCTYPES_MODULE \
michael@0 236 MODULE(jsreflect) \
michael@0 237 MODULE(jsperf) \
michael@0 238 MODULE(identity) \
michael@0 239 MODULE(nsServicesCryptoModule) \
michael@0 240 MOZ_APP_COMPONENT_MODULES \
michael@0 241 MODULE(nsTelemetryModule) \
michael@0 242 MODULE(jsinspector) \
michael@0 243 MODULE(jsdebugger) \
michael@0 244 PEERCONNECTION_MODULE \
michael@0 245 GIO_MODULE \
michael@0 246 SYNTH_PICO_MODULE \
michael@0 247 MODULE(DiskSpaceWatcherModule) \
michael@0 248 /* end of list */
michael@0 249
michael@0 250 #define MODULE(_name) \
michael@0 251 NSMODULE_DECL(_name);
michael@0 252
michael@0 253 XUL_MODULES
michael@0 254
michael@0 255 #ifdef MOZ_WIDGET_GONK
michael@0 256 MODULE(WifiProxyServiceModule)
michael@0 257 MODULE(NetworkWorkerModule)
michael@0 258 #endif
michael@0 259
michael@0 260 #undef MODULE
michael@0 261
michael@0 262 #define MODULE(_name) \
michael@0 263 &NSMODULE_NAME(_name),
michael@0 264
michael@0 265 extern const mozilla::Module *const *const kPStaticModules[] = {
michael@0 266 XUL_MODULES
michael@0 267 #ifdef MOZ_WIDGET_GONK
michael@0 268 MODULE(WifiProxyServiceModule)
michael@0 269 MODULE(NetworkWorkerModule)
michael@0 270 #endif
michael@0 271 nullptr
michael@0 272 };
michael@0 273
michael@0 274 #undef MODULE

mercurial