diff options
Diffstat (limited to 'dom/indexedDB/IndexedDatabaseManager.cpp')
-rw-r--r-- | dom/indexedDB/IndexedDatabaseManager.cpp | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/dom/indexedDB/IndexedDatabaseManager.cpp b/dom/indexedDB/IndexedDatabaseManager.cpp index f65381fe8e..62ba51c086 100644 --- a/dom/indexedDB/IndexedDatabaseManager.cpp +++ b/dom/indexedDB/IndexedDatabaseManager.cpp @@ -153,7 +153,7 @@ const char kPrefMaxSerilizedMsgSize[] = IDB_PREF_BRANCH_ROOT "maxSerializedMsgSi const char kPrefLoggingEnabled[] = IDB_PREF_LOGGING_BRANCH_ROOT "enabled"; const char kPrefLoggingDetails[] = IDB_PREF_LOGGING_BRANCH_ROOT "details"; -#if defined(DEBUG) || defined(MOZ_ENABLE_PROFILER_SPS) +#if defined(DEBUG) const char kPrefLoggingProfiler[] = IDB_PREF_LOGGING_BRANCH_ROOT "profiler-marks"; #endif @@ -415,10 +415,7 @@ IndexedDatabaseManager::Init() Preferences::RegisterCallback(LoggingModePrefChangedCallback, kPrefLoggingDetails); -#ifdef MOZ_ENABLE_PROFILER_SPS - Preferences::RegisterCallback(LoggingModePrefChangedCallback, - kPrefLoggingProfiler); -#endif + Preferences::RegisterCallbackAndCall(LoggingModePrefChangedCallback, kPrefLoggingEnabled); @@ -479,10 +476,6 @@ IndexedDatabaseManager::Destroy() Preferences::UnregisterCallback(LoggingModePrefChangedCallback, kPrefLoggingDetails); -#ifdef MOZ_ENABLE_PROFILER_SPS - Preferences::UnregisterCallback(LoggingModePrefChangedCallback, - kPrefLoggingProfiler); -#endif Preferences::UnregisterCallback(LoggingModePrefChangedCallback, kPrefLoggingEnabled); @@ -1060,15 +1053,13 @@ IndexedDatabaseManager::LoggingModePrefChangedCallback( } bool useProfiler = -#if defined(DEBUG) || defined(MOZ_ENABLE_PROFILER_SPS) +#if defined(DEBUG) Preferences::GetBool(kPrefLoggingProfiler); -#if !defined(MOZ_ENABLE_PROFILER_SPS) if (useProfiler) { NS_WARNING("IndexedDB cannot create profiler marks because this build does " "not have profiler extensions enabled!"); useProfiler = false; } -#endif #else false; #endif |