Bug 398810 - "Remove MOZILLA_1_8_BRANCH ifdefs from core on trunk" (metric extension only) [p=mh+mozilla@glandium.org (Mike Hommey) r=pete (NPOTB)]
authorreed@reedloden.com
Fri, 09 May 2008 20:46:47 -0700
changeset 15103 4b0fd4528cac8676adecf1a53ea8e4849f396d08
parent 15102 399bd322d907cfb303d837b5edc7901d79707c1a
child 15104 8d2b6627e199b24ca08846470a2d4606e6378698
push id27
push userjorendorff@mozilla.com
push dateTue, 13 May 2008 14:57:59 +0000
treeherdermozilla-central@fbb8cd8a9f55 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerspete
bugs398810
milestone1.9pre
Bug 398810 - "Remove MOZILLA_1_8_BRANCH ifdefs from core on trunk" (metric extension only) [p=mh+mozilla@glandium.org (Mike Hommey) r=pete (NPOTB)]
extensions/metrics/build/nsMetricsModule.cpp
extensions/metrics/src/nsLoadCollector.cpp
extensions/metrics/src/nsMetricsService.cpp
extensions/metrics/test/TestMetricsConfig.cpp
--- a/extensions/metrics/build/nsMetricsModule.cpp
+++ b/extensions/metrics/build/nsMetricsModule.cpp
@@ -43,19 +43,17 @@
 #include "nsProfileCollector.h"
 #include "nsUICommandCollector.h"
 #include "nsAutoCompleteCollector.h"
 #include "nsIGenericFactory.h"
 #include "nsICategoryManager.h"
 #include "nsServiceManagerUtils.h"
 #include "nsCOMPtr.h"
 #include "nsXPCOMCID.h"
-#ifndef MOZILLA_1_8_BRANCH
 #include "nsIClassInfoImpl.h"
-#endif
 
 NS_DECL_CLASSINFO(nsMetricsService)
 
 #define COLLECTOR_CONTRACTID(type) \
   "@mozilla.org/extensions/metrics/collector;1?name=" type ":" NS_METRICS_NAMESPACE
 
 static NS_METHOD
 nsMetricsServiceRegisterSelf(nsIComponentManager *compMgr,
--- a/extensions/metrics/src/nsLoadCollector.cpp
+++ b/extensions/metrics/src/nsLoadCollector.cpp
@@ -47,38 +47,17 @@
 #include "nsIChannel.h"
 #include "nsIDOMWindow.h"
 #include "nsIInterfaceRequestorUtils.h"
 #include "nsServiceManagerUtils.h"
 #include "nsIURI.h"
 #include "nsIDOMDocument.h"
 
 // Hack around internal string usage in nsIDocument.h on the branch
-#ifdef MOZILLA_1_8_BRANCH
-// nsAFlat[C]String is a deprecated synonym for ns[C]String
-typedef nsString nsAFlatString;
-typedef nsCString nsAFlatCString;
-// nsXPIDLCString is a subclass of nsCString, but they're equivalent for the
-// purposes of nsIDocument.h.
-typedef nsCString nsXPIDLCString;
-// This utility method isn't in the string glue on the branch.
-inline void CopyASCIItoUCS2(const nsACString &src, nsAString &dest) {
-  NS_CStringToUTF16(src, NS_CSTRING_ENCODING_ASCII, dest);
-}
-// Suppress inclusion of these headers
-#define nsAString_h___
-#define nsString_h___
-#define nsReadableUtils_h___
-#endif
 #include "nsIDocument.h"
-#ifdef MOZILLA_1_8_BRANCH
-#undef nsAString_h___
-#undef nsString_h___
-#undef nsReadableUtils_h___
-#endif
 
 // This is needed to gain access to the LOAD_ defines in this file.
 #define MOZILLA_INTERNAL_API
 #include "nsDocShellLoadTypes.h"
 #undef MOZILLA_INTERNAL_API
 
 //-----------------------------------------------------------------------------
 
@@ -501,19 +480,16 @@ nsLoadCollector::OnDetach()
 
 NS_IMETHODIMP
 nsLoadCollector::OnNewLog()
 {
   return NS_OK;
 }
 
 NS_IMPL_NSIDOCUMENTOBSERVER_LOAD_STUB(nsLoadCollector)
-#ifdef MOZILLA_1_8_BRANCH
-NS_IMPL_NSIDOCUMENTOBSERVER_REFLOW_STUB(nsLoadCollector)
-#endif
 NS_IMPL_NSIDOCUMENTOBSERVER_STATE_STUB(nsLoadCollector)
 NS_IMPL_NSIDOCUMENTOBSERVER_CONTENT(nsLoadCollector)
 NS_IMPL_NSIDOCUMENTOBSERVER_STYLE_STUB(nsLoadCollector)
 
 void
 nsLoadCollector::BeginUpdate(nsIDocument *document, nsUpdateType updateType)
 {
 }
--- a/extensions/metrics/src/nsMetricsService.cpp
+++ b/extensions/metrics/src/nsMetricsService.cpp
@@ -70,19 +70,17 @@
 #include "nsIHttpProtocolHandler.h"
 #include "nsIIOService.h"
 #include "nsMultiplexInputStream.h"
 #include "prtime.h"
 #include "prmem.h"
 #include "prprf.h"
 #include "prrng.h"
 #include "bzlib.h"
-#ifndef MOZILLA_1_8_BRANCH
 #include "nsIClassInfoImpl.h"
-#endif
 #include "nsIDocShellTreeItem.h"
 #include "nsDocShellCID.h"
 #include "nsMemory.h"
 #include "nsIInterfaceRequestor.h"
 #include "nsIInterfaceRequestorUtils.h"
 #include "nsIX509Cert.h"
 #include "nsAutoPtr.h"
 #include "nsIDOMWindow.h"
--- a/extensions/metrics/test/TestMetricsConfig.cpp
+++ b/extensions/metrics/test/TestMetricsConfig.cpp
@@ -38,19 +38,17 @@
 
 // Unit test for nsMetricsConfig
 
 #include "TestCommon.h"
 #include "nsMetricsConfig.h"
 #include "nsMetricsService.h"
 #include "nsXPCOM.h"
 #include "nsILocalFile.h"
-#ifndef MOZILLA_1_8_BRANCH
 #include "nsIClassInfoImpl.h"
-#endif
 
 #include <stdio.h>
 
 // This singleton must exist in any code that links against libmetrics_s.
 // TODO: find a way to declare this in src/ while still allowing it to be
 // visible to nsMetricsModule.
 NS_DECL_CLASSINFO(nsMetricsService)